Lines Matching full:virtual
6 virtual int f(); // expected-note{{overridden virtual function is here}}
10 virtual void f(); // expected-error{{virtual function 'f' has a different return type ('void') than the function it overrides (which has return type 'int')}}
21 virtual a* f(); // expected-note{{overridden virtual function is here}}
25 virtual b* f(); // expected-error{{return type of virtual function 'f' is not covariant with the return type of the function it overrides ('T2::b *' is not derived from 'T2::a *')}}
36 virtual a* f(); // FIXME: desired-note{{overridden virtual function is here}}
40 virtual b* f(); // expected-error{{invalid covariant return for virtual function: 'T3::a' is a private base class of 'T3::b'}}
52 virtual a* f(); // expected-note{{overridden virtual function is here}}
56 virtual b* f(); // expected-error{{return type of virtual function 'f' is not covariant with the return type of the function it overrides (ambiguous conversion from derived class 'T4::b' to base class 'T4::a':\n\
68 virtual a* const f();
69 virtual a* const g(); // expected-note{{overridden virtual function is here}}
73 virtual a* const f();
74 virtual a* g(); // expected-error{{return type of virtual function 'g' is not covariant with the return type of the function it overrides ('T5::a *' has different qualifiers than 'T5::a *const')}}
84 virtual const a* f();
85 virtual a* g(); // expected-note{{overridden virtual function is here}}
89 virtual a* f();
90 virtual const a* g(); // expected-error{{return type of virtual function 'g' is not covariant with the return type of the function it overrides (class type 'const T6::a *' is more qualified than class type 'T6::a *'}}
104 virtual b* f();
113 virtual a *f();
117 b* f(); // expected-error {{return type of virtual function 'f' is not covariant with the return type of the function it overrides ('T8::b' is incomplete)}}
129 virtual a *f();
133 virtual b<int> *f(); // expected-note {{in instantiation of template class 'T9::b<int>' requested here}}
139 virtual void f0();
147 void f(int) = 0; // expected-error{{not virtual and cannot be declared pure}}
150 struct Base1 { virtual void f(int); };
171 virtual void f(int) = 0; // expected-note{{unimplemented pure virtual method}}
193 virtual Base* Method();
198 virtual Derived<int>* Method();
211 class X { virtual BaseP f(); };
212 class X1 : public X { virtual DerivedP f(); };
214 template <typename T> class Y { virtual T f(); };
215 template <typename T1, typename T> class Y1 : public Y<T> { virtual T1 f(); };
229 virtual B* f1(); // expected-note{{overridden virtual function is here}}
230 virtual TB<N>* f2(); // expected-note{{overridden virtual function is here}}
233 virtual TD<M>* f1(); // expected-error{{return type of virtual function 'f1' is not covariant with the return type of the function it overrides ('TD<1> *'}}
234 virtual D* f2(); // expected-error{{return type of virtual function 'f2' is not covariant with the return type of the function it overrides ('type_dependent_covariance::D *' is not derived from 'TB<1> *')}}
247 virtual A&& f();
251 virtual B&& f();
260 virtual A& f(); // expected-note {{overridden virtual function is here}}
264 virtual B&& f(); // expected-error {{virtual function 'f' has a different return type ('T11::B &&') than the function it overrides (which has return type 'T11::A &')}}
273 virtual A&& f(); // expected-note {{overridden virtual function is here}}
277 virtual B& f(); // expected-error {{virtual function 'f' has a different return type ('T12::B &') than the function it overrides (which has return type 'T12::A &&')}}
284 virtual void foo() {} // expected-note{{overridden virtual function is here}}
289 static void foo() {} // expected-error{{'static' member function 'foo' overrides a virtual function}}