-
Notifications
You must be signed in to change notification settings - Fork 13.5k
Closed
Labels
A-collectionsArea: `std::collections`Area: `std::collections`B-unstableBlocker: Implemented in the nightly compiler and unstable.Blocker: Implemented in the nightly compiler and unstable.T-libs-apiRelevant to the library API team, which will review and decide on the PR/issue.Relevant to the library API team, which will review and decide on the PR/issue.final-comment-periodIn the final comment period and will be merged soon unless new substantive objections are raised.In the final comment period and will be merged soon unless new substantive objections are raised.
Description
This is a tracking issue for the unstable hashmap_hasher
feature in the standard library. This provides the ability to create a HashMap with a custom hashing implementation that abides by the HashState
trait. This has already been used quite a bit in the compiler itself as well as in Servo I believe.
Some notable points to consider:
- Is an extra
HashState
trait really necessary? - Is the naming of
HashState
correct? - Is the aggressive use of
Default
appropriate here? - Can the
new
constructor be leveraged to create hash maps that use a hasher implementingDefault
? Right now thenew
constructor only works withRandomState
. - How ergonomic is it to create a hash map using a custom
Hasher
implementation? In theory it should be quite ergonomic.
cc @gankro
Metadata
Metadata
Assignees
Labels
A-collectionsArea: `std::collections`Area: `std::collections`B-unstableBlocker: Implemented in the nightly compiler and unstable.Blocker: Implemented in the nightly compiler and unstable.T-libs-apiRelevant to the library API team, which will review and decide on the PR/issue.Relevant to the library API team, which will review and decide on the PR/issue.final-comment-periodIn the final comment period and will be merged soon unless new substantive objections are raised.In the final comment period and will be merged soon unless new substantive objections are raised.