From 64682769249224fb2aacf8a342d9458bc8dc2f17 Mon Sep 17 00:00:00 2001 From: Andy Edison Date: Tue, 24 Sep 2024 15:16:17 -0500 Subject: [PATCH] Remove references of deleted functions --- go/cache/ristretto/cache.go | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/go/cache/ristretto/cache.go b/go/cache/ristretto/cache.go index b745d6dc991..62e1dc859e0 100644 --- a/go/cache/ristretto/cache.go +++ b/go/cache/ristretto/cache.go @@ -24,6 +24,7 @@ import ( "bytes" "errors" "fmt" + "hash/maphash" "sync" "sync/atomic" "time" @@ -38,9 +39,9 @@ var ( ) func defaultStringHash(key string) (uint64, uint64) { - const Seed1 = uint64(0x1122334455667788) - const Seed2 = uint64(0x8877665544332211) - return hack.RuntimeStrhash(key, Seed1), hack.RuntimeStrhash(key, Seed2) + var Seed1 = maphash.MakeSeed() + var Seed2 = maphash.MakeSeed() + return maphash.String(Seed1, key), maphash.String(Seed2, key) } type itemCallback func(*Item)