Skip to content

Commit b7c4d5b

Browse files
committed
fixup! refactor extract_span_scope
1 parent 9ff6ae5 commit b7c4d5b

1 file changed

Lines changed: 1 addition & 2 deletions

File tree

  • compiler/rustc_mir_build/src/builder/matches

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

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2607,8 +2607,7 @@ impl<'a, 'tcx> Builder<'a, 'tcx> {
26072607
let span = arm.guard.map(|guard| self.thir[guard].span).unwrap_or(arm.span);
26082608
(span, arm.scope)
26092609
})
2610-
// FIXME(guard_patterns)
2611-
.unwrap_or_else(|| (sub_branch_span, self.local_scope()))
2610+
.unwrap_or_else(|| span_bug!(sub_branch_span, "guards are present, but the arm isn't"))
26122611
}
26132612

26142613
/// Append `AscribeUserType` statements onto the end of `block`

0 commit comments

Comments
 (0)