From 40ddd1123b4059a838c2c3164aad3901dc0c6ccf Mon Sep 17 00:00:00 2001 From: Tom Dohrmann Date: Wed, 11 Sep 2024 11:27:26 +0200 Subject: [PATCH] memstore: don't use predeclared identifier clear --- internal/memstore/memstore_test.go | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/internal/memstore/memstore_test.go b/internal/memstore/memstore_test.go index 2d9d2d7c22..de40896272 100644 --- a/internal/memstore/memstore_test.go +++ b/internal/memstore/memstore_test.go @@ -177,7 +177,7 @@ func TestStoreConcurrent(t *testing.T) { defer wg.Done() s.Set(key, value) } - clear := func() { + clearStore := func() { defer wg.Done() s.Clear() } @@ -187,10 +187,10 @@ func TestStoreConcurrent(t *testing.T) { } wg.Add(16) - go clear() - go clear() - go clear() - go clear() + go clearStore() + go clearStore() + go clearStore() + go clearStore() go set("foo", 1) go set("bar", 2) go set("baz", 3) @@ -199,10 +199,10 @@ func TestStoreConcurrent(t *testing.T) { go getAll() go getAll() go getAll() - go clear() - go clear() - go clear() - go clear() + go clearStore() + go clearStore() + go clearStore() + go clearStore() wg.Wait() s.Clear()