Skip to main content

UnorderedHash

Trait UnorderedHash 

Source
pub trait UnorderedHash {
    // Required method
    fn unordered_hash<H>(&self, state: &mut H)
       where H: Hasher;
}
Expand description

Hashing that ignores the order of object entries.

Implementing this is what gives Unordered<T> its Hash impl, keeping it consistent with the PartialEq derived from UnorderedPartialEq.

Required Methods§

Source

fn unordered_hash<H>(&self, state: &mut H)
where H: Hasher,

Feeds this value into state, ignoring object entry order.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§