Commit 97bb4af7 by Richard Henderson Committed by Richard Henderson

re PR middle-end/16216 (ICE in gimplify_va_arg_expr after error)

        PR middle-end/16216
        * builtins.c (gimplify_va_arg_expr): Check for valist being
        an error_mark_node.

From-SVN: r83881
parent beabab59
2004-06-29 Richard Henderson <rth@redhat.com>
PR middle-end/16216
* builtins.c (gimplify_va_arg_expr): Check for valist being
an error_mark_node.
2004-06-29 Jakub Jelinek <jakub@redhat.com>
PR target/16195
......
......@@ -4466,9 +4466,12 @@ gimplify_va_arg_expr (tree *expr_p, tree *pre_p, tree *post_p)
tree t;
/* Verify that valist is of the proper type. */
want_va_type = va_list_type_node;
have_va_type = TREE_TYPE (valist);
if (have_va_type == error_mark_node)
return GS_ERROR;
if (TREE_CODE (want_va_type) == ARRAY_TYPE)
{
/* If va_list is an array type, the argument may have decayed
......
/* PR 16216 */
void func()
{
const char *pek; int i;
pek=__builtin_va_arg(ap,const char*); /* { dg-error "" } */
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment