From cbdbbd1ba105e65c5c1afa30c6c64f44adf56ad4 Mon Sep 17 00:00:00 2001 From: Argyrios Kyrtzidis Date: Fri, 26 Apr 2013 21:33:27 +0000 Subject: [frontend] Make -chain-include work when used with modules. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@180633 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/Frontend/FrontendAction.cpp | 2 ++ 1 file changed, 2 insertions(+) (limited to 'lib/Frontend/FrontendAction.cpp') diff --git a/lib/Frontend/FrontendAction.cpp b/lib/Frontend/FrontendAction.cpp index 6031ad2b36..ece51a3570 100644 --- a/lib/Frontend/FrontendAction.cpp +++ b/lib/Frontend/FrontendAction.cpp @@ -294,6 +294,8 @@ bool FrontendAction::BeginSourceFile(CompilerInstance &CI, source.reset(ChainedIncludesSource::create(CI)); if (!source) goto failure; + CI.setModuleManager(static_cast( + &static_cast(source.get())->getFinalReader())); CI.getASTContext().setExternalSource(source); } else if (!CI.getPreprocessorOpts().ImplicitPCHInclude.empty()) { -- cgit v1.2.3-18-g5258