NewYour coding agent can read the release notes before it upgrades.Set up the MCP server →
crates.io · #1 most downloaded on crates.io
A Rust port of Google's SwissTable hash map
Last release 5 months ago
09 May 2026
Release timing varies
gaps range from 3 weeks to 5 months
Nearly every release is documented
notes for 52 of 52 stable releases
4 versions withdrawn
withdrawn after publishing
8 years old
56 releases · first in 2018
Added HashMap::rustc_try_insert
HashMap::rustc_try_insert (#722)Added hash_table::OccupiedEntry::replace_entry_with
hash_table::OccupiedEntry::replace_entry_with (#669)hash_map::{OccupiedEntry::into_entry, VacantEntryRef::insert_entry_with_key} (#670)hash_table::UnsafeIter (#667)iter methods to various HashTable iterators (#667)HashMap::{replace_key,replace_key_unchecked,insert_with_key_unchecked} (#681)into_map methods to all HashMap entry types (#686)into_table methods to all HashTable entry types (#686)#[must_use] to constructors (#697)TryReserveError now implements Error (#698)One column per quarter.
The old names are still present for now, but deprecated.
HashTable methods related to the raw bucket index (#657)VacantEntryRef::insert_with_key (#579)Copy types (#662)get_many_mut family of methods have been renamed to get_disjoint_mutserde_core instead of serde. (#649)collect on rayon parallel iterators. (#652)Bump foldhash, the default hasher, to 0.2.0.
DefaultHashBuilder with a newtype wrapper around foldhash instead of re-exporting it directly.Added Entry::or_default_entry and Entry::or_insert_entry .
Entry::or_default_entry and Entry::or_insert_entry.#[cold]Removed optional dependency on compiler-builtins. This only affects building as part of std .
std.SIMD implementation for LoongArch ( #592 , requires nightly)
match_empty (#607)ExtractIf data structures (#616)hash_map::EntryRef insertion methods K: From<&Q> to &Q: Into<K> (#611)rustc_iter (#605)allocator-api2/nightly feature is no longer enabled by hashbrown/nightly (#606)Marked const fn constructors as rustc_const_stable_indirect when built as part of the standard library.
const fn constructors as rustc_const_stable_indirect when built as
part of the standard library. (#586)This release removes the borsh feature introduced in 0.15.0 because it was found to be incorrectly implemented. Users should use the hashbrown feature
This release removes the borsh feature introduced in 0.15.0 because it was
found to be incorrectly implemented. Users should use the hashbrown feature of
the borsh crate instead which provides the same trait implementations.
Update changelog for v0.15.0, bump cargo.toml
Update changelog for v0.15.0, bump cargo.toml
Rather than just asking @Amanieu to do all this, I decided to help out a bit. Put some question marks in the date field that will need to be replaced once this is actually merged.
Will still need someone to do a proper release for this, but hopefully the changelog is good at least.
This release was yanked due to a broken implementation of the borsh feature.
This update contains breaking changes that remove the raw API with the hope of
centralising on the HashTable API in the future. You can follow the discussion
and progress in #545 to discuss features you think should be added to this API
that were previously only possible on the raw API.
borsh feature with BorshSerialize and BorshDeserialize impls. (#525)Assign impls for HashSet operators. (#529)Default impls for iterator types. (#542)HashTable::iter_hash{,_mut} methods. (#549)Hash{Table,Map,Set}::allocation_size methods. (#553)Debug and FusedIterator for all HashTable iterators. (#561)Iterator::fold for all HashTable iterators. (#561)hash_set::VacantEntry::insert to return OccupiedEntry. (#495)hash_set::Difference::size_hint lower-bound. (#530)HashSet::is_disjoint performance. (#531)equivalent feature is now enabled by default. (#532)HashSet operators now return a set with the same allocator. (#529)ahash feature has been renamed to default-hasher. (#533)Hash{Map,Set}::insert_unique_unchecked is now unsafe. (#556)get_many_mut and related methods was changed. (#562)raw-entry feature, to be eventually removed. (#534, #555)raw feature is removed;
in the future, all code should be using the HashTable API instead. (#531, #546)rykv feature was removed; this is now provided by the rykv crate instead. (#554)HashSet::get_or_insert_owned was removed in favor of get_or_insert_with. (#555)Bump version number in Cargo.toml to 0.14.5
Bump version number in Cargo.toml to 0.14.5
clone_from_impl. (#511)This release was _yanked_ due to a breaking change.
This release was yanked due to a breaking change.
Specialized fold implementation of iterators.
fold implementation of iterators. (#480)ptr::invalid_mut on nightly. (#481)HashTable type which provides a low-level but safe API with explicit hashing.
HashTable type which provides a low-level but safe API with explicit hashing. (#466)Allow serializing HashMaps that use a custom allocator.
HashMaps that use a custom allocator. (#449)Equivalent trait from the equivalent crate. (#442)Clone requirement from custom allocators. (#468)Support for allocator-api2 crate for interfacing with custom allocators on stable.
allocator-api2 crate
for interfacing with custom allocators on stable. (#417)Equivalent trait to look up values without Borrow. (#345)Hash{Map,Set}::raw_table_mut is added which returns a mutable reference. (#404)clear on empty tables. (#428)DrainFilter (drain_filter) has been renamed to ExtractIf and no longer drops remaining
elements when the iterator is dropped. #(374){Map,Set}::raw_table now returns an immutable reference. (#404)VacantEntry and OccupiedEntry now use the default hasher if none is
specified in generics. (#389)RawTable::data_start now returns a NonNull to match RawTable::data_end. (#387)RawIter::{reflect_insert, reflect_remove} are now unsafe. (#429)RawTable::find_potential is renamed to find_or_find_insert_slot and returns an InsertSlot. (#429)RawTable::remove now also returns an InsertSlot. (#429)InsertSlot can be used to insert an element with RawTable::insert_in_slot. (#429)RawIterHash no longer has a lifetime tied to that of the RawTable. (#427)HashSet::raw_table have been relaxed to not require Eq + Hash. (#423)EntryRef::and_replace_entry_with and OccupiedEntryRef::replace_entry_with
were changed to give a &K instead of a &Q to the closure.bumpalo as an allocator with custom wrapper.
Use allocator-api2 feature in bumpalo to use it as an allocator
for hashbrown collections. (#417)Added #[inline(always)] to find_inner.
#[inline(always)] to find_inner. (#375)RawTable::allocation_info for empty tables. (#376)Added Equivalent trait to customize key lookups.
Equivalent trait to customize key lookups. (#350)RawTable::allocation_info which provides information about the memory
usage of a table. (#371)ahash 0.8. (#357)with_hasher_in const. (#355)RawTable API in favor of
safer alternatives:
RawTable::erase_no_drop => Use RawTable::erase or RawTable::remove instead.Bucket::read => Use RawTable::remove instead.Bucket::drop => Use RawTable::erase instead.Bucket::write => Use Bucket::as_mut instead.HashMap allocations don't exceed isize::MAX. (#362)Nothing published for this version
Fixed double-drop in RawTable::clone_from.
RawTable::clone_from. (#348)Added Extend<&'a (K, V)> for HashMap .
Entry API for HashSet. (#342)Extend<&'a (K, V)> for HashMap<K, V, S, A>. (#340)RawTable of a HashMap. (#335)do_alloc to reduce LLVM IR generated. (#341)Fixed underflow in RawIterRange::size_hint.
RawIterRange::size_hint. (#325)Debug for ValuesMut and IntoValues. (#325)Added From<[T; N]> and From<[(K, V); N]> for HashSet and HashMap respectively.
From<[T; N]> and From<[(K, V); N]> for HashSet and HashMap respectively. (#297)allocator() getter to HashMap and HashSet. (#257)insert_unique_unchecked to HashMap and HashSet. (#293)into_keys and into_values to HashMap. (#295)From<array> on HashSet and HashMap. (#298)entry_ref API to HashMap. (#201)find. (#279)BuildHasher::hash_one when feature = "nightly" is enabled. (#292)Debug for HashSet. (#296)get_each_mut to get_many_mut and align API with the stdlib. (#291)RawTable::insert_no_grow unsafe. (#254)static_empty. (#280)Added missing allocator type parameter to HashMap's and HashSet's Clone impls.
HashMap's and HashSet's Clone impls. (#252)Added missing pub modifier to BumpWrapper.
pub modifier to BumpWrapper. (#251)Added safe try_insert_no_grow method to RawTable.
try_insert_no_grow method to RawTable. (#229)bumpalo as an allocator without the nightly feature. (#231)Default for RawTable. (#237)RawTable::get_each_mut, HashMap::get_each_mut, and
HashMap::get_each_key_value_mut. (#239)From<HashMap<T, ()>> for HashSet<T>. (#235)try_insert method to HashMap. (#247)aHash, which was resulting in inconsistent hashes being generated for a key. (#248)This release was _yanked_ due to inconsistent hashes being generated with the nightly feature.
This release was yanked due to inconsistent hashes being generated with the nightly feature. (#248)
RawTable, HashSet and HashMap over an allocator. (#133)RawTable's reserve functions once per key-value. (#204)Added safe methods to RawTable (#202):
RawTable (#202):
get: find and as_refget_mut: find and as_mutinsert_entry: insert and as_mutremove_entry: find and removeerase_entry: find and erasefrom_key_hashed_nocheck's Q: Hash. (#200)RawTable::drain safe. (#201)drain_filter now removes and yields items that do match the predicate, rather than items that don't. This is a breaking change to match the behavior o…
drain_filter now removes and yields items that do match the predicate,
rather than items that don't. This is a breaking change to match the
behavior of the drain_filter methods in std. (#187)replace_entry_with to OccupiedEntry, and and_replace_entry_with to Entry. (#190)FusedIterator and size_hint for DrainFilter. (#188)crossbeam dependency). (#193)ahash dependency to 0.4. (#198)HashMap::with_hasher and HashSet::with_hasher are now const fn. (#195)T: Hash + Eq and S: BuildHasher bounds on HashSet::new,
with_capacity, with_hasher, and with_capacity_and_hasher. (#185)Avoid closures to improve compile times.
Deprecated RawTable::erase_no_drop in favor of erase and remove.
erase and remove to RawTable. (#171)try_with_capacity to RawTable. (#174)RawIter for RawDrain,
RawIntoIter, and RawParIter. (#175)reflect_remove and reflect_insert to RawIter. (#175)drain_filter function to HashSet. (#179)RawTable::erase_no_drop in favor of erase and remove. (#176)insert_no_grow is now exposed under the "raw" feature. (#180)Marked RawTable::par_iter as unsafe.
RawTable::par_iter as unsafe. (#157)HashMap. (#159)K: Eq + Hash bounds on retain. (#163)HashMap changes from rust-lang/rust (#164):
extend_one support on nightly.CollectionAllocErr renamed to TryReserveError.HashSet::get_or_insert_owned.Default for HashSet no longer requires T: Eq + Hash and S: BuildHasher.Added or_insert_with_key to Entry.
or_insert_with_key to Entry. (#152)Clone optimization which was unsound. (#154)const-random by default, which prevented reproducible builds. (#155)repeat function. (#150)NonNull for buckets, which improves codegen for iterators. (#148)Added HashMap::get_key_value_mut.
HashMap::get_key_value_mut. (#145)Clone implementation. (#146)Added a drain_filter function to HashMap.
drain_filter function to HashMap. (#135)ahash dependency to 0.3. (#141)raw_entry can now be used without requiring S: BuildHasher. (#123)RawTable::bucket_index can now be used under the raw feature. (#128)Added an ahash-compile-time-rng feature (enabled by default) which allows disabling the compile-time-rng feature in ahash to work around a Cargo bug.
ahash-compile-time-rng feature (enabled by default) which allows disabling the
compile-time-rng feature in ahash to work around a Cargo bug. (#125)Added an inline-more feature (enabled by default) which allows choosing a tradeoff between runtime performance and compilation time.
inline-more feature (enabled by default) which allows choosing a tradeoff between
runtime performance and compilation time. (#119)Added Entry::insert and RawEntryMut::insert.
Entry::insert and RawEntryMut::insert. (#118)Group::static_empty was changed from a const to a static (#116).Fixed AHash accidentally depending on std.
std. (#110)rand dependency).This release was _yanked_ due to a breaking change for users of no-default-features.
This release was yanked due to a breaking change for users of no-default-features.
RawTable API is available under the "raw" feature. (#108)HashSet. (#98)hashbrown is now fully no_std on recent Rust versions (1.36+). (#96)RawOccupiedEntryMut now properly implements Send and Sync. (#100)lazy_static version. (#92)Resize with a more conservative amount of space after deletions.
Fixed Send trait bounds on IterMut not matching the libstd one.
Send trait bounds on IterMut not matching the libstd one. (#82)Fixed incorrect use of slice in unsafe code.
Changed shrink_to to not panic if min_capacity < capacity.
Inlined non-nightly lowest_set_bit_nonzero.
Use for_each in map Extend and FromIterator.
The code has been updated to Rust 2018 edition. This means that the minimum Rust version has been bumped to 1.31 (2018 edition).
insert_with_hasher to the raw_entry API to allow K: !(Hash + Eq). (#54)#[may_dangle] attributes to match the libstd HashMap. (#46)Rayon parallel iterator support
raw_entry support (#31)#[may_dangle] on nightly (#31)try_reserve support (#31)IterMut. (#31)Fixed non-SSE version of convert_special_to_empty_and_full_to_deleted.
Fixed compile error on nightly.
Fixed subtraction overflow in generic::Group::match_byte.
Fixed a bug in the erase_no_drop implementation.
erase_no_drop implementation. (#26)Make the compiler inline functions more aggressively.
clear segfaults when called on an empty table.
clear segfaults when called on an empty table. (#13)erase_no_drop optimization not triggering in the SSE2 implementation.
erase_no_drop optimization not triggering in the SSE2 implementation. (#3)Send and Sync for hash map and iterator types. (#7)[Unreleased]: https://github.com/rust-lang/hashbrown/compare/v0.15.2...HEAD [v0.15.2]: https://github.com/rust-lang/hashbrown/compare/v0.15.1...v0.15.
Your coding agent can read these notes before it upgrades. Set up the MCP server →