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 function in modules Bool/Int/Char/String #10259
Comments
Cross-referencing at least https://github.com/ocaml/ocaml/pull/8878/files ( |
See my comment here: #10262 (comment) . There's a tension between seeded and unseeded hash functions, and bad name choices in the past prevent us from implementing both in the same module. |
This issue has been open one year with no activity. Consequently, it is being marked with the "stale" label. What this means is that the issue will be automatically closed in 30 days unless more comments are added or the "stale" label is removed. Comments that provide new information on the issue are especially welcome: is it still reproducible? did it appear in other contexts? how critical is it? etc. |
It would be convenient if modules
Bool
/Int
/Char
/String
would provide ahash
function, so that we can pass them to functors such asHashtbl.Make
.Of course, we can use the polymorphic hash function
Hashtbl.hash
for this purpose, or define custom hash function (e.g. the identity for typeint
), but that's less convenient from a user's perspective.Note: module
Float
already provides ahash
function.The text was updated successfully, but these errors were encountered: