2021年1月8日

Go 指针逃逸分析

摘要: 引用 https://my.oschina.net/renhc/blog/2222104 阅读全文

posted @ 2021-01-08 13:42 biwentao 阅读(212) 评论(0) 推荐(0)

go 通过指针修改结构体小写字段的值

摘要: package main import ( "fmt" "unsafe" ) type W struct { b int32 c int64 } func main() { var w = W{} //这时w的变量打印出来都是默认值0,0 fmt.Println(w.b,w.c) //现在我们通过指 阅读全文

posted @ 2021-01-08 09:42 biwentao 阅读(369) 评论(0) 推荐(0)

导航