]> rtime.felk.cvut.cz Git - l4.git/blob - l4/pkg/l4re-core/uclibc/lib/contrib/uclibc/extra/scripts/unifdef.test
Update
[l4.git] / l4 / pkg / l4re-core / uclibc / lib / contrib / uclibc / extra / scripts / unifdef.test
1 Run me through unifdef -UA
2 *** Nothing should be visible here:
3 #if defined A && defined B
4 hello world
5 #endif
6 #if defined A && B
7 hello world
8 #endif
9 #if defined A && 1
10 hello world
11 #endif
12 #if defined A && (1 > 0)
13 hello world
14 #endif
15 #if defined B && defined A
16 hello world
17 #endif
18 #if B && defined A
19 hello world
20 #endif
21 #if 1 && defined A
22 hello world
23 #endif
24 #if (1 > 0) && defined A
25 hello world
26 #endif
27 #if defined A && (defined FOO || defined BAR)
28 hello world
29 #endif
30 #if (defined FOO || defined BAR) && defined A
31 hello world
32 #endif
33
34 *** Everything should be visible here, but #if/#endif removed:
35 #if defined B || !defined A
36 hello world 1
37 #endif
38 #if !defined A || defined B
39 hello world 2 (last)
40 #endif
41
42 *** This should be unchanged (#if/#endif not removed):
43 #if defined A || defined B
44 I am here 1
45 #endif
46 #if defined B || defined A
47 I am here 2
48 #endif
49 I am here 3
50 #if !defined FOO && !defined BAR \
51     && !defined BAZ
52 # error "I am here 4"
53 #endif
54 I am here 5
55 #if (!defined FOO \
56      && (defined BAR || defined BAZ \
57          || defined XYZ))
58 I am here 6
59 #endif
60 I am here 7
61 #if !defined FOO \
62     && defined BAR
63 I am here 8
64 #endif
65 I am here 9 (last)
66
67 *** End