Lines Matching refs:Protected
11 class Protected {} ProtectedInst;
18 protected:
19 void foo(Protected&); // expected-note 2 {{declared protected here}}
26 op->foo(ProtectedInst); // expected-error {{'foo' is a protected member}}
30 void (A::*b)(Protected&) = &A::foo; // expected-error {{'foo' is a protected member}}
44 protected:
45 void operator+(Protected&); // expected-note {{declared protected here}}
46 void operator[](Protected&); // expected-note {{declared protected here}}
47 void operator()(Protected&); // expected-note {{declared protected here}}
48 typedef void (*ProtectedSurrogate)(Protected&);
49 operator ProtectedSurrogate() const; // expected-note {{declared protected here}}
59 void operator+(const A &, Protected&);
63 void test(A &a, Public &pub, Protected &prot, Private &priv) {
65 a + prot; // expected-error {{'operator+' is a protected member}}
68 a[prot]; // expected-error {{'operator[]' is a protected member}}
71 a(prot); // expected-error {{'operator()' is a protected member}}
82 ca(prot); // expected-error {{'operator void (*)(class Protected &)' is a protected member}}
302 protected: virtual ~A();
332 struct B : protected A {
374 protected:
375 int protected_foo; // expected-note 3 {{declared protected here}} // expected-note {{can only access this member on an object of type 'test15::B<int>'}}
376 static int protected_sfoo; // expected-note 3 {{declared protected here}}
387 return a.protected_foo; // expected-error {{protected member}}
391 return a.protected_sfoo; // expected-error {{protected member}}
404 return a.protected_foo; // expected-error 2 {{protected member}}
408 return a.protected_sfoo; // expected-error {{protected member}}
412 return b.protected_foo; // expected-error {{protected member}}
416 return b.protected_sfoo; // expected-error {{protected member}}