diff options
author | Steve Naroff <snaroff@apple.com> | 2009-07-16 15:41:00 +0000 |
---|---|---|
committer | Steve Naroff <snaroff@apple.com> | 2009-07-16 15:41:00 +0000 |
commit | f49545602089be5b1f744e04326b8a566f6d8773 (patch) | |
tree | c6a833eba46840cff3d65f06772865ffe525c711 /lib/Sema/SemaStmt.cpp | |
parent | 95b851e55c328af4b69da7bfc1124bf258c0ffe5 (diff) |
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
Diffstat (limited to 'lib/Sema/SemaStmt.cpp')
-rw-r--r-- | lib/Sema/SemaStmt.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/lib/Sema/SemaStmt.cpp b/lib/Sema/SemaStmt.cpp index 63191e0e00..bd2b0aef3d 100644 --- a/lib/Sema/SemaStmt.cpp +++ b/lib/Sema/SemaStmt.cpp @@ -669,14 +669,14 @@ Sema::ActOnObjCForCollectionStmt(SourceLocation ForLoc, 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 @@ Sema::ActOnObjCAtCatchStmt(SourceLocation AtLoc, 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 @@ Sema::ActOnObjCAtThrowStmt(SourceLocation AtLoc, ExprArg expr,Scope *CurScope) { } 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 @@ Sema::ActOnObjCAtSynchronizedStmt(SourceLocation AtLoc, ExprArg SynchExpr, // 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) |