ref: aaa92659ea2bb5d645392fa9c86fe82e020042b7
parent: be877134e56b0ccf0293202d75dc6416311900c7
author: Rangi <[email protected]>
date: Tue Mar 30 09:05:21 EDT 2021
Require a plus sign in `ld hl, sp + <e8>` Fixes #810
--- a/src/asm/parser.y
+++ b/src/asm/parser.y
@@ -1802,9 +1802,9 @@
| z80_ld_a
;
-z80_ld_hl : T_Z80_LD T_MODE_HL T_COMMA T_MODE_SP reloc_8bit {
+z80_ld_hl : T_Z80_LD T_MODE_HL T_COMMA T_MODE_SP T_OP_ADD reloc_8bit {
out_AbsByte(0xF8);
- out_RelByte(&$5, 1);
+ out_RelByte(&$6, 1);
}
| T_Z80_LD T_MODE_HL T_COMMA reloc_16bit {
out_AbsByte(0x01 | (REG_HL << 4));