Anders Carlsson | d7ba27d | 2009-05-14 01:09:04 +0000 | [diff] [blame^] | 1 | // RUN: clang-cc -fsyntax-only -verify %s |
2 | |||||
3 | namespace T1 { | ||||
4 | |||||
5 | class A { | ||||
6 | virtual int f(); // expected-note{{overridden virtual function is here}} | ||||
7 | }; | ||||
8 | |||||
9 | class B : A { | ||||
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')}} | ||||
11 | }; | ||||
12 | |||||
13 | } |