This is the mail archive of the
mailing list for the GCC project.
Re: [C++ Patch] PR 58466
- From: Paolo Carlini <paolo dot carlini at oracle dot com>
- To: Jason Merrill <jason at redhat dot com>, "gcc-patches at gcc dot gnu dot org" <gcc-patches at gcc dot gnu dot org>
- Date: Fri, 11 Oct 2013 20:29:43 +0200
- Subject: Re: [C++ Patch] PR 58466
- Authentication-results: sourceware.org; auth=none
- References: <52582CB8 dot 7030008 at oracle dot com> <5258397A dot 8030400 at redhat dot com>
On 10/11/2013 07:46 PM, Jason Merrill wrote:
How does a TEMPLATE_PARM_INDEX get this far? It should have been
detected as dependent before this.
Thanks. Interesting. We get there from the convert_nontype_argument call
at line 6453 of pt.c (in convert_template_argument) , which is protected by:
else if (!dependent_template_arg_p (orig_arg)
&& !uses_template_parms (t))
thus dependent_template_arg_p (orig_arg) returns *false* for that tree.
This is trivially the case because dependent_template_arg_p begins:
thus it doesn't go that far when processing_template_decl is 0.
Otherwise it would return true.
Is this information already useful to you? Are we maybe failing to bump
processing_template_decl somewhere while processing the specialization?