From c7feb58815d44a3a97d357ee3260ade4ece5701e Mon Sep 17 00:00:00 2001 From: Adrian Conlon Date: Thu, 21 Feb 2019 00:02:31 +0000 Subject: [PATCH] Correct a Z80 compare mistake: the result of the implied subtraction shouldn't be applied to the flags register! Signed-off-by: Adrian Conlon --- Z80/Z80.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Z80/Z80.cs b/Z80/Z80.cs index ff43196..2678e92 100644 --- a/Z80/Z80.cs +++ b/Z80/Z80.cs @@ -1673,7 +1673,7 @@ namespace EightBit private void Compare(byte value) { - this.F() = this.Subtract(this.A(), value); + this.Subtract(this.A(), value); this.F() = AdjustXY(this.F(), value); }