Skip to content

Commit 42772e9

Browse files
committed
Address review comments
1 parent 3e030b3 commit 42772e9

File tree

1 file changed

+4
-4
lines changed
  • compiler/rustc_mir_build/src/build/matches

1 file changed

+4
-4
lines changed

compiler/rustc_mir_build/src/build/matches/mod.rs

+4-4
Original file line numberDiff line numberDiff line change
@@ -1437,17 +1437,17 @@ impl<'a, 'tcx> Builder<'a, 'tcx> {
14371437
candidates: &mut [&mut Candidate<'_, 'tcx>],
14381438
) -> BasicBlock {
14391439
ensure_sufficient_stack(|| {
1440-
self.match_candidates_with_enough_stack(span, scrutinee_span, start_block, candidates)
1440+
self.match_candidates_inner(span, scrutinee_span, start_block, candidates)
14411441
})
14421442
}
14431443

14441444
/// Construct the decision tree for `candidates`. Don't call this, call `match_candidates`
14451445
/// instead to reserve sufficient stack space.
1446-
fn match_candidates_with_enough_stack(
1446+
fn match_candidates_inner(
14471447
&mut self,
14481448
span: Span,
14491449
scrutinee_span: Span,
1450-
start_block: BasicBlock,
1450+
mut start_block: BasicBlock,
14511451
candidates: &mut [&mut Candidate<'_, 'tcx>],
14521452
) -> BasicBlock {
14531453
if let [first, ..] = candidates {
@@ -1480,7 +1480,7 @@ impl<'a, 'tcx> Builder<'a, 'tcx> {
14801480
};
14811481

14821482
// Process any candidates that remain.
1483-
let BlockAnd(start_block, remaining_candidates) = rest;
1483+
let remaining_candidates = unpack!(start_block = rest);
14841484
self.match_candidates(span, scrutinee_span, start_block, remaining_candidates)
14851485
}
14861486

0 commit comments

Comments
 (0)