|
|
|
|
|
by heythere124
3276 days ago
|
|
Not my area of expertise and it is yours, but if you eliminate a zero instruction before a copy instruction how can you be sure that doesn't affect other threads? var x Int
// Pass x to a thread by reference
x = 0
time.Sleep(1000)
x = 1
|
|
So threads never seeing the value is already a valid outcome, so the compiler might as well always do that.