http://gcc.gnu.org/bugzilla/show_bug.cgi?id=56463
Joost VandeVondele Joost.VandeVondele at mat dot ethz.ch changed:
What|Removed |Added
CC|
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=56463
Joost VandeVondele Joost.VandeVondele at mat dot ethz.ch changed:
What|Removed |Added
CC|
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=56463
--- Comment #5 from Cristóbal Camarero nakacristo at hotmail dot com
2013-02-27 08:19:04 UTC ---
Dominique, I think the test I found is more problematic than yours. Since in
mine, the huge value is completely independent of the ending condition.
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=56463
Jakub Jelinek jakub at gcc dot gnu.org changed:
What|Removed |Added
Status|UNCONFIRMED |RESOLVED
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=56463
--- Comment #2 from Cristóbal Camarero nakacristo at hotmail dot com
2013-02-26 17:39:31 UTC ---
I think that at least -Wall -Wextra -Wstrict-overflow=5 should give a giving
notice of the extremely odd behaviour.
However, I am not following
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=56463
--- Comment #3 from Jakub Jelinek jakub at gcc dot gnu.org 2013-02-26
17:53:43 UTC ---
The compiler may assume that undefined behavior doesn't happen in the program.
It is fine to have undefined behavior in code that will be never executed,
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=56463
--- Comment #4 from Dominique d'Humieres dominiq at lps dot ens.fr 2013-02-26
18:41:56 UTC ---
The compiler may assume that undefined behavior doesn't happen in the program.
It is fine to have undefined behavior in code that will be never