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/dbxread.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/dbxread.c')
-rw-r--r-- | gdb/dbxread.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/gdb/dbxread.c b/gdb/dbxread.c index 49bcebd..a536a08 100644 --- a/gdb/dbxread.c +++ b/gdb/dbxread.c @@ -1655,7 +1655,7 @@ read_dbx_symtab (minimal_symbol_reader &reader, pst ? pst->filename : NULL, objfile); if (minsym.minsym != NULL) - nlist.n_value = MSYMBOL_VALUE_RAW_ADDRESS (minsym.minsym); + nlist.n_value = minsym.minsym->value_raw_address (); } if (pst && textlow_not_set && gdbarch_sofun_address_maybe_missing (gdbarch)) @@ -1711,7 +1711,7 @@ read_dbx_symtab (minimal_symbol_reader &reader, pst ? pst->filename : NULL, objfile); if (minsym.minsym != NULL) - nlist.n_value = MSYMBOL_VALUE_RAW_ADDRESS (minsym.minsym); + nlist.n_value = minsym.minsym->value_raw_address (); } if (pst && textlow_not_set && gdbarch_sofun_address_maybe_missing (gdbarch)) @@ -2024,7 +2024,7 @@ dbx_end_psymtab (struct objfile *objfile, psymtab_storage *partial_symtabs, } if (minsym.minsym) - pst->set_text_high (MSYMBOL_VALUE_RAW_ADDRESS (minsym.minsym) + pst->set_text_high (minsym.minsym->value_raw_address () + MSYMBOL_SIZE (minsym.minsym)); last_function_name = NULL; @@ -2791,7 +2791,7 @@ process_one_symbol (int type, int desc, CORE_ADDR valu, const char *name, = find_stab_function (name, get_last_source_file (), objfile); if (minsym.minsym != NULL) - valu = BMSYMBOL_VALUE_ADDRESS (minsym); + valu = minsym.value_address (); } /* These addresses are absolute. */ |