Set groundwork for proper const normalization

This commit is contained in:
Boxy
2025-05-01 13:26:23 +01:00
parent 53e3907bcb
commit 238d113b07
18 changed files with 366 additions and 225 deletions

View File

@@ -406,7 +406,6 @@ impl<'cx, 'tcx> SelectionContext<'cx, 'tcx> {
let predicate = self.infcx.enter_forall_and_leak_universe(obligation.predicate);
let mut assume = predicate.trait_ref.args.const_at(2);
// FIXME(mgca): We should shallowly normalize this.
if self.tcx().features().generic_const_exprs() {
assume = crate::traits::evaluate_const(self.infcx, assume, obligation.param_env)
}