The previous refactoring highlighted that we were ignoring the "color"
key within the "text" output scheme for diagnostics.
Fixed thusly.
Successfully bootstrapped & regrtested on x86_64-pc-linux-gnu.
Pushed to trunk as r16-4150-g5b5dba90232bd3.
gcc/ChangeLog:
* diagnostics/output-spec.cc (text_scheme_handler::make_sink): Use
the value of the "color" to determine if the sink's printer is
colorized.
---
gcc/diagnostics/output-spec.cc | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/gcc/diagnostics/output-spec.cc b/gcc/diagnostics/output-spec.cc
index 29f53771fb7e..28ea044fcc70 100644
--- a/gcc/diagnostics/output-spec.cc
+++ b/gcc/diagnostics/output-spec.cc
@@ -418,7 +418,7 @@ text_scheme_handler::make_sink (const context &ctxt,
sink->set_show_nesting (opts.m_show_nesting);
sink->set_show_locations_in_nesting (opts.m_show_locations_in_nesting);
sink->set_show_nesting_levels (opts.m_show_levels);
- // FIXME: what about show_color?
+ pp_show_color (sink->get_printer ()) = opts.m_show_color;
return sink;
}
--
2.26.3