Mercurial > hg > CbC > CbC_gcc
view gcc/testsuite/gcc.dg/cpp/if-cexp.c @ 111:04ced10e8804
gcc 7
author | kono |
---|---|
date | Fri, 27 Oct 2017 22:46:09 +0900 |
parents | |
children |
line wrap: on
line source
/* { dg-do preprocess } */ /* Test the ? : opearator, for precedence and both true and false. */ #if 1 ? 1 ? 2 : 0 : 0 #error OK /* { dg-error "OK" "nested ? :" } */ #endif #if ((0) ? (1) ? (2) : (3) : (4) ? (5): (6)) == 5 #error OK /* { dg-error "OK" "nested ? : with parens" } */ #endif #if 2: /* { dg-error "':' without" "immediate :" } */ #endif