diff options
| author | Matthias Krüger <476013+matthiaskrgr@users.noreply.github.com> | 2025-04-02 19:44:13 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-04-02 19:44:13 +0200 |
| commit | f5276bb0cf4d0aea6771dafbd6b809b72b42bf72 (patch) | |
| tree | 8d841ed5c749447a1a2e77cba815d8351606b704 /src | |
| parent | 3fb1230adc5598f97dbb2853bb84dde5ef51c05f (diff) | |
| parent | e638ba69f09d72b0f1e2f00b03ff530460d1bfe3 (diff) | |
| download | rust-f5276bb0cf4d0aea6771dafbd6b809b72b42bf72.tar.gz rust-f5276bb0cf4d0aea6771dafbd6b809b72b42bf72.zip | |
Rollup merge of #139211 - RalfJung:interpret-run-for-validation, r=oli-obk
interpret: add a version of run_for_validation for &self Turns out we'll need this for some ongoing work in Miri. r? ``@oli-obk``
Diffstat (limited to 'src')
| -rw-r--r-- | src/tools/miri/src/concurrency/data_race.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/tools/miri/src/concurrency/data_race.rs b/src/tools/miri/src/concurrency/data_race.rs index b1ca434361b..923031dbbd1 100644 --- a/src/tools/miri/src/concurrency/data_race.rs +++ b/src/tools/miri/src/concurrency/data_race.rs @@ -717,7 +717,7 @@ pub trait EvalContextExt<'tcx>: MiriInterpCxExt<'tcx> { // The program didn't actually do a read, so suppress the memory access hooks. // This is also a very special exception where we just ignore an error -- if this read // was UB e.g. because the memory is uninitialized, we don't want to know! - let old_val = this.run_for_validation(|this| this.read_scalar(dest)).discard_err(); + let old_val = this.run_for_validation_mut(|this| this.read_scalar(dest)).discard_err(); this.allow_data_races_mut(move |this| this.write_scalar(val, dest))?; this.validate_atomic_store(dest, atomic)?; this.buffered_atomic_write(val, dest, atomic, old_val) |
