compiler,reflect: fix NumMethods for Interface type

This commit is contained in:
frenkel26
2024-05-28 15:09:59 +03:00
committed by GitHub
parent 81ce7fb738
commit f7c0466f78
4 changed files with 16 additions and 7 deletions
+1
View File
@@ -456,6 +456,7 @@ func showValue(rv reflect.Value, indent string) {
case reflect.Interface:
println(indent + " interface")
println(indent+" nil:", rv.IsNil())
println(indent+" NumMethod:", rv.NumMethod())
if !rv.IsNil() {
showValue(rv.Elem(), indent+" ")
}