1BISON(1)                         User Commands                        BISON(1)
2
3
4

NAME

6       bison - GNU Project parser generator (yacc replacement)
7

SYNOPSIS

9       bison [OPTION]... FILE
10

DESCRIPTION

12       Bison  is  a  parser  generator  in the style of yacc(1).  It should be
13       upwardly compatible with input files designed for yacc.
14
15       Input files should follow the yacc convention of ending in .y.   Unlike
16       yacc,  the generated files do not have fixed names, but instead use the
17       prefix of the input file.  Moreover, if you need to put C++ code in the
18       input  file,  you  can  end  his  name by a C++-like extension (.ypp or
19       .y++), then bison will follow your extension to name  the  output  file
20       (.cpp  or  .c++).   For  instance,  a  grammar  description  file named
21       parse.yxx  would  produce  the  generated  parser  in  a   file   named
22       parse.tab.cxx,  instead  of  yacc's  y.tab.c  or  old  Bison  version's
23       parse.tab.c.
24
25       This description of the options that can be given to bison  is  adapted
26       from  the  node Invocation in the bison.texinfo manual, which should be
27       taken as authoritative.
28
29       Bison supports both traditional single-letter options and mnemonic long
30       option  names.   Long  option names are indicated with -- instead of -.
31       Abbreviations for option names are allowed as long as they are  unique.
32       When  a  long option takes an argument, like --file-prefix, connect the
33       option name and the argument with =.
34
35       Generate LALR(1) and GLR parsers.
36
37       Mandatory arguments to long options are  mandatory  for  short  options
38       too.  The same is true for optional arguments.
39
40   Operation modes:
41       -h, --help
42              display this help and exit
43
44       -V, --version
45              output version information and exit
46
47       --print-localedir
48              output directory containing locale-dependent data
49
50       --print-datadir
51              output directory containing skeletons and XSLT
52
53       -y, --yacc
54              emulate POSIX Yacc
55
56       -W, --warnings[=CATEGORY]
57              report the warnings falling in CATEGORY
58
59   Parser:
60       -L, --language=LANGUAGE
61              specify the output programming language (this is an experimental
62              feature)
63
64       -S, --skeleton=FILE
65              specify the skeleton to use
66
67       -t, --debug
68              instrument the parser for debugging
69
70       --locations
71              enable locations computation
72
73       -p, --name-prefix=PREFIX
74              prepend PREFIX to the external symbols
75
76       -l, --no-lines
77              don't generate `#line' directives
78
79       -k, --token-table
80              include a table of token names
81
82   Output:
83       --defines[=FILE]
84              also produce a header file
85
86       -d     likewise but cannot specify FILE (for POSIX Yacc)
87
88       -r, --report=THINGS
89              also produce details on the automaton
90
91       --report-file=FILE
92              write report to FILE
93
94       -v, --verbose
95              same as `--report=state'
96
97       -b, --file-prefix=PREFIX
98              specify a PREFIX for output files
99
100       -o, --output=FILE
101              leave output to FILE
102
103       -g, --graph[=FILE]
104              also output a graph of the automaton
105
106       -x, --xml[=FILE]
107              also output an XML report of the automaton (the  XML  schema  is
108              experimental)
109
110   Warning categories include:
111       `midrule-values'
112              unset or unused midrule values
113
114       `yacc' incompatibilities with POSIX YACC
115
116       `all'  all the warnings
117
118       `no-CATEGORY'
119              turn off warnings in CATEGORY
120
121       `none' turn off all the warnings
122
123       `error'
124              treat warnings as errors
125
126   THINGS is a list of comma separated words that can include:
127       `state'
128              describe the states
129
130       `itemset'
131              complete the core item sets with their closure
132
133       `lookahead'
134              explicitly associate lookahead tokens to items
135
136       `solved'
137              describe shift/reduce conflicts solving
138
139       `all'  include all the above information
140
141       `none' disable the report
142

AUTHOR

144       Written by Robert Corbett and Richard Stallman.
145

REPORTING BUGS

147       Report bugs to <bug-bison@gnu.org>.
148
150       Copyright © 2010 Free Software Foundation, Inc.
151       This is free software; see the source for copying conditions.  There is
152       NO warranty; not even for MERCHANTABILITY or FITNESS FOR  A  PARTICULAR
153       PURPOSE.
154

SEE ALSO

156       lex(1), flex(1), yacc(1).
157
158       The full documentation for bison is maintained as a Texinfo manual.  If
159       the info and bison programs are properly installed at  your  site,  the
160       command
161
162              info bison
163
164       should give you access to the complete manual.
165
166
167
168bison 2.4.3                       August 2010                         BISON(1)
Impressum