Skip to content
This repository has been archived by the owner on Nov 6, 2020. It is now read-only.

protect unsafety in plainhasher; get more unique hashes #1841

Merged
merged 1 commit into from Aug 5, 2016

Conversation

rphmeier
Copy link
Contributor

@rphmeier rphmeier commented Aug 4, 2016

does a little more work but not too much

@rphmeier rphmeier added the A0-pleasereview 🤓 Pull request needs code review. label Aug 4, 2016
@@ -543,27 +543,37 @@ impl_hash!(H2048, 256);
// Specialized HashMap and HashSet

/// Hasher that just takes 8 bytes of the provided value.
pub struct PlainHasher(u64);
/// May only be used for keys which are 32 bytes.
pub struct PlainHasher {
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

maybe should be #[repr(C)] but probably doesn't have to be.

@coveralls
Copy link

coveralls commented Aug 4, 2016

Coverage Status

Changes Unknown when pulling 03b009f on plain_hasher into * on master*.

@gavofyork gavofyork added A8-looksgood 🦄 Pull request is reviewed well. and removed A0-pleasereview 🤓 Pull request needs code review. labels Aug 5, 2016
@gavofyork gavofyork merged commit b208331 into master Aug 5, 2016
@gavofyork gavofyork deleted the plain_hasher branch August 5, 2016 07:15
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
A8-looksgood 🦄 Pull request is reviewed well.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants