except.c, [...] (expand_resume_after_catch): new function.

Mon Jan 25 17:39:19 1999  Andrew Haley  <aph@cygnus.com>
        * except.c, java-except.h (expand_resume_after_catch): new
        function.
        * expr.c (java_lang_expand_expr): call expand_resume_after_catch
        to branch back to main flow of control after a catch block.

From-SVN: r24857
This commit is contained in:
Andrew Haley 1999-01-25 10:32:18 +00:00 committed by Andrew Haley
parent 3f7547f7c3
commit 1b18747f2e
4 changed files with 18 additions and 10 deletions

View File

@ -1,3 +1,10 @@
Mon Jan 25 17:39:19 1999 Andrew Haley <aph@cygnus.com>
* except.c, java-except.h (expand_resume_after_catch): new
function.
* expr.c (java_lang_expand_expr): call expand_resume_after_catch
to branch back to main flow of control after a catch block.
Sat Jan 23 23:02:43 1999 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
* Makefile.in (parse.o): Depend on $(CONFIG_H) and

View File

@ -293,3 +293,12 @@ emit_handlers ()
emit_label (funcend);
}
}
/* Resume executing at the statement immediately after the end of an
exception region. */
void
expand_resume_after_catch ()
{
expand_goto (top_label_entry (&caught_return_label_stack));
}

View File

@ -1896,16 +1896,7 @@ java_lang_expand_expr (exp, target, tmode, modifier)
start_catch_handler (prepare_eh_table_type (type));
expand_expr_stmt (TREE_OPERAND (current, 0));
/* Need to expand a goto to the end of the function here,
but not for the catch everything handler. */
if (type)
{
if (return_label)
emit_jump (return_label);
else
fatal ("No return_label for this function - "
"java_lang_expand_expr");
}
expand_resume_after_catch ();
end_catch_handler ();
}

View File

@ -71,3 +71,4 @@ extern void maybe_end_try PROTO ((int));
extern int add_handler PROTO ((int, int, tree, tree));
extern void expand_resume_after_catch PROTO ((void));