diff options
author | Simon Marchi <simon.marchi@efficios.com> | 2022-01-28 08:09:50 -0500 |
---|---|---|
committer | Simon Marchi <simon.marchi@efficios.com> | 2022-04-11 10:45:36 -0400 |
commit | 4aeddc50d7a06294cc124dfd8f43992ffa0b7382 (patch) | |
tree | 82c6a016c94112c6e5dc7cf763cc5641d91e6b6e /gdb/infcmd.c | |
parent | 96d368d10456f5a599db759aab20e84a61f361f9 (diff) | |
download | gdb-4aeddc50d7a06294cc124dfd8f43992ffa0b7382.zip gdb-4aeddc50d7a06294cc124dfd8f43992ffa0b7382.tar.gz gdb-4aeddc50d7a06294cc124dfd8f43992ffa0b7382.tar.bz2 |
gdb: remove symbol value macros
Remove all macros related to getting and setting some symbol value:
#define SYMBOL_VALUE(symbol) (symbol)->value.ivalue
#define SYMBOL_VALUE_ADDRESS(symbol) \
#define SET_SYMBOL_VALUE_ADDRESS(symbol, new_value) \
#define SYMBOL_VALUE_BYTES(symbol) (symbol)->value.bytes
#define SYMBOL_VALUE_COMMON_BLOCK(symbol) (symbol)->value.common_block
#define SYMBOL_BLOCK_VALUE(symbol) (symbol)->value.block
#define SYMBOL_VALUE_CHAIN(symbol) (symbol)->value.chain
#define MSYMBOL_VALUE(symbol) (symbol)->value.ivalue
#define MSYMBOL_VALUE_RAW_ADDRESS(symbol) ((symbol)->value.address + 0)
#define MSYMBOL_VALUE_ADDRESS(objfile, symbol) \
#define BMSYMBOL_VALUE_ADDRESS(symbol) \
#define SET_MSYMBOL_VALUE_ADDRESS(symbol, new_value) \
#define MSYMBOL_VALUE_BYTES(symbol) (symbol)->value.bytes
#define MSYMBOL_BLOCK_VALUE(symbol) (symbol)->value.block
Replace them with equivalent methods on the appropriate objects.
Change-Id: Iafdab3b8eefc6dc2fd895aa955bf64fafc59ed50
Diffstat (limited to 'gdb/infcmd.c')
-rw-r--r-- | gdb/infcmd.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/gdb/infcmd.c b/gdb/infcmd.c index 719bd68..84eb6e5 100644 --- a/gdb/infcmd.c +++ b/gdb/infcmd.c @@ -979,7 +979,7 @@ prepare_one_step (thread_info *tp, struct step_command_fsm *sm) symbol *sym = inline_skipped_symbol (tp); if (sym->aclass () == LOC_BLOCK) { - const block *block = SYMBOL_BLOCK_VALUE (sym); + const block *block = sym->value_block (); if (BLOCK_END (block) < tp->control.step_range_end) tp->control.step_range_end = BLOCK_END (block); } @@ -1336,7 +1336,7 @@ until_next_command (int from_tty) if (msymbol.minsym == NULL) error (_("Execution is not within a known function.")); - tp->control.step_range_start = BMSYMBOL_VALUE_ADDRESS (msymbol); + tp->control.step_range_start = msymbol.value_address (); /* The upper-bound of step_range is exclusive. In order to make PC within the range, set the step_range_end with PC + 1. */ tp->control.step_range_end = pc + 1; @@ -1345,7 +1345,7 @@ until_next_command (int from_tty) { sal = find_pc_line (pc, 0); - tp->control.step_range_start = BLOCK_ENTRY_PC (SYMBOL_BLOCK_VALUE (func)); + tp->control.step_range_start = BLOCK_ENTRY_PC (func->value_block ()); tp->control.step_range_end = sal.end; /* By setting the step_range_end based on the current pc, we are |