- Sort Score
- Result 10 results
- Languages All
Results 1 - 2 of 2 for ErrBadArgKind (0.13 sec)
-
staging/src/k8s.io/apimachinery/pkg/util/mergepatch/errors.go
} func ErrBadArgType(expected, actual interface{}) error { return fmt.Errorf("expected a %s, but received a %s", reflect.TypeOf(expected), reflect.TypeOf(actual)) } func ErrBadArgKind(expected, actual interface{}) error { var expectedKindString, actualKindString string if expected == nil { expectedKindString = "nil" } else { expectedKindString = reflect.TypeOf(expected).Kind().String() }
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Wed Nov 01 13:12:11 UTC 2017 - 3.1K bytes - Viewed (0) -
staging/src/k8s.io/apimachinery/pkg/util/strategicpatch/meta.go
if dataStruct == nil { return nil, mergepatch.ErrBadArgKind(struct{}{}, nil) } t := reflect.TypeOf(dataStruct) // Get the underlying type for pointers if t.Kind() == reflect.Pointer { t = t.Elem() } if t.Kind() != reflect.Struct { return nil, mergepatch.ErrBadArgKind(struct{}{}, dataStruct) } return t, nil }
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Tue Oct 31 16:45:45 UTC 2023 - 7.7K bytes - Viewed (0)