Re:A Usable C++ Dialect That Is Safe Against Memory Corruption
by btilly on Friday March 16, 2018 @05:40PM
(#16604218)
The example in the case that I linked was single threaded code having a check for a null pointer unexpectedly removed.
So no threads, no shared memory, no locking mechanisms, no interrupts. Just a compiler making valid optimization and removing a necessary guard condition.
Try again.
The article you linked discusses what happens when you do things you should not, like fail to initialize a variable before using it. Modern compilers, when used correctly will let you know when you do this. With the right compiler options, it won't allow you to make such mistakes.