pub trait BetterExponent {
// Required method
fn power(self, number: usize) -> Self;
}
Expand description
Exponents for unsigned integers
§Examples
use lemonmath::helper::BetterExponent;
let x = 2u32.pow(3);
assert_eq!(x, 8);
Required Methods§
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.