可以对 map 的元素取地址吗
package main
import "fmt"
func main() {
m := make(map[string]int)
fmt.Println(&m["qcrao"])
}./main.go:8:14: cannot take the address of m["qcrao"]Last updated
Was this helpful?
package main
import "fmt"
func main() {
m := make(map[string]int)
fmt.Println(&m["qcrao"])
}./main.go:8:14: cannot take the address of m["qcrao"]Last updated
Was this helpful?
Was this helpful?