Skip to content

Commit

Permalink
Fix comments on Sign flag state in InstructionType::fmt()
Browse files Browse the repository at this point in the history
  • Loading branch information
rzumer committed Feb 23, 2024
1 parent 97a17f3 commit c6a8297
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/instruction.rs
Original file line number Diff line number Diff line change
Expand Up @@ -222,12 +222,12 @@ impl fmt::Display for InstructionType {
Call(Some(cond)) | Jp(Some(cond)) | Jr(Some(cond)) | Ret(Some(cond)) => match cond {
Condition::FlagSet(flag) => match flag {
Flag::PV => write!(f, " PE"), // Parity Even
Flag::S => write!(f, " M"), // Sign Positive
Flag::S => write!(f, " M"), // Sign Negative (Minus)
_ => write!(f, " {}", flag),
},
Condition::FlagNotSet(flag) => match flag {
Flag::PV => write!(f, " PO"), // Parity Odd
Flag::S => write!(f, " P"), // Sign Negative
Flag::S => write!(f, " P"), // Sign Positive (Plus)
_ => write!(f, " N{}", flag),
},
_ => Ok(()),
Expand Down

0 comments on commit c6a8297

Please sign in to comment.