retain/release checker: Use the ObjCMethodDecl in the @implementation if no
matching ObjCMethodDecl exists in the @interface.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@70474 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/Analysis/CFRefCount.cpp b/lib/Analysis/CFRefCount.cpp
index a12542e..1dc52c7 100644
--- a/lib/Analysis/CFRefCount.cpp
+++ b/lib/Analysis/CFRefCount.cpp
@@ -770,8 +770,10 @@
     IdentifierInfo *ClsName = ID->getIdentifier();
     QualType ResultTy = MD->getResultType();
     
-    // Resolve the method decl last.
-    MD = ResolveToInterfaceMethodDecl(MD, Ctx);    
+    // Resolve the method decl last.    
+    if (const ObjCMethodDecl *InterfaceMD =
+        ResolveToInterfaceMethodDecl(MD, Ctx))
+      MD = InterfaceMD;
     
     if (MD->isInstanceMethod())
       return getInstanceMethodSummary(S, ClsName, ID, MD, ResultTy);