From 8dd2deb142f962203ed73711d320d052e8fb769f Mon Sep 17 00:00:00 2001 From: bothner Date: Fri, 19 Mar 2004 23:10:55 +0000 Subject: * class.c (assume_compiled_node_struct): Rename type to class_flag_node_struct, as it is now also used for enable_assertions. Rename assume_compiled_node typedef. Rename excludep field to value. (find_assume_compiled_node): Rename function to find_class_flag_node. Minor optimization - avoid needless strlen. (add_assume_compiled): Some tweaking and optimization. Rename and generalize to add_class_flag takem an extra parameter. (add_assume_compled): New just calls add_class_flag. (add_enable_assert, enable_assertions): New functions. (enable_assert_tree): New static. * java-tree.h (add_enable_assert, enable_assertions): New declarations. * lang.opt (fenable-assertions, fenable-assertions=, fdisable-assertions, fdisable-assertions=): New options. * lang.c (java_handle_option): Handle new options. * parse.y (build_incomplete_class_ref): Handle class$ in an inner class in an interface - create helper class nested in outer interface. (build_assertion): Short-circuit if enable_assertions is false. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@79710 138bc75d-0d04-0410-961f-82ee72b054a4 --- gcc/java/lang.c | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) (limited to 'gcc/java/lang.c') diff --git a/gcc/java/lang.c b/gcc/java/lang.c index 0fe68def937..20afb504e72 100644 --- a/gcc/java/lang.c +++ b/gcc/java/lang.c @@ -354,6 +354,22 @@ java_handle_option (size_t scode, const char *arg, int value) flag_assert = value; break; + case OPT_fenable_assertions_: + add_enable_assert (arg, value); + break; + + case OPT_fenable_assertions: + add_enable_assert ("", value); + break; + + case OPT_fdisable_assertions_: + add_enable_assert (arg, !value); + break; + + case OPT_fdisable_assertions: + add_enable_assert ("", !value); + break; + case OPT_fassume_compiled_: add_assume_compiled (arg, !value); break; -- cgit v1.2.1