Store a single copy of the error registry in DiagCtxt
And pass this to the individual emitters when necessary.
This commit is contained in:
parent
ea6f5cbd2f
commit
030545d8c3
9 changed files with 67 additions and 46 deletions
|
@ -1883,7 +1883,11 @@ impl Translate for SharedEmitter {
|
|||
}
|
||||
|
||||
impl Emitter for SharedEmitter {
|
||||
fn emit_diagnostic(&mut self, mut diag: rustc_errors::DiagInner) {
|
||||
fn emit_diagnostic(
|
||||
&mut self,
|
||||
mut diag: rustc_errors::DiagInner,
|
||||
_registry: &rustc_errors::registry::Registry,
|
||||
) {
|
||||
// Check that we aren't missing anything interesting when converting to
|
||||
// the cut-down local `DiagInner`.
|
||||
assert_eq!(diag.span, MultiSpan::new());
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue