Change:
<!-- Thank you for finding an Internal Compiler Error! If possible, try to provide a minimal verifiable example. You can read "Rust Bug Minimization Patterns" for how to create smaller examples. --<!-- If you're using the stable version of the compiler, you should also check if the bug also exists in the beta or nightly versions. --: <!-- Include a backtrace in the code block by setting in your environment. E.g. . --<details<summary<strongBacktrace</strong</summary<p</p</details
Regression in nightly-2023-04-20 commit[0] 2023-04-18: Auto merge of - petrochenkov:slimchild, r=cjgillot commit[1] 2023-04-18: Auto merge of - saethlin:encode-hashes-as-bytes, r=cjgillot commit[2] 2023-04-19: Auto merge of - jyn514:download-rustc-tests, r=albertlarsan68 commit[3] 2023-04-19: Auto merge of - miguelraz:canoodling2-electric-boogaloo, r=compiler-errors commit[4] 2023-04-19: Auto merge of - matthiaskrgr:rollup-9m7rw3u, r=matthiaskrgr commit[5] 2023-04-19: Auto merge of - Nilstrieb:fluent-macro, r=davidtwco commit[6] 2023-04-19: Auto merge of - fee1-dead-contrib:rm-const-traits, r=oli-obk commit[7] 2023-04-19: Auto merge of - WaffleLapkin:‍sound, r=compiler-errors commit[8] 2023-04-19: Auto merge of - matthiaskrgr:rollup-346kik6, r=matthiaskrgr commit[9] 2023-04-19: Auto merge of - ecnelises:big_archive, r=bjorn3 ERROR: no CI builds available between and within last 167 days
Oh this might be contained in the first rollup ping reduced a bit: `
WG-prioritization assigning priority (). label -I-prioritize +P-medium

Discussion:
return None; }; <del> self.commit_if_ok(|_| { </del> <ins> self.commit_if_ok(|snapshot| { let outer_universe = self.universe(); </ins> let ocx = ObligationCtxt::new(self); let impl_args = self.fresh_args_for_item(base_expr.span, impl_def_id); let impl_trait_ref =

// Match the impl self type against the base ty. If this fails, // we just skip this impl, since it's not particularly useful. let impl_trait_ref = ocx.normalize(&cause, self.param_env, impl_trait_ref); <del> ocx.eq(&cause, self.param_env, impl_trait_ref.self_ty(), base_ty)?; </del> <ins> ocx.eq(&cause, self.param_env, base_ty, impl_trait_ref.self_ty())?; </ins> // Register the impl's predicates. One of these predicates // must be unsatisfied, or else we wouldn't have gotten here

Ty::new_projection(self.tcx, index_trait_output_def_id, impl_trait_ref.args), ); <del> let errors = ocx.select_where_possible(); </del> <ins> let true_errors = ocx.select_where_possible(); // Do a leak check -- we can't really report report a useful error here, // but it at least avoids an ICE when the error has to do with higher-ranked // lifetimes. self.leak_check(outer_universe, Some(snapshot))?; // Bail if we have ambiguity errors, which we can't report in a useful way. let ambiguity_errors = ocx.select_all_or_error(); if true_errors.is_empty() && !ambiguity_errors.is_empty() { return Err(NoSolution); } </ins> // There should be at least one error reported. If not, we // will still delay a span bug in `report_fulfillment_errors`. Ok::<_, NoSolution>(( <del> self.err_ctxt().report_fulfillment_errors(errors), </del> <ins> self.err_ctxt().report_fulfillment_errors(true_errors), </ins> impl_trait_ref.args.type_at(1), element_ty, ))

<ins> // Test against ICE in #118111 use std::ops::Index; struct Map<T, F> { f: F, inner: T, } impl<T, F, Idx> Index<Idx> for Map<T, F> where T: Index<Idx>, F: FnOnce(&T, Idx) -> Idx, { type Output = T::Output; fn index(&self, index: Idx) -> &Self::Output { todo!() } } fn main() { Map { inner: [0_usize], f: |_, i: usize| 1_usize }[0]; //~^ ERROR cannot index into a value of type // Problem here is that //   `f: |_, i: usize| ...` // should be //   `f: |_: &_, i: usize| ...` } </ins>

<ins> error[E0608]: cannot index into a value of type `Map<[usize; 1], {closure@$DIR/bad-index-modulo-higher-ranked-regions.rs:23:32: 23:45}>` --> $DIR/bad-index-modulo-higher-ranked-regions.rs:23:55 | LL |     Map { inner: [0_usize], f: |_, i: usize| 1_usize }[0]; |                                                       ^^^ error: aborting due to previous error For more information about this error, try `rustc --explain E0608`. </ins>