xref: /freebsd/usr.bin/calendar/tests/calendar.cond (revision e6bfd18d21b225af6a0ed67ceeaf1293b7b9eba5)
1#define DEF1
2
31 1	jan 1 OK
4
5#ifdef DEF1
61 2	jan 2 OK
7#endif
8
91 3	jan 3 OK
10
11#ifdef	DEF2
121 4	jan 4 NOT OK
13#else
141 5	jan 5 OK
15#endif
16
17#ifndef	DEF2
181 6	jan 6 OK
19#else
201 7	jan 7 NOT OK
21#endif
22
23#ifdef DEF1
24#ifndef DEF2
251 8	jan 8 OK
26#endif
27#endif
28
29#ifdef DEF1
30#ifdef DEF2
311 9	jan 9 NOT OK
32#else
331 10	jan 10 OK
34#endif
35#else
361 11	jan 11 NOT OK
37#endif
38
39#define DEF2
40
41#ifndef DEF1	// skip = 1
42#ifndef DEF2	// skip = 2
431 12	jan 12 NOT OK
44#else		// skip = 1 unskip = 0
451 13	jan 13 NOT OK
46#endif		// skip = 0 unskip = 0
47#else		// skip = 0 unskip = 1
481 14	jan 14 OK
49#endif		// skip = 0 unskip = 0
50
51#undef DEF1
52
53#ifdef DEF1 // OFF
54#ifdef DEF2 // ON
55#ifdef DEF3 // OFF
561 15	jan 15 NOT OK
57#else
581 16	jan 16 NOT OK
59#endif // DEF3
60#else // DEF2
61#ifdef DEF3
621 17	jan 17 NOT OK
63#else
641 18	jan 18 NOT OK
65#endif // DEF3
66#endif // DEF2
67#else // DEF1
68#ifdef DEF2
69#ifdef DEF3
701 19	jan 19 NOT OK
71#else
721 20	jan 20 OK
73#endif // DEF3
74#else // DEF2
75#ifdef DEF3
761 21	jan 21 NOT OK
77#else
781 22	jan 22 NOT OK
79#endif // DEF3
80#endif // DEF2
81#endif // DEF1
82
831 23	jan 23 OK