reflect.Value.Kind (method)
208 uses
reflect (current package)
deepequal.go#L40: switch v1.Kind() {
deepequal.go#L64: switch v.Kind() {
deepequal.go#L90: switch v1.Kind() {
iter.go#L133: switch v.Kind() {
swapper.go#L20: if v.Kind() != Slice {
swapper.go#L21: panic(&ValueError{Method: "Swapper", Kind: v.Kind()})
value.go#L431: if x.Kind() == Invalid {
value.go#L1299: if v.Kind() == Pointer && v.typ().Elem().Kind() == abi.Struct {
value.go#L1322: if v.Kind() == Ptr && v.typ().Elem().Kind() == abi.Struct {
value.go#L1708: panic(&ValueError{"reflect.Value.IsZero", v.Kind()})
value.go#L1811: panic(&ValueError{"reflect.Value.SetZero", v.Kind()})
value.go#L1817: func (v Value) Kind() Kind {
value.go#L2706: switch v.Kind() {
value.go#L2714: panic(&ValueError{"reflect.Value.Clear", v.Kind()})
value.go#L3042: if v.Kind() != Pointer {
value.go#L3127: if v.Kind() == Interface && v.IsNil() {
value.go#L3191: k := v.Kind()
value.go#L3233: if v.Kind() == Interface {
value.go#L3236: if u.Kind() == Interface {
value.go#L3244: if v.Kind() != u.Kind() || v.Type() != u.Type() {
value.go#L3250: switch v.Kind() {
database/sql
convert.go#L362: switch sv.Kind() {
convert.go#L398: if dpv.Kind() != reflect.Pointer {
convert.go#L420: if dv.Kind() == sv.Kind() && sv.Type().ConvertibleTo(dv.Type()) {
convert.go#L430: switch dv.Kind() {
convert.go#L440: return fmt.Errorf("converting NULL to %s is unsupported", dv.Kind())
convert.go#L446: return fmt.Errorf("converting driver.Value type %T (%q) to a %s: %v", src, s, dv.Kind(), err)
convert.go#L452: return fmt.Errorf("converting NULL to %s is unsupported", dv.Kind())
convert.go#L458: return fmt.Errorf("converting driver.Value type %T (%q) to a %s: %v", src, s, dv.Kind(), err)
convert.go#L464: return fmt.Errorf("converting NULL to %s is unsupported", dv.Kind())
convert.go#L470: return fmt.Errorf("converting driver.Value type %T (%q) to a %s: %v", src, s, dv.Kind(), err)
convert.go#L476: return fmt.Errorf("converting NULL to %s is unsupported", dv.Kind())
convert.go#L506: switch rv.Kind() {
convert.go#L522: switch rv.Kind() {
convert.go#L554: if rv := reflect.ValueOf(vr); rv.Kind() == reflect.Pointer &&
database/sql/driver
types.go#L86: switch sv.Kind() {
types.go#L114: switch rv.Kind() {
types.go#L233: if rv := reflect.ValueOf(vr); rv.Kind() == reflect.Pointer &&
types.go#L263: switch rv.Kind() {
types.go#L294: return nil, fmt.Errorf("unsupported type %T, a %s", v, rv.Kind())
encoding/asn1
asn1.go#L934: switch val := v; val.Kind() {
asn1.go#L1058: if canHaveDefaultValue(v.Kind()) {
asn1.go#L1165: if v.Kind() != reflect.Pointer || v.IsNil() {
marshal.go#L476: switch v := value; v.Kind() {
marshal.go#L581: if v.Kind() == reflect.Interface && v.Type().NumMethod() == 0 {
marshal.go#L585: if v.Kind() == reflect.Slice && v.Len() == 0 && params.omitEmpty {
marshal.go#L589: if params.optional && params.defaultValue != nil && canHaveDefaultValue(v.Kind()) {
encoding/binary
binary.go#L274: switch v.Kind() {
binary.go#L311: switch v.Kind() {
binary.go#L699: switch v.Kind() {
binary.go#L846: switch v.Kind() {
binary.go#L915: switch v.Kind() {
encoding/json
decode.go#L175: if rv.Kind() != reflect.Pointer || rv.IsNil() {
decode.go#L450: if v.Kind() != reflect.Pointer && v.Type().Name() != "" && v.CanAddr() {
decode.go#L457: if v.Kind() == reflect.Interface && !v.IsNil() {
decode.go#L459: if e.Kind() == reflect.Pointer && !e.IsNil() && (!decodingNull || e.Elem().Kind() == reflect.Pointer) {
decode.go#L466: if v.Kind() != reflect.Pointer {
decode.go#L477: if v.Elem().Kind() == reflect.Interface && v.Elem().Elem().Equal(v) {
decode.go#L523: switch v.Kind() {
decode.go#L550: if v.Kind() == reflect.Slice {
decode.go#L585: if v.Kind() == reflect.Array {
decode.go#L593: if i == 0 && v.Kind() == reflect.Slice {
decode.go#L621: if v.Kind() == reflect.Interface && v.NumMethod() == 0 {
decode.go#L633: switch v.Kind() {
decode.go#L690: if v.Kind() == reflect.Map {
decode.go#L710: if subv.Kind() == reflect.Pointer {
decode.go#L774: if v.Kind() == reflect.Map {
decode.go#L904: switch v.Kind() {
decode.go#L917: switch v.Kind() {
decode.go#L942: switch v.Kind() {
decode.go#L978: switch v.Kind() {
decode.go#L980: if v.Kind() == reflect.String && v.Type() == numberType {
encode.go#L353: switch v.Kind() {
encode.go#L474: if v.Kind() == reflect.Pointer && v.IsNil() {
encode.go#L515: if v.Kind() == reflect.Pointer && v.IsNil() {
encode.go#L737: if fv.Kind() == reflect.Pointer {
encode.go#L991: if k.Kind() == reflect.String {
encode.go#L995: if k.Kind() == reflect.Pointer && k.IsNil() {
encode.go#L1001: switch k.Kind() {
encode.go#L1224: (v.Elem().Kind() == reflect.Pointer && v.Elem().IsNil()) ||
encoding/xml
marshal.go#L442: for val.Kind() == reflect.Interface || val.Kind() == reflect.Pointer {
marshal.go#L449: kind := val.Kind()
marshal.go#L538: if fv.Kind() == reflect.Interface && fv.IsNil() {
marshal.go#L558: if val.Kind() == reflect.Struct {
marshal.go#L630: switch val.Kind() {
marshal.go#L639: if val.Kind() == reflect.Slice && val.Type().Elem().Kind() != reflect.Uint8 {
marshal.go#L784: switch val.Kind() {
marshal.go#L825: for vf.Kind() == reflect.Interface || vf.Kind() == reflect.Pointer {
marshal.go#L883: switch vf.Kind() {
marshal.go#L918: k := vf.Kind()
marshal.go#L974: if vf.Kind() != reflect.Pointer && vf.Kind() != reflect.Interface || !vf.IsNil() {
marshal.go#L1122: switch v.Kind() {
read.go#L149: if val.Kind() != reflect.Pointer {
read.go#L252: if val.Kind() == reflect.Pointer {
read.go#L283: if val.Kind() == reflect.Slice && val.Type().Elem().Kind() != reflect.Uint8 {
read.go#L341: if val.Kind() == reflect.Interface && !val.IsNil() {
read.go#L343: if e.Kind() == reflect.Pointer && !e.IsNil() {
read.go#L348: if val.Kind() == reflect.Pointer {
read.go#L393: switch v := val; v.Kind() {
read.go#L602: switch t := saveComment; t.Kind() {
read.go#L609: switch t := saveXML; t.Kind() {
read.go#L624: if dst.Kind() == reflect.Pointer {
read.go#L632: switch dst.Kind() {
flag
flag.go#L303: if ptrVal.Kind() != reflect.Ptr {
flag.go#L307: if defVal.Kind() == reflect.Ptr {
fmt
print.go#L343: if val.Kind() == reflect.Interface && !val.IsNil() {
print.go#L551: switch value.Kind() {
print.go#L592: if v := reflect.ValueOf(arg); v.Kind() == reflect.Pointer && v.IsNil() {
print.go#L777: switch f := value; value.Kind() {
print.go#L875: if f.Kind() == reflect.Slice || f.CanAddr() {
print.go#L892: if f.Kind() == reflect.Slice && f.IsNil() {
print.go#L918: switch a := f.Elem(); a.Kind() {
print.go#L940: switch v := reflect.ValueOf(a[argNum]); v.Kind() {
scan.go#L1020: if ptr.Kind() != reflect.Pointer {
scan.go#L1024: switch v := ptr.Elem(); v.Kind() {
github.com/google/go-cmp/cmp
export.go#L25: if ve.Kind() == reflect.Interface && ve.IsNil() {
report_reflect.go#L310: panic(fmt.Sprintf("%v kind not handled", v.Kind()))
github.com/google/go-cmp/cmp/internal/value
sort.go#L90: return vx.Kind() < vy.Kind()
github.com/jackc/pgx/v5/pgtype
convert.go#L11: if dstPtr.Kind() != reflect.Ptr {
convert.go#L17: switch dstVal.Kind() {
convert.go#L44: if dstPtr.Kind() != reflect.Ptr {
convert.go#L51: if dstVal.Kind() == reflect.Ptr {
convert.go#L57: if baseValType, ok := kindTypes[dstVal.Kind()]; ok {
convert.go#L61: if dstVal.Kind() == reflect.Slice {
convert.go#L67: if dstVal.Kind() == reflect.Array {
convert.go#L73: if dstVal.Kind() == reflect.Struct {
json.go#L164: if rv.Kind() == reflect.Pointer && rv.Elem().Kind() == reflect.Pointer {
json.go#L202: if dstValue.Kind() == reflect.Ptr {
json.go#L204: switch el.Kind() {
json.go#L215: if v.Kind() != reflect.Pointer || v.IsNil() {
pgtype.go#L511: if dstValue := reflect.ValueOf(target); dstValue.Kind() == reflect.Ptr {
pgtype.go#L513: if elemValue.Kind() == reflect.Ptr {
pgtype.go#L565: if dstValue.Kind() == reflect.Ptr {
pgtype.go#L572: nextDstType := elemKindToPointerTypes[elemValue.Kind()]
pgtype.go#L574: if elemValue.Kind() == reflect.Slice {
pgtype.go#L583: if elemValue.Kind() == reflect.Array {
pgtype.go#L909: if targetValue.Kind() != reflect.Ptr {
pgtype.go#L1009: if targetValue.Kind() != reflect.Ptr {
pgtype.go#L1015: if targetElemValue.Kind() == reflect.Slice {
pgtype.go#L1040: if targetValue.Kind() != reflect.Ptr {
pgtype.go#L1046: if targetElemValue.Kind() == reflect.Array {
pgtype.go#L1423: nextValueType := kindToTypes[refValue.Kind()]
pgtype.go#L1439: if refValue.Kind() == reflect.Array {
pgtype.go#L1869: if sliceValue.Kind() == reflect.Slice {
pgtype.go#L2029: kind := refVal.Kind()
xml.go#L162: if dstValue.Kind() == reflect.Ptr {
xml.go#L164: switch el.Kind() {
go.uber.org/mock/gomock
call.go#L463: if t.Kind() != reflect.Ptr && t.Kind() != reflect.Interface {
matchers.go#L151: switch v.Kind() {
matchers.go#L255: switch v.Kind() {
matchers.go#L319: switch xValue.Kind() {
go.uber.org/zap/zapcore
error.go#L55: if v := reflect.ValueOf(err); v.Kind() == reflect.Ptr && v.IsNil() {
field.go#L222: if v := reflect.ValueOf(stringer); v.Kind() == reflect.Ptr && v.IsNil() {
go/ast
print.go#L23: switch v.Kind() {
print.go#L149: switch x.Kind() {
golang.org/x/net/http2
server.go#L730: if rv := reflect.ValueOf(v); rv.Kind() == reflect.Uintptr {
google.golang.org/protobuf/internal/descfmt
stringer.go#L309: if v.Kind() == reflect.Struct && !rv.IsValid() {
stringer.go#L324: switch rv.Kind() {
google.golang.org/protobuf/internal/impl
codec_map.go#L299: switch keys[i].Kind() {
codec_map.go#L311: panic("invalid kind: " + keys[i].Kind().String())
legacy_message.go#L501: if m.v.Kind() == reflect.Ptr && !m.v.IsNil() {
legacy_message.go#L559: if m.v.Kind() == reflect.Ptr {
message_opaque.go#L427: switch rv.Kind() {
message_opaque.go#L462: if nullable && rv.Kind() == reflect.Slice && rv.IsNil() {
message_reflect.go#L417: if rv.Kind() == reflect.Ptr && !rv.IsNil() {
message_reflect_field.go#L130: if rv.Kind() == reflect.Ptr && rv.IsNil() {
message_reflect_field.go#L288: switch rv.Kind() {
message_reflect_field.go#L311: if nullable && rv.Kind() == reflect.Ptr {
gotest.tools/v3/internal/assert
assert.go#L110: if v.Kind() == reflect.Ptr && v.IsNil() {
html/template
content.go#L124: for v.Kind() == reflect.Pointer && !v.IsNil() {
content.go#L143: for !v.Type().Implements(fmtStringerType) && !v.Type().Implements(errorType) && v.Kind() == reflect.Pointer && !v.IsNil() {
js.go#L142: for !v.Type().Implements(jsonMarshalType) && v.Kind() == reflect.Pointer && !v.IsNil() {
internal/fmtsort
sort.go#L77: switch aVal.Kind() {
log/slog
handler.go#L593: if v := reflect.ValueOf(v.any); v.Kind() == reflect.Pointer && v.IsNil() {
net/http
h2_bundle.go#L4710: if rv := reflect.ValueOf(v); rv.Kind() == reflect.Uintptr {
text/template
exec.go#L329: switch val.Kind() {
exec.go#L397: switch val.Kind() {
exec.go#L534: if value.Kind() == reflect.Interface && value.Type().NumMethod() == 0 {
exec.go#L691: if receiver.Kind() == reflect.Interface && isNil {
exec.go#L701: if ptr.Kind() != reflect.Interface && ptr.Kind() != reflect.Pointer && ptr.CanAddr() {
exec.go#L709: switch receiver.Kind() {
exec.go#L908: if value.Kind() == reflect.Interface && !value.IsNil() {
exec.go#L920: case value.Kind() == reflect.Pointer && value.Type().Elem().AssignableTo(typ):
exec.go#L1077: for ; v.Kind() == reflect.Pointer || v.Kind() == reflect.Interface; v = v.Elem() {
exec.go#L1090: if v.Kind() != reflect.Interface {
exec.go#L1116: if v.Kind() == reflect.Pointer {
exec.go#L1127: switch v.Kind() {
funcs.go#L93: if v.Kind() != reflect.Func {
funcs.go#L170: if intLike(value.Kind()) && intLike(argType.Kind()) && value.Type().ConvertibleTo(argType) {
funcs.go#L190: switch index.Kind() {
funcs.go#L222: switch item.Kind() {
funcs.go#L264: switch item.Kind() {
funcs.go#L306: switch item.Kind() {
funcs.go#L428: switch v.Kind() {
funcs.go#L450: switch v.Kind() {
funcs.go#L460: k1 := v1.Kind()
funcs.go#L461: k2 := v2.Kind()