1
Fork 0

Tweak diagnostics on shadowing lifetimes/labels

This commit is contained in:
Yuki Okushi 2020-12-02 11:39:42 +09:00
parent 6645da366e
commit cdcce11504
13 changed files with 95 additions and 95 deletions

View file

@ -1098,7 +1098,7 @@ fn signal_shadowing_problem(tcx: TyCtxt<'_>, name: Symbol, orig: Original, shado
)
};
err.span_label(orig.span, "first declared here");
err.span_label(shadower.span, format!("lifetime {} already in scope", name));
err.span_label(shadower.span, format!("{} `{}` already in scope", orig.kind.desc(), name));
err.emit();
}