work in progress
[fw/sdcc] / as / xa51 / xa_rasm.l
index 3f35c188a5ae6e10c46a327a704674575de23e39..8576b7349bde6b038239b64097d4db05f83c74aa 100755 (executable)
@@ -247,6 +247,14 @@ R[0-7]H            {LIST; yylval = (yytext[1] - '0') * 2 + 1 + BYTE_REG; return REG;}
                                        if (is_bit(lex_sym_name)) return BIT;
                                        if (is_reg(lex_sym_name)) return REG;
                                }
+                                if (p3) {
+                                 if (*operand[0]) {
+                                   // first one in use
+                                   strcpy (operand[1], yytext);
+                                 } else {
+                                   strcpy (operand[0], yytext);
+                                 }
+                                }
                                return WORD;
                        }
 [0-9]+\$               {