This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/51180] [C++0x] inner class alias-definition variadic template error
- From: "dodji at seketeli dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Fri, 02 Dec 2011 10:15:06 +0000
- Subject: [Bug c++/51180] [C++0x] inner class alias-definition variadic template error
- Auto-submitted: auto-generated
- References: <bug-51180-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51180
--- Comment #4 from dodji at seketeli dot org <dodji at seketeli dot org> 2011-12-02 10:15:06 UTC ---
"jason at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org> a Ãcrit:
> I'm surprised that it doesn't just work already; writing t2<B...> already
> works, doing the substitution ought to work the same way.
It wasn't working in this case because we are getting into the "if"
below in coerce_template_parms:
if ((nargs > nparms && !variadic_p)
|| (nargs < nparms - variadic_p
&& require_all_args
&& (!use_default_args
|| (TREE_VEC_ELT (parms, nargs) != error_mark_node
&& !TREE_PURPOSE (TREE_VEC_ELT (parms, nargs))))))
{
We are getting there because the number of arguments of t2 in that
case is smaller than its number of parms.
I am still tweaking other parts of the patch to make it pass bootstrap
and testing.