Skip to content

Commit

Permalink
dont iterate over the bitset
Browse files Browse the repository at this point in the history
  • Loading branch information
RalfJung committed Aug 25, 2024
1 parent 172c05c commit 74a2142
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions compiler/rustc_const_eval/src/check_consts/check.rs
Original file line number Diff line number Diff line change
Expand Up @@ -289,10 +289,8 @@ impl<'mir, 'tcx> Checker<'mir, 'tcx> {
if matches!(data.terminator().kind, TerminatorKind::Return) {
let location = ccx.body.terminator_loc(bb);
maybe_storage_live.seek_after_primary_effect(location);
for local in maybe_storage_live.get().iter() {
// If a local may be live here, it is definitely not transient.
transient.remove(local);
}
// If a local may be live here, it is definitely not transient.
transient.subtract(maybe_storage_live.get());
}
}

Expand Down

0 comments on commit 74a2142

Please sign in to comment.