diff options
Diffstat (limited to 'lib/Frontend/CompilerInstance.cpp')
| -rw-r--r-- | lib/Frontend/CompilerInstance.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/Frontend/CompilerInstance.cpp b/lib/Frontend/CompilerInstance.cpp index f12f6303f0..267d318fa9 100644 --- a/lib/Frontend/CompilerInstance.cpp +++ b/lib/Frontend/CompilerInstance.cpp @@ -870,8 +870,9 @@ static void compileModuleImpl(CompilerInstance &ImportingInstance, SourceMgr.overrideFileContents(ModuleMapFile, ModuleMapBuffer); } - // Construct a module-generating action. - GenerateModuleAction CreateModuleAction(Module->IsSystem); + // Construct a module-generating action. Passing through Module->ModuleMap is + // safe because the FileManager is shared between the compiler instances. + GenerateModuleAction CreateModuleAction(Module->ModuleMap, Module->IsSystem); // Execute the action to actually build the module in-place. Use a separate // thread so that we get a stack large enough. |
