check-init.c (check_init): Fix TRY_FINALLY_EXPR logic.
authorPer Bothner <per@bothner.com>
Thu, 8 Feb 2001 03:45:14 +0000 (19:45 -0800)
committerPer Bothner <bothner@gcc.gnu.org>
Thu, 8 Feb 2001 03:45:14 +0000 (19:45 -0800)
* check-init.c (check_init):  Fix TRY_FINALLY_EXPR logic.

* check-init.c (check_init):  Don't call done_alternative after
processing loop code, as a LOOP_EXPR never terminates normally.

From-SVN: r39534

gcc/java/ChangeLog
gcc/java/check-init.c

index fa240b0c833dc13f4c521d0d3e2cb41b3fe9d05f..992396862cb284232057fcaaefae3114a7ec23ee 100644 (file)
@@ -1,3 +1,10 @@
+2001-02-07  Per Bothner  <per@bothner.com>
+
+       * check-init.c (check_init):  Fix TRY_FINALLY_EXPR logic.
+
+       * check-init.c (check_init):  Don't call done_alternative after
+       processing loop code, as a LOOP_EXPR never terminates normally.
+
 2001-02-08  Joseph S. Myers  <jsm28@cam.ac.uk>
 
        * gcj.texi: Change sources.redhat.com reference to gcc.gnu.org.
index 9d891968d25990c72b02257e74018823fbd04db4..49df07291d5c949a78b5e42490c1a188b3a80f8c 100644 (file)
@@ -451,7 +451,6 @@ check_init (exp, before)
        BEGIN_ALTERNATIVES (before, alt);
        alt.block = exp;
        check_init (TREE_OPERAND (exp, 0), before);
-       done_alternative (before, &alt);
        END_ALTERNATIVES (before, alt);
        return;
       }
@@ -571,8 +570,9 @@ check_init (exp, before)
       {
        words tmp = ALLOC_WORDS (num_current_words);
        COPY (tmp, before);
-       check_init (TREE_OPERAND (exp, 0), tmp);
-       check_init (TREE_OPERAND (exp, 1), before);
+       check_init (TREE_OPERAND (exp, 0), before);
+       check_init (TREE_OPERAND (exp, 1), tmp);
+       UNION (before, before, tmp);
        FREE_WORDS (tmp);
       }
       return;