1 // RUN: clang-cc -fsyntax-only -Wreorder -verify %s
7 class complex : public BB
, BB1
{
9 complex() : s2(1), // expected-warning {{member 's2' will be initialized after}}
10 s1(1) , // expected-note {{field s1}}
11 s3(3), // expected-warning {{member 's3' will be initialized after}}
12 BB1(), // expected-note {{base 'struct BB1'}} \
13 // expected-warning {{base class 'struct BB1' will be initialized after}}
14 BB() {} // expected-note {{base 'struct BB'}}
21 // testing virtual bases.
28 struct A
: public virtual V
{
32 struct B
: public virtual V
{
36 struct Diamond
: public A
, public B
{
37 Diamond() : A(), B() {}
41 struct C
: public A
, public B
, private virtual V
{
46 struct D
: public A
, public B
{
47 D() : A(), V() { } // expected-warning {{base class 'struct A' will be initialized after}} \
48 // expected-note {{base 'struct V'}}
52 struct E
: public A
, public B
, private virtual V
{
53 E() : A(), V() { } // expected-warning {{base class 'struct A' will be initialized after}} \
54 // expected-note {{base 'struct V'}}
66 struct F
: public A1
, public B1
, private virtual V
{
67 F() : A1(), V() { } // expected-warning {{base class 'struct A1' will be initialized after}} \
68 // expected-note {{base 'struct V'}}
71 struct X
: public virtual A
, virtual V
, public virtual B
{
72 X(): A(), V(), B() {} // expected-warning {{base class 'struct A' will be initialized after}} \
73 // expected-note {{base 'struct V'}}