aboutsummaryrefslogtreecommitdiffstats
path: root/gcc-4.9/gcc/testsuite/g++.dg/opt/pr45316.C
blob: 74ad30ead6eb2e1235d9bf87f7e4dbbf495776fc (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
26
27
28
// { dg-do compile }
// { dg-options "-O1 -ftree-pre -fnon-call-exceptions" }

struct A
{
  int i;
};

struct B : A
{
  int i[6];
  B (int = 0) : A ()
  {
    m ();
  }
  int m ();
};

struct C : B
{
};

void
foo ()
{
  new C ();
}