From: John Millaway Date: Thu, 5 Sep 2002 10:54:29 +0000 (+0000) Subject: Changed option 'header' to 'header-file'. 'header' still works, though. X-Git-Tag: flex-2-5-19~8 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=56a530abf7e16ce35ea36748ff2e86f2f0022bc2;p=flex Changed option 'header' to 'header-file'. 'header' still works, though. --- diff --git a/flex.texi b/flex.texi index e84ef40..81c7e28 100644 --- a/flex.texi +++ b/flex.texi @@ -2404,7 +2404,7 @@ generates a ``help'' summary of @code{flex}'s options to @file{stdout} and then exits. @anchor{option-header} -@item --header=FILE, @code{%option header="FILE"} +@item --header-file=FILE, @code{%option header-file="FILE"} instructs flex to write a C header to @file{FILE}. This file contains function prototypes, extern variables, and types used by the scanner. Only the external API is exported by the header file. Many macros that @@ -2415,7 +2415,7 @@ external API. While in the header, the macro @code{yyIN_HEADER} is defined, where @samp{yy} is substituted with the appropriate prefix. -The @samp{--header} option is not compatible with the @samp{--c++} option, +The @samp{--header-file} option is not compatible with the @samp{--c++} option, since the C++ scanner provides its own header in @file{yyFlexLexer.h}. @anchor{option-case-insensitive} @@ -3887,7 +3887,7 @@ The above code may be called from within an action like this: @end verbatim @end example -You may find that @code{%option header} is particularly useful for generating +You may find that @code{%option header-file} is particularly useful for generating prototypes of all the accessor functions. @xref{option-header}. @node Extra Data diff --git a/main.c b/main.c index 7ec512f..f248af5 100644 --- a/main.c +++ b/main.c @@ -1301,7 +1301,7 @@ void flexinit (argc, argv) useecs = false; break; - case OPT_HEADER: + case OPT_HEADER_FILE: headerfilename = arg; break; @@ -1864,8 +1864,8 @@ void usage () " -S, --skel=FILE specify skeleton file\n" " -t, --stdout write scanner on stdout instead of %s\n" " --yyclass=NAME name of C++ class\n" - " --header=FILE create a C header file in addition to the scanner\n" - " --tables-file[=FILE] write tables to FILE\n" "\n" + " --header-file=FILE create a C header file in addition to the scanner\n" + " --tables-file[=FILE] write tables to FILE\n" "\n" "Scanner behavior:\n" " -7, --7bit generate 7-bit scanner\n" " -8, --8bit generate 8-bit scanner\n" diff --git a/options.c b/options.c index f9515ea..b62259e 100644 --- a/options.c +++ b/options.c @@ -105,7 +105,7 @@ optspec_t flexopts[] = { , {"--full", OPT_FULL, 0} , /* Same as -Cfr. */ - {"--header[=FILE]", OPT_HEADER, 0} + {"--header-file[=FILE]", OPT_HEADER_FILE, 0} , {"-?", OPT_HELP, 0} , diff --git a/options.h b/options.h index 51b13e5..a1cff98 100644 --- a/options.h +++ b/options.h @@ -56,7 +56,7 @@ enum flexopt_flag_t { OPT_ECS, OPT_FAST, OPT_FULL, - OPT_HEADER, + OPT_HEADER_FILE, OPT_HELP, OPT_INTERACTIVE, OPT_LEX_COMPAT,