On Saturday, 27 May 2017 at 10:02:35 UTC, Jonathan M Davis wrote:
As such, the fact that D programmers frequently decide to use __gshared in order to avoid dealing with the restrictions with shared is actually extremely bad. You can get away with it in some cases, but it's error-prone and is only going to get worse as the compiler improves.
Hm, I would think that using __gshared would not be affected by compiler improvements, since it would turn off optimizations that assume that the variable doesn't change between reads?