PR c++/72801
* pt.c (unify_pack_expansion): Don't try to deduce enclosing
template args.
From-SVN: r256802
+2018-01-17 Jason Merrill <jason@redhat.com>
+
+ PR c++/81843 - ICE with variadic member template.
+ PR c++/72801
+ * pt.c (unify_pack_expansion): Don't try to deduce enclosing
+ template args.
+
2018-01-17 David Malcolm <dmalcolm@redhat.com>
PR c++/83799
/* Add in any args remembered from an earlier partial instantiation. */
targs = add_to_template_args (PACK_EXPANSION_EXTRA_ARGS (parm), targs);
+ int levels = TMPL_ARGS_DEPTH (targs);
packed_args = expand_template_argument_pack (packed_args);
/* Determine the index and level of this parameter pack. */
template_parm_level_and_index (parm_pack, &level, &idx);
+ if (level < levels)
+ continue;
/* Keep track of the parameter packs and their corresponding
argument packs. */
--- /dev/null
+// PR c++/81843
+// { dg-do compile { target c++11 } }
+
+template < typename > struct A;
+template < typename, typename > struct B;
+template < typename ... S > struct C
+{
+ template < typename > struct D {};
+ template < typename ... T > struct D < A < B < S, T > ... > >;
+};
+
+C <>::D < A < B < int, int > > > c;