2017-10-21 23:40:19 +00:00
|
|
|
/* Conformance Test 3.3.9.1: Verification of token merging in macro */
|
|
|
|
/* expansions */
|
|
|
|
|
2022-10-17 22:50:42 +00:00
|
|
|
int printf(const char *, ...);
|
|
|
|
|
2017-10-21 23:40:19 +00:00
|
|
|
#define INCR(j,k) j##k
|
|
|
|
|
2022-10-17 22:50:42 +00:00
|
|
|
int main (void)
|
2017-10-21 23:40:19 +00:00
|
|
|
{
|
2022-10-17 22:50:42 +00:00
|
|
|
int x, y;
|
2017-10-21 23:40:19 +00:00
|
|
|
|
|
|
|
x = 3;
|
2022-10-17 22:50:42 +00:00
|
|
|
y = INCR (+, +) x;
|
|
|
|
if (x != 4 || y != 4)
|
2017-10-21 23:40:19 +00:00
|
|
|
goto Fail;
|
|
|
|
|
|
|
|
printf ("Passed Conformance Test 3.3.9.1\n");
|
2022-10-17 22:50:42 +00:00
|
|
|
return 0;
|
2017-10-21 23:40:19 +00:00
|
|
|
|
|
|
|
Fail:
|
|
|
|
printf ("Failed Conformance Test 3.3.9.1\n");
|
|
|
|
}
|