diff options
author | Pedro Alves <palves@redhat.com> | 2018-01-10 20:38:08 +0000 |
---|---|---|
committer | Pedro Alves <palves@redhat.com> | 2018-01-10 23:12:48 +0000 |
commit | 618daa933cdce21424d3759ea95a4e2f5c69a1c2 (patch) | |
tree | 5f5637c2c6c42eeea88703775150acb0f92319b0 | |
parent | c63d3e8d12f0b08cda95f89aa13274defed215f0 (diff) | |
download | gdb-618daa933cdce21424d3759ea95a4e2f5c69a1c2.zip gdb-618daa933cdce21424d3759ea95a4e2f5c69a1c2.tar.gz gdb-618daa933cdce21424d3759ea95a4e2f5c69a1c2.tar.bz2 |
language_get_symbol_name_matcher -> get_symbol_name_matcher
Rename language_get_symbol_name_matcher -> get_symbol_name_matcher,
since the function is no longer a straight "language method".
gdb/ChangeLog:
2018-01-10 Pedro Alves <palves@redhat.com>
* language.h (language_get_symbol_name_matcher): Rename ...
(get_symbol_name_matcher): ... this.
* language.c (language_get_symbol_name_matcher): Ditto.
* dictionary.c, linespec.c, minsyms.c, psymtab.c, symtab.c: All
callers adjusted.
-rw-r--r-- | gdb/ChangeLog | 8 | ||||
-rw-r--r-- | gdb/dictionary.c | 6 | ||||
-rw-r--r-- | gdb/dwarf2read.c | 2 | ||||
-rw-r--r-- | gdb/language.c | 4 | ||||
-rw-r--r-- | gdb/language.h | 2 | ||||
-rw-r--r-- | gdb/linespec.c | 2 | ||||
-rw-r--r-- | gdb/minsyms.c | 6 | ||||
-rw-r--r-- | gdb/psymtab.c | 2 | ||||
-rw-r--r-- | gdb/symtab.c | 5 |
9 files changed, 22 insertions, 15 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog index d81b485..17f7c8b 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,5 +1,13 @@ 2018-01-10 Pedro Alves <palves@redhat.com> + * language.h (language_get_symbol_name_matcher): Rename ... + (get_symbol_name_matcher): ... this. + * language.c (language_get_symbol_name_matcher): Ditto. + * dictionary.c, linespec.c, minsyms.c, psymtab.c, symtab.c: All + callers adjusted. + +2018-01-10 Pedro Alves <palves@redhat.com> + PR gdb/22670 * dwarf2read.c (gdb_index_symbol_name_matcher::gdb_index_symbol_name_matcher): diff --git a/gdb/dictionary.c b/gdb/dictionary.c index a6049f7..da8b7da 100644 --- a/gdb/dictionary.c +++ b/gdb/dictionary.c @@ -631,7 +631,7 @@ iter_match_first_hashed (const struct dictionary *dict, unsigned int hash_index = (name.search_name_hash (lang->la_language) % DICT_HASHED_NBUCKETS (dict)); symbol_name_matcher_ftype *matches_name - = language_get_symbol_name_matcher (lang, name); + = get_symbol_name_matcher (lang, name); struct symbol *sym; DICT_ITERATOR_DICT (iterator) = dict; @@ -659,7 +659,7 @@ iter_match_next_hashed (const lookup_name_info &name, { const language_defn *lang = DICT_LANGUAGE (DICT_ITERATOR_DICT (iterator)); symbol_name_matcher_ftype *matches_name - = language_get_symbol_name_matcher (lang, name); + = get_symbol_name_matcher (lang, name); struct symbol *next; for (next = DICT_ITERATOR_CURRENT (iterator)->hash_next; @@ -875,7 +875,7 @@ iter_match_next_linear (const lookup_name_info &name, const struct dictionary *dict = DICT_ITERATOR_DICT (iterator); const language_defn *lang = DICT_LANGUAGE (dict); symbol_name_matcher_ftype *matches_name - = language_get_symbol_name_matcher (lang, name); + = get_symbol_name_matcher (lang, name); int i, nsyms = DICT_LINEAR_NSYMS (dict); struct symbol *sym, *retval = NULL; diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c index 604dca5..dca2fe9 100644 --- a/gdb/dwarf2read.c +++ b/gdb/dwarf2read.c @@ -4572,7 +4572,7 @@ gdb_index_symbol_name_matcher::gdb_index_symbol_name_matcher { const language_defn *lang = language_def ((enum language) i); symbol_name_matcher_ftype *name_matcher - = language_get_symbol_name_matcher (lang, m_lookup_name); + = get_symbol_name_matcher (lang, m_lookup_name); /* Don't insert the same comparison routine more than once. Note that we do this linear walk instead of a seemingly diff --git a/gdb/language.c b/gdb/language.c index c80237e..0d8604b 100644 --- a/gdb/language.c +++ b/gdb/language.c @@ -727,8 +727,8 @@ default_symbol_name_matcher (const char *symbol_search_name, /* See language.h. */ symbol_name_matcher_ftype * -language_get_symbol_name_matcher (const language_defn *lang, - const lookup_name_info &lookup_name) +get_symbol_name_matcher (const language_defn *lang, + const lookup_name_info &lookup_name) { /* If currently in Ada mode, and the lookup name is wrapped in '<...>', hijack all symbol name comparisons using the Ada diff --git a/gdb/language.h b/gdb/language.h index 5061095..06b42ae 100644 --- a/gdb/language.h +++ b/gdb/language.h @@ -637,7 +637,7 @@ extern bool default_symbol_name_matcher the function may ignore it depending on the current language and LOOKUP_NAME. Specifically, if the current language is Ada, this may return an Ada matcher regardless of LANG. */ -symbol_name_matcher_ftype *language_get_symbol_name_matcher +symbol_name_matcher_ftype *get_symbol_name_matcher (const language_defn *lang, const lookup_name_info &lookup_name); /* The languages supported by GDB. */ diff --git a/gdb/linespec.c b/gdb/linespec.c index 73fce0c..85f4127 100644 --- a/gdb/linespec.c +++ b/gdb/linespec.c @@ -1226,7 +1226,7 @@ find_methods (struct type *t, enum language t_lang, const char *name, int method_counter; lookup_name_info lookup_name (name, symbol_name_match_type::FULL); symbol_name_matcher_ftype *symbol_name_compare - = language_get_symbol_name_matcher (language_def (t_lang), lookup_name); + = get_symbol_name_matcher (language_def (t_lang), lookup_name); t = check_typedef (t); diff --git a/gdb/minsyms.c b/gdb/minsyms.c index fded0d6..a55c071 100644 --- a/gdb/minsyms.c +++ b/gdb/minsyms.c @@ -359,8 +359,8 @@ lookup_minimal_symbol (const char *name, const char *sfile, % MINIMAL_SYMBOL_HASH_SIZE); symbol_name_matcher_ftype *match - = language_get_symbol_name_matcher (language_def (lang), - lookup_name); + = get_symbol_name_matcher (language_def (lang), + lookup_name); struct minimal_symbol **msymbol_demangled_hash = objfile->per_bfd->msymbol_demangled_hash; @@ -501,7 +501,7 @@ iterate_over_minimal_symbols (struct objfile *objf, { const language_defn *lang_def = language_def (lang); symbol_name_matcher_ftype *name_match - = language_get_symbol_name_matcher (lang_def, lookup_name); + = get_symbol_name_matcher (lang_def, lookup_name); unsigned int hash = lookup_name.search_name_hash (lang) % MINIMAL_SYMBOL_HASH_SIZE; diff --git a/gdb/psymtab.c b/gdb/psymtab.c index 88d234a..dc13fd5 100644 --- a/gdb/psymtab.c +++ b/gdb/psymtab.c @@ -556,7 +556,7 @@ psymbol_name_matches (partial_symbol *psym, { const language_defn *lang = language_def (SYMBOL_LANGUAGE (psym)); symbol_name_matcher_ftype *name_match - = language_get_symbol_name_matcher (lang, lookup_name); + = get_symbol_name_matcher (lang, lookup_name); return name_match (SYMBOL_SEARCH_NAME (psym), lookup_name, NULL); } diff --git a/gdb/symtab.c b/gdb/symtab.c index 2fe2496..81f4fc9 100644 --- a/gdb/symtab.c +++ b/gdb/symtab.c @@ -955,8 +955,7 @@ symbol_matches_search_name (const struct general_symbol_info *gsymbol, const lookup_name_info &name) { symbol_name_matcher_ftype *name_match - = language_get_symbol_name_matcher (language_def (gsymbol->language), - name); + = get_symbol_name_matcher (language_def (gsymbol->language), name); return name_match (symbol_search_name (gsymbol), name, NULL); } @@ -4707,7 +4706,7 @@ compare_symbol_name (const char *symbol_name, language symbol_language, const language_defn *lang = language_def (symbol_language); symbol_name_matcher_ftype *name_match - = language_get_symbol_name_matcher (lang, lookup_name); + = get_symbol_name_matcher (lang, lookup_name); return name_match (symbol_name, lookup_name, &match_res); } |