Remove ASTContext::isObjCObjectPointerType().
Convert all clients to use the new predicate on Type.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@76076 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/Sema/SemaStmt.cpp b/lib/Sema/SemaStmt.cpp
index 63191e0..bd2b0ae 100644
--- a/lib/Sema/SemaStmt.cpp
+++ b/lib/Sema/SemaStmt.cpp
@@ -669,14 +669,14 @@
 
       FirstType = static_cast<Expr*>(First)->getType();        
     }
-    if (!Context.isObjCObjectPointerType(FirstType))
+    if (!FirstType->isObjCObjectPointerType())
         Diag(ForLoc, diag::err_selector_element_type)
           << FirstType << First->getSourceRange();
   }
   if (Second) {
     DefaultFunctionArrayConversion(Second);
     QualType SecondType = Second->getType();
-    if (!Context.isObjCObjectPointerType(SecondType))
+    if (!SecondType->isObjCObjectPointerType())
       Diag(ForLoc, diag::err_collection_expr_type)
         << SecondType << Second->getSourceRange();
   }
@@ -1161,7 +1161,7 @@
     if (PVD->isInvalidDecl())
       return StmtError();
     
-    if (!Context.isObjCObjectPointerType(PVD->getType()))
+    if (!PVD->getType()->isObjCObjectPointerType())
       return StmtError(Diag(PVD->getLocation(), 
                        diag::err_catch_param_not_objc_type));
     if (PVD->getType()->isObjCQualifiedIdType())
@@ -1203,7 +1203,7 @@
   } else {
     QualType ThrowType = ThrowExpr->getType();
     // Make sure the expression type is an ObjC pointer or "void *".
-    if (!Context.isObjCObjectPointerType(ThrowType)) {
+    if (!ThrowType->isObjCObjectPointerType()) {
       const PointerType *PT = ThrowType->getAsPointerType();
       if (!PT || !PT->getPointeeType()->isVoidType())
         return StmtError(Diag(AtLoc, diag::error_objc_throw_expects_object)
@@ -1220,7 +1220,7 @@
 
   // Make sure the expression type is an ObjC pointer or "void *".
   Expr *SyncExpr = static_cast<Expr*>(SynchExpr.get());
-  if (!Context.isObjCObjectPointerType(SyncExpr->getType())) {
+  if (!SyncExpr->getType()->isObjCObjectPointerType()) {
     const PointerType *PT = SyncExpr->getType()->getAsPointerType();
     if (!PT || !PT->getPointeeType()->isVoidType())
       return StmtError(Diag(AtLoc, diag::error_objc_synchronized_expects_object)