diff options
| author | Oliver Scherer <github35764891676564198441@oli-obk.de> | 2019-04-09 20:43:54 +0200 |
|---|---|---|
| committer | Oliver Scherer <github35764891676564198441@oli-obk.de> | 2019-04-09 20:43:54 +0200 |
| commit | 325936ac209b8942b630e922924fc2233c94a67e (patch) | |
| tree | e438ba318b8d06a50d19fb7d6dbfbef61bc154cb | |
| parent | 776c8a309be36e271cadead765045c5305f64969 (diff) | |
Do not render ascii colors to buffers
| -rw-r--r-- | src/librustc/session/mod.rs | 4 | ||||
| -rw-r--r-- | src/librustc_errors/emitter.rs | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/src/librustc/session/mod.rs b/src/librustc/session/mod.rs index 6a0e5d98478..3711bd9fd7d 100644 --- a/src/librustc/session/mod.rs +++ b/src/librustc/session/mod.rs @@ -1050,8 +1050,8 @@ fn default_emitter( dst, Some(source_map.clone()), short, - false, - color_config.suggests_using_colors(), + false, // no teach messages when writing to a buffer + false, // no colors when writing to a buffer ), }; Box::new(emitter.ui_testing(sopts.debugging_opts.ui_testing)) diff --git a/src/librustc_errors/emitter.rs b/src/librustc_errors/emitter.rs index 5ba17d12d93..a1472479afa 100644 --- a/src/librustc_errors/emitter.rs +++ b/src/librustc_errors/emitter.rs @@ -146,7 +146,7 @@ impl ColorConfig { ColorConfig::Auto => ColorChoice::Never, } } - pub fn suggests_using_colors(self) -> bool { + fn suggests_using_colors(self) -> bool { match self { | ColorConfig::Always | ColorConfig::Auto |
