diff options
author | Douglas Gregor <dgregor@apple.com> | 2011-11-03 17:41:55 +0000 |
---|---|---|
committer | Douglas Gregor <dgregor@apple.com> | 2011-11-03 17:41:55 +0000 |
commit | a885dce496f2a9e30650f74607efe11856a76a34 (patch) | |
tree | ed5fc397adaccff8802dd1fbff299cca37e39b19 /lib/Sema/SemaAccess.cpp | |
parent | 17015eff2b3166e445377b15913474b472775e7c (diff) |
Class can't be null in this context
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@143618 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Sema/SemaAccess.cpp')
-rw-r--r-- | lib/Sema/SemaAccess.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/Sema/SemaAccess.cpp b/lib/Sema/SemaAccess.cpp index 83ca553aa6..89538ba905 100644 --- a/lib/Sema/SemaAccess.cpp +++ b/lib/Sema/SemaAccess.cpp @@ -1653,7 +1653,7 @@ void Sema::CheckLookupAccess(const LookupResult &R) { /// \return true if the Decl is accessible from the Class, false otherwise. bool Sema::IsSimplyAccessible(NamedDecl *Decl, DeclContext *Ctx) { if (CXXRecordDecl *Class = dyn_cast<CXXRecordDecl>(Ctx)) { - if (!Class || !Decl->isCXXClassMember()) + if (!Decl->isCXXClassMember()) return true; QualType qType = Class->getTypeForDecl()->getCanonicalTypeInternal(); |