diff options
Diffstat (limited to 'gas/symbols.c')
-rw-r--r-- | gas/symbols.c | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/gas/symbols.c b/gas/symbols.c index 60b1793..05ae6a7 100644 --- a/gas/symbols.c +++ b/gas/symbols.c @@ -953,7 +953,7 @@ use_complex_relocs_for (symbolS * symp) if ( (S_IS_COMMON (symp->sy_value.X_add_symbol) || S_IS_LOCAL (symp->sy_value.X_add_symbol)) - && + && (S_IS_COMMON (symp->sy_value.X_op_symbol) || S_IS_LOCAL (symp->sy_value.X_op_symbol)) @@ -963,7 +963,7 @@ use_complex_relocs_for (symbolS * symp) && S_GET_SEGMENT (symp->sy_value.X_op_symbol) != expr_section) return 0; break; - + default: break; } @@ -1117,7 +1117,7 @@ resolve_symbol_value (symbolS *symp) if (symp->bsym->flags & BSF_SRELC) relc_symbol->bsym->flags |= BSF_SRELC; else - relc_symbol->bsym->flags |= BSF_RELC; + relc_symbol->bsym->flags |= BSF_RELC; /* symp->bsym->flags |= BSF_RELC; */ copy_symbol_attributes (symp, relc_symbol); symp->sy_value.X_op = O_symbol; @@ -3120,10 +3120,10 @@ symbol_relc_make_expr (expressionS * exp) gas_assert (exp != NULL); /* Match known operators -> fill in opstr, arity, operands[] and fall - through to construct subexpression fragments; may instead return + through to construct subexpression fragments; may instead return string directly for leaf nodes. */ - /* See expr.h for the meaning of all these enums. Many operators + /* See expr.h for the meaning of all these enums. Many operators have an unnatural arity (X_add_number implicitly added). The conversion logic expands them to explicit "+" subexpressions. */ @@ -3138,10 +3138,10 @@ symbol_relc_make_expr (expressionS * exp) return symbol_relc_make_value (exp->X_add_number); case O_symbol: - if (exp->X_add_number) - { - arity = 2; - opstr = "+"; + if (exp->X_add_number) + { + arity = 2; + opstr = "+"; operands[0] = symbol_relc_make_sym (exp->X_add_symbol); operands[1] = symbol_relc_make_value (exp->X_add_number); break; @@ -3167,7 +3167,7 @@ symbol_relc_make_expr (expressionS * exp) operands[0] = symbol_relc_make_sym (exp->X_add_symbol); \ } \ break - + #define HANDLE_XADD_OPT2(str_) \ if (exp->X_add_number) \ { \ @@ -3224,16 +3224,16 @@ symbol_relc_make_expr (expressionS * exp) else { /* Allocate new string; include inter-operand padding gaps etc. */ - concat_string = xmalloc (strlen (opstr) + concat_string = xmalloc (strlen (opstr) + 1 + (arity >= 1 ? (strlen (operands[0]) + 1 ) : 0) + (arity >= 2 ? (strlen (operands[1]) + 1 ) : 0) + (arity >= 3 ? (strlen (operands[2]) + 0 ) : 0) + 1); gas_assert (concat_string != NULL); - + /* Format the thing. */ - sprintf (concat_string, + sprintf (concat_string, (arity == 0 ? "%s" : arity == 1 ? "%s:%s" : arity == 2 ? "%s:%s:%s" : |