aboutsummaryrefslogtreecommitdiffstats
path: root/gcc-4.9/gcc/testsuite/g++.old-deja/g++.jason/defctor.C
blob: 76efaa1f0565ce4f98124f4b163d2d951cc22c81 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
// { dg-do run  }
// Bug: g++ doesn't generate default constructor.

class A {
public:
  int i;
};

extern "C" int printf(const char *, ...);

int main () {
  A a;
  a.i = 1;
  A b (a);
  printf("%d\n",b.i);
}