xref: /illumos-gate/usr/src/tools/smatch/src/validation/preprocessor/preprocessor11.c (revision 1f5207b7604fb44407eb4342aff613f7c4508508)
1 #define A(1) x
2 #define B(x
3 #define C(x,
4 #define D(,)
5 #define E(__VA_ARGS__)
6 #define F(x+
7 #define G(x...,
8 #define H(x...,y)
9 #define I(...+
10 #define J(x,y)
11 /*
12  * check-name: Preprocessor #11
13  * check-command: sparse -E $file
14  *
15  * check-output-start
16 
17 
18  * check-output-end
19  *
20  * check-error-start
21 preprocessor/preprocessor11.c:1:11: error: "1" may not appear in macro parameter list
22 preprocessor/preprocessor11.c:2:11: error: missing ')' in macro parameter list
23 preprocessor/preprocessor11.c:3:12: error: missing ')' in macro parameter list
24 preprocessor/preprocessor11.c:4:11: error: parameter name missing
25 preprocessor/preprocessor11.c:5:11: error: __VA_ARGS__ can only appear in the expansion of a C99 variadic macro
26 preprocessor/preprocessor11.c:6:12: error: "+" may not appear in macro parameter list
27 preprocessor/preprocessor11.c:7:12: error: missing ')' in macro parameter list
28 preprocessor/preprocessor11.c:8:12: error: missing ')' in macro parameter list
29 preprocessor/preprocessor11.c:9:11: error: missing ')' in macro parameter list
30  * check-error-end
31  */
32