Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Hash collisions unhandled in Basic pool #2

Open
insaneinside opened this issue Feb 9, 2017 · 6 comments
Open

Hash collisions unhandled in Basic pool #2

insaneinside opened this issue Feb 9, 2017 · 6 comments

Comments

@insaneinside
Copy link
Owner

insaneinside commented Feb 9, 2017

The symbol pool implemented in basic.rs uses a value's hash as the key to pool's HashMap instance, which effectively bypasses any collision handling that would normally be provided by the map. This design was meant to avoid the overhead and additional complexity of using something like Rc where shared ownership isn't actually required — but clearly needs some rethinking.

@insaneinside
Copy link
Owner Author

insaneinside commented Feb 9, 2017

@Robbepop, thanks for the heads-up here. I think the solution you used in your own string-interner crate might be a good fit here; you're welcome to make a pull request if you're interested (otherwise I'll look at this within a day or two).

@Robbepop
Copy link

Robbepop commented Feb 9, 2017

@insaneinside I forked and tried to build your symtern in order to make the pull request but your crate does not compile at all on my computer. many errors and warnings around non-implemented traits, traits out of scope and non-matched trait bounds. I am using the nightly rust compiler.

@insaneinside
Copy link
Owner Author

My apologies! If you're still interested in taking a stab at this, you should be able to start at the tag "v0.1.0-pre.1" (which corresponds to the latest version on crates.io); I'll take care of any later merge conflicts that result.

@Robbepop
Copy link

Good to know!
I will look at it as soon as I find time. :)

@dralley
Copy link
Contributor

dralley commented Jul 28, 2019

I don't suppose either of you ever got around to this?

@Robbepop
Copy link

@dralley correct

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants