aboutsummaryrefslogtreecommitdiff
path: root/lib/Frontend/ASTUnit.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'lib/Frontend/ASTUnit.cpp')
-rw-r--r--lib/Frontend/ASTUnit.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/Frontend/ASTUnit.cpp b/lib/Frontend/ASTUnit.cpp
index 7c15d82d3b..88c55a885a 100644
--- a/lib/Frontend/ASTUnit.cpp
+++ b/lib/Frontend/ASTUnit.cpp
@@ -848,7 +848,9 @@ llvm::MemoryBuffer *ASTUnit::BuildPrecompiledPreamble() {
// Tell the compiler invocation to generate a temporary precompiled header.
FrontendOpts.ProgramAction = frontend::GeneratePCH;
- // FIXME: Set ChainedPCH, once it is ready.
+ // FIXME: Set ChainedPCH unconditionally, once it is ready.
+ if (::getenv("LIBCLANG_CHAINING"))
+ FrontendOpts.ChainedPCH = true;
// FIXME: Generate the precompiled header into memory?
FrontendOpts.OutputFile = GetPreamblePCHPath();