2 // { dg-do compile { target c++11 } }
4 struct A { int a; constexpr A() : a(0) {} };
5 struct B : A { int x; constexpr B() : x(0) {} };
6 struct X { int z; constexpr X() : z(0) {} };
8 constexpr int C::*cbx = &B::x;
9 constexpr int B::*bx = &B::x;
10 constexpr int A::*abx = static_cast<int(A::*)>(&B::x); // { dg-bogus "not a constant expression" }
13 constexpr const B& yb = y;
14 constexpr const A& ya = y;
15 constexpr int const *pcbx = &(y.*cbx);
16 constexpr int const *pbx = &(y.*bx);
17 constexpr int const *pabx = &(ya.*abx);