ref: be877134e56b0ccf0293202d75dc6416311900c7
parent: d05703c6925cc08e1827fffb52124262c5f97f19
author: Rangi <remy.oukaour+rangi42@gmail.com>
date: Tue Mar 30 09:01:49 EDT 2021
Remove support for `ld bc/de/hl/sp` for `ld hl, bc/de/hl/sp` Fixes #811
--- a/src/asm/parser.y
+++ b/src/asm/parser.y
@@ -598,7 +598,6 @@
%type <nConstValue> ccode
%type <sVal> op_a_n
%type <nConstValue> op_a_r
-%type <nConstValue> op_hl_ss
%type <sVal> op_mem_ind
%type <assertType> assert_type
@@ -1662,7 +1661,7 @@
out_RelByte(&$2, 1);
}
| T_Z80_ADD op_a_r { out_AbsByte(0x80 | $2); }
- | T_Z80_ADD op_hl_ss { out_AbsByte(0x09 | ($2 << 4)); }
+ | T_Z80_ADD T_MODE_HL T_COMMA reg_ss { out_AbsByte(0x09 | ($4 << 4)); }
| T_Z80_ADD T_MODE_SP T_COMMA reloc_8bit {
out_AbsByte(0xE8);
out_RelByte(&$4, 1);
@@ -2045,10 +2044,6 @@
;
op_mem_ind : T_LBRACK reloc_16bit T_RBRACK { $$ = $2; }
-;
-
-op_hl_ss : reg_ss
- | T_MODE_HL T_COMMA reg_ss { $$ = $3; }
;
op_a_r : reg_r