diff options
author | Joseph Myers <joseph@codesourcery.com> | 2010-05-24 19:55:44 +0100 |
---|---|---|
committer | Joseph Myers <jsm28@gcc.gnu.org> | 2010-05-24 19:55:44 +0100 |
commit | 243fbddd9c886159b7461867c84db564e0b5b0b0 (patch) | |
tree | d6028a1f52919db5575cd7449139f2ab89757163 /gcc/toplev.c | |
parent | 611d6f76fe8eae737566fb809f61b0c094ef92c9 (diff) | |
download | gcc-243fbddd9c886159b7461867c84db564e0b5b0b0.zip gcc-243fbddd9c886159b7461867c84db564e0b5b0b0.tar.gz gcc-243fbddd9c886159b7461867c84db564e0b5b0b0.tar.bz2 |
diagnostic.c: Don't include flags.h.
* diagnostic.c: Don't include flags.h.
(pedantic_warning_kind, permissive_error_kind): Take diagnostic
context parameters. Check flags in the context passed as a
parameter.
(diagnostic_build_prefix): Add context parameter. Check
show_column flag in context.
(diagnostic_action_after_output): Check fatal_errors flag in
context.
(diagnostic_report_current_module): Check show_column flag in
context.
(default_diagnostic_starter): Update call to
diagnostic_build_prefix.
(diagnostic_report_diagnostic): Pass context to
pedantic_warning_kind.
(emit_diagnostic): Pass context to permissive_error_kind.
(permerror): Pass context to permissive_error_kind.
* diagnostic.h (struct diagnostic_context): Add show_column,
pedantic_errors, permissive and fatal_errors fields.
(diagnostic_build_prefix): Update prototype.
* langhooks.c
* toplev.c (process_options): Set flags in global_dc from
flag_show_column, flag_pedantic_errors, flag_permissive,
flag_fatal_errors.
* tree-diagnostic.c (default_tree_diagnostic_starter): Update call
to diagnostic_build_prefix.
* Makefile.in (diagnostic.o): Update dependencies.
cp:
* error.c (cp_diagnostic_starter): Update call to
diagnostic_build_prefix.
(cp_print_error_function,
print_instantiation_partial_context_line): Check show_column flag
in context.
From-SVN: r159793
Diffstat (limited to 'gcc/toplev.c')
-rw-r--r-- | gcc/toplev.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/gcc/toplev.c b/gcc/toplev.c index fcd720d..9d3396b 100644 --- a/gcc/toplev.c +++ b/gcc/toplev.c @@ -1827,6 +1827,11 @@ process_options (void) if (flag_compare_debug) diagnostic_inhibit_notes (global_dc); + global_dc->show_column = flag_show_column; + global_dc->pedantic_errors = flag_pedantic_errors; + global_dc->permissive = flag_permissive; + global_dc->fatal_errors = flag_fatal_errors; + if (flag_section_anchors && !target_supports_section_anchors_p ()) { warning (OPT_fsection_anchors, |