From 483e3bf8595e0f497a8169b906fbf42ddd1b72e4 Mon Sep 17 00:00:00 2001 From: Joonatan Saarhelo Date: Wed, 22 Jan 2025 14:50:11 +0100 Subject: [PATCH] explicitly don't always build panicking Program --- crates/vm2/src/instruction_handlers/far_call.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/crates/vm2/src/instruction_handlers/far_call.rs b/crates/vm2/src/instruction_handlers/far_call.rs index 5d0040f..bf4e700 100644 --- a/crates/vm2/src/instruction_handlers/far_call.rs +++ b/crates/vm2/src/instruction_handlers/far_call.rs @@ -108,7 +108,7 @@ where // A far call pushes a new frame and returns from it in the next instruction if it panics. let (calldata, program, is_evm_interpreter) = - failing_part.unwrap_or((U256::zero().into(), Program::new_panicking(), false)); + failing_part.unwrap_or_else(|| (U256::zero().into(), Program::new_panicking(), false)); let stipend = if is_evm_interpreter { EVM_SIMULATOR_STIPEND