Fix for PR11938 - display suitable error messages for bogus .byte, .short and .quad...
authorNick Clifton <nickc@redhat.com>
Thu, 11 Jun 1998 22:58:05 +0000 (22:58 +0000)
committerNick Clifton <nickc@redhat.com>
Thu, 11 Jun 1998 22:58:05 +0000 (22:58 +0000)
gas/ChangeLog
gas/config/tc-d30v.c

index d7cde280cb10603c5478ffecf1a937ef2217575a..731ed0fe660f3a7870ecc261d48cdda702667571 100644 (file)
@@ -1,5 +1,8 @@
 Thu Jun 11 08:56:46 1998  Nick Clifton  <nickc@cygnus.com>
 
+       * config/tc-d30v.c (md_apply_fix3): Catch BFD_RELOC_8,
+       BFD_RELOC_16, BFD_RELOC_64 and issue appropriate error messages.  
+
        * write.c (adjust_reloc_syms): Add more checks for NULL pointers. 
 
        * config/tc-v850.c (v850_comm): Set SEC_COMMON bit on special
index dbf657b6ed1c2db7550208776cd6258f75d3324b..46e5eb9eb37a720b7abd0e3df041a2c4bb248b60 100644 (file)
@@ -1628,6 +1628,24 @@ md_apply_fix3 (fixp, valuep, seg)
   
   switch (fixp->fx_r_type)
     {
+    case BFD_RELOC_8:
+      /* Caused by a bad .byte directive.  */
+      as_fatal (_("line %d: unable to place address of symbol '%s' into a byte"),
+               fixp->fx_line, S_GET_NAME (fixp->fx_addsy));
+      break;
+      
+    case BFD_RELOC_16:
+      /* Caused by a bad .short directive.  */
+      as_fatal (_("line %d: unable to place address of symbol '%s' into a short"),
+               fixp->fx_line, S_GET_NAME (fixp->fx_addsy));
+      break;
+      
+    case BFD_RELOC_64:
+      /* Caused by a bad .quad directive.  */
+      as_fatal (_("line %d: unable to place address of symbol '%s' into a .quad"),
+               fixp->fx_line, S_GET_NAME (fixp->fx_addsy));
+      break;
+      
     case BFD_RELOC_D30V_6:
       check_size (value, 6, fixp->fx_file, fixp->fx_line);
       insn |= value & 0x3F;
This page took 0.030584 seconds and 4 git commands to generate.