Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 9b7e0a7

Browse files
authored
chore: Rename execute_metered_until_suspension to execute_metered_until_suspend (#2144)
1 parent 07a2e10 commit 9b7e0a7

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

crates/sdk/tests/integration_test.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -285,7 +285,7 @@ fn test_metered_execution_suspension() -> eyre::Result<()> {
285285
let metered_ctx = vm.build_metered_ctx(&exe).with_suspend_on_segment(true);
286286
let vm_state = interpreter.create_initial_vm_state(vec![]);
287287
let mut vm_exec_state = VmExecState::new(vm_state, metered_ctx);
288-
vm_exec_state = interpreter.execute_metered_until_suspension(vm_exec_state)?;
288+
vm_exec_state = interpreter.execute_metered_until_suspend(vm_exec_state)?;
289289
assert!(
290290
vm_exec_state.exit_code.is_ok(),
291291
"Execution exits with an error: {:?}",

crates/vm/src/arch/interpreter.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -410,7 +410,7 @@ where
410410
let mut exec_state = VmExecState::new(from_state, ctx);
411411

412412
loop {
413-
exec_state = self.execute_metered_until_suspension(exec_state)?;
413+
exec_state = self.execute_metered_until_suspend(exec_state)?;
414414
// The execution has terminated.
415415
if exec_state.exit_code.is_ok() && exec_state.exit_code.as_ref().unwrap().is_some() {
416416
break;
@@ -443,7 +443,7 @@ where
443443
/// normal completion.
444444
/// - `Err(ExecutionError)`: If there is an error during execution, such as an invalid state or
445445
/// run-time error.
446-
pub fn execute_metered_until_suspension(
446+
pub fn execute_metered_until_suspend(
447447
&self,
448448
mut exec_state: VmExecState<F, GuestMemory, MeteredCtx>,
449449
) -> Result<VmExecState<F, GuestMemory, MeteredCtx>, ExecutionError> {

0 commit comments

Comments
 (0)