diff --git a/set.go b/set.go index d779f9fd..1d782d41 100644 --- a/set.go +++ b/set.go @@ -26,7 +26,7 @@ func NewSet() Set { defer func() { atomic.AddUint64(&globalid, 1) }() return Set{ data: make(map[interface{}]struct{}, 0), - id: globalid, + id: atomic.LoadUint64(&globalid), } }