Don't try to label ObligationCauseCode::CompareImplItem for an RPITIT, since it has no name
This commit is contained in:
parent
8a8ad3433e
commit
d6276b37ea
4 changed files with 228 additions and 24 deletions
|
@ -3472,6 +3472,10 @@ impl<'a, 'tcx> TypeErrCtxt<'a, 'tcx> {
|
|||
)
|
||||
});
|
||||
}
|
||||
// Suppress `compare_type_predicate_entailment` errors for RPITITs, since they
|
||||
// should be implied by the parent method.
|
||||
ObligationCauseCode::CompareImplItem { trait_item_def_id, .. }
|
||||
if tcx.is_impl_trait_in_trait(trait_item_def_id) => {}
|
||||
ObligationCauseCode::CompareImplItem { trait_item_def_id, kind, .. } => {
|
||||
let item_name = tcx.item_name(trait_item_def_id);
|
||||
let msg = format!(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue