modernc.org/ccgo/v3@v3.16.14/lib/testdata/gcc-9.1.0/gcc/testsuite/gcc.c-torture/compile/r1.c (about)

     1  void assert (a) {if (a != 1) abort ();}
     2  
     3  int h1 (int *p) {return *p & 255;}
     4  
     5  void p1 () {int a = 0x01020304; assert (h1 (&a) == 0x04);}
     6  
     7  
     8  int h2 (a) {return a > 0;}
     9  
    10  p2 () {assert (h2 (1));}
    11  
    12  h3 (int *p)
    13  {
    14    *p |= 255;
    15  }
    16  
    17  p3 ()
    18  {
    19    int *p;
    20    h3 (p);
    21  }
    22  
    23  main ()
    24  {
    25    p1 ();
    26    p2 ();
    27    p3 ();
    28    puts ("Compiler test passed.");
    29  }