diff --git a/ds/heap.go b/ds/heap.go index 8c6cd9e..793f3a5 100644 --- a/ds/heap.go +++ b/ds/heap.go @@ -1,6 +1,6 @@ package ds -import "golang.org/x/exp/slices" +import "slices" // NewHeap creates a new Heap instance that is configured to use the // specified better function to order items. When better returns true, the diff --git a/ds/list.go b/ds/list.go index 7f60afc..6ac13a1 100644 --- a/ds/list.go +++ b/ds/list.go @@ -1,6 +1,6 @@ package ds -import "golang.org/x/exp/slices" +import "slices" // NewList creates a new List with the given capacity. The capacity can be // used as a form of optimization. Regardless of the value, the initial size diff --git a/ds/set.go b/ds/set.go index 5f5127a..ee8d8ef 100644 --- a/ds/set.go +++ b/ds/set.go @@ -1,6 +1,6 @@ package ds -import "golang.org/x/exp/maps" +import "maps" // NewSet creates a new Set instance with the specified initial capacity, // which is only used to preallocate memory and does not act as an upper bound. diff --git a/ds/stack.go b/ds/stack.go index e1b66e0..d3b4c19 100644 --- a/ds/stack.go +++ b/ds/stack.go @@ -1,6 +1,6 @@ package ds -import "golang.org/x/exp/slices" +import "slices" // NewStack creates a new Stack instance with the specified initial capacity, // which only serves to preallocate memory. Exceeding the initial capacity is diff --git a/example_test.go b/example_test.go index 0bb991f..377dcda 100644 --- a/example_test.go +++ b/example_test.go @@ -2,11 +2,11 @@ package gog_test import ( "fmt" + "slices" "strconv" "strings" "github.com/mokiat/gog" - "golang.org/x/exp/slices" ) func ExampleDedupe() { diff --git a/go.mod b/go.mod index 566b2db..3483ac2 100644 --- a/go.mod +++ b/go.mod @@ -5,7 +5,6 @@ go 1.22 require ( github.com/onsi/ginkgo/v2 v2.15.0 github.com/onsi/gomega v1.31.1 - golang.org/x/exp v0.0.0-20240222234643-814bf88cf225 ) require ( diff --git a/go.sum b/go.sum index dfcba3e..9750f82 100644 --- a/go.sum +++ b/go.sum @@ -20,8 +20,6 @@ github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZN github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/testify v1.6.1 h1:hDPOHmpOpP40lSULcqw7IrRb/u7w6RpDC9399XyoNd0= github.com/stretchr/testify v1.6.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= -golang.org/x/exp v0.0.0-20240222234643-814bf88cf225 h1:LfspQV/FYTatPTr/3HzIcmiUFH7PGP+OQ6mgDYo3yuQ= -golang.org/x/exp v0.0.0-20240222234643-814bf88cf225/go.mod h1:CxmFvTBINI24O/j8iY7H1xHzx2i4OsyguNBmN/uPtqc= golang.org/x/net v0.21.0 h1:AQyQV4dYCvJ7vGmJyKki9+PBdyvhkSd8EIx/qb0AYv4= golang.org/x/net v0.21.0/go.mod h1:bIjVDfnllIU7BJ2DNgfnXvpSvtn8VRwhlsaeUTyUS44= golang.org/x/sys v0.17.0 h1:25cE3gD+tdBA7lp7QfhuV+rJiE9YXTcS3VG1SqssI/Y= diff --git a/slice.go b/slice.go index deb83f1..4ac3094 100644 --- a/slice.go +++ b/slice.go @@ -1,6 +1,6 @@ package gog -import "golang.org/x/exp/maps" +import "maps" // Map can be used to transform one slice into another by providing a // function to do the mapping.