pub unsafe trait IsFloat: Sealed + Sized {
// Provided methods
fn is_float() -> bool { ... }
fn is_f32() -> bool { ... }
fn is_f64() -> bool { ... }
fn nan_value() -> Self { ... }
fn is_nan(&self) -> bool
where Self: Sized { ... }
fn is_finite(&self) -> bool
where Self: Sized { ... }
}
Expand description
§Safety
unsafe code downstream relies on the correct is_float call
Provided Methods§
fn is_float() -> bool
fn is_f32() -> bool
fn is_f64() -> bool
fn nan_value() -> Self
fn is_nan(&self) -> boolwhere
Self: Sized,
fn is_finite(&self) -> boolwhere
Self: Sized,
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.