Revert "[llvm] Improve llvm.objectsize computation by computing GEP, alloca and mallo...
[llvm-project.git] / clang / test / Preprocessor / c99-6_10_3_4_p9.c
blob04c4b79700db1f0cc09179a358436b53a2cc2795
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):\
8 printf(__VA_ARGS__))
9 debug("Flag");
10 // CHECK: fprintf(stderr, "Flag");
12 debug("X = %d\n", x);
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));