1999-09-11 Donn Terry <donn@interix.com>
authorIan Lance Taylor <ian@airs.com>
Sun, 12 Sep 1999 02:59:54 +0000 (02:59 +0000)
committerIan Lance Taylor <ian@airs.com>
Sun, 12 Sep 1999 02:59:54 +0000 (02:59 +0000)
* config/obj-coff.c (coff_frob_symbol): Prohibit weak common
symbols.

gas/ChangeLog
gas/config/obj-coff.c

index a0b15a644c08ee519aee49ab0bb55dc2d22164f0..a93c1dfb415d4aa8a680be2a1dca590d97aa5938 100644 (file)
@@ -5,6 +5,9 @@
 
 1999-09-11  Donn Terry  <donn@interix.com>
 
+       * config/obj-coff.c (coff_frob_symbol): Prohibit weak common
+       symbols.
+
        * config/obj-coff.c (obj_coff_endef): Don't merge labels, or
        symbols which do not have a constant value, or tags with
        non-tags.  Remove the symbol from the list before adding it at the
index 4207ea0fa2905f35fc728528e770aca871911b93..86e07667479003d573688a5309e3ff7fbff635ff 100644 (file)
@@ -1169,6 +1169,11 @@ coff_frob_symbol (symp, punt)
       /* more ... */
     }
 
+  /* Double check weak symbols.  */
+  if (S_IS_WEAK (symp) && S_IS_COMMON (symp))
+    as_bad (_("Symbol `%s' can not be both weak and common"),
+           S_GET_NAME (symp));
+
   if (SF_GET_TAG (symp))
     last_tagP = symp;
   else if (S_GET_STORAGE_CLASS (symp) == C_EOS)