1
0
mirror of https://github.com/pevans/erc-c.git synced 2024-07-19 15:29:27 +00:00

Use A & oper here

This commit is contained in:
Peter Evans 2018-01-21 12:47:58 -06:00
parent f9a95827f5
commit 1334e34e76

View File

@ -54,7 +54,7 @@ DEFINE_INST(bit)
// We're just relying on the modify_status function to do negative
// and zero; we also need to do overflow, but overflow is checked in
// a slightly different way with BIT...
mos6502_modify_status(cpu, MOS_NZ, oper, oper);
mos6502_modify_status(cpu, MOS_NZ, oper, cpu->A & oper);
// Normally, overflow is handled by checking if bit 7 flipped from 0
// to 1 or vice versa, and that's done by comparing the result to