mirror of
https://github.com/odin-lang/Odin.git
synced 2026-10-13 03:27:44 -04:00
Map keys of type `string16` used `default_hasher_string`, which reads the length as a byte count; for a `string16` it counts u16 units, so only the first half of the key was hashed. `cstring16` keys took the same path and were read as a pointer and a length, which crashes. Add `default_hasher_string16` and `default_hasher_cstring16` to the runtime and use them for the generated key hashers, which are also what the runtime and `intrinsics.type_hasher_proc` use.