Skip to main content

Powf

Trait Powf 

Source
pub trait Powf {
    // Required method
    fn powf(self, exp: Self) -> Self;
}
Expand description

Method for raising a number by a real number exponent.

The name “powf” is kept for familiarity, even though the exponent doesn’t have to be a floating point number.

Required Methods§

Source

fn powf(self, exp: Self) -> Self

Return self raised to the power of exp.

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.

Implementations on Foreign Types§

Source§

impl Powf for f32

Available on crate feature std, or non-crate feature libm only.
Source§

fn powf(self, exp: f32) -> f32

Source§

impl Powf for f64

Available on crate feature std, or non-crate feature libm only.
Source§

fn powf(self, exp: f64) -> f64

Implementors§