diff options
author | Ilya Biryukov <ibiryukov@google.com> | 2018-12-05 17:38:39 +0000 |
---|---|---|
committer | Ilya Biryukov <ibiryukov@google.com> | 2018-12-05 17:38:39 +0000 |
commit | 98397555a51b61fabfc992ebcb054072eb5720c2 (patch) | |
tree | 270efda3a97f641b3226eb7b3322324f4767bcee /clang/lib/Sema/SemaAccess.cpp | |
parent | 899b3afacaec07d06e3923a722681ab2e5474b40 (diff) | |
download | bcm5719-llvm-98397555a51b61fabfc992ebcb054072eb5720c2.tar.gz bcm5719-llvm-98397555a51b61fabfc992ebcb054072eb5720c2.zip |
[CodeComplete] Fix a crash in access checks of inner classes
Summary: The crash was introduced in r348135.
Reviewers: kadircet
Reviewed By: kadircet
Subscribers: cfe-commits
Differential Revision: https://reviews.llvm.org/D55260
llvm-svn: 348387
Diffstat (limited to 'clang/lib/Sema/SemaAccess.cpp')
-rw-r--r-- | clang/lib/Sema/SemaAccess.cpp | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/clang/lib/Sema/SemaAccess.cpp b/clang/lib/Sema/SemaAccess.cpp index 0432e70851f..69084589efe 100644 --- a/clang/lib/Sema/SemaAccess.cpp +++ b/clang/lib/Sema/SemaAccess.cpp @@ -1896,8 +1896,6 @@ bool Sema::IsSimplyAccessible(NamedDecl *Target, CXXRecordDecl *NamingClass, if (Target->isCXXClassMember() && NamingClass) { if (!getLangOpts().CPlusPlus) return false; - if (Target->getAccess() == AS_public) - return true; // The unprivileged access is AS_none as we don't know how the member was // accessed, which is described by the access in DeclAccessPair. // `IsAccessible` will examine the actual access of Target (i.e. |