forked from OSchip/llvm-project
Make the FileID import map key on FileID.
llvm-svn: 115118
This commit is contained in:
parent
517523014d
commit
99219f16b9
|
@ -63,7 +63,7 @@ namespace clang {
|
|||
|
||||
/// \brief Mapping from the already-imported FileIDs in the "from" source
|
||||
/// manager to the corresponding FileIDs in the "to" source manager.
|
||||
llvm::DenseMap<unsigned, FileID> ImportedFileIDs;
|
||||
llvm::DenseMap<FileID, FileID> ImportedFileIDs;
|
||||
|
||||
/// \brief Imported, anonymous tag declarations that are missing their
|
||||
/// corresponding typedefs.
|
||||
|
|
|
@ -3130,8 +3130,8 @@ SourceRange ASTImporter::Import(SourceRange FromRange) {
|
|||
}
|
||||
|
||||
FileID ASTImporter::Import(FileID FromID) {
|
||||
llvm::DenseMap<unsigned, FileID>::iterator Pos
|
||||
= ImportedFileIDs.find(FromID.getHashValue());
|
||||
llvm::DenseMap<FileID, FileID>::iterator Pos
|
||||
= ImportedFileIDs.find(FromID);
|
||||
if (Pos != ImportedFileIDs.end())
|
||||
return Pos->second;
|
||||
|
||||
|
@ -3164,7 +3164,7 @@ FileID ASTImporter::Import(FileID FromID) {
|
|||
}
|
||||
|
||||
|
||||
ImportedFileIDs[FromID.getHashValue()] = ToID;
|
||||
ImportedFileIDs[FromID] = ToID;
|
||||
return ToID;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue