From 4f92016ed3683607fba0d6253f4f0ae5cd29219a Mon Sep 17 00:00:00 2001 From: Argyrios Kyrtzidis Date: Thu, 23 Sep 2010 12:56:06 +0000 Subject: [PATCH] If -fcolor-diagnostics is explicitly passed to the driver respect that even if the driver is of the opinion that stderr can't handle them. (see http://llvm.org/PR8150) Patch by Frits van Bommel! llvm-svn: 114638 --- clang/lib/Driver/Tools.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/clang/lib/Driver/Tools.cpp b/clang/lib/Driver/Tools.cpp index bfb42d81ecd2..16339c4bd123 100644 --- a/clang/lib/Driver/Tools.cpp +++ b/clang/lib/Driver/Tools.cpp @@ -1414,8 +1414,8 @@ void Clang::ConstructJob(Compilation &C, const JobAction &JA, // Color diagnostics are the default, unless the terminal doesn't support // them. if (Args.hasFlag(options::OPT_fcolor_diagnostics, - options::OPT_fno_color_diagnostics) && - llvm::sys::Process::StandardErrHasColors()) + options::OPT_fno_color_diagnostics, + llvm::sys::Process::StandardErrHasColors())) CmdArgs.push_back("-fcolor-diagnostics"); if (!Args.hasFlag(options::OPT_fshow_source_location,