[cfe-commits] r143647 - /cfe/trunk/lib/Frontend/ASTUnit.cpp
Argyrios Kyrtzidis
akyrtzi at gmail.com
Thu Nov 3 13:57:33 PDT 2011
Author: akirtzidis
Date: Thu Nov 3 15:57:33 2011
New Revision: 143647
URL: http://llvm.org/viewvc/llvm-project?rev=143647&view=rev
Log:
After resetting the diagnostic state, set the number of warning occurring in the preamble.
Modified:
cfe/trunk/lib/Frontend/ASTUnit.cpp
Modified: cfe/trunk/lib/Frontend/ASTUnit.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Frontend/ASTUnit.cpp?rev=143647&r1=143646&r2=143647&view=diff
==============================================================================
--- cfe/trunk/lib/Frontend/ASTUnit.cpp (original)
+++ cfe/trunk/lib/Frontend/ASTUnit.cpp Thu Nov 3 15:57:33 2011
@@ -1940,6 +1940,8 @@
// Clear out the diagnostics state.
getDiagnostics().Reset();
ProcessWarningOptions(getDiagnostics(), Invocation->getDiagnosticOpts());
+ if (OverrideMainBuffer)
+ getDiagnostics().setNumWarnings(NumWarningsInPreamble);
// Parse the sources
bool Result = Parse(OverrideMainBuffer);
More information about the cfe-commits
mailing list