aboutsummaryrefslogtreecommitdiff
path: root/gdb/utils.h
diff options
context:
space:
mode:
authorTom Tromey <tom@tromey.com>2021-12-22 10:30:16 -0700
committerTom Tromey <tom@tromey.com>2021-12-29 10:24:05 -0700
commitba0084966cfee307631aba6d0f052a39ad773909 (patch)
tree63012fc81a9af3914b8f5368803dc52a76383b8f /gdb/utils.h
parent003aae076207dbf32f98ba846158fc32669ef85f (diff)
downloadfsf-binutils-gdb-ba0084966cfee307631aba6d0f052a39ad773909.zip
fsf-binutils-gdb-ba0084966cfee307631aba6d0f052a39ad773909.tar.gz
fsf-binutils-gdb-ba0084966cfee307631aba6d0f052a39ad773909.tar.bz2
Remove unusual use of core_addr_eq and core_addr_hash
gdbtypes.h uses core_addr_eq and core_addr_hash in a weird way: taking the address of a member and then passing this (as a void*) to these functions. It seems better to simply inline the ordinary code here. CORE_ADDR is a scalar so it can be directly compared, and the identity hash function seems safe to assume as well. After this, core_addr_eq and core_addr_hash are unused, so this patch removes them.
Diffstat (limited to 'gdb/utils.h')
-rw-r--r--gdb/utils.h4
1 files changed, 0 insertions, 4 deletions
diff --git a/gdb/utils.h b/gdb/utils.h
index d86b564..54cf090 100644
--- a/gdb/utils.h
+++ b/gdb/utils.h
@@ -541,10 +541,6 @@ extern const char *paddress (struct gdbarch *gdbarch, CORE_ADDR addr);
extern const char *print_core_address (struct gdbarch *gdbarch,
CORE_ADDR address);
-/* Callback hash_f and eq_f for htab_create_alloc or htab_create_alloc_ex. */
-extern hashval_t core_addr_hash (const void *ap);
-extern int core_addr_eq (const void *ap, const void *bp);
-
extern CORE_ADDR string_to_core_addr (const char *my_string);
extern void fprintf_symbol_filtered (struct ui_file *, const char *,