* Precedence Decl:: Declaring terminals with precedence and associativity.
* Union Decl:: Declaring the set of all semantic value types.
* Type Decl:: Declaring the choice of type for a nonterminal symbol.
+* Initial Action Decl:: Code run before parsing starts.
* Destructor Decl:: Declaring how symbols are freed.
* Expect Decl:: Suppressing warnings about parsing conflicts.
* Start Decl:: Specifying the start symbol.
* How Can I Reset the Parser:: @code{yyparse} Keeps some State
* Strings are Destroyed:: @code{yylval} Loses Track of Strings
* C++ Parsers:: Compiling Parsers with C++ Compilers
-* Implementing Loops:: Control Flow in the Calculator
+* Implementing Gotos/Loops:: Control Flow in the Calculator
Copying This Manual
value of @samp{a} from the outer scope. So this approach cannot
work.
-A simple solution to this problem is to declare the parser to
+A simple solution to this problem is to declare the parser to
use the @acronym{GLR} algorithm.
When the @acronym{GLR} parser reaches the critical state, it
merely splits into two branches and pursues both syntax rules
The parser can be turned into a @acronym{GLR} parser, while also telling Bison
to be silent about the one known reduce/reduce conflict, by
-adding these two declarations to the Bison input file (before the first
+adding these two declarations to the Bison input file (before the first
@samp{%%}):
@example
intended. A @acronym{GLR} parser splitting inadvertently may cause
problems less obvious than an @acronym{LALR} parser statically choosing the
wrong alternative in a conflict.
-Second, consider interactions with the lexer (@pxref{Semantic Tokens})
+Second, consider interactions with the lexer (@pxref{Semantic Tokens})
with great care. Since a split parser consumes tokens
without performing any actions during the split, the lexer cannot
obtain information via parser actions. Some cases of
@samp{x} as an @code{ID}).
Bison detects this as a reduce/reduce conflict between the rules
@code{expr : ID} and @code{declarator : ID}, which it cannot resolve at the
-time it encounters @code{x} in the example above. Since this is a
-@acronym{GLR} parser, it therefore splits the problem into two parses, one for
+time it encounters @code{x} in the example above. Since this is a
+@acronym{GLR} parser, it therefore splits the problem into two parses, one for
each choice of resolving the reduce/reduce conflict.
Unlike the example from the previous section (@pxref{Simple GLR Parsers}),
however, neither of these parses ``dies,'' because the grammar as it stands is
-ambiguous. One of the parsers eventually reduces @code{stmt : expr ';'} and
-the other reduces @code{stmt : decl}, after which both parsers are in an
-identical state: they've seen @samp{prog stmt} and have the same unprocessed
-input remaining. We say that these parses have @dfn{merged.}
+ambiguous. One of the parsers eventually reduces @code{stmt : expr ';'} and
+the other reduces @code{stmt : decl}, after which both parsers are in an
+identical state: they've seen @samp{prog stmt} and have the same unprocessed
+input remaining. We say that these parses have @dfn{merged.}
At this point, the @acronym{GLR} parser requires a specification in the
grammar of how to choose between the competing parses.
In the example above, the two @code{%dprec}
-declarations specify that Bison is to give precedence
+declarations specify that Bison is to give precedence
to the parse that interprets the example as a
@code{decl}, which implies that @code{x} is a declarator.
The parser therefore prints
@end example
@noindent
-This is another example of using @acronym{GLR} to parse an unambiguous
+This is another example of using @acronym{GLR} to parse an unambiguous
construct, as shown in the previous section (@pxref{Simple GLR Parsers}).
Here, there is no ambiguity (this cannot be parsed as a declaration).
However, at the time the Bison parser encounters @code{x}, it does not
@end example
Bison requires that all of the
-productions that participate in any particular merge have identical
+productions that participate in any particular merge have identical
@samp{%merge} clauses. Otherwise, the ambiguity would be unresolvable,
and the parser will report an error during any parse that results in
the offending merge.
* Precedence Decl:: Declaring terminals with precedence and associativity.
* Union Decl:: Declaring the set of all semantic value types.
* Type Decl:: Declaring the choice of type for a nonterminal symbol.
+* Initial Action Decl:: Code run before parsing starts.
* Destructor Decl:: Declaring how symbols are freed.
* Expect Decl:: Suppressing warnings about parsing conflicts.
* Start Decl:: Specifying the start symbol.
terminal symbol. All kinds of token declarations allow
@code{<@var{type}>}.
+@node Initial Action Decl
+@subsection Performing Actions before Parsing
+@findex %initial-action
+
+Sometimes your parser needs to perform some initializations before
+parsing. The @code{%initial-action} directive allows for such arbitrary
+code.
+
+@deffn {Directive} %initial-action @{ @var{code} @}
+@findex %initial-action
+Declare that the @var{code} must be invoked before parsing each time
+@code{yyparse} is called. The @var{code} may use @code{$$} and
+@code{@@$} --- initial value and location of the look-ahead --- and the
+@code{%parse-param}.
+@end deffn
+
+For instance, if your locations use a file name, you may use
+
+@example
+%parse-param @{ const char *filename @};
+%initial-action
+@{
+ @@$.begin.filename = @@$.end.filename = filename;
+@};
+@end example
+
+
@node Destructor Decl
@subsection Freeing Discarded Symbols
@cindex freeing discarded symbols
@findex %destructor
-Some symbols can be discarded by the parser, typically during error
-recovery (@pxref{Error Recovery}). Basically, during error recovery,
-embarrassing symbols already pushed on the stack, and embarrassing
-tokens coming from the rest of the file are thrown away until the parser
-falls on its feet. If these symbols convey heap based information, this
-memory is lost. While this behavior is tolerable for batch parsers,
-such as in compilers, it is unacceptable for parsers that can
-possibility ``never end'' such as shells, or implementations of
+Some symbols can be discarded by the parser. For instance, during error
+recovery (@pxref{Error Recovery}), embarrassing symbols already pushed
+on the stack, and embarrassing tokens coming from the rest of the file
+are thrown away until the parser falls on its feet. If these symbols
+convey heap based information, this memory is lost. While this behavior
+can be tolerable for batch parsers, such as in compilers, it is not for
+possibly ``never ending'' parsers such as shells, or implementations of
communication protocols.
The @code{%destructor} directive allows for the definition of code that
typefull: string; // $$ = $1 applies, $1 is not destroyed.
@end smallexample
+@sp 1
+
+@cindex discarded symbols
+@dfn{Discarded symbols} are the following:
+
+@itemize
+@item
+stacked symbols popped during the first phase of error recovery,
+@item
+incoming terminals during the second phase of error recovery,
+@item
+the current look-ahead when the parser aborts (either via an explicit
+call to @code{YYABORT}, or as a consequence of a failed error recovery).
+@end itemize
+
+
@node Expect Decl
@subsection Suppressing Conflict Warnings
@cindex suppressing conflict warnings
@c FIXME: C++ output.
Because of semantical differences between C and C++, the
-@acronym{LALR}(1) parsers
-in C produced by Bison by compiled as C++ cannot grow. In this precise
-case (compiling a C parser as C++) you are suggested to grow
-@code{YYINITDEPTH}. In the near future, a C++ output output will be
-provided which addresses this issue.
+@acronym{LALR}(1) parsers in C produced by Bison by compiled as C++
+cannot grow. In this precise case (compiling a C parser as C++) you are
+suggested to grow @code{YYINITDEPTH}. In the near future, a C++ output
+output will be provided which addresses this issue.
@node Error Recovery
@chapter Error Recovery
* How Can I Reset the Parser:: @code{yyparse} Keeps some State
* Strings are Destroyed:: @code{yylval} Loses Track of Strings
* C++ Parsers:: Compiling Parsers with C++ Compilers
-* Implementing Loops:: Control Flow in the Calculator
+* Implementing Gotos/Loops:: Control Flow in the Calculator
@end menu
@node Parser Stack Overflow
How can I generate parsers in C++?
@end display
-We are working on a C++ output for Bison, but unfortunately, for lack
-of time, the skeleton is not finished. It is functional, but in
-numerous respects, it will require additional work which @emph{might}
-break backward compatibility. Since the skeleton for C++ is not
-documented, we do not consider ourselves bound to this interface,
-nevertheless, as much as possible we will try to keep compatibility.
+We are working on a C++ output for Bison, but unfortunately, for lack of
+time, the skeleton is not finished. It is functional, but in numerous
+respects, it will require additional work which @emph{might} break
+backward compatibility. Since the skeleton for C++ is not documented,
+we do not consider ourselves bound to this interface, nevertheless, as
+much as possible we will try to keep compatibility.
-Another possibility is to use the regular C parsers, and to compile
-them with a C++ compiler. This works properly, provided that you bear
-some simple C++ rules in mind, such as not including ``real classes''
-(i.e., structure with constructors) in unions. Therefore, in the
-@code{%union}, use pointers to classes, or better yet, a single
-pointer type to the root of your lexical/syntactic hierarchy.
+Another possibility is to use the regular C parsers, and to compile them
+with a C++ compiler. This works properly, provided that you bear some
+simple C++ rules in mind, such as not including ``real classes'' (i.e.,
+structure with constructors) in unions. Therefore, in the
+@code{%union}, use pointers to classes.
-@node Implementing Loops
-@section Implementing Loops
+@node Implementing Gotos/Loops
+@section Implementing Gotos/Loops
@display
My simple calculator supports variables, assignments, and functions,
-but how can I implement loops?
+but how can I implement gotos, or loops?
@end display
Although very pedagogical, the examples included in the document blur
right-hand side of the rule. @xref{Actions}.
@end deffn
-@deffn {Symbol} $accept
-The predefined nonterminal whose only rule is @samp{$accept: @var{start}
-$end}, where @var{start} is the start symbol. @xref{Start Decl, , The
-Start-Symbol}. It cannot be used in the grammar.
-@end deffn
-
-@deffn {Symbol} $end
-The predefined token marking the end of the token stream. It cannot be
-used in the grammar.
-@end deffn
-
-@deffn {Symbol} $undefined
-The predefined token onto which all undefined values returned by
-@code{yylex} are mapped. It cannot be used in the grammar, rather, use
-@code{error}.
-@end deffn
-
-@deffn {Symbol} error
-A token name reserved for error recovery. This token may be used in
-grammar rules so as to allow the Bison parser to recognize an error in
-the grammar without halting the process. In effect, a sentence
-containing an error may be recognized as valid. On a syntax error, the
-token @code{error} becomes the current look-ahead token. Actions
-corresponding to @code{error} are then executed, and the look-ahead
-token is reset to the token that originally caused the violation.
-@xref{Error Recovery}.
-@end deffn
-
-@deffn {Macro} YYABORT
-Macro to pretend that an unrecoverable syntax error has occurred, by
-making @code{yyparse} return 1 immediately. The error reporting
-function @code{yyerror} is not called. @xref{Parser Function, ,The
-Parser Function @code{yyparse}}.
-@end deffn
-
-@deffn {Macro} YYACCEPT
-Macro to pretend that a complete utterance of the language has been
-read, by making @code{yyparse} return 0 immediately.
-@xref{Parser Function, ,The Parser Function @code{yyparse}}.
-@end deffn
-
-@deffn {Macro} YYBACKUP
-Macro to discard a value from the parser stack and fake a look-ahead
-token. @xref{Action Features, ,Special Features for Use in Actions}.
-@end deffn
-
-@deffn {Macro} YYDEBUG
-Macro to define to equip the parser with tracing code. @xref{Tracing,
-,Tracing Your Parser}.
-@end deffn
-
-@deffn {Macro} YYERROR
-Macro to pretend that a syntax error has just been detected: call
-@code{yyerror} and then perform normal error recovery if possible
-(@pxref{Error Recovery}), or (if recovery is impossible) make
-@code{yyparse} return 1. @xref{Error Recovery}.
-@end deffn
-
-@deffn {Macro} YYERROR_VERBOSE
-An obsolete macro that you define with @code{#define} in the prologue
-to request verbose, specific error message strings
-when @code{yyerror} is called. It doesn't matter what definition you
-use for @code{YYERROR_VERBOSE}, just whether you define it. Using
-@code{%error-verbose} is preferred.
-@end deffn
-
-@deffn {Macro} YYINITDEPTH
-Macro for specifying the initial size of the parser stack.
-@xref{Stack Overflow}.
-@end deffn
-
-@deffn {Macro} YYLEX_PARAM
-An obsolete macro for specifying an extra argument (or list of extra
-arguments) for @code{yyparse} to pass to @code{yylex}. he use of this
-macro is deprecated, and is supported only for Yacc like parsers.
-@xref{Pure Calling,, Calling Conventions for Pure Parsers}.
-@end deffn
-
-@deffn {Type} YYLTYPE
-Data type of @code{yylloc}; by default, a structure with four
-members. @xref{Location Type, , Data Types of Locations}.
-@end deffn
-
-@deffn {Macro} YYMAXDEPTH
-Macro for specifying the maximum size of the parser stack. @xref{Stack
-Overflow}.
-@end deffn
-
-@deffn {Macro} YYPARSE_PARAM
-An obsolete macro for specifying the name of a parameter that
-@code{yyparse} should accept. The use of this macro is deprecated, and
-is supported only for Yacc like parsers. @xref{Pure Calling,, Calling
-Conventions for Pure Parsers}.
-@end deffn
-
-@deffn {Macro} YYRECOVERING
-Macro whose value indicates whether the parser is recovering from a
-syntax error. @xref{Action Features, ,Special Features for Use in Actions}.
-@end deffn
-
-@deffn {Macro} YYSTACK_USE_ALLOCA
-Macro used to control the use of @code{alloca}. If defined to @samp{0},
-the parser will not use @code{alloca} but @code{malloc} when trying to
-grow its internal stacks. Do @emph{not} define @code{YYSTACK_USE_ALLOCA}
-to anything else.
-@end deffn
-
-@deffn {Type} YYSTYPE
-Data type of semantic values; @code{int} by default.
-@xref{Value Type, ,Data Types of Semantic Values}.
-@end deffn
-
-@deffn {Variable} yychar
-External integer variable that contains the integer value of the current
-look-ahead token. (In a pure parser, it is a local variable within
-@code{yyparse}.) Error-recovery rule actions may examine this variable.
-@xref{Action Features, ,Special Features for Use in Actions}.
-@end deffn
-
-@deffn {Variable} yyclearin
-Macro used in error-recovery rule actions. It clears the previous
-look-ahead token. @xref{Error Recovery}.
-@end deffn
-
-@deffn {Variable} yydebug
-External integer variable set to zero by default. If @code{yydebug}
-is given a nonzero value, the parser will output information on input
-symbols and parser action. @xref{Tracing, ,Tracing Your Parser}.
-@end deffn
-
-@deffn {Macro} yyerrok
-Macro to cause parser to recover immediately to its normal mode
-after a syntax error. @xref{Error Recovery}.
+@deffn {Delimiter} %%
+Delimiter used to separate the grammar rule section from the
+Bison declarations section or the epilogue.
+@xref{Grammar Layout, ,The Overall Layout of a Bison Grammar}.
@end deffn
-@deffn {Function} yyerror
-User-supplied function to be called by @code{yyparse} on error.
-@xref{Error Reporting, ,The Error
-Reporting Function @code{yyerror}}.
+@c Don't insert spaces, or check the DVI output.
+@deffn {Delimiter} %@{@var{code}%@}
+All code listed between @samp{%@{} and @samp{%@}} is copied directly to
+the output file uninterpreted. Such code forms the prologue of the input
+file. @xref{Grammar Outline, ,Outline of a Bison
+Grammar}.
@end deffn
-@deffn {Function} yylex
-User-supplied lexical analyzer function, called with no arguments to get
-the next token. @xref{Lexical, ,The Lexical Analyzer Function
-@code{yylex}}.
+@deffn {Construct} /*@dots{}*/
+Comment delimiters, as in C.
@end deffn
-@deffn {Variable} yylval
-External variable in which @code{yylex} should place the semantic
-value associated with a token. (In a pure parser, it is a local
-variable within @code{yyparse}, and its address is passed to
-@code{yylex}.) @xref{Token Values, ,Semantic Values of Tokens}.
+@deffn {Delimiter} :
+Separates a rule's result from its components. @xref{Rules, ,Syntax of
+Grammar Rules}.
@end deffn
-@deffn {Variable} yylloc
-External variable in which @code{yylex} should place the line and column
-numbers associated with a token. (In a pure parser, it is a local
-variable within @code{yyparse}, and its address is passed to
-@code{yylex}.) You can ignore this variable if you don't use the
-@samp{@@} feature in the grammar actions. @xref{Token Locations,
-,Textual Locations of Tokens}.
+@deffn {Delimiter} ;
+Terminates a rule. @xref{Rules, ,Syntax of Grammar Rules}.
@end deffn
-@deffn {Variable} yynerrs
-Global variable which Bison increments each time there is a syntax error.
-(In a pure parser, it is a local variable within @code{yyparse}.)
-@xref{Error Reporting, ,The Error Reporting Function @code{yyerror}}.
+@deffn {Delimiter} |
+Separates alternate rules for the same result nonterminal.
+@xref{Rules, ,Syntax of Grammar Rules}.
@end deffn
-@deffn {Function} yyparse
-The parser function produced by Bison; call this function to start
-parsing. @xref{Parser Function, ,The Parser Function @code{yyparse}}.
+@deffn {Symbol} $accept
+The predefined nonterminal whose only rule is @samp{$accept: @var{start}
+$end}, where @var{start} is the start symbol. @xref{Start Decl, , The
+Start-Symbol}. It cannot be used in the grammar.
@end deffn
@deffn {Directive} %debug
@acronym{GLR} Parsers}.
@end deffn
+@deffn {Symbol} $end
+The predefined token marking the end of the token stream. It cannot be
+used in the grammar.
+@end deffn
+
+@deffn {Symbol} error
+A token name reserved for error recovery. This token may be used in
+grammar rules so as to allow the Bison parser to recognize an error in
+the grammar without halting the process. In effect, a sentence
+containing an error may be recognized as valid. On a syntax error, the
+token @code{error} becomes the current look-ahead token. Actions
+corresponding to @code{error} are then executed, and the look-ahead
+token is reset to the token that originally caused the violation.
+@xref{Error Recovery}.
+@end deffn
+
@deffn {Directive} %error-verbose
Bison declaration to request verbose, specific error message strings
when @code{yyerror} is called.
Parsers, ,Writing @acronym{GLR} Parsers}.
@end deffn
+@deffn {Directive} %initial-action
+Run user code before parsing. @xref{Initial Action Decl, , Performing Actions before Parsing}.
+@end deffn
+
@deffn {Directive} %left
Bison declaration to assign left associativity to token(s).
@xref{Precedence Decl, ,Operator Precedence}.
,Nonterminal Symbols}.
@end deffn
+@deffn {Symbol} $undefined
+The predefined token onto which all undefined values returned by
+@code{yylex} are mapped. It cannot be used in the grammar, rather, use
+@code{error}.
+@end deffn
+
@deffn {Directive} %union
Bison declaration to specify several possible data types for semantic
values. @xref{Union Decl, ,The Collection of Value Types}.
@end deffn
-@sp 1
+@deffn {Macro} YYABORT
+Macro to pretend that an unrecoverable syntax error has occurred, by
+making @code{yyparse} return 1 immediately. The error reporting
+function @code{yyerror} is not called. @xref{Parser Function, ,The
+Parser Function @code{yyparse}}.
+@end deffn
-These are the punctuation and delimiters used in Bison input:
+@deffn {Macro} YYACCEPT
+Macro to pretend that a complete utterance of the language has been
+read, by making @code{yyparse} return 0 immediately.
+@xref{Parser Function, ,The Parser Function @code{yyparse}}.
+@end deffn
-@deffn {Delimiter} %%
-Delimiter used to separate the grammar rule section from the
-Bison declarations section or the epilogue.
-@xref{Grammar Layout, ,The Overall Layout of a Bison Grammar}.
+@deffn {Macro} YYBACKUP
+Macro to discard a value from the parser stack and fake a look-ahead
+token. @xref{Action Features, ,Special Features for Use in Actions}.
@end deffn
-@c Don't insert spaces, or check the DVI output.
-@deffn {Delimiter} %@{@var{code}%@}
-All code listed between @samp{%@{} and @samp{%@}} is copied directly to
-the output file uninterpreted. Such code forms the prologue of the input
-file. @xref{Grammar Outline, ,Outline of a Bison
-Grammar}.
+@deffn {Variable} yychar
+External integer variable that contains the integer value of the current
+look-ahead token. (In a pure parser, it is a local variable within
+@code{yyparse}.) Error-recovery rule actions may examine this variable.
+@xref{Action Features, ,Special Features for Use in Actions}.
@end deffn
-@deffn {Construct} /*@dots{}*/
-Comment delimiters, as in C.
+@deffn {Variable} yyclearin
+Macro used in error-recovery rule actions. It clears the previous
+look-ahead token. @xref{Error Recovery}.
@end deffn
-@deffn {Delimiter} :
-Separates a rule's result from its components. @xref{Rules, ,Syntax of
-Grammar Rules}.
+@deffn {Macro} YYDEBUG
+Macro to define to equip the parser with tracing code. @xref{Tracing,
+,Tracing Your Parser}.
@end deffn
-@deffn {Delimiter} ;
-Terminates a rule. @xref{Rules, ,Syntax of Grammar Rules}.
+@deffn {Variable} yydebug
+External integer variable set to zero by default. If @code{yydebug}
+is given a nonzero value, the parser will output information on input
+symbols and parser action. @xref{Tracing, ,Tracing Your Parser}.
@end deffn
-@deffn {Delimiter} |
-Separates alternate rules for the same result nonterminal.
-@xref{Rules, ,Syntax of Grammar Rules}.
+@deffn {Macro} yyerrok
+Macro to cause parser to recover immediately to its normal mode
+after a syntax error. @xref{Error Recovery}.
+@end deffn
+
+@deffn {Macro} YYERROR
+Macro to pretend that a syntax error has just been detected: call
+@code{yyerror} and then perform normal error recovery if possible
+(@pxref{Error Recovery}), or (if recovery is impossible) make
+@code{yyparse} return 1. @xref{Error Recovery}.
+@end deffn
+
+@deffn {Function} yyerror
+User-supplied function to be called by @code{yyparse} on error.
+@xref{Error Reporting, ,The Error
+Reporting Function @code{yyerror}}.
+@end deffn
+
+@deffn {Macro} YYERROR_VERBOSE
+An obsolete macro that you define with @code{#define} in the prologue
+to request verbose, specific error message strings
+when @code{yyerror} is called. It doesn't matter what definition you
+use for @code{YYERROR_VERBOSE}, just whether you define it. Using
+@code{%error-verbose} is preferred.
+@end deffn
+
+@deffn {Macro} YYINITDEPTH
+Macro for specifying the initial size of the parser stack.
+@xref{Stack Overflow}.
+@end deffn
+
+@deffn {Function} yylex
+User-supplied lexical analyzer function, called with no arguments to get
+the next token. @xref{Lexical, ,The Lexical Analyzer Function
+@code{yylex}}.
+@end deffn
+
+@deffn {Macro} YYLEX_PARAM
+An obsolete macro for specifying an extra argument (or list of extra
+arguments) for @code{yyparse} to pass to @code{yylex}. he use of this
+macro is deprecated, and is supported only for Yacc like parsers.
+@xref{Pure Calling,, Calling Conventions for Pure Parsers}.
+@end deffn
+
+@deffn {Variable} yylloc
+External variable in which @code{yylex} should place the line and column
+numbers associated with a token. (In a pure parser, it is a local
+variable within @code{yyparse}, and its address is passed to
+@code{yylex}.) You can ignore this variable if you don't use the
+@samp{@@} feature in the grammar actions. @xref{Token Locations,
+,Textual Locations of Tokens}.
+@end deffn
+
+@deffn {Type} YYLTYPE
+Data type of @code{yylloc}; by default, a structure with four
+members. @xref{Location Type, , Data Types of Locations}.
+@end deffn
+
+@deffn {Variable} yylval
+External variable in which @code{yylex} should place the semantic
+value associated with a token. (In a pure parser, it is a local
+variable within @code{yyparse}, and its address is passed to
+@code{yylex}.) @xref{Token Values, ,Semantic Values of Tokens}.
+@end deffn
+
+@deffn {Macro} YYMAXDEPTH
+Macro for specifying the maximum size of the parser stack. @xref{Stack
+Overflow}.
+@end deffn
+
+@deffn {Variable} yynerrs
+Global variable which Bison increments each time there is a syntax error.
+(In a pure parser, it is a local variable within @code{yyparse}.)
+@xref{Error Reporting, ,The Error Reporting Function @code{yyerror}}.
+@end deffn
+
+@deffn {Function} yyparse
+The parser function produced by Bison; call this function to start
+parsing. @xref{Parser Function, ,The Parser Function @code{yyparse}}.
+@end deffn
+
+@deffn {Macro} YYPARSE_PARAM
+An obsolete macro for specifying the name of a parameter that
+@code{yyparse} should accept. The use of this macro is deprecated, and
+is supported only for Yacc like parsers. @xref{Pure Calling,, Calling
+Conventions for Pure Parsers}.
+@end deffn
+
+@deffn {Macro} YYRECOVERING
+Macro whose value indicates whether the parser is recovering from a
+syntax error. @xref{Action Features, ,Special Features for Use in Actions}.
+@end deffn
+
+@deffn {Macro} YYSTACK_USE_ALLOCA
+Macro used to control the use of @code{alloca}. If defined to @samp{0},
+the parser will not use @code{alloca} but @code{malloc} when trying to
+grow its internal stacks. Do @emph{not} define @code{YYSTACK_USE_ALLOCA}
+to anything else.
+@end deffn
+
+@deffn {Type} YYSTYPE
+Data type of semantic values; @code{int} by default.
+@xref{Value Type, ,Data Types of Semantic Values}.
@end deffn
@node Glossary