* expr.c (make_expr_symbol): Fold FAKE_LABEL_NAME use into the
authorRichard Henderson <rth@redhat.com>
Tue, 27 May 2003 19:19:29 +0000 (19:19 +0000)
committerRichard Henderson <rth@redhat.com>
Tue, 27 May 2003 19:19:29 +0000 (19:19 +0000)
        symbol_create call.
        (current_location): Use symbol_temp_new_now.
        * stabs.c (s_stab_generic): Use symbol_temp_new.
        * symbols.c (temp_label_name): Remove.
        (symbol_temp_new, symbol_temp_make): Use FAKE_LABEL_NAME.

gas/ChangeLog
gas/expr.c
gas/stabs.c
gas/symbols.c

index 16a16181be52c768dfc5d0031f409329e1292867..e49f5fb7cf62826d24bc24d4f26a01fb6686afc3 100644 (file)
@@ -1,3 +1,12 @@
+2003-05-27  Richard Henderson  <rth@redhat.com>
+
+       * expr.c (make_expr_symbol): Fold FAKE_LABEL_NAME use into the
+       symbol_create call.
+       (current_location): Use symbol_temp_new_now.
+       * stabs.c (s_stab_generic): Use symbol_temp_new.
+       * symbols.c (temp_label_name): Remove.
+       (symbol_temp_new, symbol_temp_make): Use FAKE_LABEL_NAME.
+
 2003-05-27  Richard Henderson  <rth@redhat.com>
 
        * dw2gencfi.c, dw2gencfi.h: Rewrite from scratch.
index 6478887c9c5d619c9112d198b32a5dd3e2a1c616..58db726191ebeb08ab5e987ed18ce4f07396130c 100644 (file)
@@ -67,7 +67,6 @@ make_expr_symbol (expressionP)
      expressionS *expressionP;
 {
   expressionS zero;
-  const char *fake;
   symbolS *symbolP;
   struct expr_symbol_line *n;
 
@@ -91,13 +90,11 @@ make_expr_symbol (expressionP)
       expressionP = &zero;
     }
 
-  fake = FAKE_LABEL_NAME;
-
   /* Putting constant symbols in absolute_section rather than
      expr_section is convenient for the old a.out code, for which
      S_GET_SEGMENT does not always retrieve the value put in by
      S_SET_SEGMENT.  */
-  symbolP = symbol_create (fake,
+  symbolP = symbol_create (FAKE_LABEL_NAME,
                           (expressionP->X_op == O_constant
                            ? absolute_section
                            : expr_section),
@@ -745,13 +742,8 @@ current_location (expressionp)
     }
   else
     {
-      symbolS *symbolp;
-
-      symbolp = symbol_new (FAKE_LABEL_NAME, now_seg,
-                           (valueT) frag_now_fix (),
-                           frag_now);
       expressionp->X_op = O_symbol;
-      expressionp->X_add_symbol = symbolp;
+      expressionp->X_add_symbol = symbol_temp_new_now ();
       expressionp->X_add_number = 0;
     }
 }
index 38bbc24687dcea42cbf3f625f8bc38a782bf5616..900826b231f278755b5c3affed0d67336b751b45 100644 (file)
@@ -371,13 +371,11 @@ s_stab_generic (what, stab_secname, stabstr_secname)
        }
       else
        {
-         const char *fake;
          symbolS *symbol;
          expressionS exp;
 
          /* Arrange for a value representing the current location.  */
-         fake = FAKE_LABEL_NAME;
-         symbol = symbol_new (fake, saved_seg, dot, saved_frag);
+         symbol = symbol_temp_new (saved_seg, dot, saved_frag);
 
          exp.X_op = O_symbol;
          exp.X_add_symbol = symbol;
index 935c6a42bd43e5b7c80353983fdfc403720326c7..7362afbbaf4c347faa7cded247a940d91322b77a 100644 (file)
@@ -588,15 +588,13 @@ symbol_make (name)
   return (symbolP);
 }
 
-static const char temp_label_name[] = ".L0\001";
-
 symbolS *
 symbol_temp_new (seg, ofs, frag)
      segT seg;
      valueT ofs;
      fragS *frag;
 {
-  return symbol_new (temp_label_name, seg, ofs, frag);
+  return symbol_new (FAKE_LABEL_NAME, seg, ofs, frag);
 }
 
 symbolS *
@@ -608,7 +606,7 @@ symbol_temp_new_now ()
 symbolS *
 symbol_temp_make ()
 {
-  return symbol_make (temp_label_name);
+  return symbol_make (FAKE_LABEL_NAME);
 }
 
 /* Implement symbol table lookup.