3 ms·
Well, it'll be observed the next time through the loop. If that matters, then it's true that this technique isn't desirable.
by CamperBob2 1y ago
Well, it'll be observed the next time through the loop. If that matters, then it's true that this technique isn't desirable.
- manwe150 1y agoWithout atomic, the compiler won’t bother with there being a next time and just infinite loop (in the old days, you’d mark it volatile instead)
- CamperBob2 1y agoTrue enough, but volatile still works, of course.