Mercurial > ~dholland > hg > tradcpp > index.cgi
annotate tests/t08.c @ 170:2ee7db420643
Fix joerg's expansionitem_eq(). Was wrong previously.
author | David A. Holland |
---|---|
date | Fri, 12 Jun 2015 02:02:38 -0400 |
parents | c24cbfa44f81 |
children |
rev | line source |
---|---|
34
c24cbfa44f81
Don't actually include stdio.h in this for testing cpp.
David A. Holland
parents:
28
diff
changeset
|
1 /*#include <stdio.h>*/ |
28 | 2 |
3 int d = | |
4 #if 2 > 1 ? 0 : 0 ? 1 : 1 | |
5 1 | |
6 #else | |
7 0 | |
8 #endif | |
9 ; | |
10 | |
11 int e = | |
12 #if (2 > 1 ? 0 : 0) ? 1 : 1 | |
13 1 | |
14 #else | |
15 0 | |
16 #endif | |
17 ; | |
18 | |
19 int f = | |
20 #if 2 > 1 ? 0 : (0 ? 1 : 1) | |
21 1 | |
22 #else | |
23 0 | |
24 #endif | |
25 ; | |
26 | |
27 | |
28 int | |
29 main() | |
30 { | |
31 int a, b, c; | |
32 | |
33 a = 2 > 1 ? 0 : 0 ? 1 : 1; | |
34 b = (2 > 1 ? 0 : 0) ? 1 : 1; | |
35 c = 2 > 1 ? 0 : (0 ? 1 : 1); | |
36 | |
37 printf("%d %d %d\n", a, b, c); | |
38 printf("%d %d %d\n", d, e, f); | |
39 | |
40 return 0; | |
41 } |