[cfe-commits] r113379 - /cfe/trunk/lib/Frontend/PrintPreprocessedOutput.cpp
Daniel Dunbar
daniel at zuster.org
Wed Sep 8 11:19:55 PDT 2010
Author: ddunbar
Date: Wed Sep 8 13:19:55 2010
New Revision: 113379
URL: http://llvm.org/viewvc/llvm-project?rev=113379&view=rev
Log:
Frontend/-H: Add comment on why I used a temporary string here.
Modified:
cfe/trunk/lib/Frontend/PrintPreprocessedOutput.cpp
Modified: cfe/trunk/lib/Frontend/PrintPreprocessedOutput.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Frontend/PrintPreprocessedOutput.cpp?rev=113379&r1=113378&r2=113379&view=diff
==============================================================================
--- cfe/trunk/lib/Frontend/PrintPreprocessedOutput.cpp (original)
+++ cfe/trunk/lib/Frontend/PrintPreprocessedOutput.cpp Wed Sep 8 13:19:55 2010
@@ -263,6 +263,7 @@
// predefines buffer.
if (DumpHeaderIncludes && HasProcessedPredefines &&
Reason == PPCallbacks::EnterFile) {
+ // Write to a temporary string to avoid unnecessary flushing on errs().
llvm::SmallString<256> Msg;
llvm::raw_svector_ostream OS(Msg);
for (unsigned i = 0; i != CurrentIncludeDepth; ++i)
More information about the cfe-commits
mailing list