3 ms·
The author is encouraged to look into undefined behavior sanitizers: https://duckduckgo.com/?q=ubsan+sanitizer&t=ffsb&ia=web https://duckduckgo.com/?q=ubsan+sa
by einpoklum 7y ago
The author is encouraged to look into undefined behavior sanitizers:
https://duckduckgo.com/?q=ubsan+sanitizer&t=ffsb&ia=web https://duckduckgo.com/?q=ubsan+sanitizer&t=ffsb&ia=web
clang and gcc have those.
Other than that - @_kst is correct, it was the same in C89 and C99, and the intention is simply to let compilers make the optimization they like ignoring what happens for UB cases.