зеркало из https://github.com/microsoft/clang-1.git
slightly simplify interface
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@42858 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Родитель
b2cf3573d7
Коммит
00bb283ecd
|
@ -627,9 +627,8 @@ QualType ASTContext::getObjcQualifiedInterfaceType(ObjcInterfaceDecl *Decl,
|
|||
return QualType(QT, 0);
|
||||
|
||||
// No Match;
|
||||
ObjcQualifiedInterfaceType *QType = new ObjcQualifiedInterfaceType(IType);
|
||||
for (unsigned i = 0; i != NumProtocols; i++)
|
||||
QType->setProtocols(Protocols[i]);
|
||||
ObjcQualifiedInterfaceType *QType =
|
||||
new ObjcQualifiedInterfaceType(IType, Protocols, NumProtocols);
|
||||
Types.push_back(QType);
|
||||
ObjcQualifiedInterfaceTypes.InsertNode(QType, InsertPos);
|
||||
return QualType(QType, 0);
|
||||
|
|
|
@ -846,12 +846,10 @@ class ObjcQualifiedInterfaceType : public Type, public llvm::FoldingSetNode {
|
|||
// List is sorted on protocol name. No protocol is enterred more than once.
|
||||
llvm::SmallVector<ObjcProtocolDecl*, 8> Protocols;
|
||||
|
||||
ObjcQualifiedInterfaceType(ObjcInterfaceType *T) :
|
||||
Type(ObjcQualifiedInterface, QualType()), InterfaceType(T) { }
|
||||
|
||||
void setProtocols(ObjcProtocolDecl *pType) {
|
||||
Protocols.push_back(pType);
|
||||
}
|
||||
ObjcQualifiedInterfaceType(ObjcInterfaceType *T,
|
||||
ObjcProtocolDecl **Protos, unsigned NumP) :
|
||||
Type(ObjcQualifiedInterface, QualType()), InterfaceType(T),
|
||||
Protocols(Protos, Protos+NumP) { }
|
||||
friend class ASTContext; // ASTContext creates these.
|
||||
public:
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче