Skip to main content

while_changing_hash

Function while_changing_hash 

Source
pub fn while_changing_hash<T, F, H>(value: T, func: F, hasher: H) -> T
where F: Fn(T) -> T, H: Fn(&T) -> u64,
Expand description

Applies a transformation until a fix point, using a hash function for comparison.

More efficient than while_changing when equality comparison is expensive.