1 /* { dg-do compile } */
2 /* { dg-options -std=gnu89 } */
4 /* GCC 2.95.2 used to get the following variable argument macro
7 Source: Neil Booth, from PR 3852 with persmission. 31 Jul 2001. */
9 #define TEST_WORSE(args...) (5, ## args)
10 #define TEST_BAD(foo, args...) (2, (foo), ## args)
14 static int add (int a
, int b
)
21 /* Would expand to a single closing parenthesis, maybe because of
22 the "no args requires space" brokenness. */
23 if (TEST_WORSE () != 5)
25 /* The macro would expand to (0, (0) with a missing closing parenthesis. */
26 if (add
TEST_BAD (5) != 7)