We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 39b257b commit 2a68f2bCopy full SHA for 2a68f2b
src/shims/native_lib/mod.rs
@@ -242,14 +242,9 @@ trait EvalContextExtPriv<'tcx>: crate::MiriInterpCxExt<'tcx> {
242
243
match evt {
244
AccessEvent::Read(_) => {
245
- // FIXME: ProvenanceMap should have something like get_range().
246
- let p_map = alloc.provenance();
247
- for idx in overlap {
248
- // If a provenance was read by the foreign code, expose it.
249
- if let Some((prov, _idx)) = p_map.get_byte(Size::from_bytes(idx), this)
250
- {
251
- this.expose_provenance(prov)?;
252
- }
+ // If a provenance was read by the foreign code, expose it.
+ for prov in alloc.provenance().get_range(this, overlap.into()) {
+ this.expose_provenance(prov)?;
253
}
254
255
AccessEvent::Write(_, certain) => {
0 commit comments