pub fn cp_d8(cpu: &mut CPU) -> u8 {
    let value = cpu.fetch8();

    cpu.registers.f = alu_cp_8bit(cpu.registers.a, cpu.registers.f, value);

    8
}
/// Subtract 8-bit value from register A, but don't store the result. Zero flag will be set if
/// register A and the 8-bit value were equal.
///
/// Takes 8 cycles.
///
/// # Examples
///
/// ```asm
/// CP $DA ; Flag::RegisterFlags::ZERO true if A == 0xDA, Flag::RegisterFlags::CARRY true if A < 0xDA
/// ```
Subtract 8-bit value from register A, but don't store the result. Zero flag will be set if
register A and the 8-bit value were equal.

Takes 8 cycles.
Subtract 8 - bit value from register A but don ' t store the result . Zero flag will be set if register A and the 8 - bit value were equal . Takes 8 cycles .
pub fn cp_d8(cpu: &mut CPU) -> u8 {
    let value = cpu.fetch8();
    cpu.registers.f = alu_cp_8bit(cpu.registers.a, cpu.registers.f, value);
    8
}
pub fn cp_d8 ( cpu : & mut CPU ) -> u8 { let value = cpu . fetch8 ( ) ; cpu . registers . f = alu_cp_8bit ( cpu . registers . a , cpu . registers . f , value ) ; 8 }
Subtract 8-bit value from register A, but don't store the result.
Subtract 8 - bit value from register A but don ' t store the result .
cpu
&mut CPU
cpu
&mut CPU
examples
```asm
CP $DA ; Flag::RegisterFlags::ZERO true if A == 0xDA, Flag::RegisterFlags::CARRY true if A < 0xDA
```
` ` ` asm CP $DA ; Flag :: RegisterFlags :: ZERO true if A == 0xDA Flag :: RegisterFlags :: CARRY true if A < 0xDA ` ` `