Re:Understand Go pointers
by echlebek on Wednesday April 26, 2017 @09:39PM
(#14208549)
Package unsafe is in the spec, but converting unsafe.Pointer to uintptr (which is how I'm supposing you'd do your pointer arithmetic) is implementation-defined.
This means I could create a perfectly legal implementation of Go where such things result in complete nonsense. I don't think package unsafe "counts".
Re:Understand Go pointers
by pjmlp on Thursday April 27, 2017 @02:24AM
(#14209589)
If package unsafe doesn't "count", anything that C compilers allow beyond what ANSI C specifies don't count as C, thus many of its system programming features just vanish.
This means I could create a perfectly legal implementation of Go where such things result in complete nonsense. I don't think package unsafe "counts".