Set Config->ColorDiagnostics early so that all error messages are colored.
authorRui Ueyama <ruiu@google.com>
Tue, 20 Dec 2016 02:17:24 +0000 (02:17 +0000)
committerRui Ueyama <ruiu@google.com>
Tue, 20 Dec 2016 02:17:24 +0000 (02:17 +0000)
commit398f55f6f67d3b9cb31b67e564bc4ded2fab645f
tree27d32dce5743af97300e2a4f9ed886b31b7a3c06
parent51e60f9aeb09c7c25d31c70d414d2a7e0c9a03e3
Set Config->ColorDiagnostics early so that all error messages are colored.

Previously, some errors that were checked before we set to
Config->ColorDiagnostics weren't colored. This patch moves the code
to set the variable so that such error messages are colored just like
other error messages.

llvm-svn: 290157
lld/ELF/Driver.cpp
lld/ELF/DriverUtils.cpp
lld/test/ELF/color-diagnostics.test