aboutsummaryrefslogtreecommitdiff
path: root/gcc/java/jcf-dump.c
AgeCommit message (Collapse)AuthorFilesLines
2001-08-30jcf-dump.c (print_constant): Fix fencepost error so "Float" and "Double" are ↵Per Bothner1-5/+6
printed at verbosity 1. * jcf-dump.c (print_constant): Fix fencepost error so "Float" and "Double" are printed at verbosity 1. * jcf-dump.c (main): Disable flag_print_attributes if --javap. * jcf-dump.c (SPECIAL_IINC): Remove unneeded casts to long. From-SVN: r45296
2001-08-16jcf-dump.c (main): Updated for change to jcf_path_seal.Tom Tromey1-2/+2
* jcf-dump.c (main): Updated for change to jcf_path_seal. * gjavah.c (main): Updated for change to jcf_path_seal. * lang.c (version_flag): New global. (java_decode_option): Recognize `-version'. (java_init): Update for change to jcf_path_seal. * jcf.h (jcf_path_seal): Added `print' argument. * jcf-path.c (jcf_path_seal): Added `print' argument. From-SVN: r44946
2001-01-12g77spec.c (lang_specific_driver): Update copyright year to 2001.Joseph Myers1-1/+1
f: * g77spec.c (lang_specific_driver): Update copyright year to 2001. java: * gjavah.c (version), jcf-dump.c (version): Update copyright year to 2001. From-SVN: r38951
2000-11-26g77spec.c (lang_specific_driver): Update copyright year to 2000.Joseph Myers1-1/+1
f: * g77spec.c (lang_specific_driver): Update copyright year to 2000. java: * gjavah.c (version), jcf-dump.c (version), jv-scan.c (version): Update copyright year to 2000. From-SVN: r37765
2000-11-04lang-options.h: Mention -Wout-of-date.Tom Tromey1-0/+4
* lang-options.h: Mention -Wout-of-date. * jcf-dump.c (flag_newer): New global. * gjavah.c (flag_newer): New global. * jcf-io.c (find_class): Only warn when flag_newer set. * lang.c (flag_newer): New global. (struct string_option): New declaration. (lang_W_options): New global. (process_option_with_no): New function. (lang_decode_option): Use it. From-SVN: r37244
2000-05-04jcf-dump.c (SPECIAL_IINC): Ensure arguments match format specifiers in calls ↵Kaveh R. Ghazi1-2/+2
to fprintf. * jcf-dump.c (SPECIAL_IINC): Ensure arguments match format specifiers in calls to fprintf. From-SVN: r33680
2000-04-20jcf-dump.c (SPECIAL_IINC): Fixed typo printing iinc instruction.Jason Schroeder1-1/+1
Thu Apr 20 18:20:58 2000 Jason Schroeder <shrode@subnature.com> * jcf-dump.c (SPECIAL_IINC): Fixed typo printing iinc instruction. From-SVN: r33301
2000-03-13Added Java 1.1 language features.Alexandre Petit-Bianco1-0/+32
From-SVN: r32517
2000-02-26Fix copyrightsJeff Law1-1/+1
From-SVN: r32182
2000-02-21jcf-dump.c (main): Test for correct condition after output file creation.Joerg Brunsmann1-1/+1
Mon Jan 18 14:30:09 2000 Joerg Brunsmann <joerg.brunsmann@fernuni-hagen.de> * jcf-dump.c (main): Test for correct condition after output file creation. From-SVN: r32089
2000-02-18gcc.texi (Bug Reporting): Refer to bugs.html.Martin v. Löwis1-1/+1
* gcc.texi (Bug Reporting): Refer to bugs.html. (Bug Lists): Likewise. * system.h (GCCBUGURL): New preprocessor define. * rtl.c (fancy_abort): Use it. * gcc.c (main): Likewise. * typeck2.c (my_friendly_abort): Use GCCBUGURL. * g77spec.c (lang_specific_driver): Use GCCBUGURL. * gjavah.c (help): Use GCCBUGURL. * jv-scan.c (help): Likewise. * jcf-dump.c (help): Likewise. From-SVN: r32049
2000-02-15Makefile.in (TREE_H, [...]): Depend on version.h.Kaveh R. Ghazi1-1/+1
* Makefile.in (TREE_H, collect2.o, gcc.h, mips-tfile.o, cccp.o, cpphash.o, cppinit.o, protoize.o, unprotoize.o): Depend on version.h. * cccp.c: Include version.h and/or don't declare `version_string'. * collect2.c: Likewise. * alpha.c: Likewise. * arm/aof.h: Likewise. * arm/coff.h: Likewise. * arm/elf.h: Likewise. * arm/pe.h: Likewise. * arm/tcoff.h: Likewise. * arm/telf.h: Likewise. * arm/tpe.h: Likewise. * arm/vxarm.h: Likewise. * convex/convex.c: Likewise. * i386/dgux.c: Likewise. * i386/sun386.h: Likewise. * m88k/m88k.c: Likewise. * mcore/mcore-pe.h: Likewise. * mips/mips.h: Likewise. * romp/romp.h: Likewise. * sh/sh.c: Likewise. * cpphash.c: Likewise. * cppinit.c: Likewise. * dwarf2out.c: Likewise. * dwarfout.c: Likewise. * gcc.c: Likewise. * gcc.h: Likewise. * mips-tfile.c: Likewise. * protoize.c: Likewise. * toplev.c: Likewise. * tree.h: Likewise. * version.c (version_string): Constify a char*. * version.h: New file. ch: * grant.c: Don't declare `version_string'. f: * g77spec.c: Don't declare `version_string'. java: * Makefile.in (jv-scan, jcf-dump, gcjh): Depend on and link with version.o. (jcf-dump.o, gjavah.o, jv-scan.o): Depend on version.h. * gjavah.c: Include version.h. * jcf-dump.c: Likewise. * jv-scan.c: Likewise. From-SVN: r31984
2000-02-02jv-scan.c: Include version.c, <getopt.h>.Tom Tromey1-43/+128
* jv-scan.c: Include version.c, <getopt.h>. (LONG_OPT, OPT_HELP, OPT_VERSION): New macros. (options): New array. (usage): New function. (version): New function. (main): Use getopt_long to parse command line. * jcf-dump.c: Include version.c, <getopt.h>. (LONG_OPT, OPT_classpath, OPT_CLASSPATH, OPT_HELP, OPT_VERSION, OPT_JAVAP): New macros. (options): New array. (usage): Return `void'. Changed message. (help): New function. (version): New function. (main): Use getopt_long_only to parse command line. * gjavah.c: Include <getopt.h>. (LONG_OPT, OPT_classpath, OPT_CLASSPATH, OPT_HELP, OPT_TEMP, OPT_VERSION, OPT_PREPEND, OPT_FRIEND, OPT_ADD, OPT_APPEND, OPT_M, OPT_MM, OPT_MG, OPT_MD, OPT_MMD): New macros. (options): New array. (java_no_argument): Removed. (help): Updated with missing options. (main): Use getopt_long_only to parse command line. (usage): Changed message. From-SVN: r31765
2000-01-21buffer.h: PROTO -> PARAMS.Kaveh R. Ghazi1-13/+13
* buffer.h: PROTO -> PARAMS. * check-init.c: Likewise. * class.c: Likewise. * constants.c: Likewise. * convert.h: Likewise. * decl.c: Likewise. * except.c: Likewise. * expr.c: Likewise. * gjavah.c: Likewise. * java-except.h: Likewise. * java-tree.h: Likewise. * jcf-depend.c: Likewise. * jcf-dump.c: Likewise. * jcf-parse.c: Likewise. * jcf-path.c: Likewise. * jcf-reader.c: Likewise. * jcf-write.c: Likewise. * jcf.h: Likewise. * jv-scan.c: Likewise. * jvgenmain.c: Likewise. * jvspec.c: Likewise. * lang.c: Likewise. * lex.c: Likewise. * lex.h: Likewise. * parse-scan.y: Likewise. * parse.h: Likewise. * parse.y: Likewise. * typeck.c: Likewise. * verify.c: Likewise. * xref.c: Likewise. * xref.h: Likewise. * zextract.c: Likewise. * zipfile.h: Likewise. From-SVN: r31550
1999-12-31class.c (assume_compiled, [...]): Add static prototype.Kaveh R. Ghazi1-1/+1
* class.c (assume_compiled, assume_compiled_node): Add static prototype. (add_assume_compiled): Use xmalloc/xstrdup, not malloc/strdup. * jcf-dump.c (ARRAY_NEW_NUM): Cast long to int in switch. * jvgenmain.c (usage): Add static prototype with ATTRIBUTE_NORETURN. * parse.h (OBSOLETE_MODIFIER_WARNING): Rename parameter `modifier' to `__modifier' to avoid stringifying it. * parse.y (verify_constructor_circularity): Don't call a variadic function with a non-literal format string. (java_check_abstract_methods): Move unreachable code inside `continue' statement. (lookup_method_invoke): Call xstrdup, not strdup. * expr.c (expand_java_field_op): Avoid the use of ANSI string concatenation. * jcf-parse.c (yyparse): Likewise. * jv-scan.c (main): Likewise. From-SVN: r31148
1999-10-14jcf-dump.c (print_constant, [...]): Don't call a variadic function with a ↵Kaveh R. Ghazi1-19/+33
non-literal format string. * jcf-dump.c (print_constant, disassemble_method): Don't call a variadic function with a non-literal format string. * parse-scan.y (report_main_declaration): Likewise. * parse.h (ERROR_CAST_NEEDED_TO_INTEGRAL): Likewise. * parse.y (read_import_dir, patch_assignment, patch_binop, patch_array_ref): Likewise. * typeck.c (build_java_array_type): Likewise. * verify.c (verify_jvm_instructions): Likewise. From-SVN: r29981
1999-09-02class.c (finish_class): Remove unused parameter, all callers changed.Kaveh R. Ghazi1-6/+6
* class.c (finish_class): Remove unused parameter, all callers changed. * expr.c (build_java_athrow): Change return type to void. (java_lang_expand_expr): Make sure each case in switch returns a value. * java-tree.h (finish_class): Fix prototype to take void args. * jcf-dump.c (usage): Mark with ATTRIBUTE_NORETURN. (main): Issue return from main, not exit. * jcf-parse.c (parse_class_file): Fix call to `finish_class'. * jcf.h (jcf_unexpected_eof): Mark with ATTRIBUTE_NORETURN. * jv-scan.c (main): Issue return from main, not exit. * parse.y (check_abstract_method_definitions, java_check_abstract_method_definitions): Add static prototypes. (java_complete_expand_methods): Fix call to `finish_class'. * verify.c (verify_jvm_instructions): Initialize variables `oldpc' and `prevpc'. From-SVN: r29065
1999-08-10check-init.c (check_bool2_init, [...]): Add static prototypes.Kaveh R. Ghazi1-10/+13
* check-init.c (check_bool2_init, done_alternative): Add static prototypes. * class.c (add_interface_do, maybe_layout_super_class): Likewise. (add_method, build_utf8_ref, build_class_ref, append_gpp_mangled_type, layout_class_method): Constify a char*. * decl.c (push_promoted_type, make_binding_level): Add static prototypes. (push_promoted_type, pushdecl): Constify a char*. * except.c (find_handler_in_range, link_handler, check_start_handlers): Add static prototypes. * expr.c (process_jvm_instruction): Constify a char*. * gjavah.c (main): Constify a char*. * java-tree.h (verify_jvm_instructions, process_jvm_instruction): Constify a char*. * jcf-depend.c (free_entry, add_entry, munge, print_ents): Add static prototypes. (add_entry, jcf_dependency_set_target, jcf_dependency_add_target, munge, print_ents): Constify a char*. * jcf-dump.c (disassemble_method): Constify a char*. (print_constant_pool, print_exception_table): Add static prototypes. (print_constant, print_exception_table, main, disassemble_method): Constify a char*. * jcf-io.c (find_classfile, find_class): Likewise. * jcf-parse.c (JPOOL_UTF_DATA, find_in_current_zip): Likewise. (set_source_filename, predefined_filename_p): Add static prototypes. (set_source_filename, get_constant, get_class_constant, find_in_current_zip): Constify a char*. * jcf-path.c (free_entry, append_entry, add_entry, add_path): Add static prototypes. (add_entry, add_path, jcf_path_classpath_arg, jcf_path_CLASSPATH_arg, jcf_path_include_arg): Constify a char*. * jcf-reader.c (get_attribute, jcf_parse_preamble, jcf_parse_constant_pool, jcf_parse_class, jcf_parse_fields, jcf_parse_one_method, jcf_parse_methods, jcf_parse_final_attributes): Add static prototypes. (get_attribute): Constify a char*. * jcf.h (find_class, find_classfile, jcf_dependency_set_target, jcf_dependency_add_target, jcf_path_classpath_arg, jcf_path_CLASSPATH_arg, jcf_path_include_arg): Constify a char*. * jv-scan.c (main): Constify a char*. (gcc_obstack_init): Add prototype arguments. * jvgenmain.c (gcc_obstack_init): Likewise. (main): Constify a char*. * lang.c (put_decl_string, put_decl_node, java_dummy_print): Add static prototypes. (put_decl_string, lang_print_error): Constify a char*. (lang_init): Remove redundant extern prototype. * mangle.c (emit_unicode_mangled_name): Constify a char*. * typeck.c (convert_ieee_real_to_integer, parse_signature_type): Add static prototypes. (get_type_from_signature): Constify a char*. * verify.c (check_pending_block, type_stack_dup, start_pc_cmp ): Add static prototypes. (start_pc_cmp): Prefer PTR over GENERIC_PTR. (verify_jvm_instructions): Constify a char*. * xref.c (xref_flag_value): Likewise. * xref.h (xref_flag_value): Likewise. * zextract.c (makeword, makelong): Add static prototypes. (makeword, makelong): Constify a uch*. From-SVN: r28648
1999-07-30Warning fixes:Kaveh R. Ghazi1-2/+2
* expr.c (build_java_soft_divmod): Provide a default case in switch. (java_lang_expand_expr): Mark parameters `target', `tmode' and `modifier' with ATTRIBUTE_UNUSED. * gjavah.c (process_file): Add braces around ambiguous `else'. * jcf-dump.c (print_access_flags, localvar_free): Change return type to void. * parse.y (java_complete_expand_method): Initialize variable `exception_copy'. (resolve_qualified_expression_name): Likewise for `field_decl'. (patch_method_invocation): Likewise for `class_to_search'. (qualify_ambiguous_name): Likewise for `name' and `ptr_type'. (patch_assignment): Likewise for `lhs_type'. * verify.c (verify_jvm_instructions): Remove unused variable `caller'. From-SVN: r28344
1999-03-23Warning fixes:Kaveh R. Ghazi1-4/+6
* gjavah.c (print_c_decl): Remove unused argument `flags'. * jcf-dump.c (print_access_flags): Add braces around if-else. * jvspec.c (lang_specific_driver): Wrap variable `len' in macro COMBINE_INPUTS. * lex.c (build_wfl_node): Add static prototype. * lex.h (build_wfl_node): Remove static prototype. * parse.y: Include lex.c early enough to declare everything needed. Ensure calls to `build_wfl_node' pass the proper arguments. (create_class): Remove unused variable `super_decl'. (get_printable_method_name): Initialize variable `name'. From-SVN: r25921
1999-03-21Makefile.in (jcf-dump.o): Depend on $(CONFIG_H) $(srcdir)/../system.h and ↵Kaveh R. Ghazi1-20/+22
$(JAVA_TREE_H). * Makefile.in (jcf-dump.o): Depend on $(CONFIG_H) $(srcdir)/../system.h and $(JAVA_TREE_H). (jcf-io.o): Depend on $(JAVA_TREE_H). (mangle.o): Likewise. * check-init.c (check_cond_init): Add static prototype. * class.c (build_java_method_type, hashUtf8String, make_field_value, get_dispatch_vector, get_dispatch_table, append_gpp_mangled_type, mangle_static_field): Likewise. (strLengthUtf8): Hide unused definition. (hashUtf8String): Const-ify. (make_field_value): Un-ANSI-fy. * constants.c: Move inclusion of jcf.h above java-tree.h. (set_constant_entry, find_class_or_string_constant, find_name_and_type_constant, get_tag_node, build_constant_data_ref): Add static prototype. * decl.c (push_jvm_slot, builtin_function, lookup_name_current_level): Likewise. (builtin_function): Const-ify. * except.c (expand_start_java_handler, expand_end_java_handler): Add static prototype. * expr.c (flush_quick_stack, push_value, pop_value, java_stack_swap, java_stack_dup, build_java_athrow, build_java_jsr, build_java_ret, expand_java_multianewarray, expand_java_arraystore, expand_java_arrayload, expand_java_array_length, build_java_monitor, expand_java_pushc, expand_java_return, expand_java_NEW, expand_java_INSTANCEOF, expand_java_CHECKCAST, expand_iinc, expand_java_binop, note_label, expand_compare, expand_test, expand_cond, expand_java_goto, expand_java_call, expand_java_ret, pop_arguments, expand_invoke, expand_java_field_op, java_push_constant_from_pool): Likewise. (decode_newarray_type, expand_iinc): Un-ANSI-fy. (build_java_arraynull_check): Mark parameters `node' and `type' with ATTRIBUTE_UNUSED. (note_label): Likewise for parameter `current_pc'. (expand_java_call, expand_java_ret): Hide unused definition. * java-tree.h (make_class, build_constants_constructor, java_set_exception_lang_code, pop_labeled_block, emit_handlers, init_outgoing_cpool, register_class, emit_register_classes, java_layout_seen_class_methods): Prototype. (unicode_mangling_length): Const-ify. (append_gpp_mangled_name, append_gpp_mangled_classtype, emit_unicode_mangled_name, format_int, format_uint, jcf_trim_old_input, jcf_print_utf8, jcf_print_char, jcf_print_utf8_replace, open_class): Prototype. * jcf-dump.c: Include "config.h", not <config.h>. Don't include <stdio.h>. Include tree.h/java-tree.h. (utf8_equal_string usage, process_class): Add static prototype. (open_class): Don't prototype this here. (utf8_equal_string): Match arguments to format specifiers. (HANDLE_CODE_ATTRIBUTE, BRANCH, JSR, RET, LOOKUP_SWITCH, TABLE_SWITCH, disassemble_method): Likewise. * jcf-io.c: Include tree.h/java-tree.h. (open_class, find_classfile, jcf_print_utf8, jcf_print_utf8_replace): Const-ify. * jcf-parse.c (parse_zip_file_entries, process_zip_dir, parse_class_file): Add static prototype. (find_in_current_zip): Match definition to existing static prototype. * jcf-write.c: Include jcf.h before tree.h/java-tree.h. (alloc_chunk, append_chunk, append_chunk_copy, gen_jcf_label, finish_jcf_block, define_jcf_label, get_jcf_label_here, put_linenumber, localvar_alloc, localvar_free, get_access_flags, write_chunks, adjust_typed_op, generate_bytecode_conditional, generate_bytecode_return, perform_relocations, init_jcf_state, init_jcf_method, release_jcf_state, generate_classfile): Add static prototype. (emit_unop): Mark parameter `type' with ATTRIBUTE_UNUSED. (make_class_file_name): Const-ify. * jcf.h (find_classfile): Const-ify. * jv-scan.c (reset_report): Remove prototype. * jvgenmain.c: Include jcf.h/tree.h/java-tree.h. (error): Rewrite to allow varargs. * lang.c (lang_f_options): Const-ify. * lex.c (java_parse_escape_sequence): Add static prototype. (java_allocate_new_line): Match definition to existing static prototype. * mangle.c Include tree.h/java-tree.h. (unicode_mangling_length, emit_unicode_mangled_name, append_gpp_mangled_name, append_gpp_mangled_classtype): Const-ify. * parse.h (jdep_code): Remove trailing comma in enumeration. (java_get_line_col): Move prototype outside of !JC1_LITE test. (reset_report): Add prototype. * verify.c (push_pending_label, merge_types): Add static prototypes. * zipfile.h (opendir_in_zip, open_in_zip): Prototype. From-SVN: r25878
1999-03-15class.c (make_class): Don't set CLASS_P here (because this function is also ↵Per Bothner1-8/+16
called by... d * class.c (make_class): Don't set CLASS_P here (because this function is also called by build_java_array_type). (push_class): Set CLASS_P here instead. * parse.h (TYPE_CLASS_P): Check for TYPE_ARRAY_P is redundant. * jcf-dump.c (print_access_flags): Take extra parameter to indicate context. If the context is class, perfer "super" over "synchronized". * jcf-write.c (generate_classfile): Don't add ACC_SUPER if interface. * parse.y (create_class): Don't call parser_check_super here; it is not robust. Always wait until later. * parse.y (method_header): For interfaces, set ACC_ABSTRACT (to match what JDK 1.2 does), but don't set ACC_PUBLIC. From-SVN: r25784
1999-03-12Warning fixes:Kaveh R. Ghazi1-3/+2
* constants.c (find_class_or_string_constant): Cast variable `j' to a `jword' when comparing against one. * expr.c (java_lang_expand_expr): Remove unused variables `has_finally_p' and `op0'. * gjavah.c (print_field_info): Cast a value to jint when comparing against one. Likewise for a jlong. (add_namelet): Likewise cast a `sizeof' to an int when comparing against a signed quantity. * jcf-dump.c (print_signature_type): Remove unused variable `digit'. (print_signature): Don't needlessly dereference variable `str' * jcf-reader.c (get_attribute): Mark variables `max_stack' and `max_locals' with ATTRIBUTE_UNUSED. (jcf_parse_class): Likewise for variable `index'. * parse.h (reverse_jdep_list): Remove static prototype. * parse.y (build_jump_to_finally): Remove prototype and definition. (reverse_jdep_list): Add static prototype. * typeck.c (convert_ieee_real_to_integer): Remove unused variables `assignment' and `expr_decl'. * verify.c (verify_jvm_instructions): Remove unused label `bad_ldc'. From-SVN: r25731
1999-03-06Makefile.in (jcf-parse.o): Depend on $(PARSE_H).Kaveh R. Ghazi1-1/+0
* Makefile.in (jcf-parse.o): Depend on $(PARSE_H). (parse-scan.o): Depend on toplev.h. * class.c (make_method_value): Add prototype. Make it static. Remove unused second argument, caller changed. * expr.c (java_lang_expand_expr): Remove unused variable `return_label'. * java-tree.h: Don't prototype find_in_current_zip. Add prototypes for verify_constant_pool, start_java_method, end_java_method, give_name_to_locals, expand_byte_code, open_in_zip, set_constant_value, find_constant1, find_constant2, find_utf8_constant, find_string_constant, find_class_constant, find_fieldref_index, find_methodref_index, write_constant_pool, count_constant_pool_bytes and encode_newarray_type. * jcf-dump.c: Remove unused variable `LONG_temp'. * jcf-parse.c: Include parse.h. (jcf_parse_source): Remove unused parameter, all callers changed. (jcf_figure_file_type): Add static prototype. (find_in_current_zip): Likewise. Also remove unused parameter, all callers changed. (read_class): Initialize variable `saved_pos'. * jcf-reader.c (jcf_parse_preamble): Mark variables `minor_version' and `major_version' with ATTRIBUTE_UNUSED. * lex.c (java_is_eol): Wrap prototype and definition in !JC1_LITE. (java_init_lex): Wrap variable `java_lang_imported' in !JC1_LITE. (java_parse_doc_section): Initialize variable `seen_star'. (java_lex): Wrap variable `number_beginning' in !JC1_LITE. (java_lex_error): Mark parameters `msg' and `forward' with ATTRIBUTE_UNUSED. (java_get_line_col): Mark parameters `filename' and `line' with ATTRIBUTE_UNUSED. * parse-scan.y: Include toplev.h. (yyerror): Mark parameter `msg' with ATTRIBUTE_UNUSED. * parse.h: use `struct JCF', not plain `JCF'. (java_parser_context_save_global, java_expand_classes java_parser_context_restore_global, java_parse): Add prototypes. * typeck.c (convert_ieee_real_to_integer): Remove unused variable `node'. From-SVN: r25616
1999-01-23Warning fixes:Kaveh R. Ghazi1-3/+2
* Makefile.in (parse.o): Depend on $(CONFIG_H) and $(srcdir)/../system.h. (class.o): Depend on $(PARSE_H) and $(srcdir)/../output.h. (jcf-parse.o): Depend on $(srcdir)/../toplev.h. (jcf-write.o): Likewise. (jv-scan.o): Depend on $(CONFIG_H) and $(srcdir)/../system.h. (mangle.o): Depend on $(srcdir)/../toplev.h. (parse-scan.o): Depend on $(CONFIG_H) and $(srcdir)/../system.h. (zextract.o): Depend on $(CONFIG_H) and $(srcdir)/../system.h. * class.c: Include output.h and parse.h. (mangled_classname): Add the `const' keyword to a char*. (find_named_method): Hide unused function definition. (build_utf8_ref): Change type of variable `c' to unsigned char. Use ISALPHA/ISDIGIT instead of isalpha/isdigit. (build_class_ref): Add the `const' keyword to a char*. (layout_class_method): Remove unused variable `buf'. * decl.c (find_local_variable): Remove unused variable `rtl'. (pushdecl): Likewise for variables `different_binding_level' and `oldglobal'. (pushlevel): Mark parameter `unused' with ATTRIBUTE_UNUSED. (maybe_build_cleanup): Likewise for parameter `decl'. * except.c (expand_start_java_handler): Mark parameter `range' with ATTRIBUTE_UNUSED. * expr.c: Include except.h. (pop_type): Remove unused variable `i'. (pop_value): Likewise for variables `n_words' and `i'. (expand_java_arrayload): Likewise for variable `convert'. (java_lang_expand_expr): Likewise for variables `op0', `type', `mode', `unsignedp', `node' and `elements'. (expand_byte_code): Likewise for variables `prev_eh_ranges' and `eh_ranges'. (process_jvm_instruction): Add a `const' qualifier to a char*. * gjavah.c (output_directory): Add the `const' keyword to a char*. (temp_directory): Likewise. (print_c_decl): Likewise. (print_method_info): Likewise. (decode_signature_piece): Likewise. (print_mangled_classname): Likewise. * java-except.h: Provide prototypes for maybe_start_try, maybe_end_try and add_handler. * java-tree.h (mangled_classname): Add the `const' keyword to a char*. (parse_error_context): Likewise. Also add ATTRIBUTE_PRINTF_2. (pushdecl_top_level, alloc_class_constant, unicode_mangling_length, init_expr_processing, push_super_field, init_class_processing, can_widen_reference_to, class_depth, verify_jvm_instructions, maybe_pushlevels, maybe_poplevels, process_jvm_instruction, set_local_type, merge_type_state, push_type, load_type_state, add_interface, find_in_current_zip, append_gpp_mangled_classtype, emit_unicode_mangled_name): Add prototypes. * jcf-dump.c (print_constant): Add the `const' keyword to a char*. (print_signature_type): Use ISDIGIT, not isdigit. (print_signature): Remove unused variable `j'. * jcf-io.c (jcf_filbuf_from_stdio): Cast the result of `fread' to int when comparing against one. * jcf-parse.c: Include toplev.h. * jcf-write.c: Likewise. Don't include <string.h> or <sys/stat.h>. (localvar_free): Remove unused variable `i'. (generate_bytecode_conditional): Likewise for variable `kind'. * jv-scan.c: Include config.h and system.h. Remove redundant OS header and gansidecl.h includes. (warning): Add the `const' keyword to a char*. Also add ATTRIBUTE_PRINTF_1 to the prototype. Check ANSI_PROTOTYPES, not __STDC__, when determining whether to use ANSI-isms. (fatal): Likewise. Also add ATTRIBUTE_UNUSED. (xmalloc): Don't redundantly prototype here. (main): Remove unused parameter `envp'. Also fix the arguments passed to function `fatal' to match the format specifier. * lang.c (java_tree_code_name): Add the `const' keyword to a char*. * mangle.c: Include toplev.h. (emit_unicode_mangled_name): Declare parameter `len'. * parse.y (parse_warning_context): Add the `const' keyword to a char*. Also add ATTRIBUTE_PRINTF_2 to the prototype. Check `ANSI_PROTOTYPES' not `__STDC__' for whether to use ANSI-isms. (issue_warning_error_from_context): Add the `const' keyword to a char*. (parse_error_context): Likewise. Also check `ANSI_PROTOTYPES' not `__STDC__' for whether to use ANSI-isms. * typeck.c (incomplete_type_error): Mark parameters `value' and `type' with ATTRIBUTE_UNUSED. (parse_signature_type): Use ISDIGIT, not isdigit. * verify.c (check_pending_block): Add the `const' keyword to a char*. (verify_jvm_instructions): Likewise. Remove unused variables `field_name' and `default_val'. * zextract.c: Include config.h and system.h. Remove redundant OS header includes. * zipfile.h: Prototype `read_zip_archive'. From-SVN: r24835
1999-01-06Fix copyrights.Jeff Law1-1/+1
From-SVN: r24538
1999-01-06lex.h: Moved static function declarations to lex.c, to shut up some -Wall ↵Per Bothner1-11/+9
warnings. � * lex.h: Moved static function declarations to lex.c, to shut up some -Wall warnings. * lex.c: Static function declarations moved here. * jcf-dump.c: Small fixes to shut up -Wall warnings. From-SVN: r24518
1998-12-12Loks of changes so we can better compile from source.Per Bothner1-1/+1
� Loks of changes so we can better compile from source. See ChangeLog. From-SVN: r24278
1998-12-06jcf-dump.c (INVOKE): If invokeinterface, print number of args.Per Bothner1-1/+3
* jcf-dump.c (INVOKE): If invokeinterface, print number of args. From-SVN: r24140
1998-12-03jcf-dump.c (main): Fix error message.Per Bothner1-1/+1
* jcf-dump.c (main): Fix error message. * jcf-path.c (add_entry): Style fix. From-SVN: r24073
1998-11-11jcf-dump.c (TABLE_SWITCH): Fix typos.Per Bothner1-1/+1
� * jcf-dump.c (TABLE_SWITCH): Fix typos. From-SVN: r23609
1998-11-11* jcf-dump.c (main): Correctly recognize `--'-style long options.Tom Tromey1-27/+25
From-SVN: r23607
1998-10-22jcf-io.c (find_class): Use saw_java_source to determine when to look for ↵Tom Tromey1-31/+21
`.java' file. * jcf-io.c (find_class): Use saw_java_source to determine when to look for `.java' file. * jcf-parse.c (saw_java_source): New global. (yyparse): Set it if `.java' file seen. * Make-lang.in (JAVA_SRCS): Added jcf-path.c. (GCJH_SOURCES): Likewise. * Makefile.in (datadir): New macro. (libjava_zip): Likewise. (JAVA_OBJS): Added jcf-path.o. (../jcf-dump$(exeext)): Depend on and link with jcf-depend.o. (../gcjh$(exeext)): Likewise. (jcf-path.o): New target. * java-tree.h (fix_classpath): Removed decl. * jcf-parse.c (fix_classpath): Removed. (load_class): Don't call fix_classpath. * parse.y (read_import_dir): Don't call fix_classpath. * lex.h: Don't mention classpath. * lex.c (java_init_lex): Don't initialize classpath. * jcf-io.c (classpath): Removed global. (find_class): Use jcf_path iteration functions. Correctly search class path for .java file. (open_in_zip): New argument `is_system'. * jcf-dump.c (main): Call jcf_path_init. Recognize all new classpath-related options. * lang.c (lang_decode_option): Handle -fclasspath, -fCLASSPATH, and -I. (lang_init): Call jcf_path_init. * lang-options.h: Mention -I, -fclasspath, and -fCLASSPATH. * lang-specs.h: Handle -I. Minor cleanup to -M options. Correctly put braces around second string in each entry. * gjavah.c (main): Call jcf_path_init. Recognize all the new classpath-related options. (help): Updated for new options. * jcf.h: Declare functions from jcf-path.c. Don't mention `classpath' global. * jcf-path.c: New file. * jcf-depend.c: Include jcf.h. * jcf-write.c (localvar_alloc): Returns `void'. (localvar_free): Removed unused variable. * lang.c (OBJECT_SUFFIX): Define if not already defined. (init_parse): Use OBJECT_SUFFIX, not ".o". From-SVN: r23219
1998-10-14jcf-write.c (write_classfile): Add output class file as target.Tom Tromey1-3/+3
* jcf-write.c (write_classfile): Add output class file as target. * lang-options.h: Added -MD, -MMD, -M, and -MM. * jcf.h: Added declarations for dependency-tracking functions. * lang-specs.h: Handle -M, -MM, MD, and -MMD. * lang.c (lang_decode_option): Recognize -MD and -MMD. (finish_parse): Call jcf_dependency_write. (dependency_tracking): New global. (DEPEND_SET_FILE): New define. (DEPEND_ENABLE): New define. (init_parse): Enable dependency tracking if required. Include "flags.h". * Makefile.in (JAVA_OBJS): Added jcf-depend.o. (../jcf-dump$(exeext)): Depend on and link with jcf-depend.o. (../gcjh$(exeext)): Likewise. (jcf-depend.o): New target. * Make-lang.in (JAVA_SRCS): Added jcf-depend.c. (GCJH_SOURCES): Likewise. * jcf-io.c (open_class): Call jcf_dependency_add_file. Added dep_name argument. (find_classfile): Added dep_name argument. (find_class): Compute name of dependency. (open_in_zip): Call jcf_dependency_add_file. * gjavah.c (output_file): No longer global. (usage): Don't mention "gjavah". (help): Likewise. (java_no_argument): Likewise. (version): Likewise. (main): Recognize and handle -M family of options. (print_mangled_classname): Return is void. (process_file): Handle case where output is suppressed. (HANDLE_END_FIELD): Likewise. (HANDLE_METHOD): Likewise. * jcf-depend.c: New file. From-SVN: r23085
1998-10-13jcf-dump.c (process_class): Use FATAL_EXIT_CODE, not -1.Tom Tromey1-10/+16
* jcf-dump.c (process_class): Use FATAL_EXIT_CODE, not -1. (main): Likewise. Exit with SUCCESS_EXIT_CODE at end of function. Include <config.h> and "system.h". (disassemble_method): Undefine RET to avoid clash with config/i386/i386.h. From-SVN: r23050
1998-10-12Per Bothner1-31/+57
Merge from Cygnus internal source tree. From-SVN: r23024
1998-09-06Initial revisionAnthony Green1-0/+1072
From-SVN: r22299