mirror of
https://github.com/pevans/erc-c.git
synced 2024-11-23 08:31:55 +00:00
Use a bitwise-and to determine carry
A bitwise-and is what we do in most (all?) other cases; it's a bit jarring to read the current logic.
This commit is contained in:
parent
8aef335f25
commit
5d55d5b258
@ -38,7 +38,7 @@ DEFINE_INST(asl)
|
||||
|
||||
MOS_CHECK_NZ(result);
|
||||
cpu->P &= ~MOS_CARRY;
|
||||
if ((oper << 1) > 0xff) {
|
||||
if (oper & 0x80) {
|
||||
cpu->P |= MOS_CARRY;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user