aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohn McCall <rjmccall@apple.com>2010-04-09 19:01:14 +0000
committerJohn McCall <rjmccall@apple.com>2010-04-09 19:01:14 +0000
commitfd2254405de977dcc706a4dc7775c44a4218a27b (patch)
treeb28a618f46ae4d92a33788195f8a20ea1a05f3d6
parent08a41901e18aeb91b87d031b93df70374af02564 (diff)
Suppress access control diagnostics when looking up a base or member name
fails to find a type. There are no cases where it's valid for this to produce an error. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@100878 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r--lib/Sema/SemaDeclCXX.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/Sema/SemaDeclCXX.cpp b/lib/Sema/SemaDeclCXX.cpp
index d3985ef3a8..3eb8713b77 100644
--- a/lib/Sema/SemaDeclCXX.cpp
+++ b/lib/Sema/SemaDeclCXX.cpp
@@ -1076,6 +1076,9 @@ Sema::ActOnMemInitializer(DeclPtrTy ConstructorD,
if (!TyD) {
if (R.isAmbiguous()) return true;
+ // We don't want access-control diagnostics here.
+ R.suppressDiagnostics();
+
if (SS.isSet() && isDependentScopeSpecifier(SS)) {
bool NotUnknownSpecialization = false;
DeclContext *DC = computeDeclContext(SS, false);