mirror of
https://github.com/MoleskiCoder/EightBit.git
synced 2025-08-09 00:25:10 +00:00
Tidy the Z80 RES implementation a little.
Signed-off-by: Adrian Conlon <Adrian.conlon@gmail.com>
This commit is contained in:
@@ -459,7 +459,7 @@ void EightBit::Z80::bit(uint8_t& f, const int n, const uint8_t operand) {
|
|||||||
uint8_t EightBit::Z80::res(const int n, const uint8_t operand) {
|
uint8_t EightBit::Z80::res(const int n, const uint8_t operand) {
|
||||||
ASSUME(n >= 0);
|
ASSUME(n >= 0);
|
||||||
ASSUME(n <= 7);
|
ASSUME(n <= 7);
|
||||||
return operand & ~Chip::bit(n);
|
return clearBit(operand, Chip::bit(n));
|
||||||
}
|
}
|
||||||
|
|
||||||
uint8_t EightBit::Z80::set(const int n, const uint8_t operand) {
|
uint8_t EightBit::Z80::set(const int n, const uint8_t operand) {
|
||||||
|
Reference in New Issue
Block a user