How to spot undefined behavior
Posted
by BlueRaja - Danny Pflughoeft
on Stack Overflow
See other posts from Stack Overflow
or by BlueRaja - Danny Pflughoeft
Published on 2010-06-10T15:52:21Z
Indexed on
2010/06/10
16:02 UTC
Read the original article
Hit count: 352
Is there any way to know if you program has undefined behavior in C++ (or even C), short of memorizing the entire spec?
The reason I ask is that I've noticed a lot of cases of programs working in debug but not release being due to undefined behavior. It would be nice if there were a tool to at least help spot UB, so we know there's the potential for problems.
© Stack Overflow or respective owner