PR c++/77637
* parser.c (cp_parser_std_attribute_list): Reject ... without
preceding attribute.
* g++.dg/cpp0x/gen-attrs-62.C: New test.
From-SVN: r240265
+2016-09-20 Jakub Jelinek <jakub@redhat.com>
+
+ PR c++/77637
+ * parser.c (cp_parser_std_attribute_list): Reject ... without
+ preceding attribute.
+
2016-09-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
PR c++/77434
if (token->type == CPP_ELLIPSIS)
{
cp_lexer_consume_token (parser->lexer);
- TREE_VALUE (attribute)
- = make_pack_expansion (TREE_VALUE (attribute));
+ if (attribute == NULL_TREE)
+ error_at (token->location,
+ "expected attribute before %<...%>");
+ else
+ TREE_VALUE (attribute)
+ = make_pack_expansion (TREE_VALUE (attribute));
token = cp_lexer_peek_token (parser->lexer);
}
if (token->type != CPP_COMMA)
2016-09-20 Jakub Jelinek <jakub@redhat.com>
+ PR c++/77637
+ * g++.dg/cpp0x/gen-attrs-62.C: New test.
+
PR middle-end/77624
* c-c++-common/pr77624-1.c: New test.
* c-c++-common/pr77624-2.c: New test.
--- /dev/null
+// PR c++/77637
+// { dg-do compile { target c++11 } }
+
+int [[...]] a; // { dg-error "expected attribute before '...'" }
+int [[,,...]] b; // { dg-error "expected attribute before '...'" }