2 ms·
Are you writing C or C++ code or are you writing, for example C or C++ code for Windows? Because on Windows it's guaranteed to throw an access violation structu
by immibis 2y ago
Are you writing C or C++ code or are you writing, for example C or C++ code for Windows? Because on Windows it's guaranteed to throw an access violation structured exception, for example.
- Maxatar 2y agoNo it's not, even with MSVC on Windows dereferencing a null pointer is not guaranteed to do anything: Here's a classic article about the very weird and unintuitive consequences of null pointer dereferencing, such as "time travel": https://devblogs.microsoft.com/oldnewthing/20140627-00/?p=633 https://devblogs.microsoft.com/oldnewthing/20140627-00/?p=63...