2013-04-30 Richard Biener <rguenther@suse.de>
[official-gcc.git] / gcc / testsuite / gcc.dg / pr39867.c
blobcb7972452928ad0057e9848a8ff5a4b8eecbaef7
1 /* { dg-do link } */
2 /* { dg-options "-O2" } */
4 int main (void)
6 int exp = -1;
7 /* Wrong folding of the LHS to an unsigned MAX leads to 4294967295 != 2. */
8 if ((exp < 2 ? 2U : (unsigned int) exp) != 2)
9 link_error ();
10 return 0;