Trait float_cmp::Ulps [] [src]

pub trait Ulps {
    type U;
    fn ulps(&self, other: &Self) -> Self::U;
}

A trait for floating point numbers which computes the number of representable values or ULPs (Units of Least Precision) that separate the two given values.

Associated Types

Required Methods

The number of representable values or ULPs (Units of Least Precision) that separate self and other. The result U is an integral value, and will be zero if self and other are exactly equal.

Implementors