mirror of git://gcc.gnu.org/git/gcc.git
re PR c++/32567 (ICE on invalid use of parameter pack)
PR c++/32567 * typeck.c (build_unary_op) <case PREINCREMENT_EXPR>: Return error_mark_node right away if build_expr_type_conversion returned it. * g++.dg/parse/crash36.C: New test. From-SVN: r127760
This commit is contained in:
parent
14693275ea
commit
affb3cb200
|
@ -1,5 +1,10 @@
|
|||
2007-08-24 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
PR c++/32567
|
||||
* typeck.c (build_unary_op) <case PREINCREMENT_EXPR>: Return
|
||||
error_mark_node right away if build_expr_type_conversion
|
||||
returned it.
|
||||
|
||||
PR c++/32898
|
||||
* name-lookup.c (set_decl_namespace): lookup_qualified_name failure
|
||||
is error_mark_node rather than NULL_TREE.
|
||||
|
|
|
@ -4259,6 +4259,8 @@ build_unary_op (enum tree_code code, tree xarg, int noconvert)
|
|||
errstring ="no post-decrement operator for type";
|
||||
break;
|
||||
}
|
||||
else if (arg == error_mark_node)
|
||||
return error_mark_node;
|
||||
|
||||
/* Report something read-only. */
|
||||
|
||||
|
|
|
@ -1,3 +1,8 @@
|
|||
2007-08-24 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
PR c++/32567
|
||||
* g++.dg/parse/crash36.C: New test.
|
||||
|
||||
2007-08-23 H.J. Lu <hongjiu.lu@intel.com>
|
||||
|
||||
* gcc.dg/pr32721.c: Updated.
|
||||
|
|
|
@ -0,0 +1,11 @@
|
|||
// PR c++/32567
|
||||
// { dg-do compile }
|
||||
// { dg-options "-std=c++98" }
|
||||
|
||||
template <typename... T> struct A // { dg-error "does not include variadic templates" }
|
||||
{
|
||||
static T &t; // { dg-error "not expanded with|T" }
|
||||
static const int i = sizeof (++t); // { dg-error "invalid use of template type parameter" }
|
||||
};
|
||||
|
||||
int x[A <int>::i]; // { dg-error "is not an integral constant-expression" }
|
Loading…
Reference in New Issue