summaryrefslogtreecommitdiffstats
path: root/gcc/testsuite/gcc.dg/cpp/paste4.c
blob: fac1d436ffe54b24b082ecf32e8c80e253a8f74d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
/* Copyright (C) 2000 Free Software Foundation, Inc.  */
/* { dg-do compile } */

/* Since 1.0e and + form the pasted token, 1 is a separate token and
   so should be output with a preceding space.  The old preprocessor
   gets this wrong.  */

#define glue(x, y) x ## y

int main ()
{
  double d = glue (1.0e, +1); /* { dg-error "floating const|parse error" } */
  return 0;
}
OpenPOWER on IntegriCloud