From: Steve Naroff Date: Mon, 29 Jun 2009 16:22:52 +0000 (+0000) Subject: Remove ASTContext::getObjCQualifiedIdType(). X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=683087ffcf21d2a22cd2d0424b7f119168b47a8e;p=clang Remove ASTContext::getObjCQualifiedIdType(). Convert clients to use ASTContext::getObjCObjectPointerType(). git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@74424 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/include/clang/AST/ASTContext.h b/include/clang/AST/ASTContext.h index aa01b7fdf0..450b28aefb 100644 --- a/include/clang/AST/ASTContext.h +++ b/include/clang/AST/ASTContext.h @@ -351,12 +351,6 @@ public: ObjCProtocolDecl **ProtocolList, unsigned NumProtocols); - /// getObjCQualifiedIdType - Return an ObjCQualifiedIdType for a - /// given 'id' and conforming protocol list. - QualType getObjCQualifiedIdType(ObjCProtocolDecl **ProtocolList, - unsigned NumProtocols); - - /// getTypeOfType - GCC extension. QualType getTypeOfExprType(Expr *e); QualType getTypeOfType(QualType t); diff --git a/lib/AST/ASTContext.cpp b/lib/AST/ASTContext.cpp index 12f75ae863..86b5817743 100644 --- a/lib/AST/ASTContext.cpp +++ b/lib/AST/ASTContext.cpp @@ -1636,13 +1636,6 @@ QualType ASTContext::getObjCQualifiedInterfaceType(ObjCInterfaceDecl *Decl, return QualType(QType, 0); } -/// getObjCQualifiedIdType - Return an ObjCQualifiedIdType for the 'id' decl -/// and the conforming protocol list. -QualType ASTContext::getObjCQualifiedIdType(ObjCProtocolDecl **Protocols, - unsigned NumProtocols) { - return getObjCObjectPointerType(0, Protocols, NumProtocols); -} - /// getTypeOfExprType - Unlike many "get" functions, we can't unique /// TypeOfExprType AST's (since expression's are never shared). For example, /// multiple declarations that refer to "typeof(x)" all contain different diff --git a/lib/Sema/SemaType.cpp b/lib/Sema/SemaType.cpp index c6bcdc36f1..abb825383e 100644 --- a/lib/Sema/SemaType.cpp +++ b/lib/Sema/SemaType.cpp @@ -89,8 +89,8 @@ QualType Sema::ConvertDeclSpecToType(const DeclSpec &DS, case DeclSpec::TST_unspecified: // "" is an objc qualified ID with a missing id. if (DeclSpec::ProtocolQualifierListTy PQ = DS.getProtocolQualifiers()) { - Result = Context.getObjCQualifiedIdType((ObjCProtocolDecl**)PQ, - DS.getNumProtocolQualifiers()); + Result = Context.getObjCObjectPointerType(0, (ObjCProtocolDecl**)PQ, + DS.getNumProtocolQualifiers()); break; } @@ -200,8 +200,8 @@ QualType Sema::ConvertDeclSpecToType(const DeclSpec &DS, DS.getNumProtocolQualifiers()); else if (Result == Context.getObjCIdType()) // id - Result = Context.getObjCQualifiedIdType((ObjCProtocolDecl**)PQ, - DS.getNumProtocolQualifiers()); + Result = Context.getObjCObjectPointerType(0, (ObjCProtocolDecl**)PQ, + DS.getNumProtocolQualifiers()); else if (Result == Context.getObjCClassType()) { if (DeclLoc.isInvalid()) DeclLoc = DS.getSourceRange().getBegin();