On 10/15/2013 05:21 PM, Adam Butcher wrote:
On Wed, 25 Sep 2013 11:01:26 -0500, Jason Merrill wrote:
1) Build up the type as normal and use tsubst to replace the non-pack
template parameter with a pack if needed.
The problem I've hit with this (and other hacks I've tried that involve
finishing the type first and rewriting afterward) is that, with parm
types such as "pair<auto,auto>...", the specialization "pair<auto,auto>"
is indexed in pt.c by hash_specialization into type_specializations
before the '...' is seen.
I'm not sure why that's a problem; we just produce a new specialization
that uses different template arguments in tsubst. Specifically, the
pack 'auto' needs to be a different TEMPLATE_TYPE_PARM from the non-pack
'auto' produced during parsing.
Jason