aboutsummaryrefslogtreecommitdiff
path: root/lib/AST/Type.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'lib/AST/Type.cpp')
-rw-r--r--lib/AST/Type.cpp10
1 files changed, 4 insertions, 6 deletions
diff --git a/lib/AST/Type.cpp b/lib/AST/Type.cpp
index 5477a4886d..89c39d8120 100644
--- a/lib/AST/Type.cpp
+++ b/lib/AST/Type.cpp
@@ -311,9 +311,9 @@ ObjCObjectType::ObjCObjectType(QualType Canonical, QualType Base,
ObjCProtocolDecl * const *Protocols,
unsigned NumProtocols)
: Type(ObjCObject, Canonical, false, false),
- NumProtocols(NumProtocols),
BaseType(Base) {
- assert(this->NumProtocols == NumProtocols &&
+ SubclassBits = NumProtocols;
+ assert(getNumProtocols() == NumProtocols &&
"bitfield overflow in protocol count");
if (NumProtocols)
memcpy(getProtocolStorage(), Protocols,
@@ -1026,7 +1026,7 @@ void FunctionProtoType::Profile(llvm::FoldingSetNodeID &ID, QualType Result,
unsigned TypeQuals, bool hasExceptionSpec,
bool anyExceptionSpec, unsigned NumExceptions,
exception_iterator Exs,
- const FunctionType::ExtInfo &Info) {
+ FunctionType::ExtInfo Info) {
ID.AddPointer(Result.getAsOpaquePtr());
for (unsigned i = 0; i != NumArgs; ++i)
ID.AddPointer(ArgTys[i].getAsOpaquePtr());
@@ -1038,9 +1038,7 @@ void FunctionProtoType::Profile(llvm::FoldingSetNodeID &ID, QualType Result,
for (unsigned i = 0; i != NumExceptions; ++i)
ID.AddPointer(Exs[i].getAsOpaquePtr());
}
- ID.AddInteger(Info.getNoReturn());
- ID.AddInteger(Info.getRegParm());
- ID.AddInteger(Info.getCC());
+ Info.Profile(ID);
}
void FunctionProtoType::Profile(llvm::FoldingSetNodeID &ID) {