Determine support for colored output from stdout instead of stderr since that's where the diagnostics go.

llvm-svn: 202680
This commit is contained in:
Craig Topper 2014-03-03 07:37:42 +00:00
parent d779459f21
commit 6d73f449b8
1 changed files with 1 additions and 1 deletions

View File

@ -326,7 +326,7 @@ void handleErrors(SmallVectorImpl<ClangTidyError> &Errors, bool Fix) {
FileManager Files((FileSystemOptions()));
LangOptions LangOpts; // FIXME: use langopts from each original file
IntrusiveRefCntPtr<DiagnosticOptions> DiagOpts = new DiagnosticOptions();
DiagOpts->ShowColors = llvm::sys::Process::StandardErrHasColors();
DiagOpts->ShowColors = llvm::sys::Process::StandardOutHasColors();
DiagnosticConsumer *DiagPrinter =
new TextDiagnosticPrinter(llvm::outs(), &*DiagOpts);
DiagnosticsEngine Diags(IntrusiveRefCntPtr<DiagnosticIDs>(new DiagnosticIDs),