mirror of
https://github.com/vitorpamplona/amethyst.git
synced 2026-08-09 08:04:45 +00:00
Add Hex.toLong64/toLong128/toLong256 (plus the shared readLong helper) to pack the first 64, 128 or 256 bits of a hex string into a single Long, two Longs or four Longs. Big-endian, allocation-light, branch-free — 16 table lookups and shifts per word. Useful as cheap map/set keys or bucket hashes for 32-byte event ids and pubkeys without decoding to a ByteArray. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019CU1wR6NvQmdmNNsPe9GuN