This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[RFA] Use symbol search name in expand_symtabs_matching_via_partial...


We are iterating over all symbols in a partial symtab that would
match a given name, so we should match the partial symbols
search name against the given name rather than using the natural
name.  In C++, that does not make a difference, but it does in
Ada, because Ada searches using the symbol encoded name...

gdb/ChangeLog:

        * psymtab.c (expand_symtabs_matching_via_partial): Match
        the partial symbols using their SYMBOL_SEARCH_NAME.

Tested on x86_64-linux. OK to commit?

---
 gdb/psymtab.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/gdb/psymtab.c b/gdb/psymtab.c
index 74185cc..861b302 100644
--- a/gdb/psymtab.c
+++ b/gdb/psymtab.c
@@ -1305,7 +1305,7 @@ expand_symtabs_matching_via_partial
 		   || (kind == TYPES_DOMAIN
 		       && SYMBOL_CLASS (*psym) == LOC_TYPEDEF))
 		  && (*name_matcher) (current_language,
-				      SYMBOL_NATURAL_NAME (*psym), data))
+				      SYMBOL_SEARCH_NAME (*psym), data))
 		{
 		  PSYMTAB_TO_SYMTAB (ps);
 		  keep_going = 0;
-- 
1.7.1


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]