+2012-01-26 Joel Brobecker <brobecker@adacore.com>
+
+ * symfile.h (struct quick_symbol_functions) [expand_symtabs_matching]:
+ Remove language parameter from name_matcher. Adjust the comment.
+ * symtab.c (search_symbols_name_matches, expand_partial_symbol_name):
+ Remove language parameter.
+ * ada-lang.c (ada_expand_partial_symbol_name): Likewise.
+ * linespec.c (iterate_name_matcher): Likewise.
+ * dwarf2read.c (dw2_expand_symtabs_matching): Adjust type of
+ name_matcher. Adjust call accordingly.
+ * psymtab.c (expand_symtabs_matching_via_partial): Likewise.
+ (maintenance_check_symtabs): Adjust type of parameter "fun".
+ * psymtab.h (maintenance_check_symtabs): Likewise.
+
2012-01-26 Joel Brobecker <brobecker@adacore.com>
* language.h (symbol_name_match_p_ftype): New typedef.
/* A callback for expand_partial_symbol_names. */
static int
-ada_expand_partial_symbol_name (const struct language_defn *language,
- const char *name, void *user_data)
+ada_expand_partial_symbol_name (const char *name, void *user_data)
{
struct add_partial_datum *data = user_data;
dw2_expand_symtabs_matching
(struct objfile *objfile,
int (*file_matcher) (const char *, void *),
- int (*name_matcher) (const struct language_defn *, const char *, void *),
+ int (*name_matcher) (const char *, void *),
enum search_domain kind,
void *data)
{
name = index->constant_pool + MAYBE_SWAP (index->symbol_table[idx]);
- if (! (*name_matcher) (current_language, name, data))
+ if (! (*name_matcher) (name, data))
continue;
/* The name was matched, now expand corresponding CUs that were
callback to the expand_symtabs_matching method. */
static int
-iterate_name_matcher (const struct language_defn *language,
- const char *name, void *d)
+iterate_name_matcher (const char *name, void *d)
{
const struct symbol_matcher_data *data = d;
expand_symtabs_matching_via_partial
(struct objfile *objfile,
int (*file_matcher) (const char *, void *),
- int (*name_matcher) (const struct language_defn *, const char *, void *),
+ int (*name_matcher) (const char *, void *),
enum search_domain kind,
void *data)
{
&& SYMBOL_CLASS (*psym) == LOC_BLOCK)
|| (kind == TYPES_DOMAIN
&& SYMBOL_CLASS (*psym) == LOC_TYPEDEF))
- && (*name_matcher) (current_language,
- SYMBOL_SEARCH_NAME (*psym), data))
+ && (*name_matcher) (SYMBOL_SEARCH_NAME (*psym), data))
{
PSYMTAB_TO_SYMTAB (ps);
keep_going = 0;
\f
void
-expand_partial_symbol_names (int (*fun) (const struct language_defn *,
- const char *, void *),
+expand_partial_symbol_names (int (*fun) (const char *, void *),
void *data)
{
struct objfile *objfile;
extern void psymbol_bcache_free (struct psymbol_bcache *);
extern struct bcache *psymbol_bcache_get_bcache (struct psymbol_bcache *);
-void expand_partial_symbol_names (int (*fun) (const struct language_defn *,
- const char *, void *),
+void expand_partial_symbol_names (int (*fun) (const char *, void *),
void *data);
void map_partial_symbol_filenames (symbol_filename_ftype *fun, void *data,
Otherwise, if KIND does not match this symbol is skipped.
If even KIND matches, then NAME_MATCHER is called for each symbol
- defined in the file. The current language, the symbol "search"
- name and DATA are passed to NAME_MATCHER.
+ defined in the file. The symbol "search" name and DATA are passed
+ to NAME_MATCHER.
If NAME_MATCHER returns zero, then this symbol is skipped.
void (*expand_symtabs_matching)
(struct objfile *objfile,
int (*file_matcher) (const char *, void *),
- int (*name_matcher) (const struct language_defn *, const char *, void *),
+ int (*name_matcher) (const char *, void *),
enum search_domain kind,
void *data);
/* A callback for expand_symtabs_matching. */
static int
-search_symbols_name_matches (const struct language_defn *language,
- const char *symname, void *user_data)
+search_symbols_name_matches (const char *symname, void *user_data)
{
struct search_symbols_data *data = user_data;
/* A callback for expand_partial_symbol_names. */
static int
-expand_partial_symbol_name (const struct language_defn *language,
- const char *name, void *user_data)
+expand_partial_symbol_name (const char *name, void *user_data)
{
struct add_name_data *datum = (struct add_name_data *) user_data;