Skip to content

Commit afd23e6

Browse files
committed
Flush in emitDiagnosticMessage
1 parent 85d9445 commit afd23e6

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

clang/lib/Frontend/TextDiagnostic.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -676,6 +676,8 @@ void TextDiagnostic::emitDiagnosticMessage(
676676
/*IsSupplemental*/ Level == DiagnosticsEngine::Note,
677677
Message, OS.getColumn() - StartOfLocationInfo,
678678
DiagOpts.MessageLength, DiagOpts.ShowColors);
679+
680+
OS.flush();
679681
}
680682

681683
/*static*/ void
@@ -744,7 +746,6 @@ void TextDiagnostic::printDiagnosticMessage(raw_ostream &OS,
744746
if (ShowColors)
745747
OS.resetColor();
746748
OS << '\n';
747-
OS.flush();
748749
}
749750

750751
void TextDiagnostic::emitFilename(StringRef Filename, const SourceManager &SM) {

0 commit comments

Comments
 (0)