diff options
author | Fariborz Jahanian <fjahanian@apple.com> | 2014-08-13 21:24:14 +0000 |
---|---|---|
committer | Fariborz Jahanian <fjahanian@apple.com> | 2014-08-13 21:24:14 +0000 |
commit | 0ded42451d8d439a3ec774e34acfc6e6c6113cca (patch) | |
tree | a634a04ce441a8174fe22b404170dad61264675a /clang/lib/Sema/SemaExprObjC.cpp | |
parent | caa8bfd13b8e0477d5c5256170408ac24cd2e1e5 (diff) | |
download | bcm5719-llvm-0ded42451d8d439a3ec774e34acfc6e6c6113cca.tar.gz bcm5719-llvm-0ded42451d8d439a3ec774e34acfc6e6c6113cca.zip |
Objective-C. Minor refactoring of my last patch.
// rdar://16808765
llvm-svn: 215581
Diffstat (limited to 'clang/lib/Sema/SemaExprObjC.cpp')
-rw-r--r-- | clang/lib/Sema/SemaExprObjC.cpp | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/clang/lib/Sema/SemaExprObjC.cpp b/clang/lib/Sema/SemaExprObjC.cpp index 6cc1658934d..80ce9baee75 100644 --- a/clang/lib/Sema/SemaExprObjC.cpp +++ b/clang/lib/Sema/SemaExprObjC.cpp @@ -2418,13 +2418,10 @@ ExprResult Sema::BuildInstanceMessage(Expr *Receiver, Method = LookupFactoryMethodInGlobalPool(Sel, SourceRange(LBracLoc,RBracLoc), receiverIsId); - if (Method) { - SmallVector<ObjCMethodDecl*, 4> Methods; - if (CollectMultipleMethodsInGlobalPool(Sel, Methods, - Method->isInstanceMethod())) - if (ObjCMethodDecl *BestMethod = SelectBestMethod(Sel, ArgsIn, Methods)) - Method = BestMethod; - } + if (Method) + if (ObjCMethodDecl *BestMethod = + SelectBestMethod(Sel, ArgsIn, Method->isInstanceMethod())) + Method = BestMethod; } else if (ReceiverType->isObjCClassType() || ReceiverType->isObjCQualifiedClassType()) { // Handle messages to Class. |