diff options
author | Simon Marchi <simon.marchi@efficios.com> | 2022-01-28 10:28:57 -0500 |
---|---|---|
committer | Simon Marchi <simon.marchi@efficios.com> | 2022-04-11 10:46:07 -0400 |
commit | 60f62e2b83eb362c5063247235c111a59e13cad1 (patch) | |
tree | c74a83d20a05ab710391425f072f79e31276db5a /gdb/compile | |
parent | 4aeddc50d7a06294cc124dfd8f43992ffa0b7382 (diff) | |
download | gdb-60f62e2b83eb362c5063247235c111a59e13cad1.zip gdb-60f62e2b83eb362c5063247235c111a59e13cad1.tar.gz gdb-60f62e2b83eb362c5063247235c111a59e13cad1.tar.bz2 |
gdb: remove MSYMBOL_TYPE macro
Add a getter and a setter for a minimal symbol's type. Remove the
corresponding macro and adjust all callers.
Change-Id: I89900df5ffa5687133fe1a16b2e0d4684e67a77d
Diffstat (limited to 'gdb/compile')
-rw-r--r-- | gdb/compile/compile-c-symbols.c | 4 | ||||
-rw-r--r-- | gdb/compile/compile-cplus-symbols.c | 4 | ||||
-rw-r--r-- | gdb/compile/compile-object-load.c | 2 |
3 files changed, 5 insertions, 5 deletions
diff --git a/gdb/compile/compile-c-symbols.c b/gdb/compile/compile-c-symbols.c index a50e84d..642c0be 100644 --- a/gdb/compile/compile-c-symbols.c +++ b/gdb/compile/compile-c-symbols.c @@ -273,7 +273,7 @@ convert_symbol_bmsym (compile_c_instance *context, addr = msym->value_address (objfile); /* Conversion copied from write_exp_msymbol. */ - switch (MSYMBOL_TYPE (msym)) + switch (msym->type ()) { case mst_text: case mst_file_text: @@ -422,7 +422,7 @@ gcc_symbol_address (void *datum, struct gcc_c_context *gcc_context, "symbol\n", identifier); result = msym.value_address (); - if (MSYMBOL_TYPE (msym.minsym) == mst_text_gnu_ifunc) + if (msym.minsym->type () == mst_text_gnu_ifunc) result = gnu_ifunc_resolve_addr (target_gdbarch (), result); found = 1; } diff --git a/gdb/compile/compile-cplus-symbols.c b/gdb/compile/compile-cplus-symbols.c index b68184c..7ad9ea9 100644 --- a/gdb/compile/compile-cplus-symbols.c +++ b/gdb/compile/compile-cplus-symbols.c @@ -284,7 +284,7 @@ convert_symbol_bmsym (compile_cplus_instance *instance, addr = msym->value_address (objfile); /* Conversion copied from write_exp_msymbol. */ - switch (MSYMBOL_TYPE (msym)) + switch (msym->type ()) { case mst_text: case mst_file_text: @@ -459,7 +459,7 @@ gcc_cplus_symbol_address (void *datum, struct gcc_cp_context *gcc_context, "symbol\n", identifier); result = msym.value_address (); - if (MSYMBOL_TYPE (msym.minsym) == mst_text_gnu_ifunc) + if (msym.minsym->type () == mst_text_gnu_ifunc) result = gnu_ifunc_resolve_addr (target_gdbarch (), result); found = 1; } diff --git a/gdb/compile/compile-object-load.c b/gdb/compile/compile-object-load.c index bfb40c9..dee7882 100644 --- a/gdb/compile/compile-object-load.c +++ b/gdb/compile/compile-object-load.c @@ -766,7 +766,7 @@ compile_object_load (const compile_file_names &file_names, bmsym = lookup_minimal_symbol (sym->name, NULL, NULL); switch (bmsym.minsym == NULL - ? mst_unknown : MSYMBOL_TYPE (bmsym.minsym)) + ? mst_unknown : bmsym.minsym->type ()) { case mst_text: case mst_bss: |