Auto merge of #83781 - JohnTitor:rollup-1vm3dxo, r=JohnTitor
Rollup of 5 pull requests Successful merges: - #83535 (Break when there is a mismatch in the type count) - #83721 (Add a button to copy the "use statement") - #83740 (Fix comment typo in once.rs) - #83745 (Add my new email address to .mailmap) - #83754 (Add test to ensure search tabs behaviour) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
This commit is contained in:
commit
a207871d5c
14 changed files with 118 additions and 16 deletions
|
@ -70,6 +70,12 @@ impl<'a, 'tcx> TypeChecker<'a, 'tcx> {
|
|||
|
||||
// Equate expected input tys with those in the MIR.
|
||||
for (argument_index, &normalized_input_ty) in normalized_input_tys.iter().enumerate() {
|
||||
if argument_index + 1 >= body.local_decls.len() {
|
||||
self.tcx()
|
||||
.sess
|
||||
.delay_span_bug(body.span, "found more normalized_input_ty than local_decls");
|
||||
break;
|
||||
}
|
||||
// In MIR, argument N is stored in local N+1.
|
||||
let local = Local::new(argument_index + 1);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue