Debian Codegraph @

gcc/testsuite/g++.dg/cpp0x/rv-cast4.C

raw
1 // PR c++/51161
2 // { dg-do compile { target c++11 } }
3
4 struct A{};
5 struct B : A{};
6 struct C : A{};
7 struct D : B, C{};
8
9 int main()
10 {
11 D d;
12 static_cast<A &&>(d); // { dg-error "ambiguous" }
13 }