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

    let (shifted_value, flags) = alu_shift_left(value, cpu.registers.f);
    cpu.registers.write8(r8, shifted_value);
    cpu.registers.f = flags;

    8
}
/// Shift an 8-bit register to the left.
///
/// Takes 8 cycles
///
/// # Examples
///
/// ```asm
/// SLA B  ; Shift B left through the carry flag (sets Flag::RegisterFlags::ZERO if rotated result == 0)
/// ```
Shift an 8-bit register to the left.
Takes 8 cycles
Shift an 8 - bit register to the left . Takes 8 cycles
pub fn shift_left_r8(cpu: &mut CPU, r8: &Reg8) -> u8 {
    let value = cpu.registers.read8(r8);
    let (shifted_value, flags) = alu_shift_left(value, cpu.registers.f);
    cpu.registers.write8(r8, shifted_value);
    cpu.registers.f = flags;
    8
}
pub fn shift_left_r8 ( cpu : & mut CPU , r8 : & Reg8 ) -> u8 { let value = cpu . registers . read8 ( r8 ) ; let ( shifted_value , flags ) = alu_shift_left ( value , cpu . registers . f ) ; cpu . registers . write8 ( r8 , shifted_value ) ; cpu . registers . f = flags ; 8 }
Shift an 8-bit register to the left.
Shift an 8 - bit register to the left .
cpu
&mut CPU
r8
&Reg8
cpu
&mut CPU
r8
&Reg8
examples
```asm
SLA B  ; Shift B left through the carry flag (sets Flag::RegisterFlags::ZERO if rotated result == 0)
```
` ` ` asm SLA B ; Shift B left through the carry flag ( sets Flag :: RegisterFlags :: ZERO if rotated result == 0 ) ` ` `