internal

package
v0.0.0-...-dba5aa2 Latest Latest
Warning

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

Go to latest
Published: Nov 1, 2023 License: BSD-2-Clause Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AssertIs

func AssertIs[T comparable](preamble string, actual T, expect T)

func AssertOneOf

func AssertOneOf[T comparable](preamble string, actual T, list ...T)

func AssertValid

func AssertValid(obj IsValider)

func AssertValidName

func AssertValidName(kind string, str string)

func BuildEnumMap

func BuildEnumMap[T ~byte](size T, goNames []string, names []string) map[string]T

func Contains

func Contains[K comparable, V any](in map[K]V, key K) bool

func CopyList

func CopyList[T any](in []T) []T

func CopyMap

func CopyMap[K comparable, V any](in map[K]V) map[K]V

func FinishEnumMap

func FinishEnumMap[T ~byte](m map[string]T)

func IsOneOf

func IsOneOf[T comparable](actual T, list ...T) bool

func IsValidName

func IsValidName(str string) bool

func Lookup

func Lookup[K comparable, V any](in map[K]V, key K, format string, args ...any) V

func NotValidError

func NotValidError(obj any) error

func RangeErr

func RangeErr(index uint, size uint) error

func RecycleList

func RecycleList[T any](ptr *[]T, initCapacity uint)

func RecycleMap

func RecycleMap[K comparable, V any](ptr *map[K]V, initCapacity uint)

Types

type IsValider

type IsValider interface{ IsValid() bool }

type Void

type Void = struct{}

Jump to

Keyboard shortcuts

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