Function decorum::hash_float [] [src]

pub fn hash_float<T, H>(value: T, state: &mut H) where
    T: Float + Primitive,
    H: Hasher

Hashes a primitive floating-point value.

To perform the hash, the floating-point value is canonicalized. If NaN or zero, a canonical form is used so that all NaNs result in the same hash and all zeroes (positive and negative) result in the same hash.