aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.old-deja/g++.jason/temporary5.C
blob: 6a2469e3627285c251529a2caf3b051c829d7fc3 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
// PRMS Id: 6604
// Bug: Scoped constructor call is not properly recognized as a functional cast

int c;

struct A {
  A() { ++c; }
  ~A() { --c; }
  operator int () { return 1; }
};

int main ()
{
  A::A();
  return c;
}