gdb: remove SYMBOL_LINE macro

Add a getter and a setter for a symbol's line.  Remove the corresponding macro
and adjust all callers.

Change-Id: I229f2b8fcf938c07975f641361313a8761fad9a5
This commit is contained in:
Simon Marchi 2022-01-27 22:39:50 -05:00
parent 5f9c5a63ce
commit 5d0027b9ba
13 changed files with 34 additions and 25 deletions

View file

@ -3355,14 +3355,14 @@ See set/show multiple-symbol."));
if (syms[i].symbol->is_objfile_owned ())
symtab = symbol_symtab (syms[i].symbol);
if (SYMBOL_LINE (syms[i].symbol) != 0 && symtab != NULL)
if (syms[i].symbol->line () != 0 && symtab != NULL)
{
printf_filtered ("[%d] ", i + first_choice);
ada_print_symbol_signature (gdb_stdout, syms[i].symbol,
&type_print_raw_options);
printf_filtered (_(" at %s:%d\n"),
symtab_to_filename_for_display (symtab),
SYMBOL_LINE (syms[i].symbol));
syms[i].symbol->line ());
}
else if (is_enumeral
&& syms[i].symbol->type ()->name () != NULL)