2001-06-08 H.J. Lu <hjl@gnu.org>

* config/tc-mips.c (mips_ip): Properly handle illegal operands.
This commit is contained in:
H.J. Lu
2001-06-09 05:01:29 +00:00
parent d9e138e292
commit 268f6bed84
2 changed files with 19 additions and 6 deletions

View File

@ -1,3 +1,7 @@
2001-06-08 H.J. Lu <hjl@gnu.org>
* config/tc-mips.c (mips_ip): Properly handle illegal operands.
2001-06-08 H.J. Lu <hjl@gnu.org> 2001-06-08 H.J. Lu <hjl@gnu.org>
* config/tc-mips.c (md_apply_fix): Don't adjust common * config/tc-mips.c (md_apply_fix): Don't adjust common

View File

@ -7097,6 +7097,8 @@ mips_ip (str, ip)
continue; continue;
} }
else else
{
if (!insn_error)
{ {
static char buf[100]; static char buf[100];
sprintf (buf, sprintf (buf,
@ -7105,12 +7107,16 @@ mips_ip (str, ip)
mips_isa_to_str (mips_opts.isa)); mips_isa_to_str (mips_opts.isa));
insn_error = buf; insn_error = buf;
}
if (save_c)
*(--s) = save_c;
return; return;
} }
} }
ip->insn_mo = insn; ip->insn_mo = insn;
ip->insn_opcode = insn->match; ip->insn_opcode = insn->match;
insn_error = NULL;
for (args = insn->args;; ++args) for (args = insn->args;; ++args)
{ {
if (*s == ' ') if (*s == ' ')
@ -7951,8 +7957,11 @@ mips_ip (str, ip)
{ {
++insn; ++insn;
s = argsStart; s = argsStart;
insn_error = _("illegal operands");
continue; continue;
} }
if (save_c)
*(--s) = save_c;
insn_error = _("illegal operands"); insn_error = _("illegal operands");
return; return;
} }