(bison.info)C Code

Prev: Grammar Rules Up: Grammar Outline

The Additional C Code Section

   The ADDITIONAL C CODE section is copied verbatim to the end of the
parser file, just as the C DECLARATIONS section is copied to the
beginning.  This is the most convenient place to put anything that you
want to have in the parser file but which need not come before the
definition of `yyparse'.  For example, the definitions of `yylex' and
`yyerror' often go here.  Note: Parser C-Language Interface.

   If the last section is empty, you may omit the `%%' that separates it
from the grammar rules.

   The Bison parser itself contains many static variables whose names
start with `yy' and many macros whose names start with `YY'.  It is a
good idea to avoid using any such names (except those documented in this
manual) in the additional C code section of the grammar file.

automatically generated by info2www