diff --git a/src/apu.rs b/src/apu.rs index 78cd133c387601f0442c506507dc62b9e0609041..d072e606d8a053e8c91f239dc5e501d2b355bf46 100644 --- a/src/apu.rs +++ b/src/apu.rs @@ -341,7 +341,7 @@ impl Apu { } pub fn read(&mut self, addr: u16) -> u8 { - let value = match addr { + match addr { // 0xFF10 — NR10: Channel 1 sweep 0xff10 => { (self.ch1_sweep_slope & 0x07) @@ -442,9 +442,7 @@ impl Apu { warnln!("Reading from unknown APU location 0x{:04x}", addr); 0xff } - }; - - value + } } pub fn write(&mut self, addr: u16, value: u8) {