This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[PATCH] Document --version in --help output.


$ gcc --help

does not document --version at all.

$ gcc -v --help 2>/dev/null | grep -e '-version '
  -version                    This switch lacks documentation
  -ftree-vect-loop-version    Enable loop versioning when doing loop
  --version                   This switch lacks documentation
  --version               print assembler version number and exit
  -v, --version               Print version information
  --no-undefined-version      Disallow undefined version

The first line is from the Java specific section; jc1 accepts only
-version, gcj accepts only --version.  With the other patch to fix
bogusly lacking entries, the line becomes
  -version                    Display the compiler's version

The third line from the language-independent section, failing to
document --version, then as, then ld.

I suggest this patch to document --version in --help.

Surprisingly, this is not a regression AFAICS.  So I guess unless you
find that trivial enough to warrant applying now, or this is too bad on
translators: OK for 4.5?

Thanks,
Ralf

gcc/ChangeLog:
2009-03-01  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>

	* gcc.c (display_help): Document --version.

diff --git a/gcc/gcc.c b/gcc/gcc.c
index c2850bf..cf85618 100644
--- a/gcc/gcc.c
+++ b/gcc/gcc.c
@@ -3232,6 +3232,7 @@ display_help (void)
   fputs (_("                           Display specific types of command line options\n"), stdout);
   if (! verbose_flag)
     fputs (_("  (Use '-v --help' to display command line options of sub-processes)\n"), stdout);
+  fputs (_("  --version                Display compiler version information\n"), stdout);
   fputs (_("  -dumpspecs               Display all of the built in spec strings\n"), stdout);
   fputs (_("  -dumpversion             Display the version of the compiler\n"), stdout);
   fputs (_("  -dumpmachine             Display the compiler's target processor\n"), stdout);


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]