diff options
author | John McCall <rjmccall@apple.com> | 2010-02-10 09:31:12 +0000 |
---|---|---|
committer | John McCall <rjmccall@apple.com> | 2010-02-10 09:31:12 +0000 |
commit | 5b0829a321d56fe8349e3226efa66355d423c9e2 (patch) | |
tree | 3339769f5a12bf179bd769d85391d8cd9cbaec87 /clang/test/SemaCXX/virtual-override.cpp | |
parent | f22553a1c713f7cc7eb1d249d16f85fe0e606b9e (diff) | |
download | bcm5719-llvm-5b0829a321d56fe8349e3226efa66355d423c9e2.tar.gz bcm5719-llvm-5b0829a321d56fe8349e3226efa66355d423c9e2.zip |
Improve access control diagnostics. Perform access control on member-pointer
conversions. Fix an access-control bug where privileges were not considered
at intermediate points along the inheritance path. Prepare for friends.
llvm-svn: 95775
Diffstat (limited to 'clang/test/SemaCXX/virtual-override.cpp')
-rw-r--r-- | clang/test/SemaCXX/virtual-override.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/clang/test/SemaCXX/virtual-override.cpp b/clang/test/SemaCXX/virtual-override.cpp index 5e1e9b0899c..6f1d83fd8ae 100644 --- a/clang/test/SemaCXX/virtual-override.cpp +++ b/clang/test/SemaCXX/virtual-override.cpp @@ -29,14 +29,14 @@ class B : A { namespace T3 { struct a { }; -struct b : private a { }; // expected-note{{'private' inheritance specifier here}} +struct b : private a { }; // expected-note{{declared private here}} class A { virtual a* f(); // expected-note{{overridden virtual function is here}} }; class B : A { - virtual b* f(); // expected-error{{return type of virtual function 'f' is not covariant with the return type of the function it overrides (conversion from 'struct T3::b' to inaccessible base class 'struct T3::a')}} + virtual b* f(); // expected-error{{invalid covariant return for virtual function: 'struct T3::a' is a private base class of 'struct T3::b'}} }; } |