utils

package
v0.1.4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 19, 2026 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CopyMap added in v0.1.1

func CopyMap[M1 ~map[K]V, M2 ~map[K]V, K comparable, V any](dst M1, src M2) M1

func FilterFunc

func FilterFunc[S ~[]E, E any](s S, f func(E) bool) S

func LastIndex

func LastIndex[S ~[]E, E comparable](s S, v E) int

func LastIndexFunc

func LastIndexFunc[S ~[]E, E any](s S, f func(E) bool) int

func MapFunc

func MapFunc[S ~[]E, E any, R any](s S, f func(E) R) []R

func ToEntries

func ToEntries[K comparable, V any](source *orderedmap.OrderedMap[K, V]) []*orderedmap.Element[K, V]

Types

type Set

type Set[T comparable] struct {
	// contains filtered or unexported fields
}

func NewSet

func NewSet[T comparable](values ...T) *Set[T]

func (*Set[T]) Has

func (s *Set[T]) Has(value T) bool

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL