diff options
author | Steve Naroff <snaroff@apple.com> | 2008-06-04 14:43:54 +0000 |
---|---|---|
committer | Steve Naroff <snaroff@apple.com> | 2008-06-04 14:43:54 +0000 |
commit | 9ad23d6f454e64b2ff960721becc5b90dea4d353 (patch) | |
tree | 58b6fefc19152cd6dff472684227a1a536c05949 /lib/Sema/SemaExprObjC.cpp | |
parent | e184baeaa112ceac32420f8ca127b8d4d152d109 (diff) |
Sema::ActOnClassMessage() needs to look through it's local implementation for private class methods.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@51938 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Sema/SemaExprObjC.cpp')
-rw-r--r-- | lib/Sema/SemaExprObjC.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/Sema/SemaExprObjC.cpp b/lib/Sema/SemaExprObjC.cpp index 2f3949fe60..c9cfc92f4d 100644 --- a/lib/Sema/SemaExprObjC.cpp +++ b/lib/Sema/SemaExprObjC.cpp @@ -170,6 +170,12 @@ Sema::ExprResult Sema::ActOnClassMessage( ObjCMethodDecl *Method = ClassDecl->lookupClassMethod(Sel); QualType returnType; + // If we have an implementation in scope, check "private" methods. + if (!Method) { + if (ObjCImplementationDecl *ImpDecl = + ObjCImplementations[ClassDecl->getIdentifier()]) + Method = ImpDecl->getClassMethod(Sel); + } // Before we give up, check if the selector is an instance method. if (!Method) Method = ClassDecl->lookupInstanceMethod(Sel); |