Introduce PredicateKind::Clause
This commit is contained in:
@@ -1378,7 +1378,7 @@ impl<'o, 'tcx> dyn AstConv<'tcx> + 'o {
|
||||
|
||||
let bound_predicate = obligation.predicate.kind();
|
||||
match bound_predicate.skip_binder() {
|
||||
ty::PredicateKind::Trait(pred) => {
|
||||
ty::PredicateKind::Clause(ty::Clause::Trait(pred)) => {
|
||||
let pred = bound_predicate.rebind(pred);
|
||||
associated_types.entry(span).or_default().extend(
|
||||
tcx.associated_items(pred.def_id())
|
||||
@@ -1387,7 +1387,7 @@ impl<'o, 'tcx> dyn AstConv<'tcx> + 'o {
|
||||
.map(|item| item.def_id),
|
||||
);
|
||||
}
|
||||
ty::PredicateKind::Projection(pred) => {
|
||||
ty::PredicateKind::Clause(ty::Clause::Projection(pred)) => {
|
||||
let pred = bound_predicate.rebind(pred);
|
||||
// A `Self` within the original bound will be substituted with a
|
||||
// `trait_object_dummy_self`, so check for that.
|
||||
|
||||
Reference in New Issue
Block a user