I claim this is all highly unhelpful. Both the C and C++ standards explicitly permit an implementation to do something sensible in the face of undefined behaviour, the sort of thing that a regular user of the system in question might expect. It&#x27;s a bit unclear to me why compiler authors don&#x27;t just do that. Undefined means exactly what it says, nothing more, but people seem to love this idea that it has to be some kind of here-be-dragons nightmare scenario.<p>Mandatory reading: <a href="http:&#x2F;&#x2F;blog.metaobject.com&#x2F;2014&#x2F;04&#x2F;cc-osmartass.html" rel="nofollow">http:&#x2F;&#x2F;blog.metaobject.com&#x2F;2014&#x2F;04&#x2F;cc-osmartass.html</a>, <a href="http:&#x2F;&#x2F;robertoconcerto.blogspot.co.uk&#x2F;2010&#x2F;10&#x2F;strict-aliasing.html" rel="nofollow">http:&#x2F;&#x2F;robertoconcerto.blogspot.co.uk&#x2F;2010&#x2F;10&#x2F;strict-aliasin...</a>