NanLikeInterface

Trait NanLikeInterface 

Source
pub trait NanLikeInterface {
    // Required methods
    fn make_nan_like() -> Self;
    fn is_nan(&self) -> bool;
}
Expand description

Implement check is it nan and constructor with NAN value.

Required Methods§

Source

fn make_nan_like() -> Self

Construct NAN-like. If the type does not have NAN value in codomain of the type it should return default value.

Source

fn is_nan(&self) -> bool

Is current value NAN? Always false if codomain of the type does not have NAN value.

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 NanLikeInterface for f32

Source§

impl NanLikeInterface for f64

Source§

impl NanLikeInterface for i8

Source§

impl NanLikeInterface for i16

Source§

impl NanLikeInterface for i32

Source§

impl NanLikeInterface for i64

Source§

impl NanLikeInterface for i128

Source§

impl NanLikeInterface for isize

Source§

impl NanLikeInterface for u8

Source§

impl NanLikeInterface for u16

Source§

impl NanLikeInterface for u32

Source§

impl NanLikeInterface for u64

Source§

impl NanLikeInterface for u128

Source§

impl NanLikeInterface for usize

Implementors§