summaryrefslogtreecommitdiff
path: root/gcc/diagnostic.c
Commit message (Collapse)AuthorAgeFilesLines
* top level:zack2000-05-201-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | * diagnostic.c: Eliminate implicit int. * except.c, gcc.c: Add static prototypes. * final.c (final_end_function): Mark file arg ATTRIBUTE_UNUSED. * gensupport.c (process_rtx): Use XVEC to initialize vector slot of 'split'. * print-rtl.c: If DEBUG_REGISTER_NAMES, define static debug_reg_names instead of static reg_names. If not, define global reg_names. * regclass.c: Don't define global reg_names unless DEBUG_REGISTER_NAMES is defined. * reload1.c (order_regs_for_reload): Remove unused variable. * varasm.c: Include output.h after defaults.h. Define eh_frame_section as function of no args, not of unspecified args. * gcc.c: Constify argbuf; arguments to store_arg, process_command, main; elements of struct command and struct switchstr; local variables in execute, process_command, main. cp: * except.c: Add static prototypes. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@34054 138bc75d-0d04-0410-961f-82ee72b054a4
* 2000-05-13 Gabriel Dos Reis <gdr@codesourcery.com>gdr2000-05-141-2/+33
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * diagnostic.h (DIAGNOSTICS_SHOW_PREFIX_ONCE): New macro. (DIAGNOSTICS_SHOW_PREFIX_NEVER): Likewise. (DIAGNOSTICS_SHOW_PREFIX_EVERY_LINE): Likewise. (struct output_buffer: emitted_prefix_p, prefixing_rule): New fields. (set_message_prefixing_rule): Declare. * diagnostic.c: (current_prefixing_rule): New variable. (set_message_prefixing_rule): Define. (output_set_prefix): Adjust buffer->emitted_prefix_p. (init_output_buffer): Adjust Initialization. (output_emit_prefix): Rewrite. Take prefixing rules into account. cp/ 2000-05-13 Gabriel Dos Reis <gdr@codesourcery.com> * lex.c: #include diagnostic.h. (lang_init_options): Set default prefixing rules. * lang-options.h: Add -fdiagnostics-show-location=. * decl2.c: #include diagnostic.h. (lang_decode_option): Handle -fdiagnostics-show-location=. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@33890 138bc75d-0d04-0410-961f-82ee72b054a4
* * bb-reorder.c (get_next_bb_note, get_prev_bb_note): Prototype.ghazi2000-05-041-15/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * diagnostic (vbuild_message_string, build_message_string, build_location_prefix, output_get_prefix, init_output_buffer, output_notice, vline_wrapper_message_with_location, v_message_with_decl, default_print_error_function): De-constify. (set_real_maximum_length): Prototype. * diagnostic.h (struct output_buffer, init_output_buffer, output_get_prefix, output_set_prefix): De-constify. * function.c (init_function_start): Constify. * gensupport.c (remove_constraints, process_rtx): Prototype. * gthr-posix.h: Indent uses of #pragma. * objc/objc-act.c (ggc_mark_imp_list, ggc_mark_hash_table): Prototype. * predict.c (find_expected_value): Delete prototype. (expected_value_to_br_prob): Initialize variable `ev_reg'. * sbitmap.h (debug_sbitmap): Prototype. * ssa.c (compute_coalesced_reg_partition): Prototype. * stor-layout.c (debug_rli): Prototype. * tree.h (round_down): Prototype. (init_function_start): Constify. ch: * ch-tree.h (init_function_start): Constify. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@33675 138bc75d-0d04-0410-961f-82ee72b054a4
* * diagnostic.c (init_output_buffer): Don't initialize format_args.rth2000-04-221-14/+10
| | | | | | | | | | | | (output_clear): Likewise. (output_printf): Use va_copy. (vline_wrapper_message_with_location): Likewise. (v_message_with_decl): Likewise. (line_wrapper_printf): VA_START infor buffer.format_args directly. * system.h (va_copy): Provide default implementation. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@33341 138bc75d-0d04-0410-961f-82ee72b054a4
* 2000-04-22 Gabriel Dos Reis <gdr@codesourcery.com>gdr2000-04-221-114/+243
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * diagnostic.h: New file. * Makefile.in (diagnostic.o): Depends on diagnostic.h * diagnostic.c: Tweak. Rationalize the output logic. Adjust various function prototypes. (diagnostic.h): #include. (struct output_buffer): Move into diagnostic.h. (get_output_prefix): Rename to output_get_prefix. Export. (init_output_buffer): Export. Break out. Ajust intialization. (output_space_left, output_append): Export. (output_newline): Rename to output_add_newline. Export. (output_clear): Nullify additional output_buffer fields. (output_puts): Rename to output_add_string. Export. (dump_output): Rename to output_flush_on. Export. (build_location_prefix): Constify return-type. (emit_output_prefix): Rename to output_emit_prefix. Export. (set_real_maximum_length): New function. (output_set_maximum_length): Ditto (output_clear): Ditto. (output_add_character): Ditto. (output_add_integer): Ditto. (output_add_space): Ditto. (output_format): Ditto. (output_printf): Adjust buffer initialization. (vline_wrapper_message_with_location): Ditto. (v_message_with_decl): Ditto. Adjust call to output_puts and get_output_prefix. (default_print_error_function): Adjust buffer intialization. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@33337 138bc75d-0d04-0410-961f-82ee72b054a4
* * rtl.h (rtunion_def): Constify member `rtstr'.ghazi2000-03-071-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (emit_line_note_after, emit_line_note, emit_line_note_force, emit_note, decode_asm_operands): Constify. * cse.c (canon_hash): Likewise. * dbxout.c (dbxout_block): Likewise. * diagnostic.c (file_and_line_for_asm, v_error_for_asm, v_warning_for_asm): Likewise. * dwarfout.c (function_start_label): Likewise. * emit-rtl.c (emit_line_note_after, emit_line_note, emit_note, emit_line_note_force): Likewise. * final.c (last_filename, asm_insn_count, final_scan_insn, output_source_line): Likewise. * function.h (struct emit_status): Likewise. * gcse.c (hash_expr_1): Likewise. * genattr.c (gen_attr, main): Likewise. * genattrtab.c (struct function_unit, current_alternative_string, write_attr_valueq, n_comma_elts, next_comma_elt, attr_eq, attr_numeral, check_attr_test, check_attr_value, convert_set_attr_alternative, convert_set_attr, compute_alternative_mask, simplify_by_exploding, gen_attr, gen_unit): Likewise. * genflags.c (gen_insn): Likewise. * gengenrtl.c (type_from_format): Likewise. * genopinit.c (gen_insn): Likewise. * genoutput.c (n_occurrences, process_template, process_template): Likewise. * ggc-page.c (ggc_set_mark, ggc_mark_if_gcable, ggc_get_size): Likewise. * ggc-simple.c (ggc_set_mark, ggc_mark_if_gcable, ggc_get_size): Likewise. * ggc.h (ggc_mark_string, ggc_mark, ggc_mark_if_gcable, ggc_set_mark, ggc_get_size): Likewise. * objc/objc-act.c (build_module_descriptor, finish_objc): Likewise. * optabs.c (init_one_libfunc): Likewise. * output.h (assemble_start_function): Likewise. * recog.c (decode_asm_operands): Likewise. * toplev.c (rest_of_compilation): Likewise. * tree.h (emit_line_note_after, emit_line_note, emit_line_note_force): Likewise. * varasm.c (asm_output_bss, asm_output_aligned_bss, asm_emit_uninitialised, assemble_start_function, assemble_variable, const_hash, compare_constant_1, find_pool_constant, mark_constant_pool, assemble_alias): Likewise. * xcoffout.h (DBX_FINISH_SYMBOL): Likewise. * alpha/alpha.md (call_vms, call_value_vms): Likewise. * arm/aof.h (ASM_OUTPUT_ASCII): Likewise. * arm/aout.h (ASM_OUTPUT_ASCII): Likewise. * arm/arm-protos.h (output_ascii_pseudo_op, arm_dllexport_name_p, arm_dllimport_name_p): Likewise. * arm/arm.c (arm_encode_call_attribute, output_ascii_pseudo_op): Likewise. * arm/arm.h (ASM_OUTPUT_MI_THUNK): Likewise. * arm/elf.h (ASM_FINISH_DECLARE_OBJECT): Likewise. * arm/pe.c (arm_dllexport_name_p, arm_dllimport_name_p, arm_mark_dllexport, arm_mark_dllimport, arm_pe_encode_section_info): Likewise. * arm/telf.h (ASM_OUTPUT_DEF_FROM_DECLS, ASM_FINISH_DECLARE_OBJECT): Likewise. * arm/thumb.c (thumb_function_prologue): Likewise. * arm/thumb.h (ASM_OUTPUT_ASCII): Likewise. * avr/avr.h (ASM_FINISH_DECLARE_OBJECT): Likewise. * clipper/clix.h (ASM_OUTPUT_ASCII): Likewise. * fx80/fx80.h (ASM_OUTPUT_ASCII): Likewise. * i386/cygwin.h (ASM_OUTPUT_SECTION_NAME): Likewise. * i386/freebsd.h (ASM_FINISH_DECLARE_OBJECT): Likewise. * i386/i386-interix.h (ASM_OUTPUT_LIMITED_STRING, ASM_OUTPUT_ASCII, ASM_OUTPUT_SECTION_NAME): Likewise. * i386/i386-protos.h (asm_output_function_prefix): Likewise. * i386/i386.c (asm_output_function_prefix): Likewise. * i386/i386elf.h (ASM_OUTPUT_ASCII): Likewise. * i386/osfrose.h (ASM_FINISH_DECLARE_OBJECT): Likewise. * i386/ptx4-i.h (ASM_OUTPUT_ASCII): Likewise. * i386/sco5.h (ASM_FINISH_DECLARE_OBJECT, ASM_OUTPUT_LIMITED_STRING, ASM_OUTPUT_ASCII, ASM_OUTPUT_SECTION_NAME): Likewise. * i386/sysv4.h (ASM_OUTPUT_ASCII): Likewise. * i860/paragon.h (ASM_OUTPUT_ASCII): Likewise. * i860/sysv3.h (ASM_OUTPUT_ASCII): Likewise. * m32r/m32r.c (m32r_encode_section_info): Likewise. * mcore-elf.h (ASM_FINISH_DECLARE_OBJECT): Likewise. * mcore/mcore.c (mcore_encode_section_info): Likewise. * mips/elf.h (ASM_FINISH_DECLARE_OBJECT): Likewise. * mips/elf64.h (ASM_FINISH_DECLARE_OBJECT): Likewise. * mips/iris6.h (ASM_FINISH_DECLARE_OBJECT): Likewise. * mips/mips.h (ASM_OUTPUT_IDENT): Likewise. * mips/mips.md (movdi, movsi): Likewise. * mips/netbsd.h (ASM_FINISH_DECLARE_OBJECT): Likewise. * netbsd.h (ASM_FINISH_DECLARE_OBJECT): Likewise. * openbsd.h (ASM_FINISH_DECLARE_OBJECT): Likewise. * ptx4.h (ASM_FINISH_DECLARE_OBJECT, ASM_OUTPUT_LIMITED_STRING, ASM_OUTPUT_ASCII): Likewise. * rs6000/rs6000.c (rs6000_allocate_stack_space, output_epilog, output_mi_thunk, output_toc): Likewise. * rs6000/rs6000.md (movsi): Likewise. * rs6000/sysv4.h (ASM_OUTPUT_INT, ASM_OUTPUT_SECTION_NAME): Likewise. * tahoe/harris.h (ASM_OUTPUT_ASCII): Likewise. * v850/v850.c (print_operand, print_operand_address, v850_encode_data_area): Likewise. ch: * grant.c (globalize_decl): Constify a char*. cp: * decl2.c (finish_objects): Constify a char*. * method.c (emit_thunk): Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@32388 138bc75d-0d04-0410-961f-82ee72b054a4
* * diagnostic.c (init_output_buffer): Handle case of null PREFIX.kenner2000-02-231-1/+1
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@32112 138bc75d-0d04-0410-961f-82ee72b054a4
* fix commentjason2000-02-221-1/+1
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@32106 138bc75d-0d04-0410-961f-82ee72b054a4
* 2000-02-21 Gabriel Dos Reis <gdr@codesourcery.com>gdr2000-02-211-1/+8
| | | | | | | | * diagnostic.c (init_output_buffer): Make it possible to output at least 32 characters if we're given a too long prefix. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@32091 138bc75d-0d04-0410-961f-82ee72b054a4
* * Makefile.in (c-common.o): Depend on $(EXPR_H).ghazi2000-02-061-20/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * c-common.c: Include expr.h. * c-pragma.c (mark_align_stack): Add prototype. * caller-save.c (add_stored_regs): Likewise. * combine.c (record_promoted_value): Likewise. * i386.c (ix86_sched_reorder_pentium, ix86_sched_reorder_ppro): Likewise. * cppinit.c (new_pending_define): Likewise. * cpplib.c (skip_block_comment, skip_line_comment): Likewise. * dwarf2out.c (save_rtx, splice_child_die, reverse_die_lists, AT_class, AT_flag, AT_int, AT_unsigned, AT_string, AT_ref, AT_loc, AT_addr, AT_lbl, get_AT_ref, free_AT, free_die, local_scope_p, class_scope_p): Likewise. * dwarf2out.h (dwarf2out_set_demangle_name_func, dwarf2out_add_library_unit_info): Likewise. * ggc.h (ggc_page_print_statistics): Likewise. * haifa-sched.c (propagate_deps): Likewise. * reg-stack.c (next_flags_user, record_label_references): Likewise. * rtl.h (set_stack_check_libfunc): Likewise. * toplev.h (set_fatal_function): Likewise. * toplev.c (set_fatal_function): Delete prototype. * diagnostic.c: Deconstify functions returning malloc'ed ptrs. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@31810 138bc75d-0d04-0410-961f-82ee72b054a4
* * diagnostic.c (build_message_string, output_printf,ghazi2000-01-281-10/+20
| | | | | | | | line_wrapper_printf): Add ATTRIBUTE_PRINTF_*. (build_location_prefix): Fix non-literal format string. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@31669 138bc75d-0d04-0410-961f-82ee72b054a4
* * cccp.c: PROTO -> PARAMS.ghazi2000-01-141-67/+68
| | | | | | | | | | | | | | | | | | | | * cexp.y: Likewise. * collect2.c: Likewise. * combine.c: Likewise. * convert.h: Likewise. * cse.c: Likewise. * dbxout.c: Likewise. * dbxout.h: Likewise. * diagnostic.c: Likewise. * doprint.c: Likewise. * dwarf2out.c: Likewise. * dwarf2out.h: Likewise. * dwarfout.c: Likewise. * dwarfout.h: Likewise. * dyn-string.h: Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@31399 138bc75d-0d04-0410-961f-82ee72b054a4
* 2000-01-12 Gabriel Dos Reis <gdr@codesourcery.com>gdr2000-01-121-30/+409
| | | | | | | Implement automatic line wrapping mode in the g++ front-end. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@31343 138bc75d-0d04-0410-961f-82ee72b054a4
* * diagnostic.c (v_message_with_decl): Use .* format specifierghazi1999-12-271-8/+1
| | | | | | | instead of building the format specifier width manually. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@31101 138bc75d-0d04-0410-961f-82ee72b054a4
* 1999-12-18 Gabriel Dos Reis <gdr@codesourcery.com>gdr1999-12-181-0/+926
* toplev.c (notice, vmessage, v_message_with_file_and_line, v_message_with_decl, file_and_line_for_asm, v_error_with_file_and_line, v_error_with_decl, v_error_for_asm, verror, vfatal, v_warning_with_file_and_line, v_warning_with_decl, v_warning_for_asm, vwarning, vpedwarn, v_pedwarn_with_decl, v_pedwarn_with_file_and_line, vsorry, vnotice, count_error, pfatal_with_name, fatal_io_error, need_error_newline, last_error_function, last_error_tick, announce_function, default_print_error_function, print_error_function, report_error_function, fnotice, error_with_file_and_line, error_with_decl, error_for_asm, error, set_fatal_function, fatal, _fatal_insn, _fatal_insn_not_found, warning_with_file_and_line, warning_with_decl, warning_for_asm, warning, pedwarn, pedwarn_with_decl, pedwarn_with_file_and_line, sorry): Move to diagnostic.c (compile_file): Use fnotice instead of notice. Adjust call. * diagnostic.c: New file. * Makefile.in (OBJS): Include diagnostic.o (diagnostic.o): Define dependence. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@31003 138bc75d-0d04-0410-961f-82ee72b054a4