From: Tom Tromey <tromey@redhat.com>
To: sami wagiaalla <swagiaal@redhat.com>
Cc: gdb-patches@sourceware.org
Subject: Re: [patch 1/3] Template Lookup
Date: Wed, 18 Aug 2010 21:45:00 -0000 [thread overview]
Message-ID: <m3pqxfa934.fsf@fleche.redhat.com> (raw)
In-Reply-To: <4C460A3E.2040004@redhat.com> (sami wagiaalla's message of "Tue, 20 Jul 2010 16:42:38 -0400")
>>>>> "Sami" == sami wagiaalla <swagiaal@redhat.com> writes:
Sami> Same patch but using prepare_for_testing
Thanks.
I suspect this doesn't interact properly with psymtabs, because from
what I can tell the template-argument-less symbol is only entered for
full symbols, not partial symbols. This means that a reference to some
function will not work properly until the psymtab is expanded for some
other reason.
Sami> +static struct demangle_component *
Sami> +cp_remove_template_params_component (struct demangle_component *comp)
Sami> +{
Sami> +
Sami> + gdb_assert (comp != NULL);
No need for that blank line.
Sami> +char*
Sami> +symbol_get_cplus_search_name (const struct general_symbol_info *gsymbol)
"char *"
Sami> +extern char* symbol_get_cplus_search_name (const struct general_symbol_info *);
"char *"
Sami> +gdb_test_no_output "set language c++" ""
There are a couple instances of this that have to be updated in light of
Doug's recent change to how this is done.
Sami> @@ -2458,7 +2458,7 @@ find_overload_match (struct type **arg_types, int nargs,
Sami> if (fsym)
Sami> {
Sami> - qualified_name = SYMBOL_NATURAL_NAME (fsym);
Sami> + qualified_name = SYMBOL_SEARCH_NAME (fsym);
It took me a while to understand why this could be work.
It seems to me that it is not completely right though. Consider this case:
template<int X> int f (int x) { return x + X; }
int compute (int x) { return f<5> (x) + f<7> (x); }
In this situation you can't just look at overloads of "f" -- it is
ambiguous. You have to do more analysis.
Tom
next prev parent reply other threads:[~2010-08-18 21:45 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-07-19 15:28 sami wagiaalla
2010-07-20 20:42 ` sami wagiaalla
2010-08-18 21:45 ` Tom Tromey [this message]
2010-08-26 16:05 ` sami wagiaalla
2010-08-31 22:05 ` Tom Tromey
2010-09-23 18:43 ` [patch 4/4] " sami wagiaalla
2010-09-23 17:55 ` [patch 1/4] " sami wagiaalla
2010-10-05 19:08 ` sami wagiaalla
2010-10-14 15:23 ` sami wagiaalla
2010-11-01 20:15 ` sami wagiaalla
2010-08-11 18:13 ` [patch 1/3] " sami wagiaalla
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=m3pqxfa934.fsf@fleche.redhat.com \
--to=tromey@redhat.com \
--cc=gdb-patches@sourceware.org \
--cc=swagiaal@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).