bumped up golang version to 1.23
This commit is contained in:
2
to.go
2
to.go
@ -36,7 +36,7 @@ func ToList[T any](s []T) *list.List {
|
||||
|
||||
// ToMap returns a map containing all values of s.
|
||||
// The map key-value pairs are determined by mapper
|
||||
func ToMap[T any, K comparable, V any](s []T, mapper func(T) (K, V)) map[K]V {
|
||||
func ToMap[T any, K comparable, V any](s []T, mapper MapMapper[T, K, V]) map[K]V {
|
||||
m := map[K]V{}
|
||||
Each(s, func(value T) {
|
||||
k, v := mapper(value)
|
||||
|
Reference in New Issue
Block a user