Skip to content

Commit

Permalink
Rollup merge of #119601 - nnethercote:Emitter-cleanups, r=oli-obk
Browse files Browse the repository at this point in the history
`Emitter` cleanups

Some improvements I found while looking at this code.

r? `@oli-obk`
  • Loading branch information
compiler-errors committed Jan 5, 2024
2 parents 4a1b418 840824f commit 250d7e7
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/parse/session.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 2,7 @@ use std::path::Path;
use std::sync::atomic::{AtomicBool, Ordering};

use rustc_data_structures::sync::{IntoDynSyncSend, Lrc};
use rustc_errors::emitter::{DynEmitter, Emitter, EmitterWriter};
use rustc_errors::emitter::{DynEmitter, Emitter, HumanEmitter};
use rustc_errors::translation::Translate;
use rustc_errors::{ColorConfig, DiagCtxt, Diagnostic, Level as DiagnosticLevel};
use rustc_session::parse::ParseSess as RawParseSess;
Expand Down Expand Up @@ -139,7 139,7 @@ fn default_dcx(
rustc_driver::DEFAULT_LOCALE_RESOURCES.to_vec(),
false,
);
Box::new(EmitterWriter::stderr(emit_color, fallback_bundle).sm(Some(source_map.clone())))
Box::new(HumanEmitter::stderr(emit_color, fallback_bundle).sm(Some(source_map.clone())))
};
DiagCtxt::with_emitter(Box::new(SilentOnIgnoredFilesEmitter {
has_non_ignorable_parser_errors: false,
Expand Down

0 comments on commit 250d7e7

Please sign in to comment.