rt

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Aug 30, 2021 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

View Source
const (
	F_direct    = 1 << 5
	F_kind_mask = (1 << 5) - 1
)
View Source
const (
	MinInt48 = -(1 << 47)
	MaxInt48 = +(1 << 47) - 1
)

Variables

This section is empty.

Functions

func Get16

func Get16(v []byte) int16

func Get32

func Get32(v []byte) int32

func Get64

func Get64(v []byte) int64

func Mem2Str

func Mem2Str(v []byte) (s string)

func PackInt

func PackInt(v int) uint64

func Str2Mem

func Str2Mem(s string) (v []byte)

func UnpackInt

func UnpackInt(v uint64) int

Types

type GoEface

type GoEface struct {
	Type  *GoType
	Value unsafe.Pointer
}

func UnpackEface

func UnpackEface(v interface{}) GoEface

func (GoEface) Pack

func (self GoEface) Pack() (v interface{})

type GoIface

type GoIface struct {
	Itab  *GoItab
	Value unsafe.Pointer
}

type GoInterfaceMethod

type GoInterfaceMethod struct {
	Name int32
	Type int32
}

type GoInterfaceType

type GoInterfaceType struct {
	GoType
	PkgPath *byte
	Methods []GoInterfaceMethod
}

func IfaceType

func IfaceType(t *GoType) *GoInterfaceType

type GoItab

type GoItab struct {
	// contains filtered or unexported fields
}

type GoMap

type GoMap struct {
	Count      int
	Flags      uint8
	B          uint8
	Overflow   uint16
	Hash0      uint32
	Buckets    unsafe.Pointer
	OldBuckets unsafe.Pointer
	Evacuate   uintptr
	Extra      unsafe.Pointer
}

type GoMapIterator

type GoMapIterator struct {
	K           unsafe.Pointer
	V           unsafe.Pointer
	T           *GoMapType
	H           *GoMap
	Buckets     unsafe.Pointer
	Bptr        *unsafe.Pointer
	Overflow    *[]unsafe.Pointer
	OldOverflow *[]unsafe.Pointer
	StartBucket uintptr
	Offset      uint8
	Wrapped     bool
	B           uint8
	I           uint8
	Bucket      uintptr
	CheckBucket uintptr
}

type GoMapType

type GoMapType struct {
	GoType
	Key        *GoType
	Elem       *GoType
	Bucket     *GoType
	Hasher     func(unsafe.Pointer, uintptr) uintptr
	KeySize    uint8
	ElemSize   uint8
	BucketSize uint16
	Flags      uint32
}

func MapType

func MapType(t *GoType) *GoMapType

func (*GoMapType) IndirectElem

func (self *GoMapType) IndirectElem() bool

type GoPtrType

type GoPtrType struct {
	GoType
	Elem *GoType
}

type GoSlice

type GoSlice struct {
	Ptr unsafe.Pointer
	Len int
	Cap int
}

type GoString

type GoString struct {
	Ptr unsafe.Pointer
	Len int
}

type GoStructField

type GoStructField struct {
	Name     *byte
	Type     *GoType
	OffEmbed uintptr
}

type GoStructType

type GoStructType struct {
	GoType
	Pkg    *byte
	Fields []GoStructField
}

type GoType

type GoType struct {
	Size       uintptr
	PtrData    uintptr
	Hash       uint32
	Flags      uint8
	Align      uint8
	FieldAlign uint8
	KindFlags  uint8
	Traits     unsafe.Pointer
	GCData     *byte
	Str        int32
	PtrToSelf  int32
}

func PtrElem

func PtrElem(t *GoType) *GoType

func UnpackType

func UnpackType(t reflect.Type) *GoType

func (*GoType) Kind

func (self *GoType) Kind() reflect.Kind

func (*GoType) Pack

func (self *GoType) Pack() (t reflect.Type)

func (*GoType) String

func (self *GoType) String() string

Jump to

Keyboard shortcuts

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