Arrange for the preprocessor to be passed down into the PCH writer.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@68790 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/Frontend/PCHWriter.cpp b/lib/Frontend/PCHWriter.cpp
index d4961e4..b60fc2f 100644
--- a/lib/Frontend/PCHWriter.cpp
+++ b/lib/Frontend/PCHWriter.cpp
@@ -474,6 +474,13 @@
   S.ExitBlock();
 }
 
+/// \brief Writes the block containing the serialized form of the
+/// preprocessor.
+///
+void PCHWriter::WritePreprocessor(Preprocessor &PP) {
+}
+
+
 /// \brief Write the representation of a type to the PCH stream.
 void PCHWriter::WriteType(const Type *T) {
   pch::ID &ID = TypeIDs[T];
@@ -659,7 +666,7 @@
 PCHWriter::PCHWriter(llvm::BitstreamWriter &S) 
   : S(S), NextTypeID(pch::NUM_PREDEF_TYPE_IDS) { }
 
-void PCHWriter::WritePCH(ASTContext &Context) {
+void PCHWriter::WritePCH(ASTContext &Context, Preprocessor &PP) {
   // Emit the file header.
   S.Emit((unsigned)'C', 8);
   S.Emit((unsigned)'P', 8);
@@ -673,6 +680,7 @@
   // Write the remaining PCH contents.
   S.EnterSubblock(pch::PCH_BLOCK_ID, 2);
   WriteSourceManagerBlock(Context.getSourceManager());
+  WritePreprocessor(PP);
   WriteTypesBlock(Context);
   WriteDeclsBlock(Context);
   S.ExitBlock();