[PATCH 1/8] gas: have print_expr() recognize O_index
Jan Beulich
jbeulich@suse.com
Fri Mar 27 14:10:11 GMT 2026
If expr.h is to be trusted, ->X_add_number shouldn't be taken into
consideration here.
--- a/gas/symbols.c
+++ b/gas/symbols.c
@@ -3370,6 +3370,16 @@ print_expr_1 (FILE *file, expressionS *e
print_symbol_value_1 (file, exp->X_op_symbol);
fprintf (file, ">");
goto maybe_print_addnum;
+ case O_index:
+ indent_level++;
+ fprintf (file, "index\n%*s<", indent_level * 4, "");
+ if (exp->X_add_symbol != NULL)
+ print_symbol_value_1 (file, exp->X_add_symbol);
+ fprintf (file, ">\n%*s<", indent_level * 4, "");
+ print_symbol_value_1 (file, exp->X_op_symbol);
+ fprintf (file, ">");
+ indent_level--;
+ break;
default:
fprintf (file, "{unknown opcode %d}", (int) exp->X_op);
break;
More information about the Binutils
mailing list