aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.dg/cpp/if-mpar.c
blob: df200bbbab4615b31d6caca258f9a874d59a8edd (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
/* Copyright (C) 2000 Free Software Foundation, Inc.  */

/* Test various combinations of missing parentheses give the correct
   missing parenthesis message.  */

/* { dg-do preprocess } */

#if (1          /* { dg-error "missing '\\)'" "missing ')' no. 1" } */
#endif

#if 2 * (3 + 4	/* { dg-error "missing '\\)'" "missing ')' no. 2" } */
#endif

#if (2))	/* { dg-error "missing '\\('" "missing '(' no. 1" } */
#endif

#if )		/* { dg-error "missing '\\('" "missing '(' no. 2" } */
#endif

#if 4)		/* { dg-error "missing '\\('" "missing '(' no. 3" } */
#endif

#if (		/* { dg-error "missing '\\)'" "missing ')' no. 3" } */
#endif