aboutsummaryrefslogtreecommitdiff
path: root/gcc/java/jcf-write.c
AgeCommit message (Collapse)AuthorFilesLines
2003-10-22jcf-write.c: Follow spelling conventions.Kazu Hirata1-1/+1
* jcf-write.c: Follow spelling conventions. * parse.y: Likewise. From-SVN: r72812
2003-10-22ChangeLog: Fix typos.Kazu Hirata1-3/+3
* ChangeLog: Fix typos. * expr.c: Fix comment typos. * jcf-write.c: Likewise. * lang.c: Likewise. * lex.c: Likewise. * mangle.c: Likewise. * parse-scan.y: Likewise. * parse.y: Likewise. From-SVN: r72809
2003-09-30jcf-write.c (generate_bytecode_insns): Implement evaluate-once semantics for ↵Roger Sayle1-1/+31
SAVE_EXPR... * jcf-write.c (generate_bytecode_insns): Implement evaluate-once semantics for SAVE_EXPR, by caching the result in a temporary. From-SVN: r71949
2003-09-28c-decl.c (duplicate_decls): Copy DECL_SOURCE_LOCATION, not file and line ↵Richard Henderson1-4/+2
separately. * c-decl.c (duplicate_decls): Copy DECL_SOURCE_LOCATION, not file and line separately. f/ * com.c (duplicate_decls): Copy DECL_SOURCE_LOCATION, not file and line separately. java/ * check-init.c (check_init): Save and restore input_location instead of file and line separately. * decl.c (java_expand_body): Likewise. * jcf-write.c (generate_bytecode_insns): Likewise. * parse.y (safe_layout_class): Likewise. * jcf-parse.c (read_class, parse_class_file): Likewise. (java_parse_file): Use %H for warning locator. From-SVN: r71886
2003-09-23jcf-write.c (generate_bytecode_insns): Optimize binary operations with equal ↵Roger Sayle1-2/+2
operands without side-effects. * jcf-write.c (generate_bytecode_insns): Optimize binary operations with equal operands without side-effects. From-SVN: r71684
2003-09-21Revert DECL_SOURCE_LOCATION -> TREE_LOCUS change.Richard Henderson1-2/+2
From-SVN: r71641
2003-09-21tree.h (TREE_LOCUS): Rename from DECL_SOURCE_LOCATION; make const.Richard Henderson1-2/+2
* tree.h (TREE_LOCUS): Rename from DECL_SOURCE_LOCATION; make const. (TREE_FILENAME, TREE_LINENO): Likewise. (set_tree_locus, copy_tree_locus, set_tree_file_line): New. (TREE_LOCUS_SET_P): New. * c-aux-info.c, c-decl.c, c-parse.in, coverage.c, dbxout.c, diagnostic.c, dwarf2out.c, dwarfout.c, function.c, integrate.c, print-tree.c, stmt.c, toplev.c, tree-dump.c, tree-inline.c, tree-optimize.c, tree.c, tree.def, xcoffout.c, config/alpha/alpha.c, config/mips/mips.c, doc/c-tree.texi, objc/objc-act.c: Update to match. ada/ * trans.c, utils.c: Update for DECL_SOURCE_LOCATION rename and change to const. cp/ * class.c, cp-tree.h, decl.c, decl2.c, error.c, init.c, method.c, optimize.c, pt.c, semantics.c, tree.c: Update for DECL_SOURCE_LOCATION rename and change to const. f/ * com.c, ste.c: Update for DECL_SOURCE_LOCATION rename and change to const. java/ * class.c, decl.c, jcf-parse.c, jcf-write.c, parse.y, resource.c: Update for DECL_SOURCE_LOCATION rename and change to const. treelang/ * treetree.c: Update for DECL_SOURCE_LOCATION rename and change to const. From-SVN: r71636
2003-09-18* jcf-write.c (generate_bytecode_insns): Add support for fconst_2.Roger Sayle1-2/+3
From-SVN: r71524
2003-09-18jcf-write.c (generate_bytecode_insns): Add MIN_EXPR and MAX_EXPR.Andrew Haley1-0/+17
2003-09-16 Andrew Haley <aph@redhat.com> * jcf-write.c (generate_bytecode_insns): Add MIN_EXPR and MAX_EXPR. From-SVN: r71514
2003-08-12parse.y (java_check_regular_methods): Typo fixes.Tom Tromey1-0/+6
* parse.y (java_check_regular_methods): Typo fixes. Call check_interface_throws_clauses. Use check_concrete_throws_clauses. (check_interface_throws_clauses): New function. (check_concrete_throws_clauses): New function. (hack_is_accessible_p): New function. (find_most_specific_methods_list): Added FIXME. * typeck.c (lookup_do): Use `flags' argument to decide what to do. Reimplemented. (lookup_argument_method_generic): New function. (lookup_argument_method2): Removed. * jcf.h (ACC_INVISIBLE): New define. * jcf-write.c (generate_classfile): Skip invisible methods. * class.c (add_miranda_methods): New function. (layout_class_methods): Use it. (get_access_flags_from_decl): Use ACC_INVISIBLE. * java-tree.h (METHOD_INVISIBLE): New define. (lang_decl_func) [invisible]: New field. (lookup_argument_method_generic): Declare. (SEARCH_INTERFACE): New define. (SEARCH_SUPER): Likewise. (SEARCH_ONLY_INTERFACE): Likewise. (SEARCH_VISIBLE): Likewise. (lookup_argument_method2): Removed declaration. From-SVN: r70388
2003-07-19fixfixes.c [...]: Remove unnecessary casts.Kaveh R. Ghazi1-16/+13
gcc: * fixinc/fixfixes.c fixinc/fixincl.c fixinc/fixlib.c fixinc/server.c objc/objc-act.c: Remove unnecessary casts. f: * com.c data.c expr.c fini.c g77spec.c global.c lab.c lex.c name.c sta.c stc.c std.c storag.c stt.c stw.c symbol.c target.c type.c: Remove unnecessary casts. cp: * call.c class.c decl.c decl2.c g++spec.c lex.c parser.c pt.c rtti.c semantics.c typeck.c: Remove unnecessary casts. java: * class.c java-tree.h jcf-write.c jvspec.c: Remove unnecessary casts. treelang: * treetree.c: Remove unnecessary casts. From-SVN: r69593
2003-07-03system.h: Include filenames.h.Zack Weinberg1-4/+0
* system.h: Include filenames.h. (IS_DIR_SEPARATOR, IS_ABSOLUTE_PATHNAME): Don't define. (DIR_SEPARATOR, DIR_SEPARATOR_2): If not already defined, define based on HAVE_DOS_BASED_FILE_SYSTEM. * config/i386/xm-cygwin.h, config/i386/xm-djgpp.h * config/i386/xm-mingw32.h: Don't define HAVE_DOS_BASED_FILE_SYSTEM, DIR_SEPARATOR, or DIR_SEPARATOR_2. * doc/hostconfig.texi: Update to match. * cppfiles.c, gcc.c, gensupport.c, protoize.c, config/i386/cygwin.h: Use IS_ABSOLUTE_PATH throughout. * gcc.c (DIR_UP): Delete, unused. * protoize.c (IS_SAME_PATH): Define in terms of FILENAME_CMP. (is_abspath): Delete. java: * jcf-path.c: Don't default-define PATH_SEPARATOR nor DIR_SEPARATOR. Use FILENAME_CMP. * jcf-write.c: Don't default-define DIR_SEPARATOR. * jcf.h: Delete COMPARE_FILENAMES definition. From-SVN: r68863
2003-06-09Make-lang.in (JAVA_OBJS, [...]): Update.Neil Booth1-1/+1
java: * Make-lang.in (JAVA_OBJS, java/lang.o): Update. (java/j-options.c, java/j-options.h): New. * java-tree.h (resource_name, compile_resource_file, compile_resource_data): Constify. * jcf-write.c (jcf_write_base_directory): Similarly. * jcf.h (jcf_write_base_directory): Similarly. * lang.c: Include j-options.h. (cl_options_count, cl_options, string_option, java_decode_option, lang_f_options, lang_W_options, LANG_HOOKS_DECODE_OPTION, process_option_with_no): Remove. (resource_name): Constify. (LANG_HOOKS_HANDLE_OPTION): Override. (java_handle_option): New. (java_init): Don't call jcf_path_init. (java_init_options): Call jcf_path_init. * lang.opt: New. * resource.c (compile_resource_data, compile_resource_file): Constify. From-SVN: r67673
2003-05-13diagnostic.c (output_format): Add support for %m.Zack Weinberg1-4/+4
* diagnostic.c (output_format): Add support for %m. (output_printf, output_verbatim, diagnostic_set_info, verbatim): Set err_no field of the text_info structure being initialized. (fatal_io_error): Delete function. * diagnostic.h (text_info): Add err_no field. * toplev.h (fatal_io_error): Delete prototype. * c-opts.c, c-pch.c, dwarfout.c, ggc-common.c, ggc-page.c, graph.c * toplev.c, config/mips/mips.c, config/rs6000/host-darwin.c * f/com.c, java/jcf-parse.c, java/jcf-write.c, java/lex.c * objc/objc-act.c: Replace all calls to fatal_io_error with calls to fatal_error; add ": %m" to the end of all the affected error messages. From-SVN: r66769
2003-05-01input.h (lineno): Rename to ...Nathan Sidwell1-5/+5
* input.h (lineno): Rename to ... (input_line): ... here. * tree.h (lineno): Rename to ... (input_line): ... here. * scan.h (lineno): Rename to ... (input_line): ... here. * toplev.c (lineno): Rename to ... (input_line): ... here. (push_srcloc, pop_srcloc): Rename lineno to input_line. * c-common.c (c_expand_start_cond, fname_decl): Likewise. * c-decl.c (poplevel, pop_label_level, lookup_label, lookup_tag, store_parm_decls, c_expand_body_1): Likewise. * c-errors.c (pedwarn_c99): Likewise. * c-format.c (status_warning): Likewise. * c-lex.c (fe_file_change, cb_def_pragma, c_lex): Likewise. * c-opts.c (c_common_post_options, c_common_parse_file): Likewise. * c-parse.in (save_filename, maybe_type_qual, ifc): Likwise. * c-semantics.c (finish_stmt_tree, build_stmt, emit_local_var, gentrtl_goto_stmt, genrtl_expr_stmt_value, genrtl_decl_stmt, genrtl_if_stmt, genrtl_while_stmt, genrtl_do_stmt, genrtl_return_stmt, genrtl_for_stmt, build_break_stmt, build_continue_stmt, genrtl_switch_stmt, genrtl_asm_stmt, prep_stmt, find_reachable_label, expand_unreachable_stmt): Likewise. * coverage.c (create_coverage): Likewise. * diagnostic.c (pedwarn, sorry, error, fatal_error, internal_error, warning, diagnostic_report_current_module, inform): Likewise. * expr.c (expand_expr): Likewise. * integrate.c (expand_inline_function, output_inline_function): Likewise. * rtl-error.c (file_and_line_for_asm): Likewise. * tree-inline.c (find_alloca_call, find_builtin_longjmp_call, walk_tree): Likewise. * tree.c (make_node): Likewise. * ada, cp, f, java, objc, treelang: Likewise. ada * trans.c (build_unit_elab, set_lineno): Rename lineno to input_line. * utils.c (pushdecl, create_label_decl, begin_subprog_body, end_subprog_body): Likewise. * utils2.c (build_call_raise): Likewise. cp * class.c (finish_struct): Rename lineno to input_line. * decl.c (push_binding_level, pop_binding_level, suspend_binding_level, resume_binding_level, make_label_decl, use_label, start_function): Likewise. * decl2.c (warn_if_unknown_interface, start_static_initialization_or_destruction, generate_ctor_or_dtor_function, finish_file): Likewise. * error.c (cp_line_of, print_instantiation_full_context, print_instantiation_context): Likewise. * except.c (check_handlers_1, check_handlers): Likewise. * init.c (create_temporary_var): Likewise. * method.c (use_thunk, synthesize_method): Likewise. * parser.c (cp_lexer_set_source_position_from_token, cp_lexer_get_preprocessor_token): Likewise. * pt.c (push_tinst_level, pop_tinst_level, tsubst_friend_function, instantiate_class_template, tsubst_decl, tsubst, tsubst_expr, instantiate_decl): Likewise. * semantics.c (genrtl_try_block, finish_label_stmt, begin_class_definition, expand_body, genrtl_finish_function): Likewise. * tree.c (build_min_nt, build_min): Likewise. f * ansify.c (die_unless): Rename lineno to input_line. * com.c (ffecom_subscript_check_, ffecom_do_entry_, ffecom_gen_sfuncdef_, ffecom_start_progunit_, ffecom_sym_transform_, ffecom_sym_transform_assign_, bison_rule_pushlevel_, bison_rule_compstmt_, finish_function, store_parm_decls): Likewise. * intrin.c (ffeintrin_fulfill_generic): Likewise. * lex.c (ffelex_hash_, ffelex_include_, ffelex_next_line_, ffelex_file_fixed, ffelex_file_free): Likewise. * std.c (ffestd_exec_end): Likewise. * ste.c (ffeste_emit_line_note_, ffeste_start_block_, ffeste_start_stmt_): Likewise. * ste.h (ffeste_filelinenum, ffeste_set_line): Likewise. java * lex.h (lineno): Rename to ... (input_line): ... here * parse-scan.y (lineno): Rename to ... (input_line): ... here. (reset_report): Rename lineno to input_line. * check-init.c (check_init): Likewise. * class.c (push_class): Likewise. * decl.c (complete_start_java_method, end_java_method): Likewise. * expr.c (expand_byte_code): Likewise. * jcf-parse.c (give_name_to_class, parse_class_file): Likewise. * jcf-write.c (generate_bytecode_insns): Likewise. * lex.c (java_init_lex, java_allocate_new_line, do_java_lex): Likewise. * parse.h (YYNOT_TWICE): Likewise. * parse.y (empty_statement, expression_statement, java_pop_parser_context, java_parser_context_save_global, yyerror, register_fields, method_header, safe_layout_class, find_in_imports_on_demand, create_artificial_method, source_end_java_method, start_complete_expand_method, build_thisn_assign, java_complete_lhs, maybe_absorb_scoping_block): Likewise. objc * objc-act.c (objc_init): Rename lineno to input_line. (build_module_descriptor, build_selector_translation_table, build_protocol_template, build_method_prototype_list_template, build_category_template, build_selector_table, build_class_template, build_super_template, build_ivar_template, build_ivar_list_template, build_method_list_template, build_method_template, add_instance_variable): Likewise. treelang * tree1.c (treelang_init): Rename lineno to input_line. From-SVN: r66333
2003-04-10[multiple changes]Andrew Haley1-8/+17
2003-03-16 Mohan Embar <gnustuff@thisiscool.com> * Make-lang.in: added win32-host.c * jcf.h: defined macro JCF_OPEN_EXACT_CASE which resolves to open() on non-Win32 platforms and Win32-specific jcf_open_exact_case() on Win32 * jcf-io.c (find_class): use JCF_OPEN_EXACT_CASE when trying .java and .class files * win32-host.c: added to repository. Defines Win32-specific jcf_open_exact_case() 2003-04-10 Andrew Haley <aph@redhat.com> * jcf-write.c (struct jcf_partial): num_jsrs: new field. (maybe_free_localvar): Renamed from localvar_free. Add new arg, really. (generate_bytecode_insns): Set new variable, jsrs. Only free local vars if no jsr insns have been emittted. Call maybe_free_localvar, not localvar_free. From-SVN: r65430
2003-03-10jcf-io.c (caching_stat): Account for both DIR_SEPARATOR and DIR_SEPARATOR_2 ↵Ranjit Mathew1-8/+30
for a target. 2003-03-10 Ranjit Mathew <rmathew@hotmail.com> * jcf-io.c (caching_stat): Account for both DIR_SEPARATOR and DIR_SEPARATOR_2 for a target. Correct minor typos. * jcf-write.c (make_class_file_name): Take both DIR_SEPARATOR and DIR_SEPARATOR_2 for a target into account. From-SVN: r64110
2003-02-26jcf-write.c (generate_classfile): Check whether class is deprecated before ↵Tom Tromey1-2/+2
writing attribute count. * jcf-write.c (generate_classfile): Check whether class is deprecated before writing attribute count. From-SVN: r63482
2003-02-24lang-options.h: Added -Wdeprecated.Tom Tromey1-1/+30
* lang-options.h: Added -Wdeprecated. * gcj.texi (Warnings): Document -Wdeprecated. * java-tree.h (flag_deprecated): Declare. * lang.c (lang_W_options): Added deprecated. (flag_deprecated): New global. * chartables.h: Rebuilt. * gen-table.pl (process_one): Look at whitespace. (print_tables): Define LETTER_SPACE, LETTER_MASK. * parse.h (CLEAR_DEPRECATED): New macro. (CHECK_DEPRECATED_NO_RESET): New macro. * jcf-parse.c (handle_deprecated): New function. (HANDLE_DEPRECATED_ATTRIBUTE): New define. * jcf-reader.c (get_attribute): Handle Deprecated attribute. * parse.y (resolve_type_during_patch): Check deprecation. (jdep_resolve_class): Likewise. (process_imports): Likewise. (resolve_expression_name): Likewise. (check_deprecation): Strip arrays from decl. Check flag_deprecated. (patch_method_invocation): Also check the particular constructor for deprecation. (register_fields): Use CHECK_DEPRECATED_NO_RESET in loop. * jcf-write.c (append_deprecated_attribute): New function. (generate_classfile): Generate deprecated attribute when appropriate. * lex.c (java_parse_doc_section): Return type now void. Rewrote. (java_lex) [case '*']: Simplify logic. (java_start_char_p): Use LETTER_MASK. (java_part_char_p): Likewise. (java_space_char_p): New function. From-SVN: r63350
2003-01-29* jcf-write.c (generate_bytecode_conditional): Typo fixes.Tom Tromey1-2/+2
From-SVN: r62061
2003-01-18check-init.c: Fix comment typos.Kazu Hirata1-5/+5
* check-init.c: Fix comment typos. * class.c: Likewise. * constants.c: Likewise. * decl.c: Likewise. * except.c: Likewise. * expr.c: Likewise. * java-except.h: Likewise. * java-tree.h: Likewise. * javaop.h: Likewise. * jcf-dump.c: Likewise. * jcf-io.c: Likewise. * jcf-parse.c: Likewise. * jcf-write.c: Likewise. * lang.c: Likewise. * mangle.c: Likewise. * typeck.c: Likewise. * verify.c: Likewise. From-SVN: r61477
2003-01-18Make-lang.in (java/jcf-write.o): Depend on $(TM_P_H).Kaveh R. Ghazi1-0/+1
* Make-lang.in (java/jcf-write.o): Depend on $(TM_P_H). * jcf-write.c: Include "tm_p.h". From-SVN: r61476
2003-01-16arm.h (CONDITIONAL_REGISTER_USAGE): Avoid signed/unsigned warning.Kaveh R. Ghazi1-1/+1
* arm.h (CONDITIONAL_REGISTER_USAGE): Avoid signed/unsigned warning. * emit-rtl.c (gen_rtx_REG, set_mem_attributes_minus_bitpos, init_emit_once): Likewise. * flow.c (mark_regs_live_at_end, calculate_global_regs_live): Likewise. * function.c (assign_stack_temp_for_type): Likewise. * loop.c (loop_invariant_p): Likewise. * recog.c (push_operand): Likewise. * regclass.c (init_reg_sets_1): Likewise. * reload.c (update_auto_inc_notes): Likewise. * reload1.c (reload_as_needed, emit_input_reload_insns): Likewise. * stmt.c (expand_asm_operands): Likewise. * stor-layout.c (start_record_layout): Likewise. cp: * class.c (layout_virtual_bases): Avoid signed/unsigned warning. java: * jcf-write.c (generate_bytecode_insns): Avoid signed/unsigned warning. From-SVN: r61389
2003-01-12* All Files: Convert to ISO C style function definitions.Kaveh R. Ghazi1-168/+66
From-SVN: r61218
2003-01-09* All Files: Remove PARAMS macro.Kaveh R. Ghazi1-70/+65
From-SVN: r61133
2003-01-09expr.c, [...]: Don't rely on the `DEFUN', `AND' or `__STDC__' macros.Kaveh R. Ghazi1-1/+0
* expr.c, gjavah.c, javaop.h, jcf-dump.c, jcf-io.c, jcf-reader.c, jcf-write.c, jcf.h, jv-scan.c: Don't rely on the `DEFUN', `AND' or `__STDC__' macros. From-SVN: r61131
2003-01-01Make-lang.in, [...]: Replace "GNU CC" with "GCC" in the copyright header.Steven Bosscher1-5/+6
* Make-lang.in, boehm.c, buffer.c, buffer.h, builtins.c, class.c, config-lang.in, constants.c, convert.h, decl.c, except.c, expr.c, java-except.h, java-tree.h, javaop.def, jcf-parse.c, jcf-write.c, jv-scan.c, jvgenmain.c, jvspec.c, keyword.gperf, keyword.h, lang-options.h, lang-specs.h, lang.c, lex.c, lex.h, mangle.c, mangle_name.c, parse-scan.y, parse.h, parse.y, typeck.c, verify.c, xref.c, xref.h: Replace "GNU CC" with "GCC" in the copyright header. * check-init.c, gjavah.c, javaop.h, jcf-depend.c, jcf-dump.c, jcf-io.c, jcf-path.c, jcf-reader.c, jcf.h, zextract.c, zipfile.h: These files are "part of GCC". Also say "GCC" not "GNU CC". From-SVN: r60747
2002-12-20re PR java/8955 (switch case statement causes gcj to throw segmentation fault)Tom Tromey1-2/+6
* jcf-write.c (generate_bytecode_insns) [SWITCH_EXPR]: Handle case where minimum case value is Integer.MIN_VALUE. Fixes PR java/8955. From-SVN: r60372
2002-12-16Merge basic-improvements-branch to trunkZack Weinberg1-0/+2
From-SVN: r60174
2002-11-22jcf-write.c (write_classfile): Remove target class file...Ranjit Mathew1-0/+9
2002-11-22 Ranjit Mathew <rmathew@hotmail.com> Andrew Haley <aph@redhat.com> * gcc/java/jcf-write.c (write_classfile): Remove target class file, if it exists, before renaming the temporary class file to it. Co-Authored-By: Andrew Haley <aph@redhat.com> From-SVN: r59386
2002-09-16real.c, real.h: Rewrite from scratch.Richard Henderson1-13/+10
gcc/ * real.c, real.h: Rewrite from scratch. * Makefile.in (simplify-rtx.o): Depend on TREE_H. (paranoia): New target. * builtins.c (fold_builtin_inf): Use new real.h interface. * c-common.c (builtin_define_with_hex_fp_value): Likewise. * c-lex.c (interpret_float): Likewise. * emit-rtl.c (gen_lowpart_common): Likewise. * optabs.c (expand_float): Use real_2expN. * config/ia64/ia64.md (divsi3, udivsi3): Likewise. * defaults.h (INTEL_EXTENDED_IEEE_FORMAT): New. (FLOAT_WORDS_BIG_ENDIAN): New. * cse.c (find_comparison_args): Don't pass FLOAT_STORE_FLAG_VALUE directly to REAL_VALUE_NEGATIVE. * loop.c (canonicalize_condition): Likewise. * simplify-rtx.c: Include tree.h. (simplify_unary_operation): Don't handle FIX and UNSIGNED_FIX with floating-point result modes. * toplev.c (backend_init): Call init_real_once. * fold-const.c (force_fit_type): Don't call CHECK_FLOAT_VALUE. * tree.c (build_real): Likewise. * config/alpha/alpha.c, config/vax/vax.c (float_strings, float_values, inited_float_values, check_float_value): Remove. * config/alpha/alpha.h, config/m68hc11/m68hc11.h, config/m88k/m88k.h, config/vax/vax.h (CHECK_FLOAT_VALUE): Remove. * doc/tm.texi (CHECK_FLOAT_VALUE): Remove. gcc/f/ * target.c (ffetarget_real1): Don't pass FFETARGET_ATOF_ directly to ffetarget_make_real1. (ffetarget_real2): Similarly. * target.h (ffetarget_cvt_r1_to_rv_, ffetarget_cvt_rv_to_r2_, ffetarget_cvt_r2_to_rv_): Use new real.h interface and simplify. gcc/java/ * jcf-parse.c (get_constant): Runtime check for IEEE format; use new real.h interface. * jcf-write.c (find_constant_index): Use new real.h interface. * lex.c (IS_ZERO): Use REAL_VALUES_EQUAL. contrib/ * paranoia.cc: New file. From-SVN: r57198
2002-08-09jcf-write.c (get_access_flags): Return correct access flags for private and ↵Bryce McKinlay1-0/+4
protected inner classes. 2002-08-08 Bryce McKinlay <bryce@waitaki.otago.ac.nz> * jcf-write.c (get_access_flags): Return correct access flags for private and protected inner classes. From-SVN: r56146
2002-06-11jcf-write.c (generate_classfile): Use FIELD_SYNTHETIC.Tom Tromey1-3/+5
* jcf-write.c (generate_classfile): Use FIELD_SYNTHETIC. * parse-scan.y (statement_without_trailing_substatement): Added assert_statement. (assert_statement): New rule. * java-tree.h (struct lang_type) [assertions]: New field. (TYPE_USES_ASSERTIONS): New macro. (CLASS_USES_ASSERTIONS): Likewise. (FIELD_SYNTHETIC): New define. * lex.c (java_lval;): Added ASSERT_TK. * parse.y (ASSERT_TK): Added. (statement_without_trailing_substatement): Added assert_statement. (assert_statement): New rule. (build_assertion): New function. (maybe_generate_pre_expand_clinit): Create and initialize $assertionsDisabled. (lookup_package_type): Removed decl. * keyword.h: Rebuilt. * keyword.gperf (assert): New token. From-SVN: r54516
2002-06-04* jcf-write.c (perform_relocations): Optmize a goto to a goto.Tom Tromey1-0/+31
From-SVN: r54264
2002-06-04Merge from pch-branch up to tag pch-commit-20020603.Geoffrey Keating1-6/+5
From-SVN: r54232
2002-05-14jcf-write.c (write_classfile): Unlink the temporary file if it cannot be ↵Mark Mitchell1-4/+5
renamed. * jcf-write.c (write_classfile): Unlink the temporary file if it cannot be renamed. Use concat to build up the name of the temporary file From-SVN: r53439
2002-05-08jcf-write.c (write_classfile): Write the file to a temporary file and then ↵Mark Mitchell1-3/+15
rename it. * java/jcf-write.c (write_classfile): Write the file to a temporary file and then rename it. * libjava/Makefile.am (all_java_source_files): New variable. (all_java_class_files): Likewise. .java.class: New rule. (CLEANFILES): Remove tmp-list. * libjava/Makefile.in: Regenerated. From-SVN: r53298
2002-04-22jcf-write.c (push_long_const): lo, hi: New variables.Andrew Haley1-5/+10
2002-04-19 Andrew Haley <aph@redhat.com> * jcf-write.c (push_long_const): lo, hi: New variables. Use rshift_double to extract the high part of a 64-bit long. Use WORD_TO_INT to extract the low part. * jcf-parse.c (get_constant): CONSTANT_Integer: Use an unsigned HOST_WIDE_INT for num. Use JPOOL_UINT to get it. CONSTANT_Double: Use JPOOL_UINT to get both halve of a double. From-SVN: r52618
2002-04-17jcf-write.c (generate_bytecode_insns): Only write const_0 if not negative zero.Mark Wielaard1-1/+2
* jcf-write.c (generate_bytecode_insns): Only write const_0 if not negative zero. From-SVN: r52427
2002-03-12* jcf-write.c (write_classfile): Improve error strings.Bryce McKinlay1-2/+2
From-SVN: r50649
2002-02-18java-tree.h (TYPE_STRICTFP): New macro.Tom Tromey1-1/+5
* java-tree.h (TYPE_STRICTFP): New macro. (struct lang_type) [strictfp]: New field. (CLASS_STRICTFP): New macro. (METHOD_STRICTFP): New macro. (struct lang_decl) [strictfp]: New field. * parse.y (method_header): Disallow strictfp constructor or abstract method. (STRICT_TK): Move before MODIFIER_TK. * parse.h (CLASS_MODIFIERS): Added ACC_STRICT. (METHOD_MODIFIERS): Likewise. (INTERFACE_MODIFIERS): Likewise. * jcf-write.c (get_access_flags): Likewise. * class.c (set_class_decl_access_flags): Recognize ACC_STRICT. (add_method_1): Likewise. (get_access_flags_from_decl): Likewise. * jcf-dump.c (print_access_flags): Print in standard order. Also, recognize strictfp flag. * jcf.h (ACC_STRICT): New define. From-SVN: r49834
2001-12-21For PR java/4509:Tom Tromey1-2/+7
* parse.y (java_complete_lhs) [COMPOUND_EXPR]: Correctly compute CAN_COMPLETE_NORMALLY for the node. * jcf-write.c (generate_bytecode_insns) [COMPOUND_EXPR]: Don't generate code for second branch if first branch can't complete normally. (generate_bytecode_insns) [LOOP_EXPR]: Don't generate `goto' to the loop head if the loop body can't complete normally. From-SVN: r48233
2001-12-21For PR java/4766:Tom Tromey1-38/+82
* jcf-write.c (generate_bytecode_insns) [TRY_FINALLY_EXPR]: Handle case where `finally' clause can't complete normally. From-SVN: r48232
2001-12-16ChangeLog, [...]: Fix spelling errors.Joseph Myers1-2/+2
* ChangeLog, Make-lang.in, class.c, expr.c, gcj.texi, java-tree.h, jcf-parse.c, jcf-write.c, lex.c, parse.h, parse.y, verify.c: Fix spelling errors. From-SVN: r48075
2001-12-03decl.c (complete_start_java_method): Now generate TRY_FINALLY_EXPR instead ↵Per Bothner1-74/+3
of CLEANUP_POINT_EXPR and WITH_CLEANUP_EXPR. * decl.c (complete_start_java_method): Now generate TRY_FINALLY_EXPR instead of CLEANUP_POINT_EXPR and WITH_CLEANUP_EXPR. * jcf-write.c (generate_bytecode_insns): Remove support for CLEANUP_POINT_EXPR and WITH_CLEANUP_EXPR as they are no longer used. * check-init.c (check_init): Likewise. From-SVN: r47587
2001-12-01c-decl.c (duplicate_decls, [...]): Remove trailing period from diagnostics.Neil Booth1-1/+1
* c-decl.c (duplicate_decls, parmlist_tags_warning): Remove trailing period from diagnostics. * c-lex.c (cb_file_change): Similarly. * cppmacro.c (check_trad_stringification): Similarly. * gcc.c (do_spec_1): Similarly. * genattr.c (main): Similarly. * genattrtab.c (main, operate_exp, make_length_attrs): Similarly. * gencodes.c (main): Similarly. * genconfig.c (main): Similarly. * genconstants.c (main): Similarly. * genemit.c (main): Similarly. * genextract.c (main): Similarly. * genopinit.c (main): Similarly. * genoutput.c (main): Similarly. * genpeep.c (main): Similarly. * genrecog.c (main): Similarly. * mips-tfile.c (add_file, error): Similarly. * profile.c (init_branch_prob): Similarly. * reload1.c (spill_failure): Similarly. * stmt.c (parse_output_constraint): Similarly. * varasm.c (assemble_variable): Similarly. cp: * class.c (finish_struct): Similarly. * decl.c (check_tag_decl): Similarly. * lex.c (cxx_set_yydebug): Similarly. * typeck2.c (friendly_abort): Similarly. java: * expr.c (expand_byte_code): Similarly. * jcf-parse.c (load_class, jcf_parse): Similarly. * jcf-write.c (generate_classfile): Similarly. * lex.c (java_lex): Similarly. From-SVN: r47517
2001-11-19re PR java/1401 (+= semantics not correct (when generating bytecode))Tom Tromey1-1/+60
Fix for PR java/1401: * jcf-write.c (generate_bytecode_insns) [binop]: Handle case where arg0 is null. (generate_bytecode_insns) [MODIFY_EXPR]: Handle `OP=' case correctly. From-SVN: r47156
2001-11-08Patch for PR java/1414:Tom Tromey1-1/+2
* parse.y (case_label_list): New global. (goal): Register case_label_list with GC. (java_complete_lhs): Save new case on case_label_list. (patch_switch_statement): Check for duplicate case labels. From-SVN: r46845
2001-10-11parse.y (patch_synchronized_statement): Use a TRY_FINALLY_EXPR rather than a ↵Per Bothner1-13/+2
CLEANUP_POINT_EXPR/WITH_CLEANUP_EXPR pair. * parse.y (patch_synchronized_statement): Use a TRY_FINALLY_EXPR rather than a CLEANUP_POINT_EXPR/WITH_CLEANUP_EXPR pair. The former is simpler, and jcf-write.c handles it better. (java_complete_lhs): No longer need to handle CLEANUP_POINT_EXPR or WITH_CLEANUP_EXPR. * jcf-write.c: Revert Alex's change from 2000-10-18. It is no longer needed, as we already handle empty TRY_FINALLY_EXPR bodies fine. From-SVN: r46209
2001-10-08re PR java/4489 (bytecode generation endless loop with certain switch() exprs)Tom Tromey1-2/+4
Fix for PR java/4489: * jcf-write.c (generate_bytecode_insns) [SWITCH_EXPR]: Always force a new label when computing `body_block'. From-SVN: r46092