This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
default EH to being on for cleanups
- To: egcs-patches at cygnus dot com
- Subject: default EH to being on for cleanups
- From: mrs at wrs dot com (Mike Stump)
- Date: Fri, 18 Dec 1998 15:41:55 -0800
- Cc: bothner at cygnus dot com, kenner at vlsi1 dot ultra dot nyu dot edu
I think we should default EH to being on for cleanups. This will
break Ada (Ada will need to call not_using_eh_for_cleanups during
initialization).
The reason why this is ok, is because Ada hasn't yet been converted to
use exception handling in gcc, but handles it in the frontend (ick).
Java seemed to be broken without this, and so will every language that
does something with exception handling from gcc. Chill may also need
to either use EH from gcc, or call not_using_eh_for_cleanups during
initialization for much the same reasons as Ada. Fortran, C,
Objective-C and Pascal shouldn't matter. Modula will likely need to
call not_using_eh_for_cleanups until it is converted as well.
Fri Dec 18 15:27:16 1998 Mike Stump <mrs@wrs.com>
* stmt.c (using_eh_for_cleanups_p): Default to on.
(not_using_eh_for_cleanups): Added.
(using_eh_for_cleanups): Removed.
Fri Dec 18 15:27:16 1998 Mike Stump <mrs@wrs.com>
* decl.c (init_decl_processing): Don't call using_eh_for_cleanups
anymore, as it is the default.
Doing diffs in stmt.c.~1~:
*** stmt.c.~1~ Fri Dec 4 15:06:13 1998
--- stmt.c Fri Dec 18 15:26:52 1998
*************** struct label_chain
*** 422,428 ****
/* Non-zero if we are using EH to handle cleanus. */
! static int using_eh_for_cleanups_p = 0;
static int n_occurrences PROTO((int, char *));
--- 422,428 ----
/* Non-zero if we are using EH to handle cleanus. */
! static int using_eh_for_cleanups_p = 1;
static int n_occurrences PROTO((int, char *));
*************** static int add_case_node PROTO((tree, t
*** 452,460 ****
static struct case_node *case_tree2list PROTO((case_node *, case_node *));
void
! using_eh_for_cleanups ()
{
! using_eh_for_cleanups_p = 1;
}
void
--- 452,460 ----
static struct case_node *case_tree2list PROTO((case_node *, case_node *));
void
! not_using_eh_for_cleanups ()
{
! using_eh_for_cleanups_p = 0;
}
void
--------------
Doing diffs in cp/decl.c.~1~:
*** cp/decl.c.~1~ Thu Dec 17 12:32:09 1998
--- cp/decl.c Fri Dec 18 15:24:48 1998
*************** init_decl_processing ()
*** 6542,6550 ****
/* Prepare to check format strings against argument lists. */
init_function_format_info ();
- /* Show we use EH for cleanups. */
- using_eh_for_cleanups ();
-
print_error_function = lang_print_error_function;
lang_get_alias_set = &c_get_alias_set;
--- 6542,6547 ----
--------------