public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* [PATCH RFA]: clean up -fdiagnostics-show-option and -Werror= docs slightly
@ 2011-03-12  8:51 Chris Demetriou
  2011-03-13  1:23 ` Gabriel Dos Reis
  0 siblings, 1 reply; 2+ messages in thread
From: Chris Demetriou @ 2011-03-12  8:51 UTC (permalink / raw)
  To: gcc-patches

[-- Attachment #1: Type: text/plain, Size: 790 bytes --]

-fdiagnostics-show-option is now the default, and it looks like
neither its description or the -Werror= description was updated to
match.
This patch attempts to do that.

tested by building, running nroff -man gcc.1, and reading the result.

OK for trunk (i.e., pre-4.6)?


(I feel a tiny bit bad about not attempting to address the issues
raised in PRs 40989 and 48088 where -Werror= and -Wno-error= don't
work as expected... but I'm at a loss for a concise set of words to
describe the problems and it's late.  8-S)


chris
---
2011-03-12  Chris Demetriou  <cgd@google.com>

        * doc/invoke.texi (-fdiagnostics-show-option): Replace with...
        (-fno-diagnostics-show-option): this, to reflect current default.
        (-Werror=): Update text about -fno-diagnostics-show-option.

[-- Attachment #2: doc.patch --]
[-- Type: text/x-patch, Size: 2549 bytes --]

[gcc/ChangeLog]
2011-03-12  Chris Demetriou  <cgd@google.com>

	* doc/invoke.texi (-fdiagnostics-show-option): Replace with...
	(-fno-diagnostics-show-option): this, to reflect current default.
	(-Werror=): Update text about -fno-diagnostics-show-option.

Index: doc/invoke.texi
===================================================================
--- doc/invoke.texi	(revision 170864)
+++ doc/invoke.texi	(working copy)
@@ -227,7 +227,7 @@
 @xref{Language Independent Options,,Options to Control Diagnostic Messages Formatting}.
 @gccoptlist{-fmessage-length=@var{n}  @gol
 -fdiagnostics-show-location=@r{[}once@r{|}every-line@r{]}  @gol
--fdiagnostics-show-option}
+-fno-diagnostics-show-option}
 
 @item Warning Options
 @xref{Warning Options,,Options to Request or Suppress Warnings}.
@@ -2771,12 +2771,13 @@
 prefix) for physical lines that result from the process of breaking
 a message which is too long to fit on a single line.
 
-@item -fdiagnostics-show-option
+@item -fno-diagnostics-show-option
+@opindex fno-diagnostics-show-option
 @opindex fdiagnostics-show-option
-This option instructs the diagnostic machinery to add text to each
-diagnostic emitted, which indicates which command line option directly
-controls that diagnostic, when such an option is known to the
-diagnostic machinery.
+By default, each diagnostic emitted includes text which indicates the
+command line option that directly controls the diagnostic (if such an
+option is known to the diagnostic machinery).  Specifying the
+@option{-fno-diagnostics-show-option} flag suppresses that behavior.
 
 @item -Wcoverage-mismatch
 @opindex Wcoverage-mismatch
@@ -2842,10 +2843,14 @@
 negative form, to be used to negate @option{-Werror} for specific
 warnings, for example @option{-Wno-error=switch} makes
 @option{-Wswitch} warnings not be errors, even when @option{-Werror}
-is in effect.  You can use the @option{-fdiagnostics-show-option}
-option to have each controllable warning amended with the option which
-controls it, to determine what to use with this option.
+is in effect.
 
+The warning message for each controllable warning includes the
+option which controls the warning.  That option can then be used with
+@option{-Werror=} and @option{-Wno-error=} as described above.
+(Printing of the option in the warning message can be disabled using the
+@option{-fno-diagnostics-show-option} flag.)
+
 Note that specifying @option{-Werror=}@var{foo} automatically implies
 @option{-W}@var{foo}.  However, @option{-Wno-error=}@var{foo} does not
 imply anything.

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [PATCH RFA]: clean up -fdiagnostics-show-option and -Werror= docs slightly
  2011-03-12  8:51 [PATCH RFA]: clean up -fdiagnostics-show-option and -Werror= docs slightly Chris Demetriou
@ 2011-03-13  1:23 ` Gabriel Dos Reis
  0 siblings, 0 replies; 2+ messages in thread
From: Gabriel Dos Reis @ 2011-03-13  1:23 UTC (permalink / raw)
  To: Chris Demetriou; +Cc: gcc-patches

OK.

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2011-03-13  1:23 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-03-12  8:51 [PATCH RFA]: clean up -fdiagnostics-show-option and -Werror= docs slightly Chris Demetriou
2011-03-13  1:23 ` Gabriel Dos Reis

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).