diff --git a/src/machine/stack.rs b/src/machine/stack.rs index b7a979ea0..793cacb7a 100644 --- a/src/machine/stack.rs +++ b/src/machine/stack.rs @@ -230,7 +230,7 @@ impl Stack { for idx in 0..num_cells { ptr::write( - (new_ptr as usize + offset) as *mut HeapCellValue, + new_ptr.add(offset).cast::(), stack_loc_as_cell!(OrFrame, b, idx), );