This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [RFA] c++/11734 revisited
- From: Jan Kratochvil <jan dot kratochvil at redhat dot com>
- To: Keith Seitz <keiths at redhat dot com>
- Cc: Tom Tromey <tromey at redhat dot com>, gdb-patches at sourceware dot org
- Date: Sun, 6 Feb 2011 23:04:14 +0100
- Subject: Re: [RFA] c++/11734 revisited
- References: <4D002672.5090504@redhat.com> <m3oc8u1uzs.fsf@fleche.redhat.com> <4D07CD68.5000700@redhat.com>
On Tue, 14 Dec 2010 21:02:48 +0100, Keith Seitz wrote:
...
> static struct partial_symbol *
> lookup_partial_symbol (struct partial_symtab *pst, const char *name,
> - int global, domain_enum domain)
> + int global, domain_enum domain, enum language language)
> {
[...]
> + search_name = psymtab_search_name (name, language);
> + cleanup = make_cleanup (xfree, (void *) search_name);
[...]
> - if (strcmp_iw_ordered (SYMBOL_SEARCH_NAME (*center), name) >= 0)
> + if (strcmp_iw_ordered (SYMBOL_SEARCH_NAME (*center),
> + search_name) >= 0)
[...]
> while (top <= real_top
> - && SYMBOL_MATCHES_SEARCH_NAME (*top, name))
> + && SYMBOL_MATCHES_SEARCH_NAME (*top, search_name))
> {
> if (symbol_matches_domain (SYMBOL_LANGUAGE (*top),
> SYMBOL_DOMAIN (*top), domain))
> - return (*top);
> + {
> + do_cleanups (cleanup);
> + return (*top);
> + }
> top++;
> }
> }
> @@ -594,10 +657,14 @@ lookup_partial_symbol (struct partial_sy
> if (symbol_matches_domain (SYMBOL_LANGUAGE (*psym),
> SYMBOL_DOMAIN (*psym), domain)
> && SYMBOL_MATCHES_SEARCH_NAME (*psym, name))
^^^^
Here should be also `search_name' I think.
> - return (*psym);
> + {
> + do_cleanups (cleanup);
> + return (*psym);
> + }
Thanks,
Jan