Skip to content

Commit

Permalink
Merge remote-tracking branch 'gop/main' into q
Browse files Browse the repository at this point in the history
  • Loading branch information
xushiwei committed May 30, 2024
2 parents e5f38a6 + 8ca8824 commit db141e1
Show file tree
Hide file tree
Showing 4 changed files with 163 additions and 103 deletions.
10 changes: 9 additions & 1 deletion cl/_testgo/eface/in.go
Original file line number Diff line number Diff line change
Expand Up @@ -40,5 +40,13 @@ func main() {

func dump(v any) {
e := (*eface)(unsafe.Pointer(&v))
println(e._type.Size(), e._type.Kind(), e._type, e._type.Elem())
dumpTyp(e._type, "")
}

func dumpTyp(t *abi.Type, sep string) {
print(sep)
println(t.Kind(), t.Size_, t.PtrBytes, t.Hash, t.TFlag, t.Align_, t.Str_, t.PtrToThis_)
if t.Elem() != nil {
dumpTyp(t.Elem(), sep+"\t")
}
}
Loading

0 comments on commit db141e1

Please sign in to comment.