...

Package value

import "github.com/google/go-cmp/cmp/internal/value"
Overview
Index

Overview ▾

func SortKeys

func SortKeys(vs []reflect.Value) []reflect.Value

SortKeys sorts a list of map keys, deduplicating keys if necessary. The type of each value must be comparable.

func TypeString

func TypeString(t reflect.Type, qualified bool) string

TypeString is nearly identical to reflect.Type.String, but has an additional option to specify that full type names be used.

type Pointer

Pointer is an opaque typed pointer and is guaranteed to be comparable.

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

func PointerOf

func PointerOf(v reflect.Value) Pointer

PointerOf returns a Pointer from v, which must be a reflect.Ptr, reflect.Slice, or reflect.Map.

func (Pointer) IsNil

func (p Pointer) IsNil() bool

IsNil reports whether the pointer is nil.

func (Pointer) Uintptr

func (p Pointer) Uintptr() uintptr

Uintptr returns the pointer as a uintptr.