Cgo中使用unsafe.Pointer 表示空指针void*例如如下Cgo代码// export recvfunc recv(fd C.int, buf unsafe.Pointer, len C.int) C.int 等于C代码extern int recv(int fd , void* buf, int len );参考文献[1]. go.dev . cgo Documentation . https://pkg.go.dev/cmd/cgo...
Go
2023-06-25
48 点赞
0 评论
72 浏览