Commit 5a170a05 by Neil Booth Committed by Neil Booth

c.opt: Document more options.

	* c.opt: Document more options.
	* toplev.c (documented_lang_options): Remove all local help strings.
treelang:
	* lang-options.h: Remove.
	* lang.opt: Document some options.  Remove --help.
	* tree1.c (treelang_handle_option): Remove OPT__help case.

From-SVN: r69423
parent bc8229a0
2003-07-15 Neil Booth <neil@daikokuya.co.uk>
* c.opt: Document more options.
* toplev.c (documented_lang_options): Remove all local help strings.
2003-07-15 Mark Mitchell <mark@codesourcery.com> 2003-07-15 Mark Mitchell <mark@codesourcery.com>
PR debug/11473 PR debug/11473
......
...@@ -146,16 +146,19 @@ C++ ObjC++ ...@@ -146,16 +146,19 @@ C++ ObjC++
Wall Wall
C ObjC C++ ObjC++ C ObjC C++ ObjC++
Enable most preprocessor warnings Enable most warning messages
Wbad-function-cast Wbad-function-cast
C ObjC C ObjC
Warn about casting functions to incompatible types
Wcast-qual Wcast-qual
C ObjC C++ ObjC++ C ObjC C++ ObjC++
Warn about casts which discard qualifiers
Wchar-subscripts Wchar-subscripts
C ObjC C++ ObjC++ C ObjC C++ ObjC++
Warn about subscripts whose type is \"char\"
Wcomment Wcomment
C ObjC C++ ObjC++ C ObjC C++ ObjC++
...@@ -167,6 +170,7 @@ Synonym for -Wcomment ...@@ -167,6 +170,7 @@ Synonym for -Wcomment
Wconversion Wconversion
C ObjC C++ ObjC++ C ObjC C++ ObjC++
Warn about possibly confusing type conversions
Wctor-dtor-privacy Wctor-dtor-privacy
C++ ObjC++ C++ ObjC++
...@@ -176,6 +180,7 @@ C++ ObjC++ ...@@ -176,6 +180,7 @@ C++ ObjC++
Wdiv-by-zero Wdiv-by-zero
C ObjC C ObjC
Warn about compile-time integer division by zero
Weffc++ Weffc++
C++ ObjC++ C++ ObjC++
...@@ -190,24 +195,31 @@ C ObjC C++ ObjC++ ...@@ -190,24 +195,31 @@ C ObjC C++ ObjC++
Werror-implicit-function-declaration Werror-implicit-function-declaration
C ObjC RejectNegative C ObjC RejectNegative
Make implicit function declarations an error
Wfloat-equal Wfloat-equal
C ObjC C++ ObjC++ C ObjC C++ ObjC++
Warn if testing floating point numbers for equality
Wformat Wformat
C ObjC C++ ObjC++ C ObjC C++ ObjC++
Warn about printf/scanf/strftime/strfmon format string anomalies
Wformat-extra-args Wformat-extra-args
C ObjC C++ ObjC++ C ObjC C++ ObjC++
Warn if passing too many arguments to a function for its format string
Wformat-nonliteral Wformat-nonliteral
C ObjC C++ ObjC++ C ObjC C++ ObjC++
Warn about format strings that are not literals
Wformat-security Wformat-security
C ObjC C++ ObjC++ C ObjC C++ ObjC++
Warn about possible security problems with format functions
Wformat-y2k Wformat-y2k
C ObjC C++ ObjC++ C ObjC C++ ObjC++
Warn about strftime formats yielding 2-digit years
Wformat-zero-length Wformat-zero-length
C ObjC C ObjC
...@@ -220,43 +232,54 @@ C ObjC C++ ObjC++ ...@@ -220,43 +232,54 @@ C ObjC C++ ObjC++
Wimplicit-function-declaration Wimplicit-function-declaration
C ObjC C ObjC
Warn about implicit function declarations
Wimplicit-int Wimplicit-int
C ObjC C ObjC
Warn when a declaration does not specify a type
Wimport Wimport
C ObjC C++ ObjC++ C ObjC C++ ObjC++
Warn about uses of the #import directive Warn about uses of the \"#import\" directive
Winvalid-offsetof Winvalid-offsetof
C++ ObjC++ C++ ObjC++
Winvalid-pch Winvalid-pch
C ObjC C++ ObjC++ C ObjC C++ ObjC++
Warn about PCH files that are found but not used
Wlong-long Wlong-long
C ObjC C++ ObjC++ C ObjC C++ ObjC++
Do not warn about using \"long long\" when -pedantic
Wmain Wmain
C ObjC C ObjC
Warn about suspicious declarations of \"main\"
Wmissing-braces Wmissing-braces
C ObjC C++ ObjC++ C ObjC C++ ObjC++
Warn about possibly missing braces around initializers
Wmissing-declarations Wmissing-declarations
C ObjC C ObjC
Warn about global functions without previous declarations
Wmissing-format-attribute Wmissing-format-attribute
C ObjC C++ ObjC++ C ObjC C++ ObjC++
Warn about functions which might be candidates for format attributes
Wmissing-prototypes Wmissing-prototypes
C ObjC C ObjC
Warn about global functions without prototypes
Wmultichar Wmultichar
C ObjC C++ ObjC++ C ObjC C++ ObjC++
Warn about use of multi-character character constants
Wnested-externs Wnested-externs
C ObjC C ObjC
Warn about \"extern\" declarations not at file scope
Wnon-template-friend Wnon-template-friend
C++ ObjC++ C++ ObjC++
...@@ -275,39 +298,46 @@ C++ ObjC++ ...@@ -275,39 +298,46 @@ C++ ObjC++
Wparentheses Wparentheses
C ObjC C++ ObjC++ C ObjC C++ ObjC++
Warn about possibly missing parentheses
Wpmf-conversions Wpmf-conversions
C++ ObjC++ C++ ObjC++
Wpointer-arith Wpointer-arith
C ObjC C++ ObjC++ C ObjC C++ ObjC++
Warn about function pointer arithmetic
Wprotocol Wprotocol
ObjC ObjC++ ObjC ObjC++
Wredundant-decls Wredundant-decls
C ObjC C++ ObjC++ C ObjC C++ ObjC++
Warn about multiple declarations of the same object
Wreorder Wreorder
C++ ObjC++ C++ ObjC++
Wreturn-type Wreturn-type
C ObjC C++ ObjC++ C ObjC C++ ObjC++
Warn whenever a function's return type defaults to \"int\"
Wselector Wselector
ObjC ObjC++ ObjC ObjC++
Wsequence-point Wsequence-point
C ObjC C ObjC
Warn about possible violations of sequence point rules
Wsign-compare Wsign-compare
C ObjC C++ ObjC++ C ObjC C++ ObjC++
Warn about signed-unsigned comparisons
Wsign-promo Wsign-promo
C++ ObjC++ C++ ObjC++
Wstrict-prototypes Wstrict-prototypes
C ObjC C ObjC
Warn about unprototyped function declarations
Wsynth Wsynth
C++ ObjC++ C++ ObjC++
...@@ -333,6 +363,7 @@ Warn if an undefined macro is used in an #if directive ...@@ -333,6 +363,7 @@ Warn if an undefined macro is used in an #if directive
Wunknown-pragmas Wunknown-pragmas
C ObjC C++ ObjC++ C ObjC C++ ObjC++
Warn about unrecognized pragmas
Wunused-macros Wunused-macros
C ObjC C++ ObjC++ C ObjC C++ ObjC++
...@@ -340,9 +371,11 @@ Warn about macros defined in the main file that are not used ...@@ -340,9 +371,11 @@ Warn about macros defined in the main file that are not used
Wwrite-strings Wwrite-strings
C ObjC C++ ObjC++ C ObjC C++ ObjC++
Give strings the type \"array of char\"
ansi ansi
C ObjC C++ ObjC++ C ObjC C++ ObjC++
A synonym for -std=c89. In a future version of GCC it will become synonymous with -std=c99 instead
d d
C ObjC C++ ObjC++ Joined C ObjC C++ ObjC++ Joined
...@@ -362,9 +395,11 @@ C++ ObjC++ ...@@ -362,9 +395,11 @@ C++ ObjC++
fasm fasm
C ObjC C++ ObjC++ C ObjC C++ ObjC++
Recognize the \"asm\" keyword
fbuiltin fbuiltin
C ObjC C++ ObjC++ C ObjC C++ ObjC++
Recognize built-in functions
fbuiltin- fbuiltin-
C ObjC C++ ObjC++ Joined C ObjC C++ ObjC++ Joined
...@@ -374,6 +409,7 @@ C++ ObjC++ ...@@ -374,6 +409,7 @@ C++ ObjC++
fcond-mismatch fcond-mismatch
C ObjC C++ ObjC++ C ObjC C++ ObjC++
Allow the arguments of the '?' operator to have different types
fconserve-space fconserve-space
C++ ObjC++ C++ ObjC++
...@@ -421,6 +457,7 @@ C++ ObjC++ ...@@ -421,6 +457,7 @@ C++ ObjC++
ffreestanding ffreestanding
C ObjC C ObjC
Do not assume that standard C libraries and \"main\" exist
fgnu-keywords fgnu-keywords
C++ ObjC++ C++ ObjC++
...@@ -439,6 +476,7 @@ C++ ObjC++ ...@@ -439,6 +476,7 @@ C++ ObjC++
fhosted fhosted
C ObjC C ObjC
Assume normal C execution environment
fhuge-objects fhuge-objects
C++ ObjC++ C++ ObjC++
...@@ -497,21 +535,26 @@ C++ ObjC++ ...@@ -497,21 +535,26 @@ C++ ObjC++
fshort-double fshort-double
C ObjC C++ ObjC++ C ObjC C++ ObjC++
Use the same size for double as for float
fshort-enums fshort-enums
C ObjC C++ ObjC++ C ObjC C++ ObjC++
Use the narrowest integer type possible for enumeration types
fshort-wchar fshort-wchar
C ObjC C++ ObjC++ C ObjC C++ ObjC++
Force the underlying type for \"wchar_t\" to be \"unsigned short\"
fshow-column fshow-column
C ObjC C++ ObjC++ C ObjC C++ ObjC++
fsigned-bitfields fsigned-bitfields
C ObjC C++ ObjC++ C ObjC C++ ObjC++
When \"signed\" or \"unsigned\" is not given make the bitfield signed
fsigned-char fsigned-char
C ObjC C++ ObjC++ C ObjC C++ ObjC++
Make \"char\" signed by default
fsquangle fsquangle
C++ ObjC++ C++ ObjC++
...@@ -534,9 +577,11 @@ C++ ObjC++ ...@@ -534,9 +577,11 @@ C++ ObjC++
funsigned-bitfields funsigned-bitfields
C ObjC C++ ObjC++ C ObjC C++ ObjC++
When \"signed\" or \"unsigned\" is not given make the bitfield unsigned
funsigned-char funsigned-char
C ObjC C++ ObjC++ C ObjC C++ ObjC++
Make \"char\" unsigned by default
fuse-cxa-atexit fuse-cxa-atexit
C++ ObjC++ C++ ObjC++
......
...@@ -1188,172 +1188,6 @@ static const struct lang_opt ...@@ -1188,172 +1188,6 @@ static const struct lang_opt
} }
documented_lang_options[] = documented_lang_options[] =
{ {
/* In order not to overload the --help output, the convention
used here is to only describe those options which are not
enabled by default. */
{ "-ansi",
N_("Compile just for ISO C90") },
{ "-std= ",
N_("Determine language standard") },
{ "-fsigned-bitfields", "" },
{ "-funsigned-bitfields",
N_("Make bit-fields by unsigned by default") },
{ "-fno-signed-bitfields", "" },
{ "-fno-unsigned-bitfields","" },
{ "-fsigned-char",
N_("Make 'char' be signed by default") },
{ "-funsigned-char",
N_("Make 'char' be unsigned by default") },
{ "-fno-signed-char", "" },
{ "-fno-unsigned-char", "" },
{ "-fasm", "" },
{ "-fno-asm",
N_("Do not recognize the 'asm' keyword") },
{ "-fbuiltin", "" },
{ "-fno-builtin",
N_("Do not recognize any built in functions") },
{ "-fhosted",
N_("Assume normal C execution environment") },
{ "-fno-hosted", "" },
{ "-ffreestanding",
N_("Assume that standard libraries & main might not exist") },
{ "-fno-freestanding", "" },
{ "-fcond-mismatch",
N_("Allow different types as args of ? operator") },
{ "-fno-cond-mismatch", "" },
{ "-fdollars-in-identifiers",
N_("Allow the use of $ inside identifiers") },
{ "-fno-dollars-in-identifiers", "" },
{ "-fpreprocessed", "" },
{ "-fno-preprocessed", "" },
{ "-fshort-double",
N_("Use the same size for double as for float") },
{ "-fno-short-double", "" },
{ "-fshort-enums",
N_("Use the smallest fitting integer to hold enums") },
{ "-fno-short-enums", "" },
{ "-fshort-wchar",
N_("Override the underlying type for wchar_t to `unsigned short'") },
{ "-fno-short-wchar", "" },
{ "-Wall",
N_("Enable most warning messages") },
{ "-Wbad-function-cast",
N_("Warn about casting functions to incompatible types") },
{ "-Wno-bad-function-cast", "" },
{ "-Wmissing-format-attribute",
N_("Warn about functions which might be candidates for format attributes") },
{ "-Wno-missing-format-attribute", "" },
{ "-Wcast-qual",
N_("Warn about casts which discard qualifiers") },
{ "-Wno-cast-qual", "" },
{ "-Wchar-subscripts",
N_("Warn about subscripts whose type is 'char'") },
{ "-Wno-char-subscripts", "" },
{ "-Wcomment",
N_("Warn if nested comments are detected") },
{ "-Wno-comment", "" },
{ "-Wcomments",
N_("Warn if nested comments are detected") },
{ "-Wno-comments", "" },
{ "-Wconversion",
N_("Warn about possibly confusing type conversions") },
{ "-Wno-conversion", "" },
{ "-Wdiv-by-zero", "" },
{ "-Wno-div-by-zero",
N_("Do not warn about compile-time integer division by zero") },
{ "-Wfloat-equal",
N_("Warn about testing equality of floating point numbers") },
{ "-Wno-float-equal", "" },
{ "-Wformat",
N_("Warn about printf/scanf/strftime/strfmon format anomalies") },
{ "-Wno-format", "" },
{ "-Wformat-extra-args", "" },
{ "-Wno-format-extra-args",
N_("Don't warn about too many arguments to format functions") },
{ "-Wformat-nonliteral",
N_("Warn about non-string-literal format strings") },
{ "-Wno-format-nonliteral", "" },
{ "-Wformat-security",
N_("Warn about possible security problems with format functions") },
{ "-Wno-format-security", "" },
{ "-Wformat-y2k", "" },
{ "-Wno-format-y2k",
N_("Don't warn about strftime formats yielding 2 digit years") },
{ "-Wimplicit-function-declaration",
N_("Warn about implicit function declarations") },
{ "-Wno-implicit-function-declaration", "" },
{ "-Werror-implicit-function-declaration", "" },
{ "-Wimplicit-int",
N_("Warn when a declaration does not specify a type") },
{ "-Wno-implicit-int", "" },
{ "-Wimplicit", "" },
{ "-Wno-implicit", "" },
{ "-Wimport",
N_("Warn about the use of the #import directive") },
{ "-Wno-import", "" },
{ "-Winvalid-pch",
N_("Warn about PCH files that are found but not used") },
{ "-Wlong-long","" },
{ "-Wno-long-long",
N_("Do not warn about using 'long long' when -pedantic") },
{ "-Wmain",
N_("Warn about suspicious declarations of main") },
{ "-Wno-main", "" },
{ "-Wmissing-braces",
N_("Warn about possibly missing braces around initializers") },
{ "-Wno-missing-braces", "" },
{ "-Wmissing-declarations",
N_("Warn about global funcs without previous declarations") },
{ "-Wno-missing-declarations", "" },
{ "-Wmissing-prototypes",
N_("Warn about global funcs without prototypes") },
{ "-Wno-missing-prototypes", "" },
{ "-Wmultichar",
N_("Warn about use of multicharacter literals") },
{ "-Wno-multichar", "" },
{ "-Wnested-externs",
N_("Warn about externs not at file scope level") },
{ "-Wno-nested-externs", "" },
{ "-Wparentheses",
N_("Warn about possible missing parentheses") },
{ "-Wno-parentheses", "" },
{ "-Wpointer-arith",
N_("Warn about function pointer arithmetic") },
{ "-Wno-pointer-arith", "" },
{ "-Wredundant-decls",
N_("Warn about multiple declarations of the same object") },
{ "-Wno-redundant-decls", "" },
{ "-Wreturn-type",
N_("Warn whenever a function's return-type defaults to int") },
{ "-Wno-return-type", "" },
{ "-Wsequence-point",
N_("Warn about possible violations of sequence point rules") },
{ "-Wno-sequence-point", "" },
{ "-Wsign-compare",
N_("Warn about signed/unsigned comparisons") },
{ "-Wno-sign-compare", "" },
{ "-Wstrict-prototypes",
N_("Warn about non-prototyped function decls") },
{ "-Wno-strict-prototypes", "" },
{ "-Wtraditional",
N_("Warn about constructs whose meanings change in ISO C") },
{ "-Wno-traditional", "" },
{ "-Wtrigraphs",
N_("Warn when trigraphs are encountered") },
{ "-Wno-trigraphs", "" },
{ "-Wundef", "" },
{ "-Wno-undef", "" },
{ "-Wunknown-pragmas",
N_("Warn about unrecognized pragmas") },
{ "-Wno-unknown-pragmas", "" },
{ "-Wwrite-strings",
N_("Mark strings as 'const char *'") },
{ "-Wno-write-strings", "" },
#define DEFINE_LANG_NAME(NAME) { NULL, NAME }, #define DEFINE_LANG_NAME(NAME) { NULL, NAME },
#include "options_.h" #include "options_.h"
......
2003-07-15 Neil Booth <neil@daikokuya.co.uk>
* lang-options.h: Remove.
* lang.opt: Document some options. Remove --help.
* tree1.c (treelang_handle_option): Remove OPT__help case.
2003-07-12 Andreas Jaeger <aj@suse.de> 2003-07-12 Andreas Jaeger <aj@suse.de>
* Make-lang.in (treelang/tree-convert.o): Depend on TM_H. * Make-lang.in (treelang/tree-convert.o): Depend on TM_H.
......
/* Definitions for switches for TREELANG.
Copyright (C) 1995, 96-98, 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
This file is part of GCC.
GCC is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2, or (at your option)
any later version.
GCC is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; see the file COPYING. If not, write to
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
DEFINE_LANG_NAME ("treelang")
/* This is the contribution to the `lang_options' array in gcc.c for
treelang. */
{"-fparser-trace", N_("(debug) trace parsing process")},
{"-flexer-trace", N_("(debug) trace lexical analysis")},
...@@ -25,14 +25,13 @@ ...@@ -25,14 +25,13 @@
Language Language
Treelang Treelang
-help
Treelang
flexer-trace flexer-trace
Treelang Treelang
Trace lexical analysis
fparser-trace fparser-trace
Treelang Treelang
Trace the parsing process
v v
Treelang Treelang
......
...@@ -108,17 +108,6 @@ treelang_handle_option (size_t scode, const char *arg ATTRIBUTE_UNUSED, ...@@ -108,17 +108,6 @@ treelang_handle_option (size_t scode, const char *arg ATTRIBUTE_UNUSED,
default: default:
abort(); abort();
case OPT__help:
if (!version_done)
{
fputs (language_string, stdout);
fputs (version_string, stdout);
fputs ("\n", stdout);
version_done = 1;
}
fprintf (stdout, "Usage: tree1 [switches] -o output input\n");
break;
case OPT_v: case OPT_v:
if (!version_done) if (!version_done)
{ {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment