Skip to content

Commit 724b0e4

Browse files
StrophoxRalfJung
andauthored
Comment in src/tools/miri/src/alloc_addresses/mod.rs
Co-authored-by: Ralf Jung <post@ralfj.de>
1 parent 733deeb commit 724b0e4

File tree

1 file changed

+2
-0
lines changed
  • src/tools/miri/src/alloc_addresses

1 file changed

+2
-0
lines changed

src/tools/miri/src/alloc_addresses/mod.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -300,6 +300,8 @@ pub trait EvalContextExt<'tcx>: crate::MiriInterpCxExt<'tcx> {
300300
}
301301
trace!("Exposing allocation id {alloc_id:?}");
302302
global_state.exposed.insert(alloc_id);
303+
// Release the global state before we call `expose_tag`, which may call `get_alloc_info_extra`,
304+
// which may need access to the global state.
303305
drop(global_state);
304306
if this.machine.borrow_tracker.is_some() {
305307
this.expose_tag(alloc_id, tag)?;

0 commit comments

Comments
 (0)