OSDN Git Service

libcpp/
[pf3gnuchains/gcc-fork.git] / gcc / testsuite / gcc.dg / cpp / counter-2.c
1 /* Copyright 2007 Free Software Foundation, Inc.
2    Contributed by Ollie Wild <aaw@google.com>.  */
3
4 /* { dg-do preprocess } */
5 /* { dg-options -fdirectives-only } */
6
7 /* Tests __COUNTER__ macro expansion is disabled inside directives with
8    -fdirectives-only. */
9
10 #ifdef __COUNTER__  /* Macro not expanded. */
11 #endif
12
13 #if __COUNTER__ == 0  /* { dg-error "__COUNTER__ expanded inside directive with -fdirectives-only" } */
14 #endif