Type Alias R64

Source
pub type R64 = NoisyFloat<f64, FiniteChecker>;
Expand description

A floating point number behaving like f64 that does not allow NaN or +/- Infinity.

The “R” in the name stands for “Real”, since in Mathematics, the Real numbers do not include NaN or +/- Infinity.

Aliased Type§

struct R64 { /* private fields */ }

Implementations§

Source§

impl R64

Source

pub const fn unchecked_new(value: f64) -> Self

A const constructor that does not check whether value is valid.

WARNING: This constructor does not panic even in debug mode. As always, it is the user’s responsibility to ensure value is valid. Until Rust supports panics in const functions, this constructor is necessary to create a NoisyFloat in a const setting.

Source

pub const fn const_raw(self) -> f64

A const function that returns the underlying float value.