summaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.dg/parse/else.C
blob: 87ea982a81c95e585dd26f860c6cfd58444fa417 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
// { dg-do compile }
// { dg-options " " }

int f()
{
  if (1)
    {
      return 1;
  else  // { dg-error "expected .\}. before 'else'" }
    {
      return 0;
    }
}