diff options
author | Gabriel Dos Reis <gdr@codesourcery.com> | 2000-06-06 20:11:40 +0000 |
---|---|---|
committer | Gabriel Dos Reis <gdr@gcc.gnu.org> | 2000-06-06 20:11:40 +0000 |
commit | 764dbbf2ddb0b5602ae03f0ecb2c8078587e41dd (patch) | |
tree | 426d57102b49f5aa4ea84d91a2b883687998bed2 /gcc/cp | |
parent | 93136754c17836b592089e2c335108870344aead (diff) | |
download | gcc-764dbbf2ddb0b5602ae03f0ecb2c8078587e41dd.zip gcc-764dbbf2ddb0b5602ae03f0ecb2c8078587e41dd.tar.gz gcc-764dbbf2ddb0b5602ae03f0ecb2c8078587e41dd.tar.bz2 |
diagnostic.c (output_maximum_width): Remove.
2000-06-06 Gabriel Dos Reis <gdr@codesourcery.com>
* diagnostic.c (output_maximum_width): Remove.
(doing_line_wrapping): Tweak.
(diagnostic_buffer): New object.
(global_output_buffer): New object.
(output_destroy_prefix): New function.
(default_initialize_buffer): Likewise.
(reshape_diagnostic_buffer): Likewise.
(initialize_diagnostics): Likewise.
(output_clear): Tweak.
(line_wrapper_printf): Adjust call to init_output_buffer.
(vline_wrapper_message_with_location): Likewise. Use
output_destroy_prefix.
(v_message_with_decl): Likewise.
* diagnostic.h (struct output_buffer): Constify prefix.
(init_output_buffer, output_get_prefix): Constify.
(diagnostic_message_length_per_line): Likewise.
(reshape_diagnostic_buffer): Declare.
(default_initialize_buffer): Declare.
(initialize_diagnostics): Declare.
(diagnostic_buffer): Declare new obbject.
* toplev.c: #include diagnostic.h
(display_help): Document diagnostic formatting options.
(decode_f_option): Handle diagnostic formatting options.
(main): Setup initialization for diagnostic messages outputter.
* toplev.h (set_message_length): Remove.
* Makefile.in (toplev.o): Depends upon diagnostic.h
* invoke.texi : Document diagnostics formatting options.
cp/
2000-06-06 Gabriel Dos Reis <gdr@codesourcery.com>
* lex.c (lang_init_options): Tweak.
* decl2.c: Remove #inclusion of diagnostic.h
(lang_decode_option): Move diagnostic formatting options to
toplevel.
* lang-options.h: Remove documentation for diagnostic options.
* Makefile.in (lex.o): Depends upon diagnostic.h
From-SVN: r34435
Diffstat (limited to 'gcc/cp')
-rw-r--r-- | gcc/cp/ChangeLog | 12 | ||||
-rw-r--r-- | gcc/cp/Makefile.in | 2 | ||||
-rw-r--r-- | gcc/cp/decl2.c | 16 | ||||
-rw-r--r-- | gcc/cp/lang-options.h | 2 | ||||
-rw-r--r-- | gcc/cp/lex.c | 2 |
5 files changed, 14 insertions, 20 deletions
diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog index 5775c26..48b861f 100644 --- a/gcc/cp/ChangeLog +++ b/gcc/cp/ChangeLog @@ -1,3 +1,15 @@ +2000-06-06 Gabriel Dos Reis <gdr@codesourcery.com> + + * lex.c (lang_init_options): Tweak. + + * decl2.c: Remove #inclusion of diagnostic.h + (lang_decode_option): Move diagnostic formatting options to + toplevel. + + * lang-options.h: Remove documentation for diagnostic options. + + * Makefile.in (lex.o): Depends upon diagnostic.h + 2000-06-06 Mark Mitchell <mark@codesourcery.com> * decl.c (redeclaration_error_message): If two TEMPLATE_DECLs have diff --git a/gcc/cp/Makefile.in b/gcc/cp/Makefile.in index 6d9a6a9..2e437cb 100644 --- a/gcc/cp/Makefile.in +++ b/gcc/cp/Makefile.in @@ -254,7 +254,7 @@ lex.o : lex.c $(CXX_TREE_H) \ $(PARSE_H) input.c $(srcdir)/../flags.h hash.h lex.h \ $(srcdir)/../c-pragma.h $(srcdir)/../toplev.h \ $(srcdir)/../output.h $(srcdir)/../mbchar.h $(GGC_H) \ - $(srcdir)/../input.h operators.def + $(srcdir)/../input.h $(srcdir)/../diagnostic.h operators.def decl.o : decl.c $(CXX_TREE_H) $(srcdir)/../flags.h \ lex.h decl.h $(srcdir)/../stack.h $(srcdir)/../output.h $(srcdir)/../expr.h \ $(srcdir)/../except.h $(srcdir)/../toplev.h \ diff --git a/gcc/cp/decl2.c b/gcc/cp/decl2.c index f132478..f23512c 100644 --- a/gcc/cp/decl2.c +++ b/gcc/cp/decl2.c @@ -45,7 +45,6 @@ Boston, MA 02111-1307, USA. */ #include "dwarfout.h" #include "ggc.h" #include "timevar.h" -#include "diagnostic.h" #if USE_CPPLIB #include "cpplib.h" @@ -679,21 +678,6 @@ lang_decode_option (argc, argv) name_mangling_version = read_integral_parameter (option_value, p - 2, name_mangling_version); else if ((option_value - = skip_leading_substring (p, "message-length="))) - set_message_length - (read_integral_parameter (option_value, p - 2, - /* default line-wrap length */ 72)); - else if ((option_value - = skip_leading_substring (p, "diagnostics-show-location="))) - { - if (!strcmp (option_value, "once")) - set_message_prefixing_rule (DIAGNOSTICS_SHOW_PREFIX_ONCE); - else if (!strcmp (option_value, "every-line")) - set_message_prefixing_rule (DIAGNOSTICS_SHOW_PREFIX_EVERY_LINE); - else - error ("Unrecognized option `%s'", p - 2); - } - else if ((option_value = skip_leading_substring (p, "dump-translation-unit-"))) { if (p[22] == '\0') diff --git a/gcc/cp/lang-options.h b/gcc/cp/lang-options.h index 232a40c..623cee2 100644 --- a/gcc/cp/lang-options.h +++ b/gcc/cp/lang-options.h @@ -74,8 +74,6 @@ DEFINE_LANG_NAME ("C++") { "-flabels-ok", "Labels can be used as first class objects" }, { "-fno-labels-ok", "" }, { "-fmemoize-lookups", "" }, - { "-fmessage-length=", "" }, - { "-fdiagnostics-show-location=", "" }, { "-fno-memoize-lookups", "" }, { "-fms-extensions", "Don't pedwarn about uses of Microsoft extensions" }, { "-fno-ms-extensions", "" }, diff --git a/gcc/cp/lex.c b/gcc/cp/lex.c index 839f34f..99e7a45 100644 --- a/gcc/cp/lex.c +++ b/gcc/cp/lex.c @@ -392,7 +392,7 @@ lang_init_options () /* Mark as "unspecified". */ flag_bounds_check = -1; /* By default wrap lines at 72 characters. */ - set_message_length (72); + diagnostic_message_length_per_line = 72; /* By default, emit location information once for every diagnostic message. */ set_message_prefixing_rule (DIAGNOSTICS_SHOW_PREFIX_ONCE); |