File: e_14.t

package info (click to toggle)
mcpp 2.7.2-1
  • links: PTS
  • area: main
  • in suites: squeeze
  • size: 8,152 kB
  • ctags: 29,136
  • sloc: ansic: 35,238; sh: 9,241; makefile: 176; cpp: 84; exp: 18
file content (38 lines) | stat: -rw-r--r-- 699 bytes parent folder | download | duplicates (7)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
/* e_14.t:  Illegal #if expressions.    */

#define A   1
#define B   1

/* 14.1:    String literal is not allowed in #if expression.    */
#if     "string"
#endif      /* The second error ?   */

/* 14.2:    Operators =, +=, ++, etc. are not allowed in #if expression.    */
#if     A = B
#endif
#if     A++ B
#endif
#if     A --B
#endif
#if     A.B
#endif

/* 14.3:    Unterminated #if expression.    */
#if     0 <
#endif
#if     ( (A == B)
#endif

/* 14.4:    Unbalanced parenthesis in #if defined operator. */
#if     defined ( MACRO
#endif

/* 14.5:    No argument.    */
#if
#endif

/* 14.6:    Macro expanding to 0 token in #if expression.   */
#define ZERO_TOKEN
#if     ZERO_TOKEN
#endif