diff --git a/src/machine.rs b/src/machine.rs index d386478..cc12882 100644 --- a/src/machine.rs +++ b/src/machine.rs @@ -607,6 +607,12 @@ impl Machine { } } + fn branch_if_overflow_set(&mut self, addr: Address) { + if self.registers.status.contains(PS_OVERFLOW) { + self.registers.program_counter = addr; + } + } + fn push_on_stack(&mut self, val: u8) { let addr = self.registers.stack_pointer.to_address(); self.memory.set_byte(addr, val);