In the Module class, add a reference to the corresponding AST file.

llvm-svn: 164873
This commit is contained in:
Argyrios Kyrtzidis
2012-09-29 01:06:04 +00:00
parent 051b443242
commit 43af5132c5
3 changed files with 22 additions and 4 deletions

View File

@@ -980,6 +980,9 @@ Module *CompilerInstance::loadModule(SourceLocation ImportLoc,
Module = PP->getHeaderSearchInfo().getModuleMap()
.findModule((Path[0].first->getName()));
}
if (Module)
Module->setASTFile(ModuleFile);
// Cache the result of this top-level module lookup for later.
Known = KnownModules.insert(std::make_pair(Path[0].first, Module)).first;