No need to warn if 'unavailable' method/property 
is not implemented. // rdar://9651605


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@133819 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/Sema/SemaDeclObjC.cpp b/lib/Sema/SemaDeclObjC.cpp
index 3bbe421..3052b82 100644
--- a/lib/Sema/SemaDeclObjC.cpp
+++ b/lib/Sema/SemaDeclObjC.cpp
@@ -1076,6 +1076,9 @@
 
 void Sema::WarnUndefinedMethod(SourceLocation ImpLoc, ObjCMethodDecl *method,
                                bool &IncompleteImpl, unsigned DiagID) {
+  // No point warning no definition of method which is 'unavailable'.
+  if (method->hasAttr<UnavailableAttr>())
+    return;
   if (!IncompleteImpl) {
     Diag(ImpLoc, diag::warn_incomplete_impl);
     IncompleteImpl = true;