+2015-01-13 Jason Merrill <jason@redhat.com>
+
+ PR c++/64520
+ * pt.c (unify): Don't try to deduce to std::initializer_list<T...>.
+
2015-01-12 Jason Merrill <jason@redhat.com>
PR c++/64547
if (TREE_CODE (parm) == ARRAY_TYPE)
elttype = TREE_TYPE (parm);
else
- elttype = TREE_VEC_ELT (CLASSTYPE_TI_ARGS (parm), 0);
+ {
+ elttype = TREE_VEC_ELT (CLASSTYPE_TI_ARGS (parm), 0);
+ /* Deduction is defined in terms of a single type, so just punt
+ on the (bizarre) std::initializer_list<T...>. */
+ if (PACK_EXPANSION_P (elttype))
+ return unify_success (explain_p);
+ }
FOR_EACH_CONSTRUCTOR_VALUE (CONSTRUCTOR_ELTS (arg), i, elt)
{
--- /dev/null
+// PR c++/64520
+// { dg-do compile { target c++11 } }
+
+#include <initializer_list>
+struct A {
+ template <typename... B> A(std::initializer_list<B...>);
+};
+A a { 0 }; // { dg-error "" }