Skip to content

Commit fc7c38f

Browse files
committed
Make Scope private to rustc_mir::build::scope::stack
The logic for finding the correct unwind scopes is going to become more complicated, so we want to limit the amount of code that can directly access the fields of `Scope`.
1 parent 72645c3 commit fc7c38f

File tree

3 files changed

+361
-312
lines changed

3 files changed

+361
-312
lines changed

src/librustc_mir/build/matches/mod.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -228,7 +228,7 @@ impl<'a, 'tcx> Builder<'a, 'tcx> {
228228
};
229229

230230
// Step 5. Create everything else: the guards and the arms.
231-
let match_scope = self.scopes.topmost();
231+
let match_scope = self.topmost_scope();
232232

233233
let arm_end_blocks: Vec<_> = arm_candidates.into_iter().map(|(arm, mut candidates)| {
234234
let arm_source_info = self.source_info(arm.span);

0 commit comments

Comments
 (0)