From: Daniel Dunbar Date: Mon, 21 Sep 2009 03:03:47 +0000 (+0000) Subject: Change ASTUnit to only initialize the predefines buffer to the suggested predefines. X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=d5b6126389e1e2fd89e498fe17da4bb44ece0302;p=clang Change ASTUnit to only initialize the predefines buffer to the suggested predefines. - It isn't really clear what to do with the preprocessor here, but this is more sensible. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@82431 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/lib/Frontend/ASTUnit.cpp b/lib/Frontend/ASTUnit.cpp index 1e2ad46b93..d3475b5236 100644 --- a/lib/Frontend/ASTUnit.cpp +++ b/lib/Frontend/ASTUnit.cpp @@ -126,7 +126,7 @@ ASTUnit *ASTUnit::LoadFromPCHFile(const std::string &Filename, AST->getSourceManager(), HeaderInfo)); Preprocessor &PP = *AST->PP.get(); - PP.setPredefines(Predefines); + PP.setPredefines(Reader->getSuggestedPredefines()); PP.setCounterValue(Counter); Reader->setPreprocessor(PP);