brintos

brintos / llvm-project-archived public Read only

0
0
Text · 235 B · db4c90f Raw
12 lines · cpp
1// RUN: %clang_cc1 -fsyntax-only -verify %s2 3struct A { };4 5void f() {6  struct B : private A {}; // expected-note{{declared private here}}7  8  B b;9  10  A *a = &b; // expected-error{{cannot cast 'B' to its private base class 'A'}}11}12