v0.0.323 fix langext.IsNil for reflect.Array
All checks were successful
Build Docker and Deploy / Run goext test-suite (push) Successful in 1m35s

This commit is contained in:
2023-11-16 17:15:44 +01:00
parent c534e998e8
commit e657de7f78
4 changed files with 6 additions and 4 deletions

View File

@@ -35,7 +35,7 @@ func IsNil(i interface{}) bool {
return true
}
switch reflect.TypeOf(i).Kind() {
case reflect.Ptr, reflect.Map, reflect.Array, reflect.Chan, reflect.Slice:
case reflect.Ptr, reflect.Map, reflect.Chan, reflect.Slice, reflect.Func, reflect.UnsafePointer:
return reflect.ValueOf(i).IsNil()
}
return false