1 // PR c++/13478
2 
3 struct A {};
4 struct B : protected A {
BB5     B() {};
BB6     B(const A& ) {};
7 private:
BB8     B(const B& ) {};
9 };
10 
foo(const A * ap)11 void foo(const A* ap)
12 {
13   const B& br = *ap;
14 }
15