From: Richard Henderson Date: Thu, 24 Jun 2004 16:25:17 +0000 (-0700) Subject: * gimplify.c (gimplify_body): Watch for body vanishing. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=be1ba3d170d2119394c4700e320240264513d64e;p=gcc.git * gimplify.c (gimplify_body): Watch for body vanishing. From-SVN: r83598 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 9876fc878ae..da403d9ba00 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,7 @@ +2004-06-24 Richard Henderson + + * gimplify.c (gimplify_body): Watch for body vanishing. + 2004-06-24 Jeff Law * tree-ssa-dom.c (record_dominating_conditions): New function. diff --git a/gcc/gimplify.c b/gcc/gimplify.c index 480b8ebbf06..308f3e9b6a2 100644 --- a/gcc/gimplify.c +++ b/gcc/gimplify.c @@ -4142,7 +4142,9 @@ gimplify_body (tree *body_p, tree fndecl) /* Unshare again, in case gimplification was sloppy. */ unshare_all_trees (body); - if (TREE_CODE (body) == STATEMENT_LIST) + if (!body) + body = alloc_stmt_list (); + else if (TREE_CODE (body) == STATEMENT_LIST) { tree t = expr_only (*body_p); if (t)