From 9afe191bcac0e6ec5cc3958b90d06e0b7aa94580 Mon Sep 17 00:00:00 2001 From: Jakub Doka Date: Sun, 22 Dec 2024 21:41:28 +0100 Subject: [PATCH] fixed a missing feature Signed-off-by: Jakub Doka --- vm/src/mem/mod.rs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/vm/src/mem/mod.rs b/vm/src/mem/mod.rs index c82db5cb..d2174ac0 100644 --- a/vm/src/mem/mod.rs +++ b/vm/src/mem/mod.rs @@ -41,6 +41,7 @@ pub trait Memory { fn log_instr(&mut self, _at: Address, _regs: &[Value]) {} } +#[cfg(feature = "alloc")] #[derive(Default)] pub struct InstrLogger { #[cfg(debug_assertions)] @@ -49,6 +50,7 @@ pub struct InstrLogger { disp_buf: alloc::string::String, } +#[cfg(feature = "alloc")] impl InstrLogger { /// # Safety /// - `addr` needs to point to a valid instruction