mirror of
https://git.savannah.gnu.org/git/bison.git
synced 2026-03-14 14:53:03 +00:00
* doc/bison.texinfo: Update.
* doc/bison.1 (mandoc): Update. * src/system.h (EXT_GUARD_C, EXT_STYPE_H): Remove .c and .h. * src/files.c: Support output files extensions computing. (src_extension): New static variable. (header_extension): New static variable. (tr): New function. (get_extension_index): New function, gets the index of an extension filename in a string. (compute_exts_from_gf): New function, computes extensions from the grammar file extension. (compute_exts_from_src): New functions, computes extensions from the C source file extension, file given by ``-o'' option. (compute_base_names): Update. (output_files): Update.
This commit is contained in:
15
doc/bison.1
15
doc/bison.1
@@ -71,13 +71,22 @@ Unlike
|
||||
.IR yacc ,
|
||||
the generated files do not have fixed names, but instead use the prefix
|
||||
of the input file.
|
||||
Moreover, if you need to put
|
||||
.IR C++
|
||||
code in the input file, you can end his name by a C++-like extension
|
||||
(.ypp or .y++), then bison will follow your extension to name the
|
||||
output file (.cpp or .c++).
|
||||
For instance, a grammar description file named
|
||||
.B parse.y
|
||||
.B parse.yxx
|
||||
would produce the generated parser in a file named
|
||||
.BR parse.tab.c ,
|
||||
.BR parse.tab.cxx ,
|
||||
instead of
|
||||
.IR yacc 's
|
||||
.BR y.tab.c .
|
||||
.BR y.tab.c
|
||||
or old
|
||||
.IR Bison
|
||||
versions
|
||||
.BR parse.tab.c .
|
||||
.PP
|
||||
This description of the options that can be given to
|
||||
.I bison
|
||||
|
||||
Reference in New Issue
Block a user