forked from OSchip/llvm-project
Fix a really bad bug where type uniquing would merge a<x> with b<x> as the same
type, because it did not include a/b in the hash. llvm-svn: 49321
This commit is contained in:
parent
c9062d01d7
commit
64bf6ba308
|
@ -1109,6 +1109,7 @@ public:
|
|||
|
||||
void Profile(llvm::FoldingSetNodeID &ID);
|
||||
static void Profile(llvm::FoldingSetNodeID &ID,
|
||||
const ObjCInterfaceDecl *Decl,
|
||||
ObjCProtocolDecl **protocols, unsigned NumProtocols);
|
||||
|
||||
static bool classof(const Type *T) {
|
||||
|
|
|
@ -704,14 +704,16 @@ void FunctionTypeProto::Profile(llvm::FoldingSetNodeID &ID) {
|
|||
}
|
||||
|
||||
void ObjCQualifiedInterfaceType::Profile(llvm::FoldingSetNodeID &ID,
|
||||
const ObjCInterfaceDecl *Decl,
|
||||
ObjCProtocolDecl **protocols,
|
||||
unsigned NumProtocols) {
|
||||
ID.AddPointer(Decl);
|
||||
for (unsigned i = 0; i != NumProtocols; i++)
|
||||
ID.AddPointer(protocols[i]);
|
||||
}
|
||||
|
||||
void ObjCQualifiedInterfaceType::Profile(llvm::FoldingSetNodeID &ID) {
|
||||
Profile(ID, &Protocols[0], getNumProtocols());
|
||||
Profile(ID, getDecl(), &Protocols[0], getNumProtocols());
|
||||
}
|
||||
|
||||
void ObjCQualifiedIdType::Profile(llvm::FoldingSetNodeID &ID,
|
||||
|
|
Loading…
Reference in New Issue