gdb: remove SYMBOL_IS_ARGUMENT macro

Add a getter and a setter for whether a symbol is an argument.  Remove
the corresponding macro and adjust all callers.

Change-Id: I71b4f0465f3dfd2ed8b9e140bd3f7d5eb8d9ee81
This commit is contained in:
Simon Marchi
2022-01-27 22:06:47 -05:00
parent 7b3ecc7555
commit d9743061f9
19 changed files with 49 additions and 40 deletions

View File

@ -763,7 +763,7 @@ print_frame_args (const frame_print_options &fp_opts,
/* Keep track of the highest stack argument offset seen, and
skip over any kinds of symbols we don't care about. */
if (!SYMBOL_IS_ARGUMENT (sym))
if (!sym->is_argument ())
continue;
if (!print_names)
@ -829,7 +829,7 @@ print_frame_args (const frame_print_options &fp_opts,
b, VAR_DOMAIN).symbol;
gdb_assert (nsym != NULL);
if (nsym->aclass () == LOC_REGISTER
&& !SYMBOL_IS_ARGUMENT (nsym))
&& !nsym->is_argument ())
{
/* There is a LOC_ARG/LOC_REGISTER pair. This means
that it was passed on the stack and loaded into a
@ -2256,7 +2256,7 @@ iterate_over_block_locals (const struct block *b,
case LOC_STATIC:
case LOC_COMPUTED:
case LOC_OPTIMIZED_OUT:
if (SYMBOL_IS_ARGUMENT (sym))
if (sym->is_argument ())
break;
if (sym->domain () == COMMON_BLOCK_DOMAIN)
break;
@ -2503,7 +2503,7 @@ iterate_over_block_arg_vars (const struct block *b,
ALL_BLOCK_SYMBOLS (b, iter, sym)
{
/* Don't worry about things which aren't arguments. */
if (SYMBOL_IS_ARGUMENT (sym))
if (sym->is_argument ())
{
/* We have to look up the symbol because arguments can have
two entries (one a parameter, one a local) and the one we