diff options
Diffstat (limited to 'immutable_test.go')
-rw-r--r-- | immutable_test.go | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/immutable_test.go b/immutable_test.go index 93f65be..b11b13f 100644 --- a/immutable_test.go +++ b/immutable_test.go @@ -2501,11 +2501,11 @@ func (h *mockHasher[K]) Equal(a, b K) bool { } // mockComparer represents a mock implementation of immutable.Comparer. -type mockComparer struct { - compare func(a, b interface{}) int +type mockComparer[K constraints.Ordered] struct { + compare func(a, b K) int } // Compare executes the mocked CompreFn function. -func (h *mockComparer) Compare(a, b interface{}) int { +func (h *mockComparer[K]) Compare(a, b K) int { return h.compare(a, b) } |