re PR c++/36408 (ICE with statement expression in template)
PR c++/36408 * semantics.c (stmt_expr_value_expr): Don't crash on empty STATEMENT_LIST. From-SVN: r136651
This commit is contained in:
parent
976e44e324
commit
9de0e91616
|
@ -1,3 +1,9 @@
|
|||
2008-06-09 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
PR c++/36408
|
||||
* semantics.c (stmt_expr_value_expr): Don't crash on empty
|
||||
STATEMENT_LIST.
|
||||
|
||||
2008-06-08 Paolo Carlini <paolo.carlini@oracle.com>
|
||||
|
||||
PR c++/35242
|
||||
|
|
|
@ -1778,7 +1778,7 @@ stmt_expr_value_expr (tree stmt_expr)
|
|||
if (TREE_CODE (t) == BIND_EXPR)
|
||||
t = BIND_EXPR_BODY (t);
|
||||
|
||||
if (TREE_CODE (t) == STATEMENT_LIST)
|
||||
if (TREE_CODE (t) == STATEMENT_LIST && STATEMENT_LIST_TAIL (t))
|
||||
t = STATEMENT_LIST_TAIL (t)->stmt;
|
||||
|
||||
if (TREE_CODE (t) == EXPR_STMT)
|
||||
|
|
Loading…
Reference in New Issue