split out AliasTy -> AliasTerm
This commit is contained in:
parent
ecbe3fd550
commit
3bcdf3058e
70 changed files with 715 additions and 414 deletions
|
@ -2205,7 +2205,7 @@ fn param_env_with_gat_bounds<'tcx>(
|
|||
_ => predicates.push(
|
||||
ty::Binder::bind_with_vars(
|
||||
ty::ProjectionPredicate {
|
||||
projection_ty: ty::AliasTy::new(tcx, trait_ty.def_id, rebased_args),
|
||||
projection_term: ty::AliasTerm::new(tcx, trait_ty.def_id, rebased_args),
|
||||
term: normalize_impl_ty.into(),
|
||||
},
|
||||
bound_vars,
|
||||
|
|
|
@ -343,9 +343,10 @@ fn bounds_from_generic_predicates<'tcx>(
|
|||
let mut projections_str = vec![];
|
||||
for projection in &projections {
|
||||
let p = projection.skip_binder();
|
||||
let alias_ty = p.projection_ty;
|
||||
if bound == tcx.parent(alias_ty.def_id) && alias_ty.self_ty() == ty {
|
||||
let name = tcx.item_name(alias_ty.def_id);
|
||||
if bound == tcx.parent(p.projection_term.def_id)
|
||||
&& p.projection_term.self_ty() == ty
|
||||
{
|
||||
let name = tcx.item_name(p.projection_term.def_id);
|
||||
projections_str.push(format!("{} = {}", name, p.term));
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue