Registry / utility / float-ord

float-ord

JSON →
library0.3.2rscratesunverified

A total ordering for floating-point numbers, handling NaN consistently.

# Cargo.toml [dependencies] float-ord = "0.3.2"
INSTALL
IMPORT
SIG · FLOAT-ORD
F
float-ord
utilityrustv0.3.2
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

FloatOrd
✓ use float_ord::FloatOrd;

Sort a vector of floats using FloatOrd for total ordering.

use float_ord::FloatOrd; fn main() { let mut vec = vec![FloatOrd(1.0), FloatOrd(f64::NAN), FloatOrd(0.5)]; vec.sort(); println!("{:?}", vec); }
Debug
Known issues

No known issues recorded.

Upgrade
Version history
0.3.2latest on crates.io
Audit
Dependencies

No dependency data recorded yet.

Agent activity
4 hits · last 30 days
node
4
Resources
float-ord — cargo add float-ord · libregistry