1 // Example from C99 6.10.3.4p9
3 // RUN: %clang_cc1 -E %s | FileCheck -strict-whitespace %s
5 #define debug(...) fprintf(stderr, __VA_ARGS__)
6 #define showlist(...) puts(#__VA_ARGS__)
7 #define report(test, ...) ((test)?puts(#test):\
10 // CHECK: fprintf(stderr, "Flag");
13 // CHECK: fprintf(stderr, "X = %d\n", x);
15 showlist(The first
, second
, and third items
.);
16 // CHECK: puts("The first, second, and third items.");
18 report(x
>y
, "x is %d but y is %d", x
, y
);
19 // CHECK: ((x>y)?puts("x>y"): printf("x is %d but y is %d", x, y));