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] Correct --help=<language> output (PR 31356), add --help=common


:ADDPATCH other:

This patch corrects the first line of the "gcc --help=<language>" output, as reported in PR 31356. It also adds a "gcc --help=common" variant of the option, which seems like an obvious extension of the syntax (given that 90% of the work was already done!).

------------------------------------------------------------
2007-03-25  Brooks Moses  <brooks.moses@codesourcery.com>

	PR other/31356
	* gcc.c (print_specific_help): Fix --help=<language>
	header line.
	(common_handle_option): Support --help=common.

------------------------------------------------------------

Tested with a bootstrap (and running the various "gcc --help=..." variants) on i686-pc-linux-gnu. Ok for trunk?

(I'll do up a documentation patch for the --help=common option, once my pending patch for other bits of the --help= documentation is approved.)

- Brooks
Index: opts.c
===================================================================
--- opts.c	(revision 123170)
+++ opts.c	(working copy)
@@ -893,7 +893,8 @@
 	      descrip_extra = lang_names [i];
 	    }
 	  else
-	    description = _("The following options are supported by, amoung others, the language ");
+	    description = _("The following options are supported by the language ");
+	    descrip_extra = lang_names [i];
 	  break;
 	}
     }
@@ -983,7 +984,8 @@
 	/* Walk along the argument string, parsing each word in turn.
 	   The format is:
 	   arg = [^]{word}[,{arg}]
-	   word = {optimizers|target|warnings|undocumented|params}  */
+	   word = {optimizers|target|warnings|undocumented|
+		   params|common|<language>}  */
 	while (* a != 0)
 	  {
 	    static struct
@@ -1000,6 +1002,7 @@
 	      { "params", CL_PARAMS },
 	      { "joined", CL_JOINED },
 	      { "separate", CL_SEPARATE },
+	      { "common", CL_COMMON },
 	      { NULL, 0 }
 	    };
 	    unsigned int * pflags;

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