From 2cef9e3d19087a83fe1431ab8fd915cffd6a22ec Mon Sep 17 00:00:00 2001 From: Ralf Jung Date: Sun, 6 Nov 2022 13:00:09 +0100 Subject: interpret: support for per-byte provenance --- compiler/rustc_monomorphize/src/collector.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'compiler/rustc_monomorphize/src') diff --git a/compiler/rustc_monomorphize/src/collector.rs b/compiler/rustc_monomorphize/src/collector.rs index 58ddb807059..e296d4766c1 100644 --- a/compiler/rustc_monomorphize/src/collector.rs +++ b/compiler/rustc_monomorphize/src/collector.rs @@ -456,7 +456,7 @@ fn collect_items_rec<'tcx>( recursion_depth_reset = None; if let Ok(alloc) = tcx.eval_static_initializer(def_id) { - for &id in alloc.inner().provenance().values() { + for &id in alloc.inner().provenance().ptrs().values() { collect_miri(tcx, id, &mut neighbors); } } @@ -1404,7 +1404,7 @@ fn collect_miri<'tcx>(tcx: TyCtxt<'tcx>, alloc_id: AllocId, output: &mut MonoIte } GlobalAlloc::Memory(alloc) => { trace!("collecting {:?} with {:#?}", alloc_id, alloc); - for &inner in alloc.inner().provenance().values() { + for &inner in alloc.inner().provenance().ptrs().values() { rustc_data_structures::stack::ensure_sufficient_stack(|| { collect_miri(tcx, inner, output); }); @@ -1443,7 +1443,7 @@ fn collect_const_value<'tcx>( match value { ConstValue::Scalar(Scalar::Ptr(ptr, _size)) => collect_miri(tcx, ptr.provenance, output), ConstValue::Slice { data: alloc, start: _, end: _ } | ConstValue::ByRef { alloc, .. } => { - for &id in alloc.inner().provenance().values() { + for &id in alloc.inner().provenance().ptrs().values() { collect_miri(tcx, id, output); } } -- cgit 1.4.1-3-g733a5