PR c++/60187
* parser.c (cp_parser_enum_specifier): Call
check_for_bare_parameter_packs.
From-SVN: r208026
2014-02-21 Jason Merrill <jason@redhat.com>
+ PR c++/60187
+ * parser.c (cp_parser_enum_specifier): Call
+ check_for_bare_parameter_packs.
+
PR c++/59347
* pt.c (tsubst_decl) [TYPE_DECL]: Don't try to instantiate an
erroneous typedef.
{
underlying_type = grokdeclarator (NULL, &type_specifiers, TYPENAME,
/*initialized=*/0, NULL);
- if (underlying_type == error_mark_node)
+ if (underlying_type == error_mark_node
+ || check_for_bare_parameter_packs (underlying_type))
underlying_type = NULL_TREE;
}
}
--- /dev/null
+// PR c++/60187
+// { dg-require-effective-target c++11 }
+
+template<typename... T> struct A
+{
+ enum E : T {}; // { dg-error "parameter pack" }
+};
+
+A<int> a;