pub fn add_r8(cpu: &mut CPU, r8: &Reg8) -> u8 {
    let value = cpu.registers.read8(r8);

    let (acc, flags) = alu_add_8bit(cpu.registers.a, cpu.registers.f, value, false);
    cpu.registers.a = acc;
    cpu.registers.f = flags;

    4
}
/// ADD 8-bit register with register A, storing the result in A.
///
/// Takes 4 cycles.
///
/// # Examples
///
/// ```asm
/// ADD B ; A <- A + B
/// ```
ADD 8-bit register with register A, storing the result in A.
Takes 4 cycles.
ADD 8 - bit register with register A storing the result in A . Takes 4 cycles .
pub fn add_r8(cpu: &mut CPU, r8: &Reg8) -> u8 {
    let value = cpu.registers.read8(r8);
    let (acc, flags) = alu_add_8bit(cpu.registers.a, cpu.registers.f, value, false);
    cpu.registers.a = acc;
    cpu.registers.f = flags;
    4
}
pub fn add_r8 ( cpu : & mut CPU , r8 : & Reg8 ) -> u8 { let value = cpu . registers . read8 ( r8 ) ; let ( acc , flags ) = alu_add_8bit ( cpu . registers . a , cpu . registers . f , value , false ) ; cpu . registers . a = acc ; cpu . registers . f = flags ; 4 }
ADD 8-bit register with register A, storing the result in A.
ADD 8 - bit register with register A storing the result in A .
cpu
&mut CPU
r8
&Reg8
cpu
&mut CPU
r8
&Reg8
examples
None