X-Git-Url: https://git.saurik.com/bison.git/blobdiff_plain/9edcd89542cbc475e2e17606166ca7e0d541917a..7215de245c9b1ebb91efb16c91ff21e5f983f6d2:/doc/bison.texinfo?ds=sidebyside diff --git a/doc/bison.texinfo b/doc/bison.texinfo index bf0f790b..36557012 100644 --- a/doc/bison.texinfo +++ b/doc/bison.texinfo @@ -693,7 +693,7 @@ arrange for it to call @code{yyparse} or the parser will never run. @xref{Interface, ,Parser C-Language Interface}. Aside from the token type names and the symbols in the actions you -write, all variable and function names used in the Bison parser file +write, all symbols defined in the Bison parser file itself begin with @samp{yy} or @samp{YY}. This includes interface functions such as the lexical analyzer function @code{yylex}, the error reporting function @code{yyerror} and the parser function @code{yyparse} itself. @@ -702,6 +702,14 @@ Therefore, you should avoid using C identifiers starting with @samp{yy} or @samp{YY} in the Bison grammar file except for the ones defined in this manual. +In some cases the Bison parser file includes system headers, and in +those cases your code should respect the identifiers reserved by those +headers. On some non-@sc{gnu} hosts, @code{}, +@code{}, and @code{} are included as needed to +declare memory allocators and related types. On all hosts, +@code{} is included if you define @code{YYDEBUG} +(@pxref{Debugging, ,Debugging Your Parser}). + @node Stages @section Stages in Using Bison @cindex stages in using Bison