diff options
author | Joel Brobecker <brobecker@gnat.com> | 2012-02-08 19:54:35 +0000 |
---|---|---|
committer | Joel Brobecker <brobecker@gnat.com> | 2012-02-08 19:54:35 +0000 |
commit | 24580d8e8a0a1a297c642df6ecd37e96c971f293 (patch) | |
tree | c522e99a7e910b49d2191b84c104e47edebdf600 /gdb/language.h | |
parent | e08313325c3f7ea49966cc411f800eaa5c96d002 (diff) | |
download | gdb-24580d8e8a0a1a297c642df6ecd37e96c971f293.tar.gz |
Rename la_get_symbol_name_match_p into la_get_symbol_name_cmp
The la_get_symbol_name_match_p language hook was poorly named, as
it suggested that the function should return nonzero if the names
match, whereas it is the exact opposite. This patch therefore
renames the hook and associated typedef, as well some of the code
that uses that hook.
gdb/ChangeLog:
* language.h (symbol_name_cmp_ftype): Renames
symbol_name_match_p_ftype.
(struct language_defn)[la_get_symbol_name_cmp]: Renames
la_get_symbol_name_match_p.
* ada-lang.c (ada_get_symbol_name_cmp): Renames
ada_get_symbol_name_match_p. Update comment.
(ada_language_defn)[la_get_symbol_name_cmp]: Update value.
* linespec.c (struct symbol_matcher_data)[symbol_name_cmp]:
Renames symbol_name_match_p. Update field type.
(iterate_name_matcher, iterate_over_all_matching_symtabs): Adjust.
* c-lang.c, d-lang.c, f-lang.c, jv-lang.c, m2-lang.c, objc-lang.c,
opencl-lang.c, p-lang.c: Replace "la_get_symbol_name_match_p" by
"la_get_symbol_name_cmp" in comments.
* language.c: Likewise.
Diffstat (limited to 'gdb/language.h')
-rw-r--r-- | gdb/language.h | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/gdb/language.h b/gdb/language.h index d4cce9578da..a47a44d2594 100644 --- a/gdb/language.h +++ b/gdb/language.h @@ -143,7 +143,7 @@ struct language_arch_info LOOKUP_NAME should be the name of an entity after it has been transformed for lookup. */ -typedef int (*symbol_name_match_p_ftype) (const char *symbol_search_name, +typedef int (*symbol_name_cmp_ftype) (const char *symbol_search_name, const char *lookup_name); /* Structure tying together assorted information about a language. */ @@ -334,8 +334,7 @@ struct language_defn This field may be NULL, in which case strcmp_iw will be used to perform the matching. */ - symbol_name_match_p_ftype (*la_get_symbol_name_match_p) - (const char *lookup_name); + symbol_name_cmp_ftype (*la_get_symbol_name_cmp) (const char *lookup_name); /* Find all symbols in the current program space matching NAME in DOMAIN, according to this language's rules. |