Documentation
¶
Index ¶
- Constants
- func MapToSlice(m map[uint8]struct{}) []uint8
- func MustParse(v string) uint8
- func Parse(v string) (uint8, error)
- func Ptr(v uint8) *uint8
- func PtrDefToNil(v uint8, def uint8) *uint8
- func PtrZeroToNil(v uint8) *uint8
- func SafeIndex(s []uint8, i int) uint8
- func SafeIndexDef(s []uint8, i int, def uint8) uint8
- func SafeIndexPtr(s []uint8, i int) *uint8
- func SliceToMap(s []uint8) map[uint8]struct{}
- func Val(v *uint8) uint8
- func ValDef(v *uint8, def uint8) uint8
- type Slice
Constants ¶
View Source
const (
// BitSize is the size in bits of this type.
BitSize = 8
)
Variables ¶
This section is empty.
Functions ¶
func PtrDefToNil ¶
PtrDefToNil returns a pointer to the value, or nil if "def".
func PtrZeroToNil ¶
PtrZeroToNil returns a pointer to the value, or nil if 0.
func SafeIndexDef ¶
SafeIndexDef returns "s[i]" if possible, and "def" otherwise.
func SafeIndexPtr ¶
SafeIndexPtr returns "s[i]" if possible, and nil otherwise.
Types ¶
Click to show internal directories.
Click to hide internal directories.