diff --git a/pulley/src/interp.rs b/pulley/src/interp.rs index 18f146f648f4..e8a0b7ab5199 100644 --- a/pulley/src/interp.rs +++ b/pulley/src/interp.rs @@ -1885,7 +1885,7 @@ impl OpVisitor for Interpreter<'_> { // Decrement the stack pointer `amt` bytes plus 2 pointers more for // fp/lr. let ptr_size = size_of::(); - let full_amt = usize::try_from(amt).unwrap() + 2 * ptr_size; + let full_amt = usize::from(amt) + 2 * ptr_size; let new_sp = self.state[XReg::sp].get_ptr::().wrapping_sub(full_amt); self.set_sp::(new_sp)?;