Skip to content

Commit 496b1bc

Browse files
committed
Auto merge of #227 - cuviper:alloc-defaults, r=Amanieu
Hide allocator details and default to Global **This is a breaking change!** We no longer re-export the unstable allocator items from the standard library, nor the stable shims approximating the same. The choice was predicated on the "nightly" feature, but crates that did not set that feature could be forced into it by others in the dependency tree, and then fail for lack of `#![feature(allocator_api)]` when referencing these items. All types have been audited to have a default `A=Global` to make sure the type doesn't need to be named for stable users. Fixes #226. Many of the parallel iterators don't need the `S` hasher or `A` allocator at all if they convert to a tighter inner type upon construction. This has been cleaned up, and those that do still need `A` now default to `A=Global`. `RawTable::with_capacity` and `try_with_capacity` have moved back to being methods for `Global` only. New `with_capacity_in` and `try_with_capacity_in` methods allow custom allocators, with the `alloc` parameter last to match the similar methods on `HashMap` and `HashSet`.
2 parents 9beb06b + dac885a commit 496b1bc

File tree

6 files changed

+226
-161
lines changed

6 files changed

+226
-161
lines changed

0 commit comments

Comments
 (0)