public inbox for binutils@sourceware.org
 help / color / mirror / Atom feed
* another z8k gas fix
@ 2005-01-28 19:42 Christian Groessler
  0 siblings, 0 replies; only message in thread
From: Christian Groessler @ 2005-01-28 19:42 UTC (permalink / raw)
  To: binutils; +Cc: chris

Hi,

the assembler didn't flag some invalid constructs (like "ldb
@@rr2,rl0", note the double "@@") as an error. The attached patch
fixes this. Applied.

regards,
chris


gas/ChangeLog:

2005-01-28  Christian Groessler  <chris@groessler.org>

        * config/tc-z8k.c (md_assemble): Improve error detection.



Index: config/tc-z8k.c
===================================================================
RCS file: /cvs/src/src/gas/config/tc-z8k.c,v
retrieving revision 1.31
retrieving revision 1.32
diff -u -r1.31 -r1.32
--- config/tc-z8k.c     27 Jan 2005 21:32:21 -0000      1.31
+++ config/tc-z8k.c     28 Jan 2005 19:33:26 -0000      1.32
@@ -1241,11 +1241,12 @@
 
       new_input_line_pointer = get_operands (opcode, op_end, operand);
       if (new_input_line_pointer)
-        input_line_pointer = new_input_line_pointer;
-
-      opcode = get_specific (opcode, operand);
+        {
+          input_line_pointer = new_input_line_pointer;
+          opcode = get_specific (opcode, operand);
+        }
 
-      if (opcode == 0)
+      if (new_input_line_pointer == NULL || opcode == NULL)
        {
          /* Couldn't find an opcode which matched the operands.  */
          char *where = frag_more (2);

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2005-01-28 19:42 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-01-28 19:42 another z8k gas fix Christian Groessler

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).