aboutsummaryrefslogtreecommitdiffstats
path: root/gcc-4.9/gcc/testsuite/gcc.dg/cpp/macro-exp-tracking-2.c
blob: 2367765ccef8723b4ac7faed59162310b85028de (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
/* 
   { dg-options "-ftrack-macro-expansion=1" }
   { dg-do compile }
*/

#define OPERATE(OPRD1, OPRT, OPRD2) \
 OPRD1 OPRT OPRD2;	  /* { dg-message "in definition of macro 'OPERATE'" } */

#define SHIFTL(A,B) \
  OPERATE (A,<<,B) /* { dg-message "invalid operands to binary <<" } */

#define MULT(A) \
  SHIFTL (A,1)	   /* { dg-message "in expansion of macro 'SHIFTL'" } */

void
foo ()
{
  MULT (1.0);	   /* { dg-message "in expansion of macro 'MULT'" } */
}