Repository navigation
v4.0.0
Breaking changes
rapidhash::v3micro/nano output change: input lengths 5-7 were mismatching the intended C++ V3 output. The C++ rapidhash V3 has been yanked and re-released as V3 to fix the bug, and this rust implementation will follow. This changes the hash outputs forrapidhash_v3_micro_inlineandrapidhash_v3_nano_inlinefor inputs of size 5, 6, and 7 bytes.RapidBuildHasherrenamed and refactored toSeedableState.RapidHasher<'s>new lifetime parameter added to support user-defined secrets viaSeedableState.RapidHashMapandRapidHashSetmoved to crate top level for convenience. The top level uses thefast::variants, and thequality::andinner::hashmaps have been removed. They can still be built manually usinginner::RandomStateif required. Thefast::collection variants have been deprecated to be removed in a future major release.
Additions
nightlyfeature which improves str hashing performance by omitting the0xFFsuffix write and adds likely/unlikely hints.SeedableState: a hasher builder which can be seeded with fixed or user-defined secrets. This replacesRapidBuildHasher, but still defaults to random seeds. It is slightly slower thanRandomState.
Performance improvements
- Bounds check elision: Improved
RapidHasherby eliding extra bounds checks in some cases by usingassert_unchecked. - Likely/unlikely hints: Added stable likely/unlikely hints in various places to ensure small inputs are favoured.
MSRV
- MSRV reduced to 1.71.0 from 1.77.0 by removing const usage of
first_chunk.
Full Changelog: v3.1.0...v4.0.0
Main PR: #43