modernc.org/ccgo/v3@v3.16.14/lib/testdata/gcc-9.1.0/gcc/testsuite/gcc.c-torture/execute/20051021-1.c (about)

     1  /* Verify that TRUTH_AND_EXPR is not wrongly changed to TRUTH_ANDIF_EXPR.  */
     2  
     3  extern void abort (void);
     4  
     5  int count = 0;
     6  
     7  int foo1(void)
     8  {
     9    count++;
    10    return 0;
    11  }
    12  
    13  int foo2(void)
    14  {
    15    count++;
    16    return 0;
    17  }
    18  
    19  int main(void)
    20  {
    21    if ((foo1() == 1) & (foo2() == 1))
    22      abort ();
    23  
    24    if (count != 2)
    25      abort ();
    26  
    27    return 0;
    28  }