From 2fd4f16debb2f68a9b22f3906c5a5df7e118b066 Mon Sep 17 00:00:00 2001 From: Rudi Grinberg Date: Wed, 25 Sep 2024 17:22:15 +0100 Subject: [PATCH] refactor: hash sets without polymorphic hashing --- lib/hash_set.ml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/hash_set.ml b/lib/hash_set.ml index d7f6fa34..1b2b1416 100644 --- a/lib/hash_set.ml +++ b/lib/hash_set.ml @@ -76,7 +76,7 @@ let clear t = ;; let add t x = - let hash = Hashtbl.hash x in + let hash = Int.hash x in let slots = Array.length t.table in let index = hash land (slots - 1) in let inserting = ref true in @@ -125,7 +125,7 @@ let mem t x = then false else ( let t = Option.get t in - let hash = Hashtbl.hash x in + let hash = Int.hash x in let slots = Array.length t.table in let index = hash land (slots - 1) in let i = ref 0 in