Confuse about runtime.AddCleanup

101 views
Skip to first unread message

xie cui

unread,
Aug 16, 2025, 12:21:45 PMAug 16
to golang-nuts
in this cl https://go-review.googlesource.com/c/go/+/638557/12/src/net/fd_posix.go
In my understand, fd and pfd is pointer to same slot cell in gc, why runtime.AddCleanup can not accept runtime.AddCleanup(fd, func(fd){}, fd) as cleanup arg, in my mind, I think they are fd and pfd is same to gc collector.
Reply all
Reply to author
Forward
0 new messages