摘要: slice是我们使用go语言时最经常使用的数据结构,所以我们还是有必要研究一下它的实现的,尤其是slice的扩容,具体实现参考src/runtime/slice.go。 slice定义 type slice struct { array unsafe.Pointer len int // 长度 ca 阅读全文
posted @ 2021-03-05 21:05 latte575 阅读(76) 评论(0) 推荐(0)