aboutsummaryrefslogtreecommitdiffstats
path: root/gcc-4.9/gcc/testsuite/g++.old-deja/g++.pt/stmtexpr2.C
blob: 36c0fccebcd1c6d8c76b87eea0b448dfedb3b702 (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
25
// { dg-do run  }
extern "C" void abort();

int i;

void g()
{
  i++;
}

template <class T>
void f(T)
{
  __extension__ ({g();});
}

int main()
{
  f(3.0);
  if (i != 1)
    abort();

  return 0;
}