[2016][rust][23.1] Fix Instruction Display (thanks, @zenspider!)
diff --git a/2016/rust/src/assembunny.rs b/2016/rust/src/assembunny.rs
index d6d0063..9871625 100644
--- a/2016/rust/src/assembunny.rs
+++ b/2016/rust/src/assembunny.rs
@@ -167,10 +167,10 @@ impl fmt::Display for Instruction {
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match self {
&Instruction::Cpy(a, b) => write!(f, "cpy {} {}", a, b),
- &Instruction::Inc(a) => write!(f, "cpy {}", a),
- &Instruction::Dec(a) => write!(f, "cpy {}", a),
- &Instruction::Jnz(a, b) => write!(f, "cpy {} {}", a, b),
- &Instruction::Tgl(a) => write!(f, "cpy {}", a),
+ &Instruction::Inc(a) => write!(f, "inc {}", a),
+ &Instruction::Dec(a) => write!(f, "dec {}", a),
+ &Instruction::Jnz(a, b) => write!(f, "jnz {} {}", a, b),
+ &Instruction::Tgl(a) => write!(f, "tgl {}", a),
}
}
}