diff options
| author | Alex Flint <[email protected]> | 2022-10-29 15:23:56 -0400 |
|---|---|---|
| committer | Alex Flint <[email protected]> | 2022-10-29 15:23:56 -0400 |
| commit | 3489ea5b2e9aa82dab4efc5e3f48fe6171f11ddd (patch) | |
| tree | 4f09f68ab87dbff2f2a40edc15ba85d38a8119be /reflect.go | |
| parent | 763072452fe0127e2002e12418d3e9c10ae1b8c0 (diff) | |
in a second place: use reflect.Ptr not reflect.Pointer since the latter was added in Go 1.18
Diffstat (limited to 'reflect.go')
| -rw-r--r-- | reflect.go | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -102,7 +102,7 @@ func isExported(field string) bool { // isZero returns true if v contains the zero value for its type func isZero(v reflect.Value) bool { t := v.Type() - if t.Kind() == reflect.Pointer || t.Kind() == reflect.Slice || t.Kind() == reflect.Map || t.Kind() == reflect.Chan || t.Kind() == reflect.Interface { + if t.Kind() == reflect.Ptr || t.Kind() == reflect.Slice || t.Kind() == reflect.Map || t.Kind() == reflect.Chan || t.Kind() == reflect.Interface { return v.IsNil() } if !t.Comparable() { |
