Merge 'Fix program counter update in sequence test op' from Preston Thorpe

it's not emitted anywhere yet but still saw this bug

Reviewed-by: Jussi Saurio <jussi.saurio@gmail.com>

Closes #3297
This commit is contained in:
Preston Thorpe
2025-09-24 10:01:01 -04:00
committed by GitHub

View File

@@ -5390,9 +5390,11 @@ pub fn op_sequence_test(
insn
);
let cursor = state.get_cursor(*cursor_id).as_sorter_mut();
if cursor.seq_beginning() {
state.pc = target_pc.as_offset_int();
}
state.pc = if cursor.seq_beginning() {
target_pc.as_offset_int()
} else {
state.pc + 1
};
Ok(InsnFunctionStepResult::Step)
}