Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions slices/ptr.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ package slices

// References returns slice with the value of the slice in params as
// pointers.
func References[T comparable](s []T) []*T {
func References[T any](s []T) []*T {
var r = make([]*T, len(s))

for i, v := range s {
Expand All @@ -15,7 +15,7 @@ func References[T comparable](s []T) []*T {
return r
}

func Indirect[T comparable](s []*T) []T {
func Indirect[T any](s []*T) []T {
var r = make([]T, len(s))

for i, v := range s {
Expand Down
Loading