1
0
Fork
You've already forked murmur3a
0
Implementation of the 32 bit variant of the Murmur3 non-cryptographic hash function. https://hexdocs.pm/murmur3a/
  • Gleam 84.7%
  • Nix 13.6%
  • JavaScript 1.7%
2026年02月13日 23:17:01 -05:00
LICENSES feat: Hello World 2025年01月19日 15:42:45 +01:00
src Byte hashing go brrr 2026年02月13日 22:15:01 -05:00
test Add hash_bytes and simplify hashing internals 2026年02月13日 17:25:06 -05:00
.gitignore feat: Hello World 2025年01月19日 15:42:45 +01:00
flake.lock Bump nix flake 2026年02月13日 17:28:17 -05:00
flake.nix Optimise hashing to only traverse lists once 2026年01月21日 21:47:20 -05:00
gleam.toml New release, again 2026年02月13日 23:17:01 -05:00
manifest.toml Bump dependencies 2026年02月13日 15:40:11 -05:00
README.md docs: Add badges to indicate Erlang and JavaScript compatibility 2025年01月22日 09:21:30 -05:00
REUSE.toml feat: Hello World 2025年01月19日 15:42:45 +01:00

murmur3a

Package Version Hex Docs Erlang-compatible JavaScript-compatible

A pure Gleam implementation of the 32bit Murmur3 non-cryptographic hash function (with a little JavaScript optimisation).

gleam add murmur3a
importgleam/ioimportmurmur3apubfnmain(){murmur3a.hash_string("Hello!",1)|>murmur3a.hex_digest// -> "DC75D641"
}

API documentation can be found at https://hexdocs.pm/murmur3a.

Development

gleam test # Run the tests with erlang
gleam test --target javascript # Run the tests with bun

Credits

murmur3a leans heavily on Robin Heggelund Hansen's Elm implementation.