1 // RUN: %clang_cc1 -fsyntax-only -verify -std=c++98 %s
2 // RUN: %clang_cc1 -fsyntax-only -verify -std=c++17 %s
6 class F
{}; // expected-note{{implicitly declared private here}}
7 friend void foo(D::E::F
& q
);
9 friend void foo(D::E::F
& q
); // expected-error{{'F' is a private member of 'D::E'}}
12 void foo(D::E::F
& q
) {}
16 class F1
{}; // expected-note{{implicitly declared private here}}
17 friend D1::E1::F1
foo1();
19 friend D1::E1::F1
foo1(); // expected-error{{'F1' is a private member of 'D1::E1'}}
22 D1::E1::F1
foo1() { return D1::E1::F1(); }
29 friend void foo2(){ D2::E2::F2 c
;}