implement and use NormalizesTo

This commit is contained in:
lcnr
2023-12-07 18:20:27 +01:00
parent 3978f545ba
commit ffb4c08a81
21 changed files with 135 additions and 125 deletions

View File

@@ -76,7 +76,7 @@ impl<'tcx> NormalizationFolder<'_, 'tcx> {
tcx,
self.at.cause.clone(),
self.at.param_env,
ty::ProjectionPredicate { projection_ty: alias, term: new_infer_ty.into() },
ty::NormalizesTo { alias, term: new_infer_ty.into() },
);
// Do not emit an error if normalization is known to fail but instead
@@ -129,8 +129,8 @@ impl<'tcx> NormalizationFolder<'_, 'tcx> {
tcx,
self.at.cause.clone(),
self.at.param_env,
ty::ProjectionPredicate {
projection_ty: AliasTy::new(tcx, uv.def, uv.args),
ty::NormalizesTo {
alias: AliasTy::new(tcx, uv.def, uv.args),
term: new_infer_ct.into(),
},
);