Tue Oct 13 03:50:28 1998 Alexandre Petit-Bianco <apbianco@cygnus.com> * decl.c (runtime_exception_type_node, error_exception_type_node): New global variables. (init_decl_processing): Initialized. * expr.c (java_lang_expand_expr): Set caught exception type to null if catch handler argument doesn't exit. * java-tree.def (SYNCHRONIZED_EXPR, THROW_EXPR): New Java specific tree codes. * java-tree.h (runtime_exception_type_node, error_exception_type_node): Global variables declared. (DECL_FUNCTION_THROWS): New macro. (DECL_FUNCTION_BODY): Modified comment. (DECL_SPECIFIC_COUNT): Likewise. (struct lang_decl): New field throws_list. (IS_UNCHECKED_EXPRESSION_P): New macro. * lex.c (java_lex): Generate location information for THROW_TK. * parse.h (PUSH_EXCEPTIONS, POP_EXCEPTIONS, IN_TRY_BLOCK_P, EXCEPTIONS_P): New macros. (enum jdep_code): New value JDEP_EXCEPTION. (BUILD_MONITOR_ENTER, BUILD_MONITOR_EXIT, BUILD_ASSIGN_EXCEPTION_INFO, BUILD_THROW, SET_WFL_OPERATOR, PATCH_METHOD_RETURN_ERROR): New macros. (patch_method_invocation_stmt): Added new argument to prototype. (patch_synchronized_statement, patch_throw_statement, check_thrown_exceptions, check_thrown_exceptions_do, purge_unchecked_exceptions, check_throws_clauses): New function prototypes. * parse.y Fixed typo in keyword section. (throw:): Rule tagged <node>. (THROW_TK): Keyword tagged <operator>. (method_header:): Last argument to call to method_header passed from throws: rule. (throws:, class_type_list:, throw_statement:, synchronized_statement:, synchronized:): Defined actions. (method_header): New local variable current. Register exceptions from throws clause. (java_complete_tree): Complete and verify exceptions from throws clause. (complete_class_report_errors): Error message on exceptions not found (java_check_regular_methods): Fixed typo. Shortcut on private overriding methods. Changed error message on method redefinition. Check for throws clause compatibility. (check_throws_clauses): New function. (java_check_abstract_methods): Use DECL_NAME for wfl or current method. Changed error message on method redefinition. (currently_caught_type_list): New static variable. (java_complete_expand_methods): Purge unchecked exceptions from throws clause list. Call PUSH_EXCEPTIONS before walk and POP_EXCEPTIONS after. (resolve_qualified_expression_name): Pass new argument as NULL to patch_method_invocation_stmt. (patch_method_invocation_stmt): New argument ref_decl. Invoke PATCH_METHOD_RETURN_ERROR when returning with error. Reverse argument list when appropriate. Use new argument if non null to store selected method decl. (patch_invoke): Convert if necessary args of builtin types before forming CALL_EXPR. Argument list no longer reversed here. (invocation_mode): Treat final methods as static methods. (java_complete_tree): New cases for THROW_EXPR: and SYNCHRONIZED_EXPR:. Check thrown exceptions when completing function call. (complete_function_arguments): No more RECORD_TYPE conversion. Function parameter nodes no longer saved. (valid_ref_assignconv_cast_p): Avoid handling null type. (patch_binop): Fixed null constant reference handling. (build_try_statement): Use BUILD_ASSIGN_EXCEPTION_INFO and BUILD_THROW macros. (patch_try_statement): Fixed comments. Record caught types in list, push the list, expand try block and pop the list. (patch_synchronized_statement, patch_throw_statement, check_thrown_exceptions, check_thrown_exceptions_do, purge_unchecked_exceptions): New functions. * typeck.c (lookup_argument_method): Allow WFL in place of method DECL_NAME during method definition check Implements the `synchronized' statement, the `throw' statements and the `throws' clause. Fixes method invocation bugs. From-SVN: r23087
| Name | 
 Last commit 
 | 
Last update | 
|---|---|---|
| .. | ||
| ch | Loading commit data... | |
| config | Loading commit data... | |
| cp | Loading commit data... | |
| f | Loading commit data... | |
| ginclude | Loading commit data... | |
| intl | Loading commit data... | |
| java | Loading commit data... | |
| objc | Loading commit data... | |
| po | Loading commit data... | |
| testsuite | Loading commit data... | |
| .cvsignore | Loading commit data... | |
| .gdbinit | Loading commit data... | |
| ABOUT-GCC-NLS | Loading commit data... | |
| ABOUT-NLS | Loading commit data... | |
| BUGS | Loading commit data... | |
| COPYING | Loading commit data... | |
| COPYING.LIB | Loading commit data... | |
| ChangeLog | Loading commit data... | |
| ChangeLog.0 | Loading commit data... | |
| ChangeLog.lib | Loading commit data... | |
| FSFChangeLog | Loading commit data... | |
| FSFChangeLog.10 | Loading commit data... | |
| FSFChangeLog.11 | Loading commit data... | |
| FSFChangeLog.12 | Loading commit data... | |
| INSTALL | Loading commit data... | |
| LANGUAGES | Loading commit data... | |
| LITERATURE | Loading commit data... | |
| Makefile.in | Loading commit data... | |
| NEWS | Loading commit data... | |
| PROBLEMS | Loading commit data... | |
| PROJECTS | Loading commit data... | |
| README | Loading commit data... | |
| README-bugs | Loading commit data... | |
| README-fixinc | Loading commit data... | |
| README.ACORN | Loading commit data... | |
| README.ALTOS | Loading commit data... | |
| README.APOLLO | Loading commit data... | |
| README.C4X | Loading commit data... | |
| README.DWARF | Loading commit data... | |
| README.FRESCO | Loading commit data... | |
| README.NS32K | Loading commit data... | |
| README.RS6000 | Loading commit data... | |
| README.TRAD | Loading commit data... | |
| README.X11 | Loading commit data... | |
| README.g77 | Loading commit data... | |
| README.gnat | Loading commit data... | |
| SERVICE | Loading commit data... | |
| TESTS.FLUNK | Loading commit data... | |
| acconfig.h | Loading commit data... | |
| aclocal.m4 | Loading commit data... | |
| alias.c | Loading commit data... | |
| assert.h | Loading commit data... | |
| basic-block.h | Loading commit data... | |
| bitmap.c | Loading commit data... | |
| bitmap.h | Loading commit data... | |
| build-make | Loading commit data... | |
| c-aux-info.c | Loading commit data... | |
| c-common.c | Loading commit data... | |
| c-convert.c | Loading commit data... | |
| c-decl.c | Loading commit data... | |
| c-gperf.h | Loading commit data... | |
| c-iterate.c | Loading commit data... | |
| c-lang.c | Loading commit data... | |
| c-lex.c | Loading commit data... | |
| c-lex.h | Loading commit data... | |
| c-parse.c | Loading commit data... | |
| c-parse.gperf | Loading commit data... | |
| c-parse.h | Loading commit data... | |
| c-parse.in | Loading commit data... | |
| c-parse.y | Loading commit data... | |
| c-pragma.c | Loading commit data... | |
| c-pragma.h | Loading commit data... | |
| c-tree.h | Loading commit data... | |
| c-typeck.c | Loading commit data... | |
| caller-save.c | Loading commit data... | |
| calls.c | Loading commit data... | |
| cccp.1 | Loading commit data... | |
| cccp.c | Loading commit data... | |
| cexp.c | Loading commit data... | |
| cexp.y | Loading commit data... | |
| collect2.c | Loading commit data... | |
| combine.c | Loading commit data... | |
| conditions.h | Loading commit data... | |
| config.guess | Loading commit data... | |
| config.in | Loading commit data... | |
| config.sub | Loading commit data... | |
| configure | Loading commit data... | |
| configure.bat | Loading commit data... | |
| configure.frag | Loading commit data... | |
| configure.in | Loading commit data... | |
| configure.lang | Loading commit data... | |
| convert.c | Loading commit data... | |
| convert.h | Loading commit data... | |
| cpp.1 | Loading commit data... | |
| cpp.cps | Loading commit data... | |
| cpp.fns | Loading commit data... | |
| cpp.texi | Loading commit data... | |
| cppalloc.c | Loading commit data... | |
| cpperror.c | Loading commit data... | |
| cppexp.c | Loading commit data... | |
| cpphash.c | Loading commit data... | |
| cpphash.h | Loading commit data... | |
| cpplib.c | Loading commit data... | |
| cpplib.h | Loading commit data... | |
| cppmain.c | Loading commit data... | |
| cross-make | Loading commit data... | |
| crtstuff.c | Loading commit data... | |
| cse.c | Loading commit data... | |
| cstamp-h.in | Loading commit data... | |
| dbxout.c | Loading commit data... | |
| dbxout.h | Loading commit data... | |
| dbxstclass.h | Loading commit data... | |
| defaults.h | Loading commit data... | |
| demangle.h | Loading commit data... | |
| doprint.c | Loading commit data... | |
| doschk.c | Loading commit data... | |
| dostage2 | Loading commit data... | |
| dostage3 | Loading commit data... | |
| dwarf.h | Loading commit data... | |
| dwarf2.h | Loading commit data... | |
| dwarf2out.c | Loading commit data... | |
| dwarf2out.h | Loading commit data... | |
| dwarfout.c | Loading commit data... | |
| dwarfout.h | Loading commit data... | |
| dyn-string.c | Loading commit data... | |
| dyn-string.h | Loading commit data... | |
| eh-common.h | Loading commit data... | |
| emit-rtl.c | Loading commit data... | |
| enquire.c | Loading commit data... | |
| except.c | Loading commit data... | |
| except.h | Loading commit data... | |
| exgettext | Loading commit data... | |
| explow.c | Loading commit data... | |
| expmed.c | Loading commit data... | |
| expr.c | Loading commit data... | |
| expr.h | Loading commit data... | |
| extend.texi | Loading commit data... | |
| final.c | Loading commit data... | |
| fix-header.c | Loading commit data... | |
| fixcpp | Loading commit data... | |
| fixinc-nt.sed | Loading commit data... | |
| fixinc.dgux | Loading commit data... | |
| fixinc.irix | Loading commit data... | |
| fixinc.ptx | Loading commit data... | |
| fixinc.sco | Loading commit data... | |
| fixinc.svr4 | Loading commit data... | |
| fixinc.winnt | Loading commit data... | |
| fixinc.wrap | Loading commit data... | |
| fixincludes | Loading commit data... | |
| fixproto | Loading commit data... | |
| flags.h | Loading commit data... | |
| floatlib.c | Loading commit data... | |
| flow.c | Loading commit data... | |
| fold-const.c | Loading commit data... | |
| fp-test.c | Loading commit data... | |
| frame.c | Loading commit data... | |
| frame.h | Loading commit data... | |
| function.c | Loading commit data... | |
| function.h | Loading commit data... | |
| future.options | Loading commit data... | |
| gansidecl.h | Loading commit data... | |
| gbl-ctors.h | Loading commit data... | |
| gcc.1 | Loading commit data... | |
| gcc.c | Loading commit data... | |
| gcc.cps | Loading commit data... | |
| gcc.hlp | Loading commit data... | |
| gcc.texi | Loading commit data... | |
| gcov-io.h | Loading commit data... | |
| gcov.c | Loading commit data... | |
| gcov.texi | Loading commit data... | |
| gcse.c | Loading commit data... | |
| gen-protos.c | Loading commit data... | |
| genattr.c | Loading commit data... | |
| genattrtab.c | Loading commit data... | |
| gencheck.c | Loading commit data... | |
| gencodes.c | Loading commit data... | |
| genconfig.c | Loading commit data... | |
| genemit.c | Loading commit data... | |
| genextract.c | Loading commit data... | |
| genflags.c | Loading commit data... | |
| gengenrtl.c | Loading commit data... | |
| genmultilib | Loading commit data... | |
| genopinit.c | Loading commit data... | |
| genoutput.c | Loading commit data... | |
| genpeep.c | Loading commit data... | |
| genrecog.c | Loading commit data... | |
| getpwd.c | Loading commit data... | |
| glimits.h | Loading commit data... | |
| global.c | Loading commit data... | |
| gmon.c | Loading commit data... | |
| gstab.h | Loading commit data... | |
| gsyms.h | Loading commit data... | |
| gsyslimits.h | Loading commit data... | |
| gthr-dce.h | Loading commit data... | |
| gthr-posix.h | Loading commit data... | |
| gthr-single.h | Loading commit data... | |
| gthr-solaris.h | Loading commit data... | |
| gthr-vxworks.h | Loading commit data... | |
| gthr.h | Loading commit data... | |
| haifa-sched.c | Loading commit data... | |
| halfpic.c | Loading commit data... | |
| halfpic.h | Loading commit data... | |
| hard-reg-set.h | Loading commit data... | |
| hash.c | Loading commit data... | |
| hash.h | Loading commit data... | |
| input.h | Loading commit data... | |
| install.texi | Loading commit data... | |
| install1.texi | Loading commit data... | |
| integrate.c | Loading commit data... | |
| integrate.h | Loading commit data... | |
| intl.c | Loading commit data... | |
| intl.h | Loading commit data... | |
| invoke.texi | Loading commit data... | |
| jump.c | Loading commit data... | |
| just-fixinc | Loading commit data... | |
| libgcc1-test.c | Loading commit data... | |
| libgcc1.c | Loading commit data... | |
| libgcc2.c | Loading commit data... | |
| limitx.h | Loading commit data... | |
| limity.h | Loading commit data... | |
| listing | Loading commit data... | |
| local-alloc.c | Loading commit data... | |
| longlong.h | Loading commit data... | |
| loop.c | Loading commit data... | |
| loop.h | Loading commit data... | |
| machmode.def | Loading commit data... | |
| machmode.h | Loading commit data... | |
| make-l2.com | Loading commit data... | |
| makefile.vms | Loading commit data... | |
| mbchar.c | Loading commit data... | |
| mbchar.h | Loading commit data... | |
| md.texi | Loading commit data... | |
| mips-tdump.c | Loading commit data... | |
| mips-tfile.c | Loading commit data... | |
| mkinstalldirs | Loading commit data... | |
| move-if-change | Loading commit data... | |
| optabs.c | Loading commit data... | |
| output.h | Loading commit data... | |
| patch-apollo-includes | Loading commit data... | |
| pcp.h | Loading commit data... | |
| prefix.c | Loading commit data... | |
| print-rtl.c | Loading commit data... | |
| print-tree.c | Loading commit data... | |
| profile.c | Loading commit data... | |
| protoize.c | Loading commit data... | |
| pself.c | Loading commit data... | |
| pself1.c | Loading commit data... | |
| pself2.c | Loading commit data... | |
| pself3.c | Loading commit data... | |
| real.c | Loading commit data... | |
| real.h | Loading commit data... | |
| recog.c | Loading commit data... | |
| recog.h | Loading commit data... | |
| reg-stack.c | Loading commit data... | |
| regclass.c | Loading commit data... | |
| regmove.c | Loading commit data... | |
| regs.h | Loading commit data... | |
| reload.c | Loading commit data... | |
| reload.h | Loading commit data... | |
| reload1.c | Loading commit data... | |
| reorg.c | Loading commit data... | |
| rtl.c | Loading commit data... | |
| rtl.def | Loading commit data... | |
| rtl.h | Loading commit data... | |
| rtl.texi | Loading commit data... | |
| rtlanal.c | Loading commit data... | |
| scan-decls.c | Loading commit data... | |
| scan-types.sh | Loading commit data... | |
| scan.c | Loading commit data... | |
| scan.h | Loading commit data... | |
| sched.c | Loading commit data... | |
| sdbout.c | Loading commit data... | |
| sdbout.h | Loading commit data... | |
| sort-protos | Loading commit data... | |
| stab.def | Loading commit data... | |
| stack.h | Loading commit data... | |
| stmt.c | Loading commit data... | |
| stor-layout.c | Loading commit data... | |
| stupid.c | Loading commit data... | |
| sys-protos.h | Loading commit data... | |
| sys-types.h | Loading commit data... | |
| system.h | Loading commit data... | |
| texinfo.tex | Loading commit data... | |
| tlink.c | Loading commit data... | |
| tm.texi | Loading commit data... | |
| tmp-emsgids.c | Loading commit data... | |
| toplev.c | Loading commit data... | |
| toplev.h | Loading commit data... | |
| tree.c | Loading commit data... | |
| tree.def | Loading commit data... | |
| tree.h | Loading commit data... | |
| typeclass.h | Loading commit data... | |
| unprotoize.c | Loading commit data... | |
| unroll.c | Loading commit data... | |
| varasm.c | Loading commit data... | |
| varray.c | Loading commit data... | |
| varray.h | Loading commit data... | |
| version.c | Loading commit data... | |
| vmsconfig.com | Loading commit data... | |
| xcoffout.c | Loading commit data... | |
| xcoffout.h | Loading commit data... |