Use trait definition cycle detection for trait alias definitions, too

This commit is contained in:
Oli Scherer 2024-12-19 08:57:49 +00:00
parent 91b6b4e038
commit 37f2998c6e
5 changed files with 35 additions and 6 deletions

View file

@ -653,7 +653,7 @@ pub(super) fn implied_predicates_with_filter<'tcx>(
}
}
}
PredicateFilter::SelfAndAssociatedTypeBounds => {
PredicateFilter::All | PredicateFilter::SelfAndAssociatedTypeBounds => {
for &(pred, span) in implied_bounds {
debug!("superbound: {:?}", pred);
if let ty::ClauseKind::Trait(bound) = pred.kind().skip_binder()