4 ms·
Russ Cox has some nice examples of the issues with this: Otherwise the meaning of &f().x is different for f() returning pointer-to-struct and f() returning
by thomasahle 6y ago
Russ Cox has some nice examples of the issues with this:
Otherwise the meaning of &f().x is different for f() returning pointer-to-struct and f() returning struct.
Similarly &m["x"] is a compile error today but would silently make a copy tomorrow rather than produce a pointer to the value in a map.
All of that would be incredibly confusing and the source of many subtle bugs.