摘要: go中 for循环的坑 在使用for循环修改结构体切片中的值时,发现并没有修改成功。 type Dog struct { name string } func (d *Dog) setNewName(name string) { d.name = name } func main() { d := 阅读全文
posted @ 2023-04-26 16:06 lopzzzzzzzzzzzzzz 阅读(131) 评论(0) 推荐(0)