[Bug tree-optimization/49234] [4.6/4.7/4.8 Regression] -Wstrict-overflow gives obviously unwarranted warning
ian at airs dot com
gcc-bugzilla@gcc.gnu.org
Wed Mar 6 16:19:00 GMT 2013
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=49234
--- Comment #19 from Ian Lance Taylor <ian at airs dot com> 2013-03-06 16:18:50 UTC ---
Those tests are more or less the whole point of the strict-overflow warning.
-Wstrict-overflow exists to have an optional warning that tells you when you
may run into trouble. For a warning of this type it's much better to have a
false positive than a false negative. A false positive is just annoying. A
false negative causes you to miss a potential bug in the program.
Sorry you've put so much time into this, but I don't see how it could be
acceptable to have a false negative on a case like Wstrict-overflow-12.c.
More information about the Gcc-bugs
mailing list