aboutsummaryrefslogtreecommitdiff
path: root/test/CXX/class.access/p4.cpp
diff options
context:
space:
mode:
authorJohn McCall <rjmccall@apple.com>2010-09-03 04:56:05 +0000
committerJohn McCall <rjmccall@apple.com>2010-09-03 04:56:05 +0000
commitfe24e05a87e48fa3318b65d1a92c542107639fd9 (patch)
tree5afaecfcdd231fc82120cf2ae7ec56ee8a5187d0 /test/CXX/class.access/p4.cpp
parentfae962200efef618d1c24c14b9c3fed25876f059 (diff)
Add a quick-and-dirty hack to give a better diagnostic for [class.protected]
restrictions. The note's not really on the right place given its wording, but putting a second note on the call site (or muddying the wording) doesn't appeal. There are corner cases where this can be wrong, but I'm not concerned. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@112950 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/CXX/class.access/p4.cpp')
-rw-r--r--test/CXX/class.access/p4.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/test/CXX/class.access/p4.cpp b/test/CXX/class.access/p4.cpp
index fa6e183890..115a22ad44 100644
--- a/test/CXX/class.access/p4.cpp
+++ b/test/CXX/class.access/p4.cpp
@@ -372,7 +372,7 @@ namespace test15 {
int private_foo; // expected-note {{declared private here}}
static int private_sfoo; // expected-note {{declared private here}}
protected:
- int protected_foo; // expected-note 4 {{declared protected here}}
+ int protected_foo; // expected-note 3 {{declared protected here}} // expected-note {{object type must derive from context type 'test15::B<int>'}}
static int protected_sfoo; // expected-note 3 {{declared protected here}}
int test1(A<int> &a) {