From f1f40ac05c9d23b6a03dcd1d233f28f4794c0f07 Mon Sep 17 00:00:00 2001 From: Rune Tynan Date: Mon, 13 Feb 2023 23:19:34 -0500 Subject: Fix alloc_base_addr type --- compiler/rustc_const_eval/src/interpret/memory.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'compiler/rustc_const_eval') diff --git a/compiler/rustc_const_eval/src/interpret/memory.rs b/compiler/rustc_const_eval/src/interpret/memory.rs index a817211e745..ead4ee7b5f7 100644 --- a/compiler/rustc_const_eval/src/interpret/memory.rs +++ b/compiler/rustc_const_eval/src/interpret/memory.rs @@ -533,7 +533,7 @@ impl<'mir, 'tcx: 'mir, M: Machine<'mir, 'tcx>> InterpCx<'mir, 'tcx, M> { /// It is up to the caller to take sufficient care when using this address: /// there could be provenance or uninit memory in there, and other memory /// accesses could invalidate the exposed pointer. - pub fn alloc_base_addr(&self, id: AllocId) -> InterpResult<'tcx, *const ()> { + pub fn alloc_base_addr(&self, id: AllocId) -> InterpResult<'tcx, *const u8> { let alloc = self.get_alloc_raw(id)?; Ok(alloc.base_addr()) } -- cgit 1.4.1-3-g733a5