Whoops: missed carry adjustment for the 6809

Signed-off-by: Adrian Conlon <Adrian.conlon@gmail.com>
This commit is contained in:
Adrian Conlon 2018-08-20 12:54:01 +01:00
parent dad5ee8926
commit 9122b5aa76

View File

@ -376,7 +376,7 @@ uint8_t EightBit::mc6809::neg(uint8_t operand) {
const register16_t result = 0 - operand;
operand = result.low;
adjustNZ(operand);
setFlag(CC(), CF, result.word & Bit8);
adjustCarry(result.word);
return operand;
}