expr.c (expand_expr): Do not return the last statement in a block as the block's...
authorAndrew Haley <aph@cygnus.com>
Thu, 15 Jul 1999 05:17:08 +0000 (05:17 +0000)
committerAndrew Haley <aph@gcc.gnu.org>
Thu, 15 Jul 1999 05:17:08 +0000 (05:17 +0000)
1999-07-14  Andrew Haley  <aph@cygnus.com>
        * expr.c (expand_expr): Do not return the last statement in a
        block as the block's value.

From-SVN: r28112

gcc/java/ChangeLog
gcc/java/expr.c

index df78c4269c01f7bf7cd1a0801a42ebac0ac81fe0..d170b3db10df2d4c30beca64ce3cf985902632fe 100644 (file)
@@ -1,3 +1,8 @@
+1999-07-14  Andrew Haley  <aph@cygnus.com>
+
+        * expr.c (expand_expr): Do not return the last statement in a
+        block as the block's value.
+
 Sat Jul  3 22:26:32 1999  Alexandre Petit-Bianco  <apbianco@cygnus.com>
 
        * expr.c (force_evaluation_order): Save the COMPOUND_EXPR'ed
index 8998bdb3a58fc3eb75e4ca01aa6d79950ef97831..d47ed1af8570f500bef66e846da7bbde3ffa2aa1 100644 (file)
@@ -1895,7 +1895,6 @@ java_lang_expand_expr (exp, target, tmode, modifier)
        {
          tree local;
          tree body = BLOCK_EXPR_BODY (exp);
-         struct rtx_def *to_return;
          pushlevel (2);        /* 2 and above */
          expand_start_bindings (0);
          local = BLOCK_EXPR_DECLS (exp);
@@ -1913,10 +1912,11 @@ java_lang_expand_expr (exp, target, tmode, modifier)
              emit_queue ();
              body = TREE_OPERAND (body, 1);
            }
-         to_return = expand_expr (body, target, tmode, modifier);
+         expand_expr (body, const0_rtx, VOIDmode, 0);
+         emit_queue ();
          poplevel (1, 1, 0);
          expand_end_bindings (getdecls (), 1, 0);
-         return to_return;
+         return const0_rtx;
        }
       break;