On Wed, Nov 27, 2013 at 6:44 AM, Stefan Roas wrote:

> Such code has never been valid and any assumption anyone may falsely have
> on such code is outright wrong. Such code may do anything, which includes
> nothing so IMHO it's perfectly ok for the optimizer to throw it away.
> After all we'd be better of not relying on something that is "undefined".

The problem with that attitude is that it results in C programmers
never fixing their code and never even knowing that it is wrong
because the compiler never rejected their code or at the very least
provided a warning. Not everyone knows everything about C and that is
why we have compiler warnings. Every use of undefined behaviour should
at minimum result in a compiler warning.

PS: Debian has a build log scanner for reporting compiler warnings to
developers:

http://qa.debian.org/bls/

-- 
bye,
pabs

http://wiki.debian.org/PaulWise


-- 
To UNSUBSCRIBE, email to [email protected]
with a subject of "unsubscribe". Trouble? Contact [email protected]
Archive: 
http://lists.debian.org/CAKTje6Fw=Mer+gXu4KJrNic=m0opor1rcpg-eadecnxb9wv...@mail.gmail.com

Reply via email to