https://gcc.gnu.org/bugzilla/show_bug.cgi?id=55986
Andrew Pinski changed:
What|Removed |Added
Resolution|--- |FIXED
Keywords|
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=55986
--- Comment #5 from Shafik Yaghmour ---
It looks like this case from this Stackoverflow question
http://stackoverflow.com/q/32920229/1708801 is possibly related:
int main(int argc, char**)
{
constexpr int a = argc * 0;
}
gcc treats `argc *
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=55986
Shafik Yaghmour changed:
What|Removed |Added
CC||yaghmour.shafik at gmail dot
com
---
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55986
--- Comment #3 from David Krauss 2013-01-15 08:02:55
UTC ---
Likewise this is allowed:
switch( 0 )
case i-i: ;
I think this is a purposeful language extension, which could use a switch to
disable. It would be nice if static_assert we
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55986
--- Comment #2 from David Krauss 2013-01-15 04:48:47
UTC ---
Passing `-O2` additionally causes it to skip a condition like `(i == 0 || i !=
0)`, so it looks like a general issue with expression simplification bypassing
use.
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55986
--- Comment #1 from David Krauss 2013-01-15 04:47:53
UTC ---
Passing `-O2` additionally causes it to skip a condition like `(i == 0 || i !=
0)`, so it looks like a general issue with expression simplification bypassing
ODR-use.