1
Fork 0

Modify primary span label for E0308

The previous output was unintuitive to users.
This commit is contained in:
Esteban Küber 2023-01-02 18:00:33 -08:00
parent 006ca9b14d
commit 62ba3e70a1
383 changed files with 889 additions and 926 deletions

View file

@ -2454,7 +2454,9 @@ impl<'cx, 'tcx> SelectionContext<'cx, 'tcx> {
.at(&cause, obligation.param_env)
.define_opaque_types(false)
.eq(placeholder_obligation_trait_ref, impl_trait_ref)
.map_err(|e| debug!("match_impl: failed eq_trait_refs due to `{e}`"))?;
.map_err(|e| {
debug!("match_impl: failed eq_trait_refs due to `{}`", e.to_string(self.tcx()))
})?;
nested_obligations.extend(obligations);
if !self.is_intercrate()