X-Git-Url: https://oss.titaniummirror.com/gitweb?a=blobdiff_plain;f=gcc%2Ftestsuite%2Fgcc.dg%2Fcpp%2Fmacro8.c;fp=gcc%2Ftestsuite%2Fgcc.dg%2Fcpp%2Fmacro8.c;h=0000000000000000000000000000000000000000;hb=6fed43773c9b0ce596dca5686f37ac3fc0fa11c0;hp=f49b0be9e2ebffcec1a3d8e48ffaa63d6415de58;hpb=27b11d56b743098deb193d510b337ba22dc52e5c;p=msp430-gcc.git diff --git a/gcc/testsuite/gcc.dg/cpp/macro8.c b/gcc/testsuite/gcc.dg/cpp/macro8.c deleted file mode 100644 index f49b0be9..00000000 --- a/gcc/testsuite/gcc.dg/cpp/macro8.c +++ /dev/null @@ -1,29 +0,0 @@ -/* { dg-do compile } */ -/* { dg-options -std=gnu89 } */ - -/* GCC 2.95.2 used to get the following variable argument macro - expansions wrong. - - Source: Neil Booth, from PR 3852 with persmission. 31 Jul 2001. */ - -#define TEST_WORSE(args...) (5, ## args) -#define TEST_BAD(foo, args...) (2, (foo), ## args) - -extern void abort (); - -static int add (int a, int b) -{ - return a + b; -} - -int main () -{ - /* Would expand to a single closing parenthesis, maybe because of - the "no args requires space" brokenness. */ - if (TEST_WORSE () != 5) - abort (); - /* The macro would expand to (0, (0) with a missing closing parenthesis. */ - if (add TEST_BAD (5) != 7) - abort (); - return 0; -}