internal

package
v2.0.5 Latest Latest
Warning

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

Go to latest
Published: Oct 6, 2022 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrUnsupported   = errors.New("unsupported")
	ErrUnaddressable = errors.New("unaddressable")
)

Error to be used by sub packages. These will be overridden by bytes

Functions

func IsSafeSlice

func IsSafeSlice(t reflect.Type) bool

IsSafeSlice returns if the given type is a slice or array, with a element type that can be safely converted to bytes. All signed and unsigned intergers except uint and int, and floats are considered to be safe types. uint and int are considered to be unsafe since their size is platform dependent.

Types

type Provider

type Provider interface {
	FromI8([]int8, []byte) int
	FromI16([]int16, []byte, bool) int
	FromI32([]int32, []byte, bool) int
	FromI64([]int64, []byte, bool) int
	FromU16([]uint16, []byte, bool) int
	FromU32([]uint32, []byte, bool) int
	FromU64([]uint64, []byte, bool) int
	FromF32([]float32, []byte, bool) int
	FromF64([]float64, []byte, bool) int
	ToI8([]uint8, []int8) int
	ToI16([]byte, []int16, bool) int
	ToI32([]byte, []int32, bool) int
	ToI64([]byte, []int64, bool) int
	ToU16([]byte, []uint16, bool) int
	ToU32([]byte, []uint32, bool) int
	ToU64([]byte, []uint64, bool) int
	ToF32([]byte, []float32, bool) int
	ToF64([]byte, []float64, bool) int
	FromSlice(interface{}, []byte, bool) (int, error)
	ToSlice([]byte, interface{}, bool) (int, error)
	FromValue(reflect.Value, []byte, bool) (int, error)
	ToValue([]byte, reflect.Value, bool) (int, error)
}

Provider a provider

Directories

Path Synopsis
asm
asm/gen command

Jump to

Keyboard shortcuts

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