4 ms·
The consts are currently defined in modules with the same name as the type, `std::f32::NAN;`. This feature allows them to be associated with the type itself - `
by tatterdemalion 9y ago
The consts are currently defined in modules with the same name as the type, `std::f32::NAN;`. This feature allows them to be associated with the type itself - `f32::NAN`. A small convenience.
- kzrdude 9y agoIt's more than a small convenience. It's a big feature that we can use when designing traits and APIs.
- tatterdemalion 9y agoYes of course (I work on Rust). I mean that the difference between f32::NAN and std::f32::NAN is a small convenience.