summaryrefslogtreecommitdiff
path: root/lib/std/hashfuncs.myr
diff options
context:
space:
mode:
Diffstat (limited to 'lib/std/hashfuncs.myr')
-rw-r--r--lib/std/hashfuncs.myr8
1 files changed, 6 insertions, 2 deletions
diff --git a/lib/std/hashfuncs.myr b/lib/std/hashfuncs.myr
index 5ad1180..f76ebda 100644
--- a/lib/std/hashfuncs.myr
+++ b/lib/std/hashfuncs.myr
@@ -2,18 +2,22 @@ use "alloc"
use "chartype"
use "die"
use "getint"
-use "sleq"
use "slpush"
use "traits"
use "types"
use "utf"
+use "memops"
pkg std =
const siphash24 : (data : byte[:], seed : byte[16] -> uint64)
impl equatable @a[:] =
eq = {a, b
- -> sleq(a, b)
+ if a.len == b.len
+ -> memeq((a : byte#), (b : byte#), a.len * sizeof(@a))
+ else
+ -> false
+ ;;
}
;;