Home | History | Annotate | Download | only in SemaCXX

Lines Matching refs:base2

642 struct Base2 : Bottom {
643 constexpr Base2(const int &r) : r(r) {}
647 struct Derived : Base, Base2 {
648 constexpr Derived() : Base(76), Base2(a) {}
657 constexpr Base base2(76);
667 static_assert(derived == base2, "");
670 constexpr Bottom &bot2 = (Base2&)derived;
674 constexpr Bottom *pb2 = (Base2*)&derived;
679 constexpr Base2 &fail = (Base2&)bot1; // expected-error {{constant expression}} expected-note {{cannot cast object of dynamic type 'const Class::Derived' to type 'Class::Base2'}}
681 constexpr Base2 &ok2 = (Base2&)bot2;
684 constexpr Base2 *pfail = (Base2*)pb1; // expected-error {{constant expression}} expected-note {{cannot cast object of dynamic type 'const Class::Derived' to type 'Class::Base2'}}
686 constexpr Base2 *pok2 = (Base2*)pb2;
689 static_assert((Base2*)(Derived*)(Base*)pb1 == pok2, "");