From 00fbc8669d898689cb1a77ba34fc2d2fd4025dc9 Mon Sep 17 00:00:00 2001 From: Joonatan Saarhelo Date: Mon, 28 Oct 2024 19:26:04 +0100 Subject: [PATCH] even more leftover code --- crates/vm2/src/program.rs | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/crates/vm2/src/program.rs b/crates/vm2/src/program.rs index 7cbf0e9..6a6fc00 100644 --- a/crates/vm2/src/program.rs +++ b/crates/vm2/src/program.rs @@ -54,13 +54,12 @@ impl fmt::Debug for Program { impl> Program { /// Creates a new program. #[allow(clippy::missing_panics_doc)] // false positive - pub fn new(bytecode: &[u8], enable_hooks: bool) -> Self { + pub fn new(bytecode: &[u8]) -> Self { let instructions = decode_program( &bytecode .chunks_exact(8) .map(|chunk| u64::from_be_bytes(chunk.try_into().unwrap())) .collect::>(), - enable_hooks, ); let code_page = bytecode .chunks_exact(32) @@ -73,13 +72,12 @@ impl> Program { } /// Creates a new program from `U256` words. - pub fn from_words(bytecode_words: Vec, enable_hooks: bool) -> Self { + pub fn from_words(bytecode_words: Vec) -> Self { let instructions = decode_program( &bytecode_words .iter() .flat_map(|x| x.0.into_iter().rev()) .collect::>(), - enable_hooks, ); Self { instructions: instructions.into(),