OSSP CVS Repository

ossp - Check-in [2793]
Not logged in
[Honeypot]  [Browse]  [Home]  [Login]  [Reports
[Search]  [Ticket]  [Timeline
  [Patchset]  [Tagging/Branching

Check-in Number: 2793
Date: 2002-Nov-09 15:28:38 (local)
2002-Nov-09 14:28:38 (UTC)
User:rse
Branch:
Comment: upgrade documentation set
Tickets:
Inspections:
Files:
ossp-adm/autotools/bison.html      1.1 -> 1.2     2174 inserted, 1095 deleted
ossp-adm/autotools/bison_toc.html      added-> 1.1
ossp-adm/autotools/flex.html      1.1 -> 1.2     5657 inserted, 2645 deleted
ossp-adm/autotools/flex_toc.html      added-> 1.1

ossp-adm/autotools/bison.html 1.1 -> 1.2

--- bison.html   2002/07/10 08:46:24     1.1
+++ bison.html   2002/11/09 14:28:38     1.2
@@ -1,13 +1,13 @@
 <HTML>
 <HEAD>
-<!-- Created by texi2html 1.56k from bison.texinfo on 4 November 2001 -->
+<!-- Created by texi2html 1.56k from bison.texinfo on 9 November 2002 -->
 
-<TITLE>Bison 1.30</TITLE>
+<TITLE>Bison 1.75</TITLE>
 </HEAD>
 <BODY>
 <H1>Bison</H1>
 <H2>The YACC-compatible Parser Generator</H2>
-<H2>20 September 2001, Bison Version 1.30</H2>
+<H2>14 October 2002, Bison Version 1.75</H2>
 <ADDRESS>by Charles Donnelly and Richard Stallman</ADDRESS>
 <P>
 <P><HR><P>
@@ -47,7 +47,7 @@
 
 
 <P>
-This edition corresponds to version 1.30 of Bison.
+This edition corresponds to version 1.75 of Bison.
 
 
 
@@ -56,9 +56,9 @@
 
 <P>
 As of Bison version 1.24, we have changed the distribution terms for
-<CODE>yyparse</CODE> to permit using Bison's output in nonfree programs.
-Formerly, Bison parsers could be used only in programs that were free
-software.
+<CODE>yyparse</CODE> to permit using Bison's output in nonfree programs when
+Bison is generating C code for LALR(1) parsers.  Formerly, these
+parsers could be used only in programs that were free software.
 
 
 <P>
@@ -87,6 +87,15 @@
 using the other GNU tools.
 
 
+<P>
+This exception applies only when Bison is generating C code for a
+LALR(1) parser; otherwise, the GPL terms operate as usual.  You can
+tell whether the exception applies to your <SAMP>`.c'</SAMP> output file by
+inspecting it to see whether it says "As a special exception, when
+this file is copied by Bison into a Bison output file, you may use
+that output file without restriction."
+
+
 
 
 <H1><A NAME="SEC3" HREF="bison_toc.html#TOC3">GNU GENERAL PUBLIC LICENSE</A></H1>
@@ -569,20 +578,44 @@
 
 
 <P>
-Not all context-free languages can be handled by Bison, only those
-that are LALR(1).  In brief, this means that it must be possible to
+<A NAME="IDX6"></A>
+<A NAME="IDX7"></A>
+There are various important subclasses of context-free grammar.  Although it
+can handle almost all context-free grammars, Bison is optimized for what
+are called LALR(1) grammars.
+In brief, in these grammars, it must be possible to
 tell how to parse any portion of an input string with just a single
 token of look-ahead.  Strictly speaking, that is a description of an
 LR(1) grammar, and LALR(1) involves additional restrictions that are
 hard to explain simply; but it is rare in actual practice to find an
-LR(1) grammar that fails to be LALR(1).  See section <A HREF="bison.html#SEC88">Mysterious Reduce/Reduce Conflicts</A>, for more information on this.
+LR(1) grammar that fails to be LALR(1).  See section <A HREF="bison.html#SEC89">Mysterious Reduce/Reduce Conflicts</A>, for more information on this.
 
 
 <P>
-<A NAME="IDX6"></A>
-<A NAME="IDX7"></A>
 <A NAME="IDX8"></A>
 <A NAME="IDX9"></A>
+<A NAME="IDX10"></A>
+<A NAME="IDX11"></A>
+Parsers for LALR(1) grammars are <EM>deterministic</EM>, meaning roughly that
+the next grammar rule to apply at any point in the input is uniquely
+determined by the preceding input and a fixed, finite portion (called
+a <EM>look-ahead</EM>) of the remaining input.
+A context-free grammar can be <EM>ambiguous</EM>, meaning that
+there are multiple ways to apply the grammar rules to get the some inputs.
+Even unambiguous grammars can be <EM>non-deterministic</EM>, meaning that no
+fixed look-ahead always suffices to determine the next grammar rule to apply.
+With the proper declarations, Bison is also able to parse these more general
+context-free grammars, using a technique known as GLR parsing (for
+Generalized LR).  Bison's GLR parsers are able to handle any context-free
+grammar for which the number of possible parses of any given string
+is finite.
+
+
+<P>
+<A NAME="IDX12"></A>
+<A NAME="IDX13"></A>
+<A NAME="IDX14"></A>
+<A NAME="IDX15"></A>
 In the formal grammatical rules for a language, each kind of syntactic unit
 or grouping is named by a <EM>symbol</EM>.  Those which are built by grouping
 smaller constructs according to grammatical rules are called
@@ -591,6 +624,7 @@
 corresponding to a single terminal symbol a <EM>token</EM>, and a piece
 corresponding to a single nonterminal symbol a <EM>grouping</EM>.
 
+
 <P>
 We can use the C language as an example of what symbols, terminal and
 nonterminal, mean.  The tokens of C are identifiers, constants (numeric and
@@ -607,15 +641,14 @@
 Here is a simple C function subdivided into tokens:
 
 
+<P>
+@ifnotinfo
 
 <PRE>
 int             /* keyword `int' */
-square (x)      /* identifier, open-paren, */
-                /* identifier, close-paren */
-     int x;     /* keyword `int', identifier, semicolon */
+square (int x)  /* identifier, open-paren, identifier, identifier, close-paren */
 {               /* open-brace */
-  return x * x; /* keyword `return', identifier, */
-                /* asterisk, identifier, semicolon */
+  return x * x; /* keyword `return', identifier, asterisk, identifier, semicolon */
 }               /* close-brace */
 </PRE>
 
@@ -650,7 +683,7 @@
 
 
 <P>
-<A NAME="IDX10"></A>
+<A NAME="IDX16"></A>
 One nonterminal symbol must be distinguished as the special one which
 defines a complete utterance in the language.  It is called the <EM>start
 symbol</EM>.  In a compiler, this means a complete input program.  In the C
@@ -678,15 +711,15 @@
 
 <H2><A NAME="SEC9" HREF="bison_toc.html#TOC9">From Formal Rules to Bison Input</A></H2>
 <P>
-<A NAME="IDX11"></A>
-<A NAME="IDX12"></A>
-<A NAME="IDX13"></A>
+<A NAME="IDX17"></A>
+<A NAME="IDX18"></A>
+<A NAME="IDX19"></A>
 
 
 <P>
 A formal grammar is a mathematical construct.  To define the language
 for Bison, you must write a file expressing the grammar in Bison syntax:
-a <EM>Bison grammar</EM> file.  See section <A HREF="bison.html#SEC39">Bison Grammar Files</A>.
+a <EM>Bison grammar</EM> file.  See section <A HREF="bison.html#SEC40">Bison Grammar Files</A>.
 
 
 <P>
@@ -703,7 +736,7 @@
 <CODE>RETURN</CODE>.  A terminal symbol that stands for a particular keyword in
 the language should be named after that keyword converted to upper case.
 The terminal symbol <CODE>error</CODE> is reserved for error recovery.
-See section <A HREF="bison.html#SEC45">Symbols, Terminal and Nonterminal</A>.
+See section <A HREF="bison.html#SEC46">Symbols, Terminal and Nonterminal</A>.
 
 
 <P>
@@ -715,7 +748,7 @@
 
 <P>
 A third way to represent a terminal symbol is with a C string constant
-containing several characters.  See section <A HREF="bison.html#SEC45">Symbols, Terminal and Nonterminal</A>, for more information.
+containing several characters.  See section <A HREF="bison.html#SEC46">Symbols, Terminal and Nonterminal</A>, for more information.
 
 
 <P>
@@ -733,15 +766,15 @@
 </PRE>
 
 <P>
-See section <A HREF="bison.html#SEC46">Syntax of Grammar Rules</A>.
+See section <A HREF="bison.html#SEC47">Syntax of Grammar Rules</A>.
 
 
 
 
 <H2><A NAME="SEC10" HREF="bison_toc.html#TOC10">Semantic Values</A></H2>
 <P>
-<A NAME="IDX14"></A>
-<A NAME="IDX15"></A>
+<A NAME="IDX20"></A>
+<A NAME="IDX21"></A>
 
 
 <P>
@@ -752,11 +785,12 @@
 <SAMP>`x+4'</SAMP> is grammatical then <SAMP>`x+1'</SAMP> or <SAMP>`x+3989'</SAMP> is equally
 grammatical.
 
+
 <P>
 But the precise value is very important for what the input means once it is
 parsed.  A compiler is useless if it fails to distinguish between 4, 1 and
 3989 as constants in the program!  Therefore, each token in a Bison grammar
-has both a token type and a <EM>semantic value</EM>.  See section <A HREF="bison.html#SEC48">Defining Language Semantics</A>,
+has both a token type and a <EM>semantic value</EM>.  See section <A HREF="bison.html#SEC49">Defining Language Semantics</A>,
 for details.
 
 
@@ -767,6 +801,7 @@
 group it with other tokens.  The grammar rules know nothing about tokens
 except their types.
 
+
 <P>
 The semantic value has all the rest of the information about the
 meaning of the token, such as the value of an integer, or the name of an
@@ -795,8 +830,8 @@
 
 <H2><A NAME="SEC11" HREF="bison_toc.html#TOC11">Semantic Actions</A></H2>
 <P>
-<A NAME="IDX16"></A>
-<A NAME="IDX17"></A>
+<A NAME="IDX22"></A>
+<A NAME="IDX23"></A>
 
 
 <P>
@@ -804,7 +839,7 @@
 also produce some output based on the input.  In a Bison grammar, a grammar
 rule can have an <EM>action</EM> made up of C statements.  Each time the
 parser recognizes a match for that rule, the action is executed.
-See section <A HREF="bison.html#SEC51">Actions</A>.
+See section <A HREF="bison.html#SEC52">Actions</A>.
 
 
 <P>
@@ -835,52 +870,257 @@
 
 
 
-<H2><A NAME="SEC12" HREF="bison_toc.html#TOC12">Locations</A></H2>
+<H2><A NAME="SEC12" HREF="bison_toc.html#TOC12">Writing GLR Parsers</A></H2>
 <P>
-<A NAME="IDX18"></A>
-<A NAME="IDX19"></A>
-<A NAME="IDX20"></A>
+<A NAME="IDX24"></A>
+<A NAME="IDX25"></A>
+<A NAME="IDX26"></A>
+<A NAME="IDX27"></A>
+<A NAME="IDX28"></A>
+
+
+<P>
+In some grammars, there will be cases where Bison's standard LALR(1)
+parsing algorithm cannot decide whether to apply a certain grammar rule
+at a given point.  That is, it may not be able to decide (on the basis
+of the input read so far) which of two possible reductions (applications
+of a grammar rule) applies, or whether to apply a reduction or read more
+of the input and apply a reduction later in the input.  These are known
+respectively as <EM>reduce/reduce</EM> conflicts (see section <A HREF="bison.html#SEC88">Reduce/Reduce Conflicts</A>),
+and <EM>shift/reduce</EM> conflicts (see section <A HREF="bison.html#SEC80">Shift/Reduce Conflicts</A>).
+
+
+<P>
+To use a grammar that is not easily modified to be LALR(1), a more
+general parsing algorithm is sometimes necessary.  If you include
+<CODE>%glr-parser</CODE> among the Bison declarations in your file
+(see section <A HREF="bison.html#SEC41">Outline of a Bison Grammar</A>), the result will be a Generalized LR (GLR)
+parser.  These parsers handle Bison grammars that contain no unresolved
+conflicts (i.e., after applying precedence declarations) identically to
+LALR(1) parsers.  However, when faced with unresolved shift/reduce and
+reduce/reduce conflicts, GLR parsers use the simple expedient of doing
+both, effectively cloning the parser to follow both possibilities.  Each
+of the resulting parsers can again split, so that at any given time,
+there can be any number of possible parses being explored.  The parsers
+proceed in lockstep; that is, all of them consume (shift) a given input
+symbol before any of them proceed to the next.  Each of the cloned
+parsers eventually meets one of two possible fates: either it runs into
+a parsing error, in which case it simply vanishes, or it merges with
+another parser, because the two of them have reduced the input to an
+identical set of symbols.
+
+
+<P>
+During the time that there are multiple parsers, semantic actions are
+recorded, but not performed.  When a parser disappears, its recorded
+semantic actions disappear as well, and are never performed.  When a
+reduction makes two parsers identical, causing them to merge, Bison
+records both sets of semantic actions.  Whenever the last two parsers
+merge, reverting to the single-parser case, Bison resolves all the
+outstanding actions either by precedences given to the grammar rules
+involved, or by performing both actions, and then calling a designated
+user-defined function on the resulting values to produce an arbitrary
+merged result.
+
+
+<P>
+Let's consider an example, vastly simplified from C++.
+
+
+
+<PRE>
+%{
+  #define YYSTYPE const char*
+%}
+
+%token TYPENAME ID
+
+%right '='
+%left '+'
+
+%glr-parser
+
+%%
+
+prog :
+     | prog stmt   { printf ("\n"); }
+     ;
+
+stmt : expr ';'  %dprec 1
+     | decl      %dprec 2
+     ;
+
+expr : ID               { printf ("%s ", $$); }
+     | TYPENAME '(' expr ')'
+                        { printf ("%s &#60;cast&#62; ", $1); }
+     | expr '+' expr    { printf ("+ "); }
+     | expr '=' expr    { printf ("= "); }
+     ;
+
+decl : TYPENAME declarator ';'
+                        { printf ("%s &#60;declare&#62; ", $1); }
+     | TYPENAME declarator '=' expr ';'
+                        { printf ("%s &#60;init-declare&#62; ", $1); }
+     ;
+
+declarator : ID         { printf ("\"%s\" ", $1); }
+     | '(' declarator ')'
+     ;
+</PRE>
+
+<P>
+This models a problematic part of the C++ grammar--the ambiguity between
+certain declarations and statements.  For example,
+
+
+
+<PRE>
+T (x) = y+z;
+</PRE>
+
+<P>
+parses as either an <CODE>expr</CODE> or a <CODE>stmt</CODE>
+(assuming that <SAMP>`T'</SAMP> is recognized as a TYPENAME and <SAMP>`x'</SAMP> as an ID).
+Bison detects this as a reduce/reduce conflict between the rules
+<CODE>expr : ID</CODE> and <CODE>declarator : ID</CODE>, which it cannot resolve at the
+time it encounters <CODE>x</CODE> in the example above.  The two <CODE>%dprec</CODE>
+declarations, however, give precedence to interpreting the example as a
+<CODE>decl</CODE>, which implies that <CODE>x</CODE> is a declarator.
+The parser therefore prints
+
+
+
+<PRE>
+"x" y z + T &#60;init-declare&#62;
+</PRE>
+
+<P>
+Consider a different input string for this parser:
+
+
+
+<PRE>
+T (x) + y;
+</PRE>
+
+<P>
+Here, there is no ambiguity (this cannot be parsed as a declaration).
+However, at the time the Bison parser encounters <CODE>x</CODE>, it does not
+have enough information to resolve the reduce/reduce conflict (again,
+between <CODE>x</CODE> as an <CODE>expr</CODE> or a <CODE>declarator</CODE>).  In this
+case, no precedence declaration is used.  Instead, the parser splits
+into two, one assuming that <CODE>x</CODE> is an <CODE>expr</CODE>, and the other
+assuming <CODE>x</CODE> is a <CODE>declarator</CODE>.  The second of these parsers
+then vanishes when it sees <CODE>+</CODE>, and the parser prints
+
+
+
+<PRE>
+x T &#60;cast&#62; y +
+</PRE>
+
+<P>
+Suppose that instead of resolving the ambiguity, you wanted to see all
+the possibilities.  For this purpose, we must <EM>merge</EM> the semantic
+actions of the two possible parsers, rather than choosing one over the
+other.  To do so, you could change the declaration of <CODE>stmt</CODE> as
+follows:
+
+
+
+<PRE>
+stmt : expr ';'  %merge &#60;stmtMerge&#62;
+     | decl      %merge &#60;stmtMerge&#62;
+     ;
+</PRE>
+
+<P>
+
+
+<P>
+and define the <CODE>stmtMerge</CODE> function as:
+
+
+
+<PRE>
+static YYSTYPE stmtMerge (YYSTYPE x0, YYSTYPE x1)
+{
+  printf ("&#60;OR&#62; ");
+  return "";
+}
+</PRE>
+
+<P>
+with an accompanying forward declaration
+in the C declarations at the beginning of the file:
+
+
+
+<PRE>
+%{
+  #define YYSTYPE const char*
+  static YYSTYPE stmtMerge (YYSTYPE x0, YYSTYPE x1);
+%}
+</PRE>
+
+<P>
+With these declarations, the resulting parser will parse the first example
+as both an <CODE>expr</CODE> and a <CODE>decl</CODE>, and print
+
+
+
+<PRE>
+"x" y z + T &#60;init-declare&#62; x T &#60;cast&#62; y z + = &#60;OR&#62;
+</PRE>
+
+
+
+<H2><A NAME="SEC13" HREF="bison_toc.html#TOC13">Locations</A></H2>
+<P>
+<A NAME="IDX29"></A>
+<A NAME="IDX30"></A>
+<A NAME="IDX31"></A>
 
 
 <P>
 Many applications, like interpreters or compilers, have to produce verbose
-and useful error messages. To achieve this, one must be able to keep track of
+and useful error messages.  To achieve this, one must be able to keep track of
 the <EM>textual position</EM>, or <EM>location</EM>, of each syntactic construct.
 Bison provides a mechanism for handling these locations.
 
 
 <P>
-Each token has a semantic value. In a similar fashion, each token has an
+Each token has a semantic value.  In a similar fashion, each token has an
 associated location, but the type of locations is the same for all tokens and
-groupings. Moreover, the output parser is equipped with a default data
-structure for storing locations (see section <A HREF="bison.html#SEC54">Tracking Locations</A>, for more details).
+groupings.  Moreover, the output parser is equipped with a default data
+structure for storing locations (see section <A HREF="bison.html#SEC55">Tracking Locations</A>, for more details).
 
 
 <P>
 Like semantic values, locations can be reached in actions using a dedicated
-set of constructs. In the example above, the location of the whole grouping
+set of constructs.  In the example above, the location of the whole grouping
 is <CODE>@$</CODE>, while the locations of the subexpressions are <CODE>@1</CODE> and
 <CODE>@3</CODE>.
 
 
 <P>
 When a rule is matched, a default action is used to compute the semantic value
-of its left hand side (see section <A HREF="bison.html#SEC51">Actions</A>). In the same way, another default
-action is used for locations. However, the action for locations is general
+of its left hand side (see section <A HREF="bison.html#SEC52">Actions</A>).  In the same way, another default
+action is used for locations.  However, the action for locations is general
 enough for most cases, meaning there is usually no need to describe for each
-rule how <CODE>@$</CODE> should be formed. When building a new location for a given
+rule how <CODE>@$</CODE> should be formed.  When building a new location for a given
 grouping, the default behavior of the output parser is to take the beginning
 of the first symbol, and the end of the last symbol.
 
 
 
 
-<H2><A NAME="SEC13" HREF="bison_toc.html#TOC13">Bison Output: the Parser File</A></H2>
+<H2><A NAME="SEC14" HREF="bison_toc.html#TOC14">Bison Output: the Parser File</A></H2>
 <P>
-<A NAME="IDX21"></A>
-<A NAME="IDX22"></A>
-<A NAME="IDX23"></A>
-<A NAME="IDX24"></A>
+<A NAME="IDX32"></A>
+<A NAME="IDX33"></A>
+<A NAME="IDX34"></A>
+<A NAME="IDX35"></A>
 
 
 <P>
@@ -900,12 +1140,13 @@
 
 
 <P>
-The tokens come from a function called the <EM>lexical analyzer</EM> that you
-must supply in some fashion (such as by writing it in C).  The Bison parser
-calls the lexical analyzer each time it wants a new token.  It doesn't know
-what is "inside" the tokens (though their semantic values may reflect
-this).  Typically the lexical analyzer makes the tokens by parsing
-characters of text, but Bison does not depend on this.  See section <A HREF="bison.html#SEC70">The Lexical Analyzer Function <CODE>yylex</CODE></A>.
+The tokens come from a function called the <EM>lexical analyzer</EM> that
+you must supply in some fashion (such as by writing it in C).  The Bison
+parser calls the lexical analyzer each time it wants a new token.  It
+doesn't know what is "inside" the tokens (though their semantic values
+may reflect this).  Typically the lexical analyzer makes the tokens by
+parsing characters of text, but Bison does not depend on this.
+See section <A HREF="bison.html#SEC71">The Lexical Analyzer Function <CODE>yylex</CODE></A>.
 
 
 <P>
@@ -916,12 +1157,12 @@
 parser calls to report an error.  In addition, a complete C program must
 start with a function called <CODE>main</CODE>; you have to provide this, and
 arrange for it to call <CODE>yyparse</CODE> or the parser will never run.
-See section <A HREF="bison.html#SEC68">Parser C-Language Interface</A>.
+See section <A HREF="bison.html#SEC69">Parser C-Language Interface</A>.
 
 
 <P>
 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'</SAMP> or <SAMP>`YY'</SAMP>.  This includes interface functions
 such as the lexical analyzer function <CODE>yylex</CODE>, the error reporting
 function <CODE>yyerror</CODE> and the parser function <CODE>yyparse</CODE> itself.
@@ -931,12 +1172,22 @@
 this manual.
 
 
+<P>
+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-GNU hosts, <CODE>&#60;alloca.h&#62;</CODE>,
+<CODE>&#60;stddef.h&#62;</CODE>, and <CODE>&#60;stdlib.h&#62;</CODE> are included as needed to
+declare memory allocators and related types.  Other system headers may
+be included if you define <CODE>YYDEBUG</CODE> to a nonzero value
+(see section <A HREF="bison.html#SEC99">Tracing Your Parser</A>).
+
+
 
 
-<H2><A NAME="SEC14" HREF="bison_toc.html#TOC14">Stages in Using Bison</A></H2>
+<H2><A NAME="SEC15" HREF="bison_toc.html#TOC15">Stages in Using Bison</A></H2>
 <P>
-<A NAME="IDX25"></A>
-<A NAME="IDX26"></A>
+<A NAME="IDX36"></A>
+<A NAME="IDX37"></A>
 
 
 <P>
@@ -949,16 +1200,16 @@
 <LI>
 
 Formally specify the grammar in a form recognized by Bison
-(see section <A HREF="bison.html#SEC39">Bison Grammar Files</A>).  For each grammatical rule in the language,
-describe the action that is to be taken when an instance of that rule
-is recognized.  The action is described by a sequence of C statements.
+(see section <A HREF="bison.html#SEC40">Bison Grammar Files</A>).  For each grammatical rule
+in the language, describe the action that is to be taken when an
+instance of that rule is recognized.  The action is described by a
+sequence of C statements.
 
 <LI>
 
-Write a lexical analyzer to process input and pass tokens to the
-parser.  The lexical analyzer may be written by hand in C
-(see section <A HREF="bison.html#SEC70">The Lexical Analyzer Function <CODE>yylex</CODE></A>).  It could also be produced using Lex, but the use
-of Lex is not discussed in this manual.
+Write a lexical analyzer to process input and pass tokens to the parser.
+The lexical analyzer may be written by hand in C (see section <A HREF="bison.html#SEC71">The Lexical Analyzer Function <CODE>yylex</CODE></A>).  It could also be produced
+using Lex, but the use of Lex is not discussed in this manual.
 
 <LI>
 
@@ -991,12 +1242,12 @@
 
 
 
-<H2><A NAME="SEC15" HREF="bison_toc.html#TOC15">The Overall Layout of a Bison Grammar</A></H2>
+<H2><A NAME="SEC16" HREF="bison_toc.html#TOC16">The Overall Layout of a Bison Grammar</A></H2>
 <P>
-<A NAME="IDX27"></A>
-<A NAME="IDX28"></A>
-<A NAME="IDX29"></A>
-<A NAME="IDX30"></A>
+<A NAME="IDX38"></A>
+<A NAME="IDX39"></A>
+<A NAME="IDX40"></A>
+<A NAME="IDX41"></A>
 
 
 <P>
@@ -1007,7 +1258,7 @@
 
 <PRE>
 %{
-<VAR>C declarations</VAR>
+<VAR>Prologue</VAR>
 %}
 
 <VAR>Bison declarations</VAR>
@@ -1015,7 +1266,7 @@
 %%
 <VAR>Grammar rules</VAR>
 %%
-<VAR>Additional C code</VAR>
+<VAR>Epilogue</VAR>
 </PRE>
 
 <P>
@@ -1024,8 +1275,8 @@
 
 
 <P>
-The C declarations may define types and variables used in the actions.
-You can also use preprocessor commands to define macros used there, and use
+The prologue may define types and variables used in the actions.  You can
+also use preprocessor commands to define macros used there, and use
 <CODE>#include</CODE> to include header files that do any of these things.
 
 
@@ -1041,18 +1292,18 @@
 
 
 <P>
-The additional C code can contain any C code you want to use.  Often the
-definition of the lexical analyzer <CODE>yylex</CODE> goes here, plus subroutines
-called by the actions in the grammar rules.  In a simple program, all the
-rest of the program can go here.
+The epilogue can contain any code you want to use.  Often the definition of
+the lexical analyzer <CODE>yylex</CODE> goes here, plus subroutines called by the
+actions in the grammar rules.  In a simple program, all the rest of the
+program can go here.
 
 
 
 
-<H1><A NAME="SEC16" HREF="bison_toc.html#TOC16">Examples</A></H1>
+<H1><A NAME="SEC17" HREF="bison_toc.html#TOC17">Examples</A></H1>
 <P>
-<A NAME="IDX31"></A>
-<A NAME="IDX32"></A>
+<A NAME="IDX42"></A>
+<A NAME="IDX43"></A>
 
 
 <P>
@@ -1070,12 +1321,12 @@
 
 
 
-<H2><A NAME="SEC17" HREF="bison_toc.html#TOC17">Reverse Polish Notation Calculator</A></H2>
+<H2><A NAME="SEC18" HREF="bison_toc.html#TOC18">Reverse Polish Notation Calculator</A></H2>
 <P>
-<A NAME="IDX33"></A>
-<A NAME="IDX34"></A>
-<A NAME="IDX35"></A>
-<A NAME="IDX36"></A>
+<A NAME="IDX44"></A>
+<A NAME="IDX45"></A>
+<A NAME="IDX46"></A>
+<A NAME="IDX47"></A>
 
 
 <P>
@@ -1092,7 +1343,7 @@
 
 
 
-<H3><A NAME="SEC18" HREF="bison_toc.html#TOC18">Declarations for <CODE>rpcalc</CODE></A></H3>
+<H3><A NAME="SEC19" HREF="bison_toc.html#TOC19">Declarations for <CODE>rpcalc</CODE></A></H3>
 
 <P>
 Here are the C and Bison declarations for the reverse polish notation
@@ -1101,7 +1352,7 @@
 
 
 <PRE>
-/* Reverse polish notation calculator. */
+/* Reverse polish notation calculator.  */
 
 %{
 #define YYSTYPE double
@@ -1110,21 +1361,22 @@
 
 %token NUM
 
-%% /* Grammar rules and actions follow */
+%% /* Grammar rules and actions follow.  */
 </PRE>
 
 <P>
-The C declarations section (see section <A HREF="bison.html#SEC41">The C Declarations Section</A>) contains two
+The declarations section (see section <A HREF="bison.html#SEC42">The prologue</A>) contains two
 preprocessor directives.
 
 
 <P>
 The <CODE>#define</CODE> directive defines the macro <CODE>YYSTYPE</CODE>, thus
-specifying the C data type for semantic values of both tokens and groupings
-(see section <A HREF="bison.html#SEC49">Data Types of Semantic Values</A>).  The Bison parser will use whatever type
-<CODE>YYSTYPE</CODE> is defined as; if you don't define it, <CODE>int</CODE> is the
-default.  Because we specify <CODE>double</CODE>, each token and each expression
-has an associated value, which is a floating point number.
+specifying the C data type for semantic values of both tokens and
+groupings (see section <A HREF="bison.html#SEC50">Data Types of Semantic Values</A>).  The
+Bison parser will use whatever type <CODE>YYSTYPE</CODE> is defined as; if you
+don't define it, <CODE>int</CODE> is the default.  Because we specify
+<CODE>double</CODE>, each token and each expression has an associated value,
+which is a floating point number.
 
 
 <P>
@@ -1133,9 +1385,9 @@
 
 
 <P>
-The second section, Bison declarations, provides information to Bison about
-the token types (see section <A HREF="bison.html#SEC42">The Bison Declarations Section</A>).  Each terminal symbol that is
-not a single-character literal must be declared here.  (Single-character
+The second section, Bison declarations, provides information to Bison
+about the token types (see section <A HREF="bison.html#SEC43">The Bison Declarations Section</A>).  Each terminal symbol that is not a
+single-character literal must be declared here.  (Single-character
 literals normally don't need to be declared.)  In this example, all the
 arithmetic operators are designated by single-character literals, so the
 only terminal symbol that needs to be declared is <CODE>NUM</CODE>, the token
@@ -1144,7 +1396,7 @@
 
 
 
-<H3><A NAME="SEC19" HREF="bison_toc.html#TOC19">Grammar Rules for <CODE>rpcalc</CODE></A></H3>
+<H3><A NAME="SEC20" HREF="bison_toc.html#TOC20">Grammar Rules for <CODE>rpcalc</CODE></A></H3>
 
 <P>
 Here are the grammar rules for the reverse polish notation calculator.
@@ -1185,7 +1437,7 @@
 <P>
 The semantics of the language is determined by the actions taken when a
 grouping is recognized.  The actions are the C code that appears inside
-braces.  See section <A HREF="bison.html#SEC51">Actions</A>.
+braces.  See section <A HREF="bison.html#SEC52">Actions</A>.
 
 
 <P>
@@ -1199,7 +1451,7 @@
 
 
 
-<H4><A NAME="SEC20" HREF="bison_toc.html#TOC20">Explanation of <CODE>input</CODE></A></H4>
+<H4><A NAME="SEC21" HREF="bison_toc.html#TOC21">Explanation of <CODE>input</CODE></A></H4>
 
 <P>
 Consider the definition of <CODE>input</CODE>:
@@ -1217,7 +1469,7 @@
 string, or a complete input followed by an input line".  Notice that
 "complete input" is defined in terms of itself.  This definition is said
 to be <EM>left recursive</EM> since <CODE>input</CODE> appears always as the
-leftmost symbol in the sequence.  See section <A HREF="bison.html#SEC47">Recursive Rules</A>.
+leftmost symbol in the sequence.  See section <A HREF="bison.html#SEC48">Recursive Rules</A>.
 
 
 <P>
@@ -1240,12 +1492,12 @@
 <P>
 The parser function <CODE>yyparse</CODE> continues to process input until a
 grammatical error is seen or the lexical analyzer says there are no more
-input tokens; we will arrange for the latter to happen at end of file.
+input tokens; we will arrange for the latter to happen at end-of-input.
 
 
 
 
-<H4><A NAME="SEC21" HREF="bison_toc.html#TOC21">Explanation of <CODE>line</CODE></A></H4>
+<H4><A NAME="SEC22" HREF="bison_toc.html#TOC22">Explanation of <CODE>line</CODE></A></H4>
 
 <P>
 Now consider the definition of <CODE>line</CODE>:
@@ -1278,7 +1530,7 @@
 
 
 
-<H4><A NAME="SEC22" HREF="bison_toc.html#TOC22">Explanation of <CODE>expr</CODE></A></H4>
+<H4><A NAME="SEC23" HREF="bison_toc.html#TOC23">Explanation of <CODE>expr</CODE></A></H4>
 
 <P>
 The <CODE>exp</CODE> grouping has several rules, one for each kind of expression.
@@ -1317,7 +1569,7 @@
 associated semantic value, but if it had one you could refer to it as
 <CODE>$3</CODE>.  When <CODE>yyparse</CODE> recognizes a sum expression using this
 rule, the sum of the two subexpressions' values is produced as the value of
-the entire expression.  See section <A HREF="bison.html#SEC51">Actions</A>.
+the entire expression.  See section <A HREF="bison.html#SEC52">Actions</A>.
 
 
 <P>
@@ -1328,7 +1580,7 @@
 
 <P>
 The formatting shown here is the recommended convention, but Bison does
-not require it.  You can add or change whitespace as much as you wish.
+not require it.  You can add or change white space as much as you wish.
 For example, this:
 
 
@@ -1354,16 +1606,16 @@
 
 
 
-<H3><A NAME="SEC23" HREF="bison_toc.html#TOC23">The <CODE>rpcalc</CODE> Lexical Analyzer</A></H3>
+<H3><A NAME="SEC24" HREF="bison_toc.html#TOC24">The <CODE>rpcalc</CODE> Lexical Analyzer</A></H3>
 <P>
-<A NAME="IDX37"></A>
-<A NAME="IDX38"></A>
+<A NAME="IDX48"></A>
+<A NAME="IDX49"></A>
 
 
 <P>
-The lexical analyzer's job is low-level parsing: converting characters or
-sequences of characters into tokens.  The Bison parser gets its tokens by
-calling the lexical analyzer.  See section <A HREF="bison.html#SEC70">The Lexical Analyzer Function <CODE>yylex</CODE></A>.
+The lexical analyzer's job is low-level parsing: converting characters
+or sequences of characters into tokens.  The Bison parser gets its
+tokens by calling the lexical analyzer.  See section <A HREF="bison.html#SEC71">The Lexical Analyzer Function <CODE>yylex</CODE></A>.
 
 
 <P>
@@ -1379,7 +1631,7 @@
 represents a token type.  The same text used in Bison rules to stand for
 this token type is also a C expression for the numeric code for the type.
 This works in two ways.  If the token type is a character literal, then its
-numeric code is the ASCII code for that character; you can use the same
+numeric code is that of the character; you can use the same
 character literal in the lexical analyzer to express the number.  If the
 token type is an identifier, that identifier is defined by Bison as a C
 macro whose definition is the appropriate number.  In this example,
@@ -1387,16 +1639,15 @@
 
 
 <P>
-The semantic value of the token (if it has one) is stored into the global
-variable <CODE>yylval</CODE>, which is where the Bison parser will look for it.
-(The C data type of <CODE>yylval</CODE> is <CODE>YYSTYPE</CODE>, which was defined
-at the beginning of the grammar; see section <A HREF="bison.html#SEC18">Declarations for <CODE>rpcalc</CODE></A>.)
+The semantic value of the token (if it has one) is stored into the
+global variable <CODE>yylval</CODE>, which is where the Bison parser will look
+for it.  (The C data type of <CODE>yylval</CODE> is <CODE>YYSTYPE</CODE>, which was
+defined at the beginning of the grammar; see section <A HREF="bison.html#SEC19">Declarations for <CODE>rpcalc</CODE></A>.)
 
 
 <P>
-A token type code of zero is returned if the end-of-file is encountered.
-(Bison recognizes any nonpositive value as indicating the end of the
-input.)
+A token type code of zero is returned if the end-of-input is encountered.
+(Bison recognizes any nonpositive value as indicating end-of-input.)
 
 
 <P>
@@ -1405,10 +1656,10 @@
 
 
 <PRE>
-/* Lexical analyzer returns a double floating point
-   number on the stack and the token NUM, or the ASCII
-   character read if not a number.  Skips all blanks
-   and tabs, returns 0 for EOF. */
+/* The lexical analyzer returns a double floating point
+   number on the stack and the token NUM, or the numeric code
+   of the character read if not a number.  It skips all blanks
+   and tabs, and returns 0 for end-of-input.  */
 
 #include &#60;ctype.h&#62;
 
@@ -1417,30 +1668,30 @@
 {
   int c;
 
-  /* skip white space  */
+  /* Skip white space.  */
   while ((c = getchar ()) == ' ' || c == '\t')
     ;
-  /* process numbers   */
+  /* Process numbers.  */
   if (c == '.' || isdigit (c))
     {
       ungetc (c, stdin);
       scanf ("%lf", &#38;yylval);
       return NUM;
     }
-  /* return end-of-file  */
+  /* Return end-of-input.  */
   if (c == EOF)
     return 0;
-  /* return single chars */
+  /* Return a single char.  */
   return c;
 }
 </PRE>
 
 
 
-<H3><A NAME="SEC24" HREF="bison_toc.html#TOC24">The Controlling Function</A></H3>
+<H3><A NAME="SEC25" HREF="bison_toc.html#TOC25">The Controlling Function</A></H3>
 <P>
-<A NAME="IDX39"></A>
-<A NAME="IDX40"></A>
+<A NAME="IDX50"></A>
+<A NAME="IDX51"></A>
 
 
 <P>
@@ -1460,16 +1711,16 @@
 
 
 
-<H3><A NAME="SEC25" HREF="bison_toc.html#TOC25">The Error Reporting Routine</A></H3>
+<H3><A NAME="SEC26" HREF="bison_toc.html#TOC26">The Error Reporting Routine</A></H3>
 <P>
-<A NAME="IDX41"></A>
+<A NAME="IDX52"></A>
 
 
 <P>
 When <CODE>yyparse</CODE> detects a syntax error, it calls the error reporting
 function <CODE>yyerror</CODE> to print an error message (usually but not
 always <CODE>"parse error"</CODE>).  It is up to the programmer to supply
-<CODE>yyerror</CODE> (see section <A HREF="bison.html#SEC68">Parser C-Language Interface</A>), so
+<CODE>yyerror</CODE> (see section <A HREF="bison.html#SEC69">Parser C-Language Interface</A>), so
 here is the definition we will use:
 
 
@@ -1478,7 +1729,7 @@
 #include &#60;stdio.h&#62;
 
 void
-yyerror (const char *s)  /* Called by yyparse on error */
+yyerror (const char *s)  /* called by yyparse on error */
 {
   printf ("%s\n", s);
 }
@@ -1487,7 +1738,7 @@
 <P>
 After <CODE>yyerror</CODE> returns, the Bison parser may recover from the error
 and continue parsing if the grammar contains a suitable error rule
-(see section <A HREF="bison.html#SEC90">Error Recovery</A>).  Otherwise, <CODE>yyparse</CODE> returns nonzero.  We
+(see section <A HREF="bison.html#SEC92">Error Recovery</A>).  Otherwise, <CODE>yyparse</CODE> returns nonzero.  We
 have not written any error rules in this example, so any invalid input will
 cause the calculator program to exit.  This is not clean behavior for a
 real calculator, but it is adequate for the first example.
@@ -1495,9 +1746,9 @@
 
 
 
-<H3><A NAME="SEC26" HREF="bison_toc.html#TOC26">Running Bison to Make the Parser</A></H3>
+<H3><A NAME="SEC27" HREF="bison_toc.html#TOC27">Running Bison to Make the Parser</A></H3>
 <P>
-<A NAME="IDX42"></A>
+<A NAME="IDX53"></A>
 
 
 <P>
@@ -1505,7 +1756,8 @@
 arrange all the source code in one or more source files.  For such a
 simple example, the easiest thing is to put everything in one file.  The
 definitions of <CODE>yylex</CODE>, <CODE>yyerror</CODE> and <CODE>main</CODE> go at the
-end, in the "additional C code" section of the file (see section <A HREF="bison.html#SEC15">The Overall Layout of a Bison Grammar</A>).
+end, in the epilogue of the file
+(see section <A HREF="bison.html#SEC16">The Overall Layout of a Bison Grammar</A>).
 
 
 <P>
@@ -1526,7 +1778,7 @@
 <P>
 In this example the file was called <TT>`rpcalc.y'</TT> (for "Reverse Polish
 CALCulator").  Bison produces a file named <TT>`<VAR>file_name</VAR>.tab.c'</TT>,
-removing the <SAMP>`.y'</SAMP> from the original file name. The file output by
+removing the <SAMP>`.y'</SAMP> from the original file name.  The file output by
 Bison contains the source code for <CODE>yyparse</CODE>.  The additional
 functions in the input file (<CODE>yylex</CODE>, <CODE>yyerror</CODE> and <CODE>main</CODE>)
 are copied verbatim to the output.
@@ -1534,9 +1786,9 @@
 
 
 
-<H3><A NAME="SEC27" HREF="bison_toc.html#TOC27">Compiling the Parser File</A></H3>
+<H3><A NAME="SEC28" HREF="bison_toc.html#TOC28">Compiling the Parser File</A></H3>
 <P>
-<A NAME="IDX43"></A>
+<A NAME="IDX54"></A>
 
 
 <P>
@@ -1546,15 +1798,15 @@
 
 <PRE>
 # List files in current directory.
-% ls
+$ <KBD>ls</KBD>
 rpcalc.tab.c  rpcalc.y
 
 # Compile the Bison parser.
 # <SAMP>`-lm'</SAMP> tells compiler to search math library for <CODE>pow</CODE>.
-% cc rpcalc.tab.c -lm -o rpcalc
+$ <KBD>cc -lm -o rpcalc rpcalc.tab.c</KBD>
 
 # List files again.
-% ls
+$ <KBD>ls</KBD>
 rpcalc  rpcalc.tab.c  rpcalc.y
 </PRE>
 
@@ -1565,28 +1817,28 @@
 
 
 <PRE>
-% rpcalc
-4 9 +
+$ <KBD>rpcalc</KBD>
+<KBD>4 9 +</KBD>
 13
-3 7 + 3 4 5 *+-
+<KBD>3 7 + 3 4 5 *+-</KBD>
 -13
-3 7 + 3 4 5 * + - n              Note the unary minus, <SAMP>`n'</SAMP>
+<KBD>3 7 + 3 4 5 * + - n</KBD>              Note the unary minus, <SAMP>`n'</SAMP>
 13
-5 6 / 4 n +
+<KBD>5 6 / 4 n +</KBD>
 -3.166666667
-3 4 ^                            Exponentiation
+<KBD>3 4 ^</KBD>                            Exponentiation
 81
-^D                               End-of-file indicator
-%
+<KBD>^D</KBD>                               End-of-file indicator
+$
 </PRE>
 
 
 
-<H2><A NAME="SEC28" HREF="bison_toc.html#TOC28">Infix Notation Calculator: <CODE>calc</CODE></A></H2>
+<H2><A NAME="SEC29" HREF="bison_toc.html#TOC29">Infix Notation Calculator: <CODE>calc</CODE></A></H2>
 <P>
-<A NAME="IDX44"></A>
-<A NAME="IDX45"></A>
-<A NAME="IDX46"></A>
+<A NAME="IDX55"></A>
+<A NAME="IDX56"></A>
+<A NAME="IDX57"></A>
 
 
 <P>
@@ -1658,14 +1910,14 @@
 declarations; the higher the line number of the declaration (lower on
 the page or screen), the higher the precedence.  Hence, exponentiation
 has the highest precedence, unary minus (<CODE>NEG</CODE>) is next, followed
-by <SAMP>`*'</SAMP> and <SAMP>`/'</SAMP>, and so on.  See section <A HREF="bison.html#SEC80">Operator Precedence</A>.
+by <SAMP>`*'</SAMP> and <SAMP>`/'</SAMP>, and so on.  See section <A HREF="bison.html#SEC81">Operator Precedence</A>.
 
 
 <P>
-The other important new feature is the <CODE>%prec</CODE> in the grammar section
-for the unary minus operator.  The <CODE>%prec</CODE> simply instructs Bison that
-the rule <SAMP>`| '-' exp'</SAMP> has the same precedence as <CODE>NEG</CODE>---in this
-case the next-to-highest.  See section <A HREF="bison.html#SEC85">Context-Dependent Precedence</A>.
+The other important new feature is the <CODE>%prec</CODE> in the grammar
+section for the unary minus operator.  The <CODE>%prec</CODE> simply instructs
+Bison that the rule <SAMP>`| '-' exp'</SAMP> has the same precedence as
+<CODE>NEG</CODE>---in this case the next-to-highest.  See section <A HREF="bison.html#SEC86">Context-Dependent Precedence</A>.
 
 
 <P>
@@ -1674,20 +1926,20 @@
 
 
 <PRE>
-% calc
-4 + 4.5 - (34/(8*3+-3))
+$ <KBD>calc</KBD>
+<KBD>4 + 4.5 - (34/(8*3+-3))</KBD>
 6.880952381
--56 + 2
+<KBD>-56 + 2</KBD>
 -54
-3 ^ 2
+<KBD>3 ^ 2</KBD>
 9
 </PRE>
 
 
 
-<H2><A NAME="SEC29" HREF="bison_toc.html#TOC29">Simple Error Recovery</A></H2>
+<H2><A NAME="SEC30" HREF="bison_toc.html#TOC30">Simple Error Recovery</A></H2>
 <P>
-<A NAME="IDX47"></A>
+<A NAME="IDX58"></A>
 
 
 <P>
@@ -1720,10 +1972,11 @@
 and parsing will continue.  (The <CODE>yyerror</CODE> function is still called
 upon to print its message as well.)  The action executes the statement
 <CODE>yyerrok</CODE>, a macro defined automatically by Bison; its meaning is
-that error recovery is complete (see section <A HREF="bison.html#SEC90">Error Recovery</A>).  Note the
+that error recovery is complete (see section <A HREF="bison.html#SEC92">Error Recovery</A>).  Note the
 difference between <CODE>yyerrok</CODE> and <CODE>yyerror</CODE>; neither one is a
 misprint.
 
+
 <P>
 This form of error recovery deals with syntax errors.  There are other
 kinds of errors; for example, division by zero, which raises an exception
@@ -1736,32 +1989,28 @@
 
 
 
-<H2><A NAME="SEC30" HREF="bison_toc.html#TOC30">Location Tracking Calculator: <CODE>ltcalc</CODE></A></H2>
-<P>
-<A NAME="IDX48"></A>
-<A NAME="IDX49"></A>
-<A NAME="IDX50"></A>
-
-
+<H2><A NAME="SEC31" HREF="bison_toc.html#TOC31">Location Tracking Calculator: <CODE>ltcalc</CODE></A></H2>
 <P>
-This example extends the infix notation calculator with location tracking.
-This feature will be used to improve error reporting, and provide better
-error messages.
+<A NAME="IDX59"></A>
+<A NAME="IDX60"></A>
+<A NAME="IDX61"></A>
 
 
 <P>
-For the sake of clarity, we will switch for this example to an integer
-calculator, since most of the work needed to use locations will be done
-in the lexical analyser.
+This example extends the infix notation calculator with location
+tracking.  This feature will be used to improve the error messages.  For
+the sake of clarity, this example is a simple integer calculator, since
+most of the work needed to use locations will be done in the lexical
+analyzer.
 
 
 
 
-<H3><A NAME="SEC31" HREF="bison_toc.html#TOC31">Declarations for <CODE>ltcalc</CODE></A></H3>
+<H3><A NAME="SEC32" HREF="bison_toc.html#TOC32">Declarations for <CODE>ltcalc</CODE></A></H3>
 
 <P>
-The C and Bison declarations for the location tracking calculator are the same
-as the declarations for the infix notation calculator.
+The C and Bison declarations for the location tracking calculator are
+the same as the declarations for the infix notation calculator.
 
 
 
@@ -1785,27 +2034,28 @@
 </PRE>
 
 <P>
-In the code above, there are no declarations specific to locations.  Defining
-a data type for storing locations is not needed: we will use the type provided
-by default (see section <A HREF="bison.html#SEC55">Data Type of Locations</A>), which is a four
-member structure with the following integer fields: <CODE>first_line</CODE>,
-<CODE>first_column</CODE>, <CODE>last_line</CODE> and <CODE>last_column</CODE>.
+Note there are no declarations specific to locations.  Defining a data
+type for storing locations is not needed: we will use the type provided
+by default (see section <A HREF="bison.html#SEC56">Data Type of Locations</A>), which is a
+four member structure with the following integer fields:
+<CODE>first_line</CODE>, <CODE>first_column</CODE>, <CODE>last_line</CODE> and
+<CODE>last_column</CODE>.
 
 
 
 
-<H3><A NAME="SEC32" HREF="bison_toc.html#TOC32">Grammar Rules for <CODE>ltcalc</CODE></A></H3>
+<H3><A NAME="SEC33" HREF="bison_toc.html#TOC33">Grammar Rules for <CODE>ltcalc</CODE></A></H3>
 
 <P>
-Whether you choose to handle locations or not has no effect on the syntax of
-your language.  Therefore, grammar rules for this example will be very close to
-those of the previous example: we will only modify them to benefit from the new
-informations we will have.
+Whether handling locations or not has no effect on the syntax of your
+language.  Therefore, grammar rules for this example will be very close
+to those of the previous example: we will only modify them to benefit
+from the new information.
 
 
 <P>
-Here, we will use locations to report divisions by zero, and locate the wrong
-expressions or subexpressions.
+Here, we will use locations to report divisions by zero, and locate the
+wrong expressions or subexpressions.
 
 
 
@@ -1829,9 +2079,9 @@
               else
                 {
                   $$ = 1;
-                  printf("Division by zero, l%d,c%d-l%d,c%d",
-                         @3.first_line, @3.first_column,
-                         @3.last_line, @3.last_column);
+                  fprintf (stderr, "%d.%d-%d.%d: division by zero",
+                           @3.first_line, @3.first_column,
+                           @3.last_line, @3.last_column);
                 }
             }
         | '-' exp %preg NEG     { $$ = -$2; }
@@ -1846,31 +2096,28 @@
 
 
 <P>
-In this example, we never assign a value to <CODE>@$</CODE>, because the
-output parser can do this automatically.  By default, before executing
-the C code of each action, <CODE>@$</CODE> is set to range from the beginning
-of <CODE>@1</CODE> to the end of <CODE>@<VAR>n</VAR></CODE>, for a rule with <VAR>n</VAR>
-components.
+We don't need to assign a value to <CODE>@$</CODE>: the output parser does it
+automatically.  By default, before executing the C code of each action,
+<CODE>@$</CODE> is set to range from the beginning of <CODE>@1</CODE> to the end
+of <CODE>@<VAR>n</VAR></CODE>, for a rule with <VAR>n</VAR> components.  This behavior
+can be redefined (see section <A HREF="bison.html#SEC58">Default Action for Locations</A>), and for very specific rules, <CODE>@$</CODE> can be computed by
+hand.
 
 
-<P>
-Of course, this behavior can be redefined (see section <A HREF="bison.html#SEC57">Default Action for Locations</A>), and for very specific rules,
-<CODE>@$</CODE> can be computed by hand.
-
 
 
-
-<H3><A NAME="SEC33" HREF="bison_toc.html#TOC33">The <CODE>ltcalc</CODE> Lexical Analyzer.</A></H3>
+<H3><A NAME="SEC34" HREF="bison_toc.html#TOC34">The <CODE>ltcalc</CODE> Lexical Analyzer.</A></H3>
 
 <P>
-Until now, we relied on Bison's defaults to enable location tracking. The next
-step is to rewrite the lexical analyser, and make it able to feed the parser
-with locations of tokens, as he already does for semantic values.
+Until now, we relied on Bison's defaults to enable location
+tracking.  The next step is to rewrite the lexical analyzer, and make it
+able to feed the parser with the token locations, as it already does for
+semantic values.
 
 
 <P>
-To do so, we must take into account every single character of the input text,
-to avoid the computed locations of being fuzzy or wrong:
+To this end, we must take into account every single character of the
+input text, to avoid the computed locations of being fuzzy or wrong:
 
 
 
@@ -1880,15 +2127,15 @@
 {
   int c;
 
-  /* skip white space */
+  /* Skip white space.  */
   while ((c = getchar ()) == ' ' || c == '\t')
     ++yylloc.last_column;
 
-  /* step */
+  /* Step.  */
   yylloc.first_line = yylloc.last_line;
   yylloc.first_column = yylloc.last_column;
 
-  /* process numbers */
+  /* Process numbers.  */
   if (isdigit (c))
     {
       yylval = c - '0';
@@ -1902,11 +2149,11 @@
       return NUM;
     }
 
-  /* return end-of-file */
+  /* Return end-of-input.  */
   if (c == EOF)
     return 0;
 
-  /* return single chars and update location */
+  /* Return a single char, and update location.  */
   if (c == '\n')
     {
       ++yylloc.last_line;
@@ -1919,17 +2166,17 @@
 </PRE>
 
 <P>
-Basically, the lexical analyzer does the same processing as before: it skips
-blanks and tabs, and reads numbers or single-character tokens.  In addition
-to this, it updates the <CODE>yylloc</CODE> global variable (of type <CODE>YYLTYPE</CODE>),
-where the location of tokens is stored.
+Basically, the lexical analyzer performs the same processing as before:
+it skips blanks and tabs, and reads numbers or single-character tokens.
+In addition, it updates <CODE>yylloc</CODE>, the global variable (of type
+<CODE>YYLTYPE</CODE>) containing the token's location.
 
 
 <P>
-Now, each time this function returns a token, the parser has it's number as
-well as it's semantic value, and it's position in the text. The last needed
-change is to initialize <CODE>yylloc</CODE>, for example in the controlling
-function:
+Now, each time this function returns a token, the parser has its number
+as well as its semantic value, and its location in the text.  The last
+needed change is to initialize <CODE>yylloc</CODE>, for example in the
+controlling function:
 
 
 
@@ -1944,18 +2191,18 @@
 </PRE>
 
 <P>
-Remember that computing locations is not a matter of syntax.  Every character
-must be associated to a location update, whether it is in valid input, in
-comments, in literal strings, and so on...
+Remember that computing locations is not a matter of syntax.  Every
+character must be associated to a location update, whether it is in
+valid input, in comments, in literal strings, and so on.
 
 
 
 
-<H2><A NAME="SEC34" HREF="bison_toc.html#TOC34">Multi-Function Calculator: <CODE>mfcalc</CODE></A></H2>
+<H2><A NAME="SEC35" HREF="bison_toc.html#TOC35">Multi-Function Calculator: <CODE>mfcalc</CODE></A></H2>
 <P>
-<A NAME="IDX51"></A>
-<A NAME="IDX52"></A>
-<A NAME="IDX53"></A>
+<A NAME="IDX62"></A>
+<A NAME="IDX63"></A>
+<A NAME="IDX64"></A>
 
 
 <P>
@@ -1987,20 +2234,20 @@
 
 
 <PRE>
-% mfcalc
-pi = 3.141592653589
+$ <KBD>mfcalc</KBD>
+<KBD>pi = 3.141592653589</KBD>
 3.1415926536
-sin(pi)
+<KBD>sin(pi)</KBD>
 0.0000000000
-alpha = beta1 = 2.3
+<KBD>alpha = beta1 = 2.3</KBD>
 2.3000000000
-alpha
+<KBD>alpha</KBD>
 2.3000000000
-ln(alpha)
+<KBD>ln(alpha)</KBD>
 0.8329091229
-exp(ln(beta1))
+<KBD>exp(ln(beta1))</KBD>
 2.3000000000
-%
+$
 </PRE>
 
 <P>
@@ -2009,7 +2256,7 @@
 
 
 
-<H3><A NAME="SEC35" HREF="bison_toc.html#TOC35">Declarations for <CODE>mfcalc</CODE></A></H3>
+<H3><A NAME="SEC36" HREF="bison_toc.html#TOC36">Declarations for <CODE>mfcalc</CODE></A></H3>
 
 <P>
 Here are the C and Bison declarations for the multi-function calculator.
@@ -2018,7 +2265,7 @@
 
 <PRE>
 %{
-#include &#60;math.h&#62;  /* For math functions, cos(), sin(), etc. */
+#include &#60;math.h&#62;  /* For math functions, cos(), sin(), etc.  */
 #include "calc.h"  /* Contains definition of `symrec'        */
 %}
 %union {
@@ -2044,14 +2291,14 @@
 <P>
 The above grammar introduces only two new features of the Bison language.
 These features allow semantic values to have various data types
-(see section <A HREF="bison.html#SEC50">More Than One Value Type</A>).
+(see section <A HREF="bison.html#SEC51">More Than One Value Type</A>).
 
 
 <P>
 The <CODE>%union</CODE> declaration specifies the entire list of possible types;
 this is instead of defining <CODE>YYSTYPE</CODE>.  The allowable types are now
 double-floats (for <CODE>exp</CODE> and <CODE>NUM</CODE>) and pointers to entries in
-the symbol table.  See section <A HREF="bison.html#SEC61">The Collection of Value Types</A>.
+the symbol table.  See section <A HREF="bison.html#SEC62">The Collection of Value Types</A>.
 
 
 <P>
@@ -2063,16 +2310,17 @@
 
 
 <P>
-The Bison construct <CODE>%type</CODE> is used for declaring nonterminal symbols,
-just as <CODE>%token</CODE> is used for declaring token types.  We have not used
-<CODE>%type</CODE> before because nonterminal symbols are normally declared
-implicitly by the rules that define them.  But <CODE>exp</CODE> must be declared
-explicitly so we can specify its value type.  See section <A HREF="bison.html#SEC62">Nonterminal Symbols</A>.
+The Bison construct <CODE>%type</CODE> is used for declaring nonterminal
+symbols, just as <CODE>%token</CODE> is used for declaring token types.  We
+have not used <CODE>%type</CODE> before because nonterminal symbols are
+normally declared implicitly by the rules that define them.  But
+<CODE>exp</CODE> must be declared explicitly so we can specify its value type.
+See section <A HREF="bison.html#SEC63">Nonterminal Symbols</A>.
 
 
 
 
-<H3><A NAME="SEC36" HREF="bison_toc.html#TOC36">Grammar Rules for <CODE>mfcalc</CODE></A></H3>
+<H3><A NAME="SEC37" HREF="bison_toc.html#TOC37">Grammar Rules for <CODE>mfcalc</CODE></A></H3>
 
 <P>
 Here are the grammar rules for the multi-function calculator.
@@ -2110,9 +2358,9 @@
 
 
 
-<H3><A NAME="SEC37" HREF="bison_toc.html#TOC37">The <CODE>mfcalc</CODE> Symbol Table</A></H3>
+<H3><A NAME="SEC38" HREF="bison_toc.html#TOC38">The <CODE>mfcalc</CODE> Symbol Table</A></H3>
 <P>
-<A NAME="IDX54"></A>
+<A NAME="IDX65"></A>
 
 
 <P>
@@ -2130,7 +2378,7 @@
 
 
 <PRE>
-/* Fonctions type.                                   */
+/* Function type.                                    */
 typedef double (*func_t) (double);
 
 /* Data type for links in the chain of symbols.      */
@@ -2198,7 +2446,7 @@
 /* The symbol table: a chain of `struct symrec'.  */
 symrec *sym_table = (symrec *) 0;
 
-/* Put arithmetic functions in table. */
+/* Put arithmetic functions in table.  */
 void
 init_table (void)
 {
@@ -2236,7 +2484,7 @@
   ptr-&#62;name = (char *) malloc (strlen (sym_name) + 1);
   strcpy (ptr-&#62;name,sym_name);
   ptr-&#62;type = sym_type;
-  ptr-&#62;value.var = 0; /* set value to 0 even if fctn.  */
+  ptr-&#62;value.var = 0; /* Set value to 0 even if fctn.  */
   ptr-&#62;next = (struct symrec *)sym_table;
   sym_table = ptr;
   return ptr;
@@ -2269,6 +2517,7 @@
 <CODE>putsym</CODE>.  Again, a pointer and its type (which must be <CODE>VAR</CODE>) is
 returned to <CODE>yyparse</CODE>.
 
+
 <P>
 No change is needed in the handling of numeric values and arithmetic
 operators in <CODE>yylex</CODE>.
@@ -2283,7 +2532,7 @@
 {
   int c;
 
-  /* Ignore whitespace, get first nonwhite character.  */
+  /* Ignore white space, get first nonwhite character.  */
   while ((c = getchar ()) == ' ' || c == '\t');
 
   if (c == EOF)
@@ -2324,7 +2573,7 @@
           /* Get another character.                    */
           c = getchar ();
         }
-      while (c != EOF &#38;&#38; isalnum (c));
+      while (isalnum (c));
 
       ungetc (c, stdin);
       symbuf[i] = '\0';
@@ -2342,16 +2591,16 @@
 </PRE>
 
 <P>
-This program is both powerful and flexible. You may easily add new
-functions, and it is a simple job to modify this code to install predefined
-variables such as <CODE>pi</CODE> or <CODE>e</CODE> as well.
+This program is both powerful and flexible.  You may easily add new
+functions, and it is a simple job to modify this code to install
+predefined variables such as <CODE>pi</CODE> or <CODE>e</CODE> as well.
 
 
 
 
-<H2><A NAME="SEC38" HREF="bison_toc.html#TOC38">Exercises</A></H2>
+<H2><A NAME="SEC39" HREF="bison_toc.html#TOC39">Exercises</A></H2>
 <P>
-<A NAME="IDX55"></A>
+<A NAME="IDX66"></A>
 
 
 
@@ -2374,7 +2623,7 @@
 
 
 
-<H1><A NAME="SEC39" HREF="bison_toc.html#TOC39">Bison Grammar Files</A></H1>
+<H1><A NAME="SEC40" HREF="bison_toc.html#TOC40">Bison Grammar Files</A></H1>
 
 <P>
 Bison takes as input a context-free grammar specification and produces a
@@ -2383,12 +2632,12 @@
 
 <P>
 The Bison grammar input file conventionally has a name ending in <SAMP>`.y'</SAMP>.
-See section <A HREF="bison.html#SEC96">Invoking Bison</A>.
+See section <A HREF="bison.html#SEC100">Invoking Bison</A>.
 
 
 
 
-<H2><A NAME="SEC40" HREF="bison_toc.html#TOC40">Outline of a Bison Grammar</A></H2>
+<H2><A NAME="SEC41" HREF="bison_toc.html#TOC41">Outline of a Bison Grammar</A></H2>
 
 <P>
 A Bison grammar file has four main sections, shown here with the
@@ -2398,7 +2647,7 @@
 
 <PRE>
 %{
-<VAR>C declarations</VAR>
+<VAR>Prologue</VAR>
 %}
 
 <VAR>Bison declarations</VAR>
@@ -2407,7 +2656,7 @@
 <VAR>Grammar rules</VAR>
 %%
 
-<VAR>Additional C code</VAR>
+<VAR>Epilogue</VAR>
 </PRE>
 
 <P>
@@ -2416,14 +2665,15 @@
 
 
 
-<H3><A NAME="SEC41" HREF="bison_toc.html#TOC41">The C Declarations Section</A></H3>
+<H3><A NAME="SEC42" HREF="bison_toc.html#TOC42">The prologue</A></H3>
 <P>
-<A NAME="IDX56"></A>
-<A NAME="IDX57"></A>
+<A NAME="IDX67"></A>
+<A NAME="IDX68"></A>
+<A NAME="IDX69"></A>
 
 
 <P>
-The <VAR>C declarations</VAR> section contains macro definitions and
+The <VAR>Prologue</VAR> section contains macro definitions and
 declarations of functions and variables that are used in the actions in the
 grammar rules.  These are copied to the beginning of the parser file so
 that they precede the definition of <CODE>yyparse</CODE>.  You can use
@@ -2432,32 +2682,62 @@
 delimiters that bracket this section.
 
 
+<P>
+You may have more than one <VAR>Prologue</VAR> section, intermixed with the
+<VAR>Bison declarations</VAR>.  This allows you to have C and Bison
+declarations that refer to each other.  For example, the <CODE>%union</CODE>
+declaration may use types defined in a header file, and you may wish to
+prototype functions that take arguments of type <CODE>YYSTYPE</CODE>.  This
+can be done with two <VAR>Prologue</VAR> blocks, one before and one after the
+<CODE>%union</CODE> declaration.
+
+
+
+<PRE>
+%{
+#include &#60;stdio.h&#62;
+#include "ptypes.h"
+%}
+
+%union {
+  long n;
+  tree t;  /* <CODE>tree</CODE> is defined in <TT>`ptypes.h'</TT>. */
+}
+
+%{
+static void yyprint(FILE *, int, YYSTYPE);
+#define YYPRINT(F, N, L) yyprint(F, N, L)
+%}
+
+...
+</PRE>
+
 
 
-<H3><A NAME="SEC42" HREF="bison_toc.html#TOC42">The Bison Declarations Section</A></H3>
+<H3><A NAME="SEC43" HREF="bison_toc.html#TOC43">The Bison Declarations Section</A></H3>
 <P>
-<A NAME="IDX58"></A>
-<A NAME="IDX59"></A>
+<A NAME="IDX70"></A>
+<A NAME="IDX71"></A>
 
 
 <P>
 The <VAR>Bison declarations</VAR> section contains declarations that define
 terminal and nonterminal symbols, specify precedence, and so on.
 In some simple grammars you may not need any declarations.
-See section <A HREF="bison.html#SEC58">Bison Declarations</A>.
+See section <A HREF="bison.html#SEC59">Bison Declarations</A>.
 
 
 
 
-<H3><A NAME="SEC43" HREF="bison_toc.html#TOC43">The Grammar Rules Section</A></H3>
+<H3><A NAME="SEC44" HREF="bison_toc.html#TOC44">The Grammar Rules Section</A></H3>
 <P>
-<A NAME="IDX60"></A>
-<A NAME="IDX61"></A>
+<A NAME="IDX72"></A>
+<A NAME="IDX73"></A>
 
 
 <P>
 The <EM>grammar rules</EM> section contains one or more Bison grammar
-rules, and nothing else.  See section <A HREF="bison.html#SEC46">Syntax of Grammar Rules</A>.
+rules, and nothing else.  See section <A HREF="bison.html#SEC47">Syntax of Grammar Rules</A>.
 
 
 <P>
@@ -2468,19 +2748,20 @@
 
 
 
-<H3><A NAME="SEC44" HREF="bison_toc.html#TOC44">The Additional C Code Section</A></H3>
+<H3><A NAME="SEC45" HREF="bison_toc.html#TOC45">The epilogue</A></H3>
 <P>
-<A NAME="IDX62"></A>
-<A NAME="IDX63"></A>
+<A NAME="IDX74"></A>
+<A NAME="IDX75"></A>
+<A NAME="IDX76"></A>
 
 
 <P>
-The <VAR>additional C code</VAR> section is copied verbatim to the end of the
-parser file, just as the <VAR>C declarations</VAR> 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 <CODE>yyparse</CODE>.  For example, the definitions of
-<CODE>yylex</CODE> and <CODE>yyerror</CODE> often go here.  See section <A HREF="bison.html#SEC68">Parser C-Language Interface</A>.
+The <VAR>Epilogue</VAR> is copied verbatim to the end of the parser file, just as
+the <VAR>Prologue</VAR> 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 <CODE>yyparse</CODE>.  For example, the
+definitions of <CODE>yylex</CODE> and <CODE>yyerror</CODE> often go here.
+See section <A HREF="bison.html#SEC69">Parser C-Language Interface</A>.
 
 
 <P>
@@ -2492,17 +2773,17 @@
 The Bison parser itself contains many static variables whose names start
 with <SAMP>`yy'</SAMP> and many macros whose names start with <SAMP>`YY'</SAMP>.  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.
+manual) in the epilogue of the grammar file.
 
 
 
 
-<H2><A NAME="SEC45" HREF="bison_toc.html#TOC45">Symbols, Terminal and Nonterminal</A></H2>
+<H2><A NAME="SEC46" HREF="bison_toc.html#TOC46">Symbols, Terminal and Nonterminal</A></H2>
 <P>
-<A NAME="IDX64"></A>
-<A NAME="IDX65"></A>
-<A NAME="IDX66"></A>
-<A NAME="IDX67"></A>
+<A NAME="IDX77"></A>
+<A NAME="IDX78"></A>
+<A NAME="IDX79"></A>
+<A NAME="IDX80"></A>
 
 
 <P>
@@ -2542,18 +2823,18 @@
 A <EM>named token type</EM> is written with an identifier, like an
 identifier in C.  By convention, it should be all upper case.  Each
 such name must be defined with a Bison declaration such as
-<CODE>%token</CODE>.  See section <A HREF="bison.html#SEC59">Token Type Names</A>.
+<CODE>%token</CODE>.  See section <A HREF="bison.html#SEC60">Token Type Names</A>.
 
 <LI>
 
-<A NAME="IDX68"></A>
-<A NAME="IDX69"></A>
-<A NAME="IDX70"></A>
+<A NAME="IDX81"></A>
+<A NAME="IDX82"></A>
+<A NAME="IDX83"></A>
 A <EM>character token type</EM> (or <EM>literal character token</EM>) is
 written in the grammar using the same syntax used in C for character
 constants; for example, <CODE>'+'</CODE> is a character token type.  A
 character token type doesn't need to be declared unless you need to
-specify its semantic value data type (see section <A HREF="bison.html#SEC49">Data Types of Semantic Values</A>), associativity, or precedence (see section <A HREF="bison.html#SEC80">Operator Precedence</A>).
+specify its semantic value data type (see section <A HREF="bison.html#SEC50">Data Types of Semantic Values</A>), associativity, or precedence (see section <A HREF="bison.html#SEC81">Operator Precedence</A>).
 
 By convention, a character token type is used only to represent a
 token that consists of that particular character.  Thus, the token
@@ -2563,24 +2844,24 @@
 
 All the usual escape sequences used in character literals in C can be
 used in Bison as well, but you must not use the null character as a
-character literal because its ASCII code, zero, is the code <CODE>yylex</CODE>
-returns for end-of-input (see section <A HREF="bison.html#SEC71">Calling Convention for <CODE>yylex</CODE></A>).
+character literal because its numeric code, zero, signifies
+end-of-input (see section <A HREF="bison.html#SEC72">Calling Convention for <CODE>yylex</CODE></A>).
 
 <LI>
 
-<A NAME="IDX71"></A>
-<A NAME="IDX72"></A>
-<A NAME="IDX73"></A>
+<A NAME="IDX84"></A>
+<A NAME="IDX85"></A>
+<A NAME="IDX86"></A>
 A <EM>literal string token</EM> is written like a C string constant; for
 example, <CODE>"&#60;="</CODE> is a literal string token.  A literal string token
 doesn't need to be declared unless you need to specify its semantic
-value data type (see section <A HREF="bison.html#SEC49">Data Types of Semantic Values</A>), associativity, or precedence
-(see section <A HREF="bison.html#SEC80">Operator Precedence</A>).
+value data type (see section <A HREF="bison.html#SEC50">Data Types of Semantic Values</A>), associativity, or precedence
+(see section <A HREF="bison.html#SEC81">Operator Precedence</A>).
 
 You can associate the literal string token with a symbolic name as an
-alias, using the <CODE>%token</CODE> declaration (see section <A HREF="bison.html#SEC59">Token Type Names</A>).  If you don't do that, the lexical analyzer has to
+alias, using the <CODE>%token</CODE> declaration (see section <A HREF="bison.html#SEC60">Token Type Names</A>).  If you don't do that, the lexical analyzer has to
 retrieve the token number for the literal string token from the
-<CODE>yytname</CODE> table (see section <A HREF="bison.html#SEC71">Calling Convention for <CODE>yylex</CODE></A>).
+<CODE>yytname</CODE> table (see section <A HREF="bison.html#SEC72">Calling Convention for <CODE>yylex</CODE></A>).
 
 <STRONG>WARNING</STRONG>: literal string tokens do not work in Yacc.
 
@@ -2603,15 +2884,18 @@
 
 
 <P>
-The value returned by <CODE>yylex</CODE> is always one of the terminal symbols
-(or 0 for end-of-input).  Whichever way you write the token type in the
-grammar rules, you write it the same way in the definition of <CODE>yylex</CODE>.
-The numeric code for a character token type is simply the ASCII code for
-the character, so <CODE>yylex</CODE> can use the identical character constant to
-generate the requisite code.  Each named token type becomes a C macro in
+The value returned by <CODE>yylex</CODE> is always one of the terminal
+symbols, except that a zero or negative value signifies end-of-input.
+Whichever way you write the token type in the grammar rules, you write
+it the same way in the definition of <CODE>yylex</CODE>.  The numeric code
+for a character token type is simply the positive numeric code of the
+character, so <CODE>yylex</CODE> can use the identical value to generate the
+requisite code, though you may need to convert it to <CODE>unsigned
+char</CODE> to avoid sign-extension on hosts where <CODE>char</CODE> is signed.
+Each named token type becomes a C macro in
 the parser file, so <CODE>yylex</CODE> can use the name to stand for the code.
 (This is why periods don't make sense in terminal symbols.)
-See section <A HREF="bison.html#SEC71">Calling Convention for <CODE>yylex</CODE></A>.
+See section <A HREF="bison.html#SEC72">Calling Convention for <CODE>yylex</CODE></A>.
 
 
 <P>
@@ -2619,22 +2903,51 @@
 token-type macro definitions to be available there.  Use the <SAMP>`-d'</SAMP>
 option when you run Bison, so that it will write these macro definitions
 into a separate header file <TT>`<VAR>name</VAR>.tab.h'</TT> which you can include
-in the other source files that need it.  See section <A HREF="bison.html#SEC96">Invoking Bison</A>.
+in the other source files that need it.  See section <A HREF="bison.html#SEC100">Invoking Bison</A>.
+
+
+<P>
+If you want to write a grammar that is portable to any Standard C
+host, you must use only non-null character tokens taken from the basic
+execution character set of Standard C.  This set consists of the ten
+digits, the 52 lower- and upper-case English letters, and the
+characters in the following C-language string:
+
+
+
+<PRE>
+"\a\b\t\n\v\f\r !\"#%&#38;'()*+,-./:;&#60;=&#62;?[\\]^_{|}~"
+</PRE>
+
+<P>
+The <CODE>yylex</CODE> function and Bison must use a consistent character
+set and encoding for character tokens.  For example, if you run Bison in an
+ASCII environment, but then compile and run the resulting program
+in an environment that uses an incompatible character set like
+EBCDIC, the resulting program may not work because the
+tables generated by Bison will assume ASCII numeric values for
+character tokens.  It is standard
+practice for software distributions to contain C source files that
+were generated by Bison in an ASCII environment, so installers on
+platforms that are incompatible with ASCII must rebuild those
+files before compiling them.
 
 
 <P>
 The symbol <CODE>error</CODE> is a terminal symbol reserved for error recovery
-(see section <A HREF="bison.html#SEC90">Error Recovery</A>); you shouldn't use it for any other purpose.
-In particular, <CODE>yylex</CODE> should never return this value.
+(see section <A HREF="bison.html#SEC92">Error Recovery</A>); you shouldn't use it for any other purpose.
+In particular, <CODE>yylex</CODE> should never return this value.  The default
+value of the error token is 256, unless you explicitly assigned 256 to
+one of your tokens with a <CODE>%token</CODE> declaration.
 
 
 
 
-<H2><A NAME="SEC46" HREF="bison_toc.html#TOC46">Syntax of Grammar Rules</A></H2>
+<H2><A NAME="SEC47" HREF="bison_toc.html#TOC47">Syntax of Grammar Rules</A></H2>
 <P>
-<A NAME="IDX74"></A>
-<A NAME="IDX75"></A>
-<A NAME="IDX76"></A>
+<A NAME="IDX87"></A>
+<A NAME="IDX88"></A>
+<A NAME="IDX89"></A>
 
 
 <P>
@@ -2650,7 +2963,7 @@
 <P>
 where <VAR>result</VAR> is the nonterminal symbol that this rule describes,
 and <VAR>components</VAR> are various terminal and nonterminal symbols that
-are put together by this rule (see section <A HREF="bison.html#SEC45">Symbols, Terminal and Nonterminal</A>).
+are put together by this rule (see section <A HREF="bison.html#SEC46">Symbols, Terminal and Nonterminal</A>).
 
 
 <P>
@@ -2669,8 +2982,8 @@
 
 
 <P>
-Whitespace in rules is significant only to separate symbols.  You can add
-extra whitespace as you wish.
+White space in rules is significant only to separate symbols.  You can add
+extra white space as you wish.
 
 
 <P>
@@ -2685,11 +2998,11 @@
 
 <P>
 Usually there is only one action and it follows the components.
-See section <A HREF="bison.html#SEC51">Actions</A>.
+See section <A HREF="bison.html#SEC52">Actions</A>.
 
 
 <P>
-<A NAME="IDX77"></A>
+<A NAME="IDX90"></A>
 Multiple rules for the same <VAR>result</VAR> can be written separately or can
 be joined with the vertical-bar character <SAMP>`|'</SAMP> as follows:
 
@@ -2730,9 +3043,9 @@
 
 
 
-<H2><A NAME="SEC47" HREF="bison_toc.html#TOC47">Recursive Rules</A></H2>
+<H2><A NAME="SEC48" HREF="bison_toc.html#TOC48">Recursive Rules</A></H2>
 <P>
-<A NAME="IDX78"></A>
+<A NAME="IDX91"></A>
 
 
 <P>
@@ -2751,8 +3064,8 @@
 </PRE>
 
 <P>
-<A NAME="IDX79"></A>
-<A NAME="IDX80"></A>
+<A NAME="IDX92"></A>
+<A NAME="IDX93"></A>
 Since the recursive use of <CODE>expseq1</CODE> is the leftmost symbol in the
 right hand side, we call this <EM>left recursion</EM>.  By contrast, here
 the same construct is defined using <EM>right recursion</EM>:
@@ -2766,18 +3079,18 @@
 </PRE>
 
 <P>
-Any kind of sequence can be defined using either left recursion or
-right recursion, but you should always use left recursion, because it
-can parse a sequence of any number of elements with bounded stack
-space.  Right recursion uses up space on the Bison stack in proportion
-to the number of elements in the sequence, because all the elements
-must be shifted onto the stack before the rule can be applied even
-once.  See section <A HREF="bison.html#SEC77">The Bison Parser Algorithm</A>, for
-further explanation of this.
+Any kind of sequence can be defined using either left recursion or right
+recursion, but you should always use left recursion, because it can
+parse a sequence of any number of elements with bounded stack space.
+Right recursion uses up space on the Bison stack in proportion to the
+number of elements in the sequence, because all the elements must be
+shifted onto the stack before the rule can be applied even once.
+See section <A HREF="bison.html#SEC78">The Bison Parser Algorithm</A>, for further explanation
+of this.
 
 
 <P>
-<A NAME="IDX81"></A>
+<A NAME="IDX94"></A>
 <EM>Indirect</EM> or <EM>mutual</EM> recursion occurs when the result of the
 rule does not appear directly on its right hand side, but does appear
 in rules for other nonterminals which do appear on its right hand
@@ -2806,10 +3119,10 @@
 
 
 
-<H2><A NAME="SEC48" HREF="bison_toc.html#TOC48">Defining Language Semantics</A></H2>
+<H2><A NAME="SEC49" HREF="bison_toc.html#TOC49">Defining Language Semantics</A></H2>
 <P>
-<A NAME="IDX82"></A>
-<A NAME="IDX83"></A>
+<A NAME="IDX95"></A>
+<A NAME="IDX96"></A>
 
 
 <P>
@@ -2827,18 +3140,18 @@
 
 
 
-<H3><A NAME="SEC49" HREF="bison_toc.html#TOC49">Data Types of Semantic Values</A></H3>
+<H3><A NAME="SEC50" HREF="bison_toc.html#TOC50">Data Types of Semantic Values</A></H3>
 <P>
-<A NAME="IDX84"></A>
-<A NAME="IDX85"></A>
-<A NAME="IDX86"></A>
-<A NAME="IDX87"></A>
+<A NAME="IDX97"></A>
+<A NAME="IDX98"></A>
+<A NAME="IDX99"></A>
+<A NAME="IDX100"></A>
 
 
 <P>
 In a simple program it may be sufficient to use the same data type for
 the semantic values of all language constructs.  This was true in the
-RPN and infix calculator examples (see section <A HREF="bison.html#SEC17">Reverse Polish Notation Calculator</A>).
+RPN and infix calculator examples (see section <A HREF="bison.html#SEC18">Reverse Polish Notation Calculator</A>).
 
 
 <P>
@@ -2852,13 +3165,13 @@
 </PRE>
 
 <P>
-This macro definition must go in the C declarations section of the grammar
-file (see section <A HREF="bison.html#SEC40">Outline of a Bison Grammar</A>).
+This macro definition must go in the prologue of the grammar file
+(see section <A HREF="bison.html#SEC41">Outline of a Bison Grammar</A>).
 
 
 
 
-<H3><A NAME="SEC50" HREF="bison_toc.html#TOC50">More Than One Value Type</A></H3>
+<H3><A NAME="SEC51" HREF="bison_toc.html#TOC51">More Than One Value Type</A></H3>
 
 <P>
 In most programs, you will need different data types for different kinds
@@ -2877,23 +3190,23 @@
 <LI>
 
 Specify the entire collection of possible data types, with the
-<CODE>%union</CODE> Bison declaration (see section <A HREF="bison.html#SEC61">The Collection of Value Types</A>).
+<CODE>%union</CODE> Bison declaration (see section <A HREF="bison.html#SEC62">The Collection of Value Types</A>).
 
 <LI>
 
 Choose one of those types for each symbol (terminal or nonterminal) for
 which semantic values are used.  This is done for tokens with the
-<CODE>%token</CODE> Bison declaration (see section <A HREF="bison.html#SEC59">Token Type Names</A>)
-and for groupings with the <CODE>%type</CODE> Bison declaration (see section <A HREF="bison.html#SEC62">Nonterminal Symbols</A>).
+<CODE>%token</CODE> Bison declaration (see section <A HREF="bison.html#SEC60">Token Type Names</A>)
+and for groupings with the <CODE>%type</CODE> Bison declaration (see section <A HREF="bison.html#SEC63">Nonterminal Symbols</A>).
 </UL>
 
 
 
-<H3><A NAME="SEC51" HREF="bison_toc.html#TOC51">Actions</A></H3>
+<H3><A NAME="SEC52" HREF="bison_toc.html#TOC52">Actions</A></H3>
 <P>
-<A NAME="IDX88"></A>
-<A NAME="IDX89"></A>
-<A NAME="IDX90"></A>
+<A NAME="IDX101"></A>
+<A NAME="IDX102"></A>
+<A NAME="IDX103"></A>
 
 
 <P>
@@ -2905,10 +3218,10 @@
 
 <P>
 An action consists of C statements surrounded by braces, much like a
-compound statement in C.  It can be placed at any position in the rule; it
-is executed at that position.  Most rules have just one action at the end
-of the rule, following all the components.  Actions in the middle of a rule
-are tricky and used only for special purposes (see section <A HREF="bison.html#SEC53">Actions in Mid-Rule</A>).
+compound statement in C.  It can be placed at any position in the rule;
+it is executed at that position.  Most rules have just one action at the
+end of the rule, following all the components.  Actions in the middle of
+a rule are tricky and used only for special purposes (see section <A HREF="bison.html#SEC54">Actions in Mid-Rule</A>).
 
 
 <P>
@@ -2941,8 +3254,22 @@
 useful semantic value associated with the <SAMP>`+'</SAMP> token, it could be
 referred to as <CODE>$2</CODE>.
 
+
 <P>
-<A NAME="IDX91"></A>
+Note that the vertical-bar character <SAMP>`|'</SAMP> is really a rule
+separator, and actions are attached to a single rule.  This is a
+difference with tools like Flex, for which <SAMP>`|'</SAMP> stands for either
+"or", or "the same action as that of the next rule".  In the
+following example, the action is triggered only when <SAMP>`b'</SAMP> is found:
+
+
+
+<PRE>
+a-or-b: 'a'|'b'   { a_or_b_found = 1; };
+</PRE>
+
+<P>
+<A NAME="IDX104"></A>
 If you don't specify an action for a rule, Bison supplies a default:
 <CODE>$$ = $1</CODE>.  Thus, the value of the first symbol in the rule becomes
 the value of the whole rule.  Of course, the default rule is valid only
@@ -2978,10 +3305,10 @@
 
 
 
-<H3><A NAME="SEC52" HREF="bison_toc.html#TOC52">Data Types of Values in Actions</A></H3>
+<H3><A NAME="SEC53" HREF="bison_toc.html#TOC53">Data Types of Values in Actions</A></H3>
 <P>
-<A NAME="IDX92"></A>
-<A NAME="IDX93"></A>
+<A NAME="IDX105"></A>
+<A NAME="IDX106"></A>
 
 
 <P>
@@ -2997,6 +3324,7 @@
 in the rule.  In this example,
 
 
+
 <PRE>
 exp:    ...
         | exp '+' exp
@@ -3009,6 +3337,7 @@
 <CODE>$2</CODE> were used, it would have the data type declared for the
 terminal symbol <CODE>'+'</CODE>, whatever that might be.
 
+
 <P>
 Alternatively, you can specify the data type when you refer to the value,
 by inserting <SAMP>`&#60;<VAR>type</VAR>&#62;'</SAMP> after the <SAMP>`$'</SAMP> at the beginning of the
@@ -3030,10 +3359,10 @@
 
 
 
-<H3><A NAME="SEC53" HREF="bison_toc.html#TOC53">Actions in Mid-Rule</A></H3>
+<H3><A NAME="SEC54" HREF="bison_toc.html#TOC54">Actions in Mid-Rule</A></H3>
 <P>
-<A NAME="IDX94"></A>
-<A NAME="IDX95"></A>
+<A NAME="IDX107"></A>
+<A NAME="IDX108"></A>
 
 
 <P>
@@ -3143,7 +3472,7 @@
 must commit to using one rule or the other, without sufficient
 information to do it correctly.  (The open-brace token is what is called
 the <EM>look-ahead</EM> token at this time, since the parser is still
-deciding what to do about it.  See section <A HREF="bison.html#SEC78">Look-Ahead Tokens</A>.)
+deciding what to do about it.  See section <A HREF="bison.html#SEC79">Look-Ahead Tokens</A>.)
 
 
 <P>
@@ -3212,30 +3541,30 @@
 
 
 
-<H2><A NAME="SEC54" HREF="bison_toc.html#TOC54">Tracking Locations</A></H2>
+<H2><A NAME="SEC55" HREF="bison_toc.html#TOC55">Tracking Locations</A></H2>
 <P>
-<A NAME="IDX96"></A>
-<A NAME="IDX97"></A>
-<A NAME="IDX98"></A>
+<A NAME="IDX109"></A>
+<A NAME="IDX110"></A>
+<A NAME="IDX111"></A>
 
 
 <P>
 Though grammar rules and semantic actions are enough to write a fully
-functional parser, it can be useful to process some additionnal informations,
+functional parser, it can be useful to process some additional information,
 especially symbol locations.
 
 
 <P>
-The way locations are handled is defined by providing a data type, and actions
-to take when rules are matched.
+The way locations are handled is defined by providing a data type, and
+actions to take when rules are matched.
 
 
 
 
-<H3><A NAME="SEC55" HREF="bison_toc.html#TOC55">Data Type of Locations</A></H3>
+<H3><A NAME="SEC56" HREF="bison_toc.html#TOC56">Data Type of Locations</A></H3>
 <P>
-<A NAME="IDX99"></A>
-<A NAME="IDX100"></A>
+<A NAME="IDX112"></A>
+<A NAME="IDX113"></A>
 
 
 <P>
@@ -3262,12 +3591,12 @@
 
 
 
-<H3><A NAME="SEC56" HREF="bison_toc.html#TOC56">Actions and Locations</A></H3>
+<H3><A NAME="SEC57" HREF="bison_toc.html#TOC57">Actions and Locations</A></H3>
 <P>
-<A NAME="IDX101"></A>
-<A NAME="IDX102"></A>
-<A NAME="IDX103"></A>
-<A NAME="IDX104"></A>
+<A NAME="IDX114"></A>
+<A NAME="IDX115"></A>
+<A NAME="IDX116"></A>
+<A NAME="IDX117"></A>
 
 
 <P>
@@ -3277,7 +3606,7 @@
 
 <P>
 The most obvious way for building locations of syntactic groupings is very
-similar to the way semantic values are computed. In a given rule, several
+similar to the way semantic values are computed.  In a given rule, several
 constructs can be used to access the locations of the elements being matched.
 The location of the <VAR>n</VAR>th component of the right hand side is
 <CODE>@<VAR>n</VAR></CODE>, while the location of the left hand side grouping is
@@ -3311,13 +3640,13 @@
 
 <P>
 As for semantic values, there is a default action for locations that is
-run each time a rule is matched. It sets the beginning of <CODE>@$</CODE> to the
+run each time a rule is matched.  It sets the beginning of <CODE>@$</CODE> to the
 beginning of the first symbol, and the end of <CODE>@$</CODE> to the end of the
 last symbol.
 
 
 <P>
-With this default action, the location tracking can be fully automatic. The
+With this default action, the location tracking can be fully automatic.  The
 example above simply rewrites this way:
 
 
@@ -3340,17 +3669,17 @@
 
 
 
-<H3><A NAME="SEC57" HREF="bison_toc.html#TOC57">Default Action for Locations</A></H3>
+<H3><A NAME="SEC58" HREF="bison_toc.html#TOC58">Default Action for Locations</A></H3>
 <P>
-<A NAME="IDX105"></A>
+<A NAME="IDX118"></A>
 
 
 <P>
-Actually, actions are not the best place to compute locations. Since locations
-are much more general than semantic values, there is room in the output parser
-to redefine the default action to take for each rule. The
-<CODE>YYLLOC_DEFAULT</CODE> macro is called each time a rule is matched, before the
-associated action is run.
+Actually, actions are not the best place to compute locations.  Since
+locations are much more general than semantic values, there is room in
+the output parser to redefine the default action to take for each
+rule.  The <CODE>YYLLOC_DEFAULT</CODE> macro is invoked each time a rule is
+matched, before the associated action is run.
 
 
 <P>
@@ -3359,21 +3688,36 @@
 
 
 <P>
-The <CODE>YYLLOC_DEFAULT</CODE> macro takes three parameters. The first one is
-the location of the grouping (the result of the computation). The second one
+The <CODE>YYLLOC_DEFAULT</CODE> macro takes three parameters.  The first one is
+the location of the grouping (the result of the computation).  The second one
 is an array holding locations of all right hand side elements of the rule
-being matched. The last one is the size of the right hand side rule.
+being matched.  The last one is the size of the right hand side rule.
+
+
+<P>
+By default, it is defined this way for simple LALR(1) parsers:
 
 
+
+<PRE>
+#define YYLLOC_DEFAULT(Current, Rhs, N)          \
+  Current.first_line   = Rhs[1].first_line;      \
+  Current.first_column = Rhs[1].first_column;    \
+  Current.last_line    = Rhs[N].last_line;       \
+  Current.last_column  = Rhs[N].last_column;
+</PRE>
+
 <P>
-By default, it is defined this way:
+and like this for GLR parsers:
 
 
 
 <PRE>
-#define YYLLOC_DEFAULT(Current, Rhs, N)         \
-  Current.last_line   = Rhs[N].last_line;       \
-  Current.last_column = Rhs[N].last_column;
+#define YYLLOC_DEFAULT(Current, Rhs, N)          \
+  Current.first_line   = YYRHSLOC(Rhs,1).first_line;      \
+  Current.first_column = YYRHSLOC(Rhs,1).first_column;    \
+  Current.last_line    = YYRHSLOC(Rhs,N).last_line;       \
+  Current.last_column  = YYRHSLOC(Rhs,N).last_column;
 </PRE>
 
 <P>
@@ -3384,39 +3728,34 @@
 <UL>
 <LI>
 
-All arguments are free of side-effects. However, only the first one (the
+All arguments are free of side-effects.  However, only the first one (the
 result) should be modified by <CODE>YYLLOC_DEFAULT</CODE>.
 
 <LI>
 
-Before <CODE>YYLLOC_DEFAULT</CODE> is executed, the output parser sets <CODE>@$</CODE>
-to <CODE>@1</CODE>.
-
-<LI>
-
-For consistency with semantic actions, valid indexes for the location array
-range from 1 to <VAR>n</VAR>.
+For consistency with semantic actions, valid indexes for the location
+array range from 1 to <VAR>n</VAR>.
 </UL>
 
 
 
-<H2><A NAME="SEC58" HREF="bison_toc.html#TOC58">Bison Declarations</A></H2>
+<H2><A NAME="SEC59" HREF="bison_toc.html#TOC59">Bison Declarations</A></H2>
 <P>
-<A NAME="IDX106"></A>
-<A NAME="IDX107"></A>
+<A NAME="IDX119"></A>
+<A NAME="IDX120"></A>
 
 
 <P>
 The <EM>Bison declarations</EM> section of a Bison grammar defines the symbols
 used in formulating the grammar and the data types of semantic values.
-See section <A HREF="bison.html#SEC45">Symbols, Terminal and Nonterminal</A>.
+See section <A HREF="bison.html#SEC46">Symbols, Terminal and Nonterminal</A>.
 
 
 <P>
 All token type names (but not single-character literal tokens such as
 <CODE>'+'</CODE> and <CODE>'*'</CODE>) must be declared.  Nonterminal symbols must be
 declared if you need to specify which data type to use for the semantic
-value (see section <A HREF="bison.html#SEC50">More Than One Value Type</A>).
+value (see section <A HREF="bison.html#SEC51">More Than One Value Type</A>).
 
 
 <P>
@@ -3427,12 +3766,12 @@
 
 
 
-<H3><A NAME="SEC59" HREF="bison_toc.html#TOC59">Token Type Names</A></H3>
+<H3><A NAME="SEC60" HREF="bison_toc.html#TOC60">Token Type Names</A></H3>
 <P>
-<A NAME="IDX108"></A>
-<A NAME="IDX109"></A>
-<A NAME="IDX110"></A>
-<A NAME="IDX111"></A>
+<A NAME="IDX121"></A>
+<A NAME="IDX122"></A>
+<A NAME="IDX123"></A>
+<A NAME="IDX124"></A>
 
 
 <P>
@@ -3453,7 +3792,7 @@
 <P>
 Alternatively, you can use <CODE>%left</CODE>, <CODE>%right</CODE>, or
 <CODE>%nonassoc</CODE> instead of <CODE>%token</CODE>, if you wish to specify
-associativity and precedence.  See section <A HREF="bison.html#SEC60">Operator Precedence</A>.
+associativity and precedence.  See section <A HREF="bison.html#SEC61">Operator Precedence</A>.
 
 
 <P>
@@ -3469,13 +3808,13 @@
 <P>
 It is generally best, however, to let Bison choose the numeric codes for
 all token types.  Bison will automatically select codes that don't conflict
-with each other or with ASCII characters.
+with each other or with normal characters.
 
 
 <P>
 In the event that the stack type is a union, you must augment the
 <CODE>%token</CODE> or other token declaration to include the data type
-alternative delimited by angle-brackets (see section <A HREF="bison.html#SEC50">More Than One Value Type</A>).
+alternative delimited by angle-brackets (see section <A HREF="bison.html#SEC51">More Than One Value Type</A>).
 
 
 <P>
@@ -3518,23 +3857,24 @@
 Once you equate the literal string and the token name, you can use them
 interchangeably in further declarations or the grammar rules.  The
 <CODE>yylex</CODE> function can use the token name or the literal string to
-obtain the token type code number (see section <A HREF="bison.html#SEC71">Calling Convention for <CODE>yylex</CODE></A>).
+obtain the token type code number (see section <A HREF="bison.html#SEC72">Calling Convention for <CODE>yylex</CODE></A>).
 
 
 
 
-<H3><A NAME="SEC60" HREF="bison_toc.html#TOC60">Operator Precedence</A></H3>
+<H3><A NAME="SEC61" HREF="bison_toc.html#TOC61">Operator Precedence</A></H3>
 <P>
-<A NAME="IDX112"></A>
-<A NAME="IDX113"></A>
-<A NAME="IDX114"></A>
+<A NAME="IDX125"></A>
+<A NAME="IDX126"></A>
+<A NAME="IDX127"></A>
 
 
 <P>
 Use the <CODE>%left</CODE>, <CODE>%right</CODE> or <CODE>%nonassoc</CODE> declaration to
 declare a token and specify its precedence and associativity, all at
 once.  These are called <EM>precedence declarations</EM>.
-See section <A HREF="bison.html#SEC80">Operator Precedence</A>, for general information on operator precedence.
+See section <A HREF="bison.html#SEC81">Operator Precedence</A>, for general information on
+operator precedence.
 
 
 <P>
@@ -3587,11 +3927,11 @@
 
 
 
-<H3><A NAME="SEC61" HREF="bison_toc.html#TOC61">The Collection of Value Types</A></H3>
+<H3><A NAME="SEC62" HREF="bison_toc.html#TOC62">The Collection of Value Types</A></H3>
 <P>
-<A NAME="IDX115"></A>
-<A NAME="IDX116"></A>
-<A NAME="IDX117"></A>
+<A NAME="IDX128"></A>
+<A NAME="IDX129"></A>
+<A NAME="IDX130"></A>
 
 
 <P>
@@ -3617,7 +3957,7 @@
 This says that the two alternative types are <CODE>double</CODE> and <CODE>symrec
 *</CODE>.  They are given names <CODE>val</CODE> and <CODE>tptr</CODE>; these names are used
 in the <CODE>%token</CODE> and <CODE>%type</CODE> declarations to pick one of the types
-for a terminal or nonterminal symbol (see section <A HREF="bison.html#SEC62">Nonterminal Symbols</A>).
+for a terminal or nonterminal symbol (see section <A HREF="bison.html#SEC63">Nonterminal Symbols</A>).
 
 
 <P>
@@ -3627,11 +3967,11 @@
 
 
 
-<H3><A NAME="SEC62" HREF="bison_toc.html#TOC62">Nonterminal Symbols</A></H3>
+<H3><A NAME="SEC63" HREF="bison_toc.html#TOC63">Nonterminal Symbols</A></H3>
 <P>
-<A NAME="IDX118"></A>
-<A NAME="IDX119"></A>
-<A NAME="IDX120"></A>
+<A NAME="IDX131"></A>
+<A NAME="IDX132"></A>
+<A NAME="IDX133"></A>
 
 
 <P>
@@ -3646,11 +3986,12 @@
 </PRE>
 
 <P>
-Here <VAR>nonterminal</VAR> is the name of a nonterminal symbol, and <VAR>type</VAR>
-is the name given in the <CODE>%union</CODE> to the alternative that you want
-(see section <A HREF="bison.html#SEC61">The Collection of Value Types</A>).  You can give any number of nonterminal symbols in
-the same <CODE>%type</CODE> declaration, if they have the same value type.  Use
-spaces to separate the symbol names.
+Here <VAR>nonterminal</VAR> is the name of a nonterminal symbol, and
+<VAR>type</VAR> is the name given in the <CODE>%union</CODE> to the alternative
+that you want (see section <A HREF="bison.html#SEC62">The Collection of Value Types</A>).  You
+can give any number of nonterminal symbols in the same <CODE>%type</CODE>
+declaration, if they have the same value type.  Use spaces to separate
+the symbol names.
 
 
 <P>
@@ -3662,22 +4003,22 @@
 
 
 
-<H3><A NAME="SEC63" HREF="bison_toc.html#TOC63">Suppressing Conflict Warnings</A></H3>
+<H3><A NAME="SEC64" HREF="bison_toc.html#TOC64">Suppressing Conflict Warnings</A></H3>
 <P>
-<A NAME="IDX121"></A>
-<A NAME="IDX122"></A>
-<A NAME="IDX123"></A>
-<A NAME="IDX124"></A>
-<A NAME="IDX125"></A>
+<A NAME="IDX134"></A>
+<A NAME="IDX135"></A>
+<A NAME="IDX136"></A>
+<A NAME="IDX137"></A>
+<A NAME="IDX138"></A>
 
 
 <P>
 Bison normally warns if there are any conflicts in the grammar
-(see section <A HREF="bison.html#SEC79">Shift/Reduce Conflicts</A>), but most real grammars have harmless shift/reduce
-conflicts which are resolved in a predictable way and would be difficult to
-eliminate.  It is desirable to suppress the warning about these conflicts
-unless the number of conflicts changes.  You can do this with the
-<CODE>%expect</CODE> declaration.
+(see section <A HREF="bison.html#SEC80">Shift/Reduce Conflicts</A>), but most real grammars
+have harmless shift/reduce conflicts which are resolved in a predictable
+way and would be difficult to eliminate.  It is desirable to suppress
+the warning about these conflicts unless the number of conflicts
+changes.  You can do this with the <CODE>%expect</CODE> declaration.
 
 
 <P>
@@ -3690,10 +4031,11 @@
 </PRE>
 
 <P>
-Here <VAR>n</VAR> is a decimal integer.  The declaration says there should be no
-warning if there are <VAR>n</VAR> shift/reduce conflicts and no reduce/reduce
-conflicts.  The usual warning is given if there are either more or fewer
-conflicts, or if there are any reduce/reduce conflicts.
+Here <VAR>n</VAR> is a decimal integer.  The declaration says there should be
+no warning if there are <VAR>n</VAR> shift/reduce conflicts and no
+reduce/reduce conflicts.  An error, instead of the usual warning, is
+given if there are either more or fewer conflicts, or if there are any
+reduce/reduce conflicts.
 
 
 <P>
@@ -3728,12 +4070,12 @@
 
 
 
-<H3><A NAME="SEC64" HREF="bison_toc.html#TOC64">The Start-Symbol</A></H3>
+<H3><A NAME="SEC65" HREF="bison_toc.html#TOC65">The Start-Symbol</A></H3>
 <P>
-<A NAME="IDX126"></A>
-<A NAME="IDX127"></A>
-<A NAME="IDX128"></A>
-<A NAME="IDX129"></A>
+<A NAME="IDX139"></A>
+<A NAME="IDX140"></A>
+<A NAME="IDX141"></A>
+<A NAME="IDX142"></A>
 
 
 <P>
@@ -3749,11 +4091,11 @@
 
 
 
-<H3><A NAME="SEC65" HREF="bison_toc.html#TOC65">A Pure (Reentrant) Parser</A></H3>
+<H3><A NAME="SEC66" HREF="bison_toc.html#TOC66">A Pure (Reentrant) Parser</A></H3>
 <P>
-<A NAME="IDX130"></A>
-<A NAME="IDX131"></A>
-<A NAME="IDX132"></A>
+<A NAME="IDX143"></A>
+<A NAME="IDX144"></A>
+<A NAME="IDX145"></A>
 
 
 <P>
@@ -3775,21 +4117,21 @@
 
 <P>
 Alternatively, you can generate a pure, reentrant parser.  The Bison
-declaration <CODE>%pure_parser</CODE> says that you want the parser to be
+declaration <CODE>%pure-parser</CODE> says that you want the parser to be
 reentrant.  It looks like this:
 
 
 
 <PRE>
-%pure_parser
+%pure-parser
 </PRE>
 
 <P>
 The result is that the communication variables <CODE>yylval</CODE> and
 <CODE>yylloc</CODE> become local variables in <CODE>yyparse</CODE>, and a different
 calling convention is used for the lexical analyzer function
-<CODE>yylex</CODE>.  See section <A HREF="bison.html#SEC74">Calling Conventions for Pure Parsers</A>, for the details of this.  The variable <CODE>yynerrs</CODE> also
-becomes local in <CODE>yyparse</CODE> (see section <A HREF="bison.html#SEC75">The Error Reporting Function <CODE>yyerror</CODE></A>).  The convention for calling
+<CODE>yylex</CODE>.  See section <A HREF="bison.html#SEC75">Calling Conventions for Pure Parsers</A>, for the details of this.  The variable <CODE>yynerrs</CODE> also
+becomes local in <CODE>yyparse</CODE> (see section <A HREF="bison.html#SEC76">The Error Reporting Function <CODE>yyerror</CODE></A>).  The convention for calling
 <CODE>yyparse</CODE> itself is unchanged.
 
 
@@ -3801,15 +4143,15 @@
 
 
 
-<H3><A NAME="SEC66" HREF="bison_toc.html#TOC66">Bison Declaration Summary</A></H3>
+<H3><A NAME="SEC67" HREF="bison_toc.html#TOC67">Bison Declaration Summary</A></H3>
 <P>
-<A NAME="IDX133"></A>
-<A NAME="IDX134"></A>
-<A NAME="IDX135"></A>
+<A NAME="IDX146"></A>
+<A NAME="IDX147"></A>
+<A NAME="IDX148"></A>
 
 
 <P>
-Here is a summary of all Bison declarations:
+Here is a summary of the declarations used to define a grammar:
 
 
 <DL COMPACT>
@@ -3817,62 +4159,93 @@
 <DT><CODE>%union</CODE>
 <DD>
 Declare the collection of data types that semantic values may have
-(see section <A HREF="bison.html#SEC61">The Collection of Value Types</A>).
+(see section <A HREF="bison.html#SEC62">The Collection of Value Types</A>).
 
 <DT><CODE>%token</CODE>
 <DD>
 Declare a terminal symbol (token type name) with no precedence
-or associativity specified (see section <A HREF="bison.html#SEC59">Token Type Names</A>).
+or associativity specified (see section <A HREF="bison.html#SEC60">Token Type Names</A>).
 
 <DT><CODE>%right</CODE>
 <DD>
 Declare a terminal symbol (token type name) that is right-associative
-(see section <A HREF="bison.html#SEC60">Operator Precedence</A>).
+(see section <A HREF="bison.html#SEC61">Operator Precedence</A>).
 
 <DT><CODE>%left</CODE>
 <DD>
 Declare a terminal symbol (token type name) that is left-associative
-(see section <A HREF="bison.html#SEC60">Operator Precedence</A>).
+(see section <A HREF="bison.html#SEC61">Operator Precedence</A>).
 
 <DT><CODE>%nonassoc</CODE>
 <DD>
 Declare a terminal symbol (token type name) that is nonassociative
 (using it in a way that would be associative is a syntax error)
-(see section <A HREF="bison.html#SEC60">Operator Precedence</A>).
+(see section <A HREF="bison.html#SEC61">Operator Precedence</A>).
 
 <DT><CODE>%type</CODE>
 <DD>
 Declare the type of semantic values for a nonterminal symbol
-(see section <A HREF="bison.html#SEC62">Nonterminal Symbols</A>).
+(see section <A HREF="bison.html#SEC63">Nonterminal Symbols</A>).
 
 <DT><CODE>%start</CODE>
 <DD>
-Specify the grammar's start symbol (see section <A HREF="bison.html#SEC64">The Start-Symbol</A>).
+Specify the grammar's start symbol (see section <A HREF="bison.html#SEC65">The Start-Symbol</A>).
 
 <DT><CODE>%expect</CODE>
 <DD>
 Declare the expected number of shift-reduce conflicts
-(see section <A HREF="bison.html#SEC63">Suppressing Conflict Warnings</A>).
+(see section <A HREF="bison.html#SEC64">Suppressing Conflict Warnings</A>).
+</DL>
 
-<DT><CODE>%yacc</CODE>
+<P>
+In order to change the behavior of @command{bison}, use the following
+directives:
+
+
+<DL COMPACT>
+
+<DT><CODE>%debug</CODE>
 <DD>
-<DT><CODE>%fixed_output_files</CODE>
+In the parser file, define the macro <CODE>YYDEBUG</CODE> to 1 if it is not
+already defined, so that the debugging facilities are compiled.
+See section <A HREF="bison.html#SEC99">Tracing Your Parser</A>.
+
+<DT><CODE>%defines</CODE>
 <DD>
-Pretend the option @option{--yacc} was given, i.e., imitate Yacc,
-including its naming conventions.  See section <A HREF="bison.html#SEC97">Bison Options</A>, for more.
+Write an extra output file containing macro definitions for the token
+type names defined in the grammar and the semantic value type
+<CODE>YYSTYPE</CODE>, as well as a few <CODE>extern</CODE> variable declarations.
+
+If the parser output file is named <TT>`<VAR>name</VAR>.c'</TT> then this file
+is named <TT>`<VAR>name</VAR>.h'</TT>.
+
+This output file is essential if you wish to put the definition of
+<CODE>yylex</CODE> in a separate source file, because <CODE>yylex</CODE> needs to
+be able to refer to token type codes and the variable
+<CODE>yylval</CODE>.  See section <A HREF="bison.html#SEC73">Semantic Values of Tokens</A>.
+
+<DT><CODE>%file-prefix="<VAR>prefix</VAR>"</CODE>
+<DD>
+Specify a prefix to use for all Bison output file names.  The names are
+chosen as if the input file were named <TT>`<VAR>prefix</VAR>.y'</TT>.
 
 <DT><CODE>%locations</CODE>
 <DD>
-Generate the code processing the locations (see section <A HREF="bison.html#SEC76">Special Features for Use in Actions</A>).  This mode is enabled as soon as
+Generate the code processing the locations (see section <A HREF="bison.html#SEC77">Special Features for Use in Actions</A>).  This mode is enabled as soon as
 the grammar uses the special <SAMP>`@<VAR>n</VAR>'</SAMP> tokens, but if your
 grammar does not use it, using <SAMP>`%locations'</SAMP> allows for more
 accurate parse error messages.
 
-<DT><CODE>%pure_parser</CODE>
+<DT><CODE>%name-prefix="<VAR>prefix</VAR>"</CODE>
 <DD>
-Request a pure (reentrant) parser program (see section <A HREF="bison.html#SEC65">A Pure (Reentrant) Parser</A>).
+Rename the external symbols used in the parser so that they start with
+<VAR>prefix</VAR> instead of <SAMP>`yy'</SAMP>.  The precise list of symbols renamed
+is <CODE>yyparse</CODE>, <CODE>yylex</CODE>, <CODE>yyerror</CODE>, <CODE>yynerrs</CODE>,
+<CODE>yylval</CODE>, <CODE>yychar</CODE>, <CODE>yydebug</CODE>, and possible
+<CODE>yylloc</CODE>.  For example, if you use <SAMP>`%name-prefix="c_"'</SAMP>, the
+names become <CODE>c_parse</CODE>, <CODE>c_lex</CODE>, and so on.  See section <A HREF="bison.html#SEC68">Multiple Parsers in the Same Program</A>.
 
-<DT><CODE>%no_parser</CODE>
+<DT><CODE>%no-parser</CODE>
 <DD>
 Do not include any C code in the parser file; generate tables only.  The
 parser file contains just <CODE>#define</CODE> directives and static variable
@@ -3882,7 +4255,7 @@
 into a file named <TT>`<VAR>filename</VAR>.act'</TT>, in the form of a
 brace-surrounded body fit for a <CODE>switch</CODE> statement.
 
-<DT><CODE>%no_lines</CODE>
+<DT><CODE>%no-lines</CODE>
 <DD>
 Don't generate any <CODE>#line</CODE> preprocessor commands in the parser
 file.  Ordinarily Bison writes these commands in the parser file so that
@@ -3891,45 +4264,22 @@
 associate errors with the parser file, treating it an independent source
 file in its own right.
 
-<DT><CODE>%debug</CODE>
+<DT><CODE>%output="<VAR>filename</VAR>"</CODE>
 <DD>
-Output a definition of the macro <CODE>YYDEBUG</CODE> into the parser file, so
-that the debugging facilities are compiled.  See section <A HREF="bison.html#SEC95">Debugging Your Parser</A>.
+Specify the <VAR>filename</VAR> for the parser file.
 
-<DT><CODE>%defines</CODE>
-<DD>
-Write an extra output file containing macro definitions for the token
-type names defined in the grammar and the semantic value type
-<CODE>YYSTYPE</CODE>, as well as a few <CODE>extern</CODE> variable declarations.
-
-If the parser output file is named <TT>`<VAR>name</VAR>.c'</TT> then this file
-is named <TT>`<VAR>name</VAR>.h'</TT>.
-This output file is essential if you wish to put the definition of
-<CODE>yylex</CODE> in a separate source file, because <CODE>yylex</CODE> needs to
-be able to refer to token type codes and the variable
-<CODE>yylval</CODE>.  See section <A HREF="bison.html#SEC72">Semantic Values of Tokens</A>.
-<DT><CODE>%verbose</CODE>
+<DT><CODE>%pure-parser</CODE>
 <DD>
-Write an extra output file containing verbose descriptions of the
-parser states and what is done for each type of look-ahead token in
-that state.
-
-This file also describes all the conflicts, both those resolved by
-operator precedence and the unresolved ones.
+Request a pure (reentrant) parser program (see section <A HREF="bison.html#SEC66">A Pure (Reentrant) Parser</A>).
 
-The file's name is made by removing <SAMP>`.tab.c'</SAMP> or <SAMP>`.c'</SAMP> from
-the parser output file name, and adding <SAMP>`.output'</SAMP> instead.
-Therefore, if the input file is <TT>`foo.y'</TT>, then the parser file is
-called <TT>`foo.tab.c'</TT> by default.  As a consequence, the verbose
-output file is called <TT>`foo.output'</TT>.
-<DT><CODE>%token_table</CODE>
+<DT><CODE>%token-table</CODE>
 <DD>
 Generate an array of token names in the parser file.  The name of the
 array is <CODE>yytname</CODE>; <CODE>yytname[<VAR>i</VAR>]</CODE> is the name of the
-token whose internal Bison token code number is <VAR>i</VAR>.  The first three
-elements of <CODE>yytname</CODE> are always <CODE>"$"</CODE>, <CODE>"error"</CODE>, and
-<CODE>"$illegal"</CODE>; after these come the symbols defined in the grammar
-file.
+token whose internal Bison token code number is <VAR>i</VAR>.  The first
+three elements of <CODE>yytname</CODE> are always <CODE>"$end"</CODE>,
+<CODE>"error"</CODE>, and <CODE>"$undefined"</CODE>; after these come the symbols
+defined in the grammar file.
 
 For single-character literal tokens and literal string tokens, the name
 in the table includes the single-quote or double-quote characters: for
@@ -3941,7 +4291,7 @@
 contains <SAMP>`"*"*"'</SAMP>.  (In C, that would be written as
 <CODE>"\"*\"*\""</CODE>).
 
-When you specify <CODE>%token_table</CODE>, Bison also generates macro
+When you specify <CODE>%token-table</CODE>, Bison also generates macro
 definitions for macros <CODE>YYNTOKENS</CODE>, <CODE>YYNNTS</CODE>, and
 <CODE>YYNRULES</CODE>, and <CODE>YYNSTATES</CODE>:
 
@@ -3958,13 +4308,25 @@
 The number of grammar rules,
 <DT><CODE>YYNSTATES</CODE>
 <DD>
-The number of parser states (see section <A HREF="bison.html#SEC86">Parser States</A>).
+The number of parser states (see section <A HREF="bison.html#SEC87">Parser States</A>).
 </DL>
+
+<DT><CODE>%verbose</CODE>
+<DD>
+Write an extra output file containing verbose descriptions of the
+parser states and what is done for each type of look-ahead token in
+that state.  See section <A HREF="bison.html#SEC98">Understanding Your Parser</A>, for more
+information.
+
+<DT><CODE>%yacc</CODE>
+<DD>
+Pretend the option @option{--yacc} was given, i.e., imitate Yacc,
+including its naming conventions.  See section <A HREF="bison.html#SEC101">Bison Options</A>, for more.
 </DL>
 
 
 
-<H2><A NAME="SEC67" HREF="bison_toc.html#TOC67">Multiple Parsers in the Same Program</A></H2>
+<H2><A NAME="SEC68" HREF="bison_toc.html#TOC68">Multiple Parsers in the Same Program</A></H2>
 
 <P>
 Most programs that use Bison parse only one language and therefore contain
@@ -3975,10 +4337,10 @@
 
 <P>
 The easy way to do this is to use the option <SAMP>`-p <VAR>prefix</VAR>'</SAMP>
-(see section <A HREF="bison.html#SEC96">Invoking Bison</A>).  This renames the interface functions and
-variables of the Bison parser to start with <VAR>prefix</VAR> instead of
-<SAMP>`yy'</SAMP>.  You can use this to give each parser distinct names that do
-not conflict.
+(see section <A HREF="bison.html#SEC100">Invoking Bison</A>).  This renames the interface
+functions and variables of the Bison parser to start with <VAR>prefix</VAR>
+instead of <SAMP>`yy'</SAMP>.  You can use this to give each parser distinct
+names that do not conflict.
 
 
 <P>
@@ -3993,7 +4355,7 @@
 renamed.</STRONG> These others are not global; there is no conflict if the same
 name is used in different parsers.  For example, <CODE>YYSTYPE</CODE> is not
 renamed, but defining this in different ways in different parsers causes
-no trouble (see section <A HREF="bison.html#SEC49">Data Types of Semantic Values</A>).
+no trouble (see section <A HREF="bison.html#SEC50">Data Types of Semantic Values</A>).
 
 
 <P>
@@ -4005,10 +4367,10 @@
 
 
 
-<H1><A NAME="SEC68" HREF="bison_toc.html#TOC68">Parser C-Language Interface</A></H1>
+<H1><A NAME="SEC69" HREF="bison_toc.html#TOC69">Parser C-Language Interface</A></H1>
 <P>
-<A NAME="IDX136"></A>
-<A NAME="IDX137"></A>
+<A NAME="IDX149"></A>
+<A NAME="IDX150"></A>
 
 
 <P>
@@ -4020,15 +4382,15 @@
 <P>
 Keep in mind that the parser uses many C identifiers starting with
 <SAMP>`yy'</SAMP> and <SAMP>`YY'</SAMP> for internal purposes.  If you use such an
-identifier (aside from those in this manual) in an action or in additional
-C code in the grammar file, you are likely to run into trouble.
+identifier (aside from those in this manual) in an action or in epilogue
+in the grammar file, you are likely to run into trouble.
 
 
 
 
-<H2><A NAME="SEC69" HREF="bison_toc.html#TOC69">The Parser Function <CODE>yyparse</CODE></A></H2>
+<H2><A NAME="SEC70" HREF="bison_toc.html#TOC70">The Parser Function <CODE>yyparse</CODE></A></H2>
 <P>
-<A NAME="IDX138"></A>
+<A NAME="IDX151"></A>
 
 
 <P>
@@ -4057,21 +4419,21 @@
 
 <DT><CODE>YYACCEPT</CODE>
 <DD>
-<A NAME="IDX139"></A>
+<A NAME="IDX152"></A>
 Return immediately with value 0 (to report success).
 
 <DT><CODE>YYABORT</CODE>
 <DD>
-<A NAME="IDX140"></A>
+<A NAME="IDX153"></A>
 Return immediately with value 1 (to report failure).
 </DL>
 
 
 
-<H2><A NAME="SEC70" HREF="bison_toc.html#TOC70">The Lexical Analyzer Function <CODE>yylex</CODE></A></H2>
+<H2><A NAME="SEC71" HREF="bison_toc.html#TOC71">The Lexical Analyzer Function <CODE>yylex</CODE></A></H2>
 <P>
-<A NAME="IDX141"></A>
-<A NAME="IDX142"></A>
+<A NAME="IDX154"></A>
+<A NAME="IDX155"></A>
 
 
 <P>
@@ -4088,29 +4450,32 @@
 To do this, use the <SAMP>`-d'</SAMP> option when you run Bison, so that it will
 write these macro definitions into a separate header file
 <TT>`<VAR>name</VAR>.tab.h'</TT> which you can include in the other source files
-that need it.  See section <A HREF="bison.html#SEC96">Invoking Bison</A>.
+that need it.  See section <A HREF="bison.html#SEC100">Invoking Bison</A>.
 
 
 
-<H3><A NAME="SEC71" HREF="bison_toc.html#TOC71">Calling Convention for <CODE>yylex</CODE></A></H3>
+
+<H3><A NAME="SEC72" HREF="bison_toc.html#TOC72">Calling Convention for <CODE>yylex</CODE></A></H3>
 
 <P>
-The value that <CODE>yylex</CODE> returns must be the numeric code for the type
-of token it has just found, or 0 for end-of-input.
+The value that <CODE>yylex</CODE> returns must be the positive numeric code
+for the type of token it has just found; a zero or negative value
+signifies end-of-input.
 
 
 <P>
 When a token is referred to in the grammar rules by a name, that name
 in the parser file becomes a C macro whose definition is the proper
 numeric code for that token type.  So <CODE>yylex</CODE> can use the name
-to indicate that type.  See section <A HREF="bison.html#SEC45">Symbols, Terminal and Nonterminal</A>.
+to indicate that type.  See section <A HREF="bison.html#SEC46">Symbols, Terminal and Nonterminal</A>.
 
 
 <P>
 When a token is referred to in the grammar rules by a character literal,
 the numeric code for that character is also the code for the token type.
-So <CODE>yylex</CODE> can simply return that character code.  The null character
-must not be used this way, because its code is zero and that is what
+So <CODE>yylex</CODE> can simply return that character code, possibly converted
+to <CODE>unsigned char</CODE> to avoid sign-extension.  The null character
+must not be used this way, because its code is zero and that
 signifies end-of-input.
 
 
@@ -4124,13 +4489,13 @@
 yylex (void)
 {
   ...
-  if (c == EOF)     /* Detect end of file. */
+  if (c == EOF)    /* Detect end-of-input.  */
     return 0;
   ...
   if (c == '+' || c == '-')
-    return c;      /* Assume token type for `+' is '+'. */
+    return c;      /* Assume token type for `+' is '+'.  */
   ...
-  return INT;      /* Return the type of the token. */
+  return INT;      /* Return the type of the token.  */
   ...
 }
 </PRE>
@@ -4172,8 +4537,8 @@
   {
     if (yytname[i] != 0
         &#38;&#38; yytname[i][0] == '"'
-        &#38;&#38; strncmp (yytname[i] + 1, token_buffer,
-                    strlen (token_buffer))
+        &#38;&#38; ! strncmp (yytname[i] + 1, token_buffer,
+                      strlen (token_buffer))
         &#38;&#38; yytname[i][strlen (token_buffer) + 1] == '"'
         &#38;&#38; yytname[i][strlen (token_buffer) + 2] == 0)
       break;
@@ -4181,15 +4546,15 @@
 </PRE>
 
 The <CODE>yytname</CODE> table is generated only if you use the
-<CODE>%token_table</CODE> declaration.  See section <A HREF="bison.html#SEC66">Bison Declaration Summary</A>.
+<CODE>%token-table</CODE> declaration.  See section <A HREF="bison.html#SEC67">Bison Declaration Summary</A>.
 </UL>
 
 
 
-<H3><A NAME="SEC72" HREF="bison_toc.html#TOC72">Semantic Values of Tokens</A></H3>
+<H3><A NAME="SEC73" HREF="bison_toc.html#TOC73">Semantic Values of Tokens</A></H3>
 
 <P>
-<A NAME="IDX143"></A>
+<A NAME="IDX156"></A>
 In an ordinary (non-reentrant) parser, the semantic value of the token must
 be stored into the global variable <CODE>yylval</CODE>.  When you are using
 just one data type for semantic values, <CODE>yylval</CODE> has that type.
@@ -4200,16 +4565,16 @@
 
 <PRE>
   ...
-  yylval = value;  /* Put value onto Bison stack. */
-  return INT;      /* Return the type of the token. */
+  yylval = value;  /* Put value onto Bison stack.  */
+  return INT;      /* Return the type of the token.  */
   ...
 </PRE>
 
 <P>
 When you are using multiple data types, <CODE>yylval</CODE>'s type is a union
-made from the <CODE>%union</CODE> declaration (see section <A HREF="bison.html#SEC61">The Collection of Value Types</A>).  So when
-you store a token's value, you must use the proper member of the union.
-If the <CODE>%union</CODE> declaration looks like this:
+made from the <CODE>%union</CODE> declaration (see section <A HREF="bison.html#SEC62">The Collection of Value Types</A>).  So when you store a token's value, you
+must use the proper member of the union.  If the <CODE>%union</CODE>
+declaration looks like this:
 
 
 
@@ -4228,18 +4593,18 @@
 
 <PRE>
   ...
-  yylval.intval = value; /* Put value onto Bison stack. */
-  return INT;          /* Return the type of the token. */
+  yylval.intval = value; /* Put value onto Bison stack.  */
+  return INT;            /* Return the type of the token.  */
   ...
 </PRE>
 
 
 
-<H3><A NAME="SEC73" HREF="bison_toc.html#TOC73">Textual Positions of Tokens</A></H3>
+<H3><A NAME="SEC74" HREF="bison_toc.html#TOC74">Textual Positions of Tokens</A></H3>
 
 <P>
-<A NAME="IDX144"></A>
-If you are using the <SAMP>`@<VAR>n</VAR>'</SAMP>-feature (see section <A HREF="bison.html#SEC54">Tracking Locations</A>) in actions to keep track of the
+<A NAME="IDX157"></A>
+If you are using the <SAMP>`@<VAR>n</VAR>'</SAMP>-feature (see section <A HREF="bison.html#SEC55">Tracking Locations</A>) in actions to keep track of the
 textual locations of tokens and groupings, then you must provide this
 information in <CODE>yylex</CODE>.  The function <CODE>yyparse</CODE> expects to
 find the textual location of a token just parsed in the global variable
@@ -4256,18 +4621,18 @@
 
 
 <P>
-<A NAME="IDX145"></A>
+<A NAME="IDX158"></A>
 The data type of <CODE>yylloc</CODE> has the name <CODE>YYLTYPE</CODE>.
 
 
 
 
-<H3><A NAME="SEC74" HREF="bison_toc.html#TOC74">Calling Conventions for Pure Parsers</A></H3>
+<H3><A NAME="SEC75" HREF="bison_toc.html#TOC75">Calling Conventions for Pure Parsers</A></H3>
 
 <P>
-When you use the Bison declaration <CODE>%pure_parser</CODE> to request a
+When you use the Bison declaration <CODE>%pure-parser</CODE> to request a
 pure, reentrant parser, the global communication variables <CODE>yylval</CODE>
-and <CODE>yylloc</CODE> cannot be used.  (See section <A HREF="bison.html#SEC65">A Pure (Reentrant) Parser</A>.)  In such parsers the two global variables are replaced by
+and <CODE>yylloc</CODE> cannot be used.  (See section <A HREF="bison.html#SEC66">A Pure (Reentrant) Parser</A>.)  In such parsers the two global variables are replaced by
 pointers passed as arguments to <CODE>yylex</CODE>.  You must declare them as
 shown here, and pass the information back by storing it through those
 pointers.
@@ -4293,7 +4658,7 @@
 
 
 <P>
-<A NAME="IDX146"></A>
+<A NAME="IDX159"></A>
 If you use a reentrant parser, you can optionally pass additional
 parameter information to it in a reentrant way.  To do so, define the
 macro <CODE>YYPARSE_PARAM</CODE> as a variable name.  This modifies the
@@ -4353,7 +4718,7 @@
 </PRE>
 
 <P>
-<A NAME="IDX147"></A>
+<A NAME="IDX160"></A>
 If you wish to pass the additional parameter data to <CODE>yylex</CODE>,
 define the macro <CODE>YYLEX_PARAM</CODE> just like <CODE>YYPARSE_PARAM</CODE>, as
 shown here:
@@ -4383,26 +4748,26 @@
 
 
 <P>
-You can use <SAMP>`%pure_parser'</SAMP> to request a reentrant parser without
+You can use <SAMP>`%pure-parser'</SAMP> to request a reentrant parser without
 also using <CODE>YYPARSE_PARAM</CODE>.  Then you should call <CODE>yyparse</CODE>
 with no arguments, as usual.
 
 
 
 
-<H2><A NAME="SEC75" HREF="bison_toc.html#TOC75">The Error Reporting Function <CODE>yyerror</CODE></A></H2>
+<H2><A NAME="SEC76" HREF="bison_toc.html#TOC76">The Error Reporting Function <CODE>yyerror</CODE></A></H2>
 <P>
-<A NAME="IDX148"></A>
-<A NAME="IDX149"></A>
-<A NAME="IDX150"></A>
-<A NAME="IDX151"></A>
+<A NAME="IDX161"></A>
+<A NAME="IDX162"></A>
+<A NAME="IDX163"></A>
+<A NAME="IDX164"></A>
 
 
 <P>
 The Bison parser detects a <EM>parse error</EM> or <EM>syntax error</EM>
 whenever it reads a token which cannot satisfy any syntax rule.  An
 action in the grammar can also explicitly proclaim an error, using the
-macro <CODE>YYERROR</CODE> (see section <A HREF="bison.html#SEC76">Special Features for Use in Actions</A>).
+macro <CODE>YYERROR</CODE> (see section <A HREF="bison.html#SEC77">Special Features for Use in Actions</A>).
 
 
 <P>
@@ -4414,9 +4779,9 @@
 
 
 <P>
-<A NAME="IDX152"></A>
+<A NAME="IDX165"></A>
 If you define the macro <CODE>YYERROR_VERBOSE</CODE> in the Bison declarations
-section (see section <A HREF="bison.html#SEC42">The Bison Declarations Section</A>),
+section (see section <A HREF="bison.html#SEC43">The Bison Declarations Section</A>),
 then Bison provides a more verbose and specific error message string
 instead of just plain <CODE>"parse error"</CODE>.  It doesn't matter what
 definition you use for <CODE>YYERROR_VERBOSE</CODE>, just whether you define
@@ -4449,24 +4814,24 @@
 <P>
 After <CODE>yyerror</CODE> returns to <CODE>yyparse</CODE>, the latter will attempt
 error recovery if you have written suitable error recovery grammar rules
-(see section <A HREF="bison.html#SEC90">Error Recovery</A>).  If recovery is impossible, <CODE>yyparse</CODE> will
+(see section <A HREF="bison.html#SEC92">Error Recovery</A>).  If recovery is impossible, <CODE>yyparse</CODE> will
 immediately return 1.
 
 
 <P>
-<A NAME="IDX153"></A>
+<A NAME="IDX166"></A>
 The variable <CODE>yynerrs</CODE> contains the number of syntax errors
 encountered so far.  Normally this variable is global; but if you
-request a pure parser (see section <A HREF="bison.html#SEC65">A Pure (Reentrant) Parser</A>) then it is a local variable
-which only the actions can access.
+request a pure parser (see section <A HREF="bison.html#SEC66">A Pure (Reentrant) Parser</A>)
+then it is a local variable which only the actions can access.
 
 
 
 
-<H2><A NAME="SEC76" HREF="bison_toc.html#TOC76">Special Features for Use in Actions</A></H2>
+<H2><A NAME="SEC77" HREF="bison_toc.html#TOC77">Special Features for Use in Actions</A></H2>
 <P>
-<A NAME="IDX154"></A>
-<A NAME="IDX155"></A>
+<A NAME="IDX167"></A>
+<A NAME="IDX168"></A>
 
 
 <P>
@@ -4479,38 +4844,40 @@
 <DT><SAMP>`$$'</SAMP>
 <DD>
 Acts like a variable that contains the semantic value for the
-grouping made by the current rule.  See section <A HREF="bison.html#SEC51">Actions</A>.
+grouping made by the current rule.  See section <A HREF="bison.html#SEC52">Actions</A>.
 
 <DT><SAMP>`$<VAR>n</VAR>'</SAMP>
 <DD>
 Acts like a variable that contains the semantic value for the
-<VAR>n</VAR>th component of the current rule.  See section <A HREF="bison.html#SEC51">Actions</A>.
+<VAR>n</VAR>th component of the current rule.  See section <A HREF="bison.html#SEC52">Actions</A>.
 
 <DT><SAMP>`$&#60;<VAR>typealt</VAR>&#62;$'</SAMP>
 <DD>
 Like <CODE>$$</CODE> but specifies alternative <VAR>typealt</VAR> in the union
-specified by the <CODE>%union</CODE> declaration.  See section <A HREF="bison.html#SEC52">Data Types of Values in Actions</A>.
+specified by the <CODE>%union</CODE> declaration.  See section <A HREF="bison.html#SEC53">Data Types of Values in Actions</A>.
 
 <DT><SAMP>`$&#60;<VAR>typealt</VAR>&#62;<VAR>n</VAR>'</SAMP>
 <DD>
 Like <CODE>$<VAR>n</VAR></CODE> but specifies alternative <VAR>typealt</VAR> in the
 union specified by the <CODE>%union</CODE> declaration.
-See section <A HREF="bison.html#SEC52">Data Types of Values in Actions</A>.
+See section <A HREF="bison.html#SEC53">Data Types of Values in Actions</A>.
+
 <DT><SAMP>`YYABORT;'</SAMP>
 <DD>
 Return immediately from <CODE>yyparse</CODE>, indicating failure.
-See section <A HREF="bison.html#SEC69">The Parser Function <CODE>yyparse</CODE></A>.
+See section <A HREF="bison.html#SEC70">The Parser Function <CODE>yyparse</CODE></A>.
 
 <DT><SAMP>`YYACCEPT;'</SAMP>
 <DD>
 Return immediately from <CODE>yyparse</CODE>, indicating success.
-See section <A HREF="bison.html#SEC69">The Parser Function <CODE>yyparse</CODE></A>.
+See section <A HREF="bison.html#SEC70">The Parser Function <CODE>yyparse</CODE></A>.
 
 <DT><SAMP>`YYBACKUP (<VAR>token</VAR>, <VAR>value</VAR>);'</SAMP>
 <DD>
-<A NAME="IDX156"></A>
+<A NAME="IDX169"></A>
 Unshift a token.  This macro is allowed only for rules that reduce
 a single value, and only when there is no look-ahead token.
+It is also disallowed in GLR parsers.
 It installs a look-ahead token with token type <VAR>token</VAR> and
 semantic value <VAR>value</VAR>; then it discards the value that was
 going to be reduced by this rule.
@@ -4524,66 +4891,66 @@
 
 <DT><SAMP>`YYEMPTY'</SAMP>
 <DD>
-<A NAME="IDX157"></A>
+<A NAME="IDX170"></A>
 Value stored in <CODE>yychar</CODE> when there is no look-ahead token.
 
 <DT><SAMP>`YYERROR;'</SAMP>
 <DD>
-<A NAME="IDX158"></A>
+<A NAME="IDX171"></A>
 Cause an immediate syntax error.  This statement initiates error
 recovery just as if the parser itself had detected an error; however, it
 does not call <CODE>yyerror</CODE>, and does not print any message.  If you
 want to print an error message, call <CODE>yyerror</CODE> explicitly before
-the <SAMP>`YYERROR;'</SAMP> statement.  See section <A HREF="bison.html#SEC90">Error Recovery</A>.
+the <SAMP>`YYERROR;'</SAMP> statement.  See section <A HREF="bison.html#SEC92">Error Recovery</A>.
 
 <DT><SAMP>`YYRECOVERING'</SAMP>
 <DD>
 This macro stands for an expression that has the value 1 when the parser
 is recovering from a syntax error, and 0 the rest of the time.
-See section <A HREF="bison.html#SEC90">Error Recovery</A>.
+See section <A HREF="bison.html#SEC92">Error Recovery</A>.
 
 <DT><SAMP>`yychar'</SAMP>
 <DD>
 Variable containing the current look-ahead token.  (In a pure parser,
 this is actually a local variable within <CODE>yyparse</CODE>.)  When there is
 no look-ahead token, the value <CODE>YYEMPTY</CODE> is stored in the variable.
-See section <A HREF="bison.html#SEC78">Look-Ahead Tokens</A>.
+See section <A HREF="bison.html#SEC79">Look-Ahead Tokens</A>.
 
 <DT><SAMP>`yyclearin;'</SAMP>
 <DD>
 Discard the current look-ahead token.  This is useful primarily in
-error rules.  See section <A HREF="bison.html#SEC90">Error Recovery</A>.
+error rules.  See section <A HREF="bison.html#SEC92">Error Recovery</A>.
 
 <DT><SAMP>`yyerrok;'</SAMP>
 <DD>
 Resume generating error messages immediately for subsequent syntax
 errors.  This is useful primarily in error rules.
-See section <A HREF="bison.html#SEC90">Error Recovery</A>.
+See section <A HREF="bison.html#SEC92">Error Recovery</A>.
 
 <DT><SAMP>`@$'</SAMP>
 <DD>
-<A NAME="IDX159"></A>
+<A NAME="IDX172"></A>
 Acts like a structure variable containing information on the textual position
-of the grouping made by the current rule.  See section <A HREF="bison.html#SEC54">Tracking Locations</A>.
+of the grouping made by the current rule.  See section <A HREF="bison.html#SEC55">Tracking Locations</A>.
 
 <DT><SAMP>`@<VAR>n</VAR>'</SAMP>
 <DD>
-<A NAME="IDX160"></A>
+<A NAME="IDX173"></A>
 Acts like a structure variable containing information on the textual position
-of the <VAR>n</VAR>th component of the current rule.  See section <A HREF="bison.html#SEC54">Tracking Locations</A>.
+of the <VAR>n</VAR>th component of the current rule.  See section <A HREF="bison.html#SEC55">Tracking Locations</A>.
 
 </DL>
 
 
 
-<H1><A NAME="SEC77" HREF="bison_toc.html#TOC77">The Bison Parser Algorithm</A></H1>
+<H1><A NAME="SEC78" HREF="bison_toc.html#TOC78">The Bison Parser Algorithm</A></H1>
 <P>
-<A NAME="IDX161"></A>
-<A NAME="IDX162"></A>
-<A NAME="IDX163"></A>
-<A NAME="IDX164"></A>
-<A NAME="IDX165"></A>
-<A NAME="IDX166"></A>
+<A NAME="IDX174"></A>
+<A NAME="IDX175"></A>
+<A NAME="IDX176"></A>
+<A NAME="IDX177"></A>
+<A NAME="IDX178"></A>
+<A NAME="IDX179"></A>
 
 
 <P>
@@ -4653,9 +5020,9 @@
 
 
 
-<H2><A NAME="SEC78" HREF="bison_toc.html#TOC78">Look-Ahead Tokens</A></H2>
+<H2><A NAME="SEC79" HREF="bison_toc.html#TOC79">Look-Ahead Tokens</A></H2>
 <P>
-<A NAME="IDX167"></A>
+<A NAME="IDX180"></A>
 
 
 <P>
@@ -4713,19 +5080,19 @@
 
 
 <P>
-<A NAME="IDX168"></A>
+<A NAME="IDX181"></A>
 The current look-ahead token is stored in the variable <CODE>yychar</CODE>.
-See section <A HREF="bison.html#SEC76">Special Features for Use in Actions</A>.
+See section <A HREF="bison.html#SEC77">Special Features for Use in Actions</A>.
 
 
 
 
-<H2><A NAME="SEC79" HREF="bison_toc.html#TOC79">Shift/Reduce Conflicts</A></H2>
+<H2><A NAME="SEC80" HREF="bison_toc.html#TOC80">Shift/Reduce Conflicts</A></H2>
 <P>
-<A NAME="IDX169"></A>
-<A NAME="IDX170"></A>
-<A NAME="IDX171"></A>
-<A NAME="IDX172"></A>
+<A NAME="IDX182"></A>
+<A NAME="IDX183"></A>
+<A NAME="IDX184"></A>
+<A NAME="IDX185"></A>
 
 
 <P>
@@ -4803,7 +5170,7 @@
 To avoid warnings from Bison about predictable, legitimate shift/reduce
 conflicts, use the <CODE>%expect <VAR>n</VAR></CODE> declaration.  There will be no
 warning as long as the number of shift/reduce conflicts is exactly <VAR>n</VAR>.
-See section <A HREF="bison.html#SEC63">Suppressing Conflict Warnings</A>.
+See section <A HREF="bison.html#SEC64">Suppressing Conflict Warnings</A>.
 
 
 <P>
@@ -4832,10 +5199,10 @@
 
 
 
-<H2><A NAME="SEC80" HREF="bison_toc.html#TOC80">Operator Precedence</A></H2>
+<H2><A NAME="SEC81" HREF="bison_toc.html#TOC81">Operator Precedence</A></H2>
 <P>
-<A NAME="IDX173"></A>
-<A NAME="IDX174"></A>
+<A NAME="IDX186"></A>
+<A NAME="IDX187"></A>
 
 
 <P>
@@ -4847,7 +5214,7 @@
 
 
 
-<H3><A NAME="SEC81" HREF="bison_toc.html#TOC81">When Precedence is Needed</A></H3>
+<H3><A NAME="SEC82" HREF="bison_toc.html#TOC82">When Precedence is Needed</A></H3>
 
 <P>
 Consider the following ambiguous grammar fragment (ambiguous because the
@@ -4888,7 +5255,7 @@
 
 
 <P>
-<A NAME="IDX175"></A>
+<A NAME="IDX188"></A>
 What about input such as <SAMP>`1 - 2 - 5'</SAMP>; should this be
 <SAMP>`(1 - 2) - 5'</SAMP> or should it be <SAMP>`1 - (2 - 5)'</SAMP>?  For most
 operators we prefer the former, which is called <EM>left association</EM>.
@@ -4901,11 +5268,11 @@
 
 
 
-<H3><A NAME="SEC82" HREF="bison_toc.html#TOC82">Specifying Operator Precedence</A></H3>
+<H3><A NAME="SEC83" HREF="bison_toc.html#TOC83">Specifying Operator Precedence</A></H3>
 <P>
-<A NAME="IDX176"></A>
-<A NAME="IDX177"></A>
-<A NAME="IDX178"></A>
+<A NAME="IDX189"></A>
+<A NAME="IDX190"></A>
+<A NAME="IDX191"></A>
 
 
 <P>
@@ -4929,7 +5296,7 @@
 
 
 
-<H3><A NAME="SEC83" HREF="bison_toc.html#TOC83">Precedence Examples</A></H3>
+<H3><A NAME="SEC84" HREF="bison_toc.html#TOC84">Precedence Examples</A></H3>
 
 <P>
 In our example, we would want the following declarations:
@@ -4963,25 +5330,25 @@
 
 
 
-<H3><A NAME="SEC84" HREF="bison_toc.html#TOC84">How Precedence Works</A></H3>
+<H3><A NAME="SEC85" HREF="bison_toc.html#TOC85">How Precedence Works</A></H3>
 
 <P>
 The first effect of the precedence declarations is to assign precedence
 levels to the terminal symbols declared.  The second effect is to assign
-precedence levels to certain rules: each rule gets its precedence from the
-last terminal symbol mentioned in the components.  (You can also specify
-explicitly the precedence of a rule.  See section <A HREF="bison.html#SEC85">Context-Dependent Precedence</A>.)
+precedence levels to certain rules: each rule gets its precedence from
+the last terminal symbol mentioned in the components.  (You can also
+specify explicitly the precedence of a rule.  See section <A HREF="bison.html#SEC86">Context-Dependent Precedence</A>.)
 
 
 <P>
-Finally, the resolution of conflicts works by comparing the
-precedence of the rule being considered with that of the
-look-ahead token.  If the token's precedence is higher, the
-choice is to shift.  If the rule's precedence is higher, the
-choice is to reduce.  If they have equal precedence, the choice
-is made based on the associativity of that precedence level.  The
-verbose output file made by <SAMP>`-v'</SAMP> (see section <A HREF="bison.html#SEC96">Invoking Bison</A>) says
-how each conflict was resolved.
+Finally, the resolution of conflicts works by comparing the precedence
+of the rule being considered with that of the look-ahead token.  If the
+token's precedence is higher, the choice is to shift.  If the rule's
+precedence is higher, the choice is to reduce.  If they have equal
+precedence, the choice is made based on the associativity of that
+precedence level.  The verbose output file made by <SAMP>`-v'</SAMP>
+(see section <A HREF="bison.html#SEC100">Invoking Bison</A>) says how each conflict was
+resolved.
 
 
 <P>
@@ -4991,13 +5358,13 @@
 
 
 
-<H2><A NAME="SEC85" HREF="bison_toc.html#TOC85">Context-Dependent Precedence</A></H2>
+<H2><A NAME="SEC86" HREF="bison_toc.html#TOC86">Context-Dependent Precedence</A></H2>
 <P>
-<A NAME="IDX179"></A>
-<A NAME="IDX180"></A>
-<A NAME="IDX181"></A>
-<A NAME="IDX182"></A>
-<A NAME="IDX183"></A>
+<A NAME="IDX192"></A>
+<A NAME="IDX193"></A>
+<A NAME="IDX194"></A>
+<A NAME="IDX195"></A>
+<A NAME="IDX196"></A>
 
 
 <P>
@@ -5014,6 +5381,7 @@
 precedence, you need to use an additional mechanism: the <CODE>%prec</CODE>
 modifier for rules.
 
+
 <P>
 The <CODE>%prec</CODE> modifier declares the precedence of a particular rule by
 specifying a terminal symbol whose precedence should be used for that rule.
@@ -5031,7 +5399,7 @@
 assign the rule the precedence of <VAR>terminal-symbol</VAR>, overriding
 the precedence that would be deduced for it in the ordinary way.  The
 altered rule precedence then affects how conflicts involving that rule
-are resolved (see section <A HREF="bison.html#SEC80">Operator Precedence</A>).
+are resolved (see section <A HREF="bison.html#SEC81">Operator Precedence</A>).
 
 
 <P>
@@ -5063,11 +5431,11 @@
 
 
 
-<H2><A NAME="SEC86" HREF="bison_toc.html#TOC86">Parser States</A></H2>
+<H2><A NAME="SEC87" HREF="bison_toc.html#TOC87">Parser States</A></H2>
 <P>
-<A NAME="IDX184"></A>
-<A NAME="IDX185"></A>
-<A NAME="IDX186"></A>
+<A NAME="IDX197"></A>
+<A NAME="IDX198"></A>
+<A NAME="IDX199"></A>
 
 
 <P>
@@ -5093,15 +5461,15 @@
 <P>
 There is one other alternative: the table can say that the look-ahead token
 is erroneous in the current state.  This causes error processing to begin
-(see section <A HREF="bison.html#SEC90">Error Recovery</A>).
+(see section <A HREF="bison.html#SEC92">Error Recovery</A>).
 
 
 
 
-<H2><A NAME="SEC87" HREF="bison_toc.html#TOC87">Reduce/Reduce Conflicts</A></H2>
+<H2><A NAME="SEC88" HREF="bison_toc.html#TOC88">Reduce/Reduce Conflicts</A></H2>
 <P>
-<A NAME="IDX187"></A>
-<A NAME="IDX188"></A>
+<A NAME="IDX200"></A>
+<A NAME="IDX201"></A>
 
 
 <P>
@@ -5241,7 +5609,7 @@
 
 
 
-<H2><A NAME="SEC88" HREF="bison_toc.html#TOC88">Mysterious Reduce/Reduce Conflicts</A></H2>
+<H2><A NAME="SEC89" HREF="bison_toc.html#TOC89">Mysterious Reduce/Reduce Conflicts</A></H2>
 
 <P>
 Sometimes reduce/reduce conflicts can occur that don't look warranted.
@@ -5281,8 +5649,8 @@
 
 
 <P>
-<A NAME="IDX189"></A>
-<A NAME="IDX190"></A>
+<A NAME="IDX202"></A>
+<A NAME="IDX203"></A>
 However, Bison, like most parser generators, cannot actually handle all
 LR(1) grammars.  In this grammar, two contexts, that after an <CODE>ID</CODE>
 at the beginning of a <CODE>param_spec</CODE> and likewise at the beginning of
@@ -5357,11 +5725,100 @@
 
 
 
-<H2><A NAME="SEC89" HREF="bison_toc.html#TOC89">Stack Overflow, and How to Avoid It</A></H2>
+<H2><A NAME="SEC90" HREF="bison_toc.html#TOC90">Generalized LR (GLR) Parsing</A></H2>
 <P>
-<A NAME="IDX191"></A>
-<A NAME="IDX192"></A>
-<A NAME="IDX193"></A>
+<A NAME="IDX204"></A>
+<A NAME="IDX205"></A>
+<A NAME="IDX206"></A>
+<A NAME="IDX207"></A>
+
+
+<P>
+Bison produces <EM>deterministic</EM> parsers that choose uniquely
+when to reduce and which reduction to apply
+based on a summary of the preceding input and on one extra token of lookahead.
+As a result, normal Bison handles a proper subset of the family of
+context-free languages.
+Ambiguous grammars, since they have strings with more than one possible
+sequence of reductions cannot have deterministic parsers in this sense.
+The same is true of languages that require more than one symbol of
+lookahead, since the parser lacks the information necessary to make a
+decision at the point it must be made in a shift-reduce parser.
+Finally, as previously mentioned (see section <A HREF="bison.html#SEC89">Mysterious Reduce/Reduce Conflicts</A>),
+there are languages where Bison's particular choice of how to
+summarize the input seen so far loses necessary information.
+
+
+<P>
+When you use the <SAMP>`%glr-parser'</SAMP> declaration in your grammar file,
+Bison generates a parser that uses a different algorithm, called
+Generalized LR (or GLR).  A Bison GLR parser uses the same basic
+algorithm for parsing as an ordinary Bison parser, but behaves
+differently in cases where there is a shift-reduce conflict that has not
+been resolved by precedence rules (see section <A HREF="bison.html#SEC81">Operator Precedence</A>) or a
+reduce-reduce conflict.  When a GLR parser encounters such a situation, it
+effectively <EM>splits</EM> into a several parsers, one for each possible
+shift or reduction.  These parsers then proceed as usual, consuming
+tokens in lock-step.  Some of the stacks may encounter other conflicts
+and split further, with the result that instead of a sequence of states,
+a Bison GLR parsing stack is what is in effect a tree of states.
+
+
+<P>
+In effect, each stack represents a guess as to what the proper parse
+is.  Additional input may indicate that a guess was wrong, in which case
+the appropriate stack silently disappears.  Otherwise, the semantics
+actions generated in each stack are saved, rather than being executed
+immediately.  When a stack disappears, its saved semantic actions never
+get executed.  When a reduction causes two stacks to become equivalent,
+their sets of semantic actions are both saved with the state that
+results from the reduction.  We say that two stacks are equivalent
+when they both represent the same sequence of states,
+and each pair of corresponding states represents a
+grammar symbol that produces the same segment of the input token
+stream.
+
+
+<P>
+Whenever the parser makes a transition from having multiple
+states to having one, it reverts to the normal LALR(1) parsing
+algorithm, after resolving and executing the saved-up actions.
+At this transition, some of the states on the stack will have semantic
+values that are sets (actually multisets) of possible actions.  The
+parser tries to pick one of the actions by first finding one whose rule
+has the highest dynamic precedence, as set by the <SAMP>`%dprec'</SAMP>
+declaration.  Otherwise, if the alternative actions are not ordered by
+precedence, but there the same merging function is declared for both
+rules by the <SAMP>`%merge'</SAMP> declaration,
+Bison resolves and evaluates both and then calls the merge function on
+the result.  Otherwise, it reports an ambiguity.
+
+
+<P>
+It is possible to use a data structure for the GLR parsing tree that
+permits the processing of any LALR(1) grammar in linear time (in the
+size of the input), any unambiguous (not necessarily LALR(1)) grammar in
+quadratic worst-case time, and any general (possibly ambiguous)
+context-free grammar in cubic worst-case time.  However, Bison currently
+uses a simpler data structure that requires time proportional to the
+length of the input times the maximum number of stacks required for any
+prefix of the input.  Thus, really ambiguous or non-deterministic
+grammars can require exponential time and space to process.  Such badly
+behaving examples, however, are not generally of practical interest.
+Usually, non-determinism in a grammar is local--the parser is "in
+doubt" only for a few tokens at a time.  Therefore, the current data
+structure should generally be adequate.  On LALR(1) portions of a
+grammar, in particular, it is only slightly slower than with the default
+Bison parser.
+
+
+
+
+<H2><A NAME="SEC91" HREF="bison_toc.html#TOC91">Stack Overflow, and How to Avoid It</A></H2>
+<P>
+<A NAME="IDX208"></A>
+<A NAME="IDX209"></A>
+<A NAME="IDX210"></A>
 
 
 <P>
@@ -5372,7 +5829,13 @@
 
 
 <P>
-<A NAME="IDX194"></A>
+Becaue Bison parsers have growing stacks, hitting the upper limit
+usually results from using a right recursion instead of a left
+recursion, See section <A HREF="bison.html#SEC48">Recursive Rules</A>.
+
+
+<P>
+<A NAME="IDX211"></A>
 By defining the macro <CODE>YYMAXDEPTH</CODE>, you can control how deep the
 parser stack can become before a stack overflow occurs.  Define the
 macro with a value that is an integer.  This value is the maximum number
@@ -5390,24 +5853,32 @@
 
 
 <P>
-<A NAME="IDX195"></A>
+<A NAME="IDX212"></A>
 The default value of <CODE>YYMAXDEPTH</CODE>, if you do not define it, is
 10000.
 
 
 <P>
-<A NAME="IDX196"></A>
+<A NAME="IDX213"></A>
 You can control how much stack is allocated initially by defining the
 macro <CODE>YYINITDEPTH</CODE>.  This value too must be a compile-time
 constant integer.  The default is 200.
 
 
+<P>
+Because of semantical differences between C and C++, the 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</CODE>.  In the near future, a C++ output output will be
+provided which addresses this issue.
+
 
 
-<H1><A NAME="SEC90" HREF="bison_toc.html#TOC90">Error Recovery</A></H1>
+
+<H1><A NAME="SEC92" HREF="bison_toc.html#TOC92">Error Recovery</A></H1>
 <P>
-<A NAME="IDX197"></A>
-<A NAME="IDX198"></A>
+<A NAME="IDX214"></A>
+<A NAME="IDX215"></A>
 
 
 <P>
@@ -5428,7 +5899,7 @@
 
 
 <P>
-<A NAME="IDX199"></A>
+<A NAME="IDX216"></A>
 You can define how to recover from a syntax error by writing rules to
 recognize the special token <CODE>error</CODE>.  This is a terminal symbol that
 is always defined (you need not declare it) and reserved for error
@@ -5485,7 +5956,7 @@
 
 
 <PRE>
-stmnt: error ';'  /* on error, skip until ';' is read */
+stmnt: error ';'  /* On error, skip until ';' is read.  */
 </PRE>
 
 <P>
@@ -5527,7 +5998,7 @@
 
 
 <P>
-<A NAME="IDX200"></A>
+<A NAME="IDX217"></A>
 You can make error messages resume immediately by using the macro
 <CODE>yyerrok</CODE> in an action.  If you do this in the error rule's action, no
 error messages will be suppressed.  This macro requires no arguments;
@@ -5535,7 +6006,7 @@
 
 
 <P>
-<A NAME="IDX201"></A>
+<A NAME="IDX218"></A>
 The previous look-ahead token is reanalyzed immediately after an error.  If
 this is unacceptable, then the macro <CODE>yyclearin</CODE> may be used to clear
 this token.  Write the statement <SAMP>`yyclearin;'</SAMP> in the error rule's
@@ -5551,7 +6022,7 @@
 
 
 <P>
-<A NAME="IDX202"></A>
+<A NAME="IDX219"></A>
 The macro <CODE>YYRECOVERING</CODE> stands for an expression that has the
 value 1 when the parser is recovering from a syntax error, and 0 the
 rest of the time.  A value of 1 indicates that error messages are
@@ -5560,7 +6031,7 @@
 
 
 
-<H1><A NAME="SEC91" HREF="bison_toc.html#TOC91">Handling Context Dependencies</A></H1>
+<H1><A NAME="SEC93" HREF="bison_toc.html#TOC93">Handling Context Dependencies</A></H1>
 
 <P>
 The Bison paradigm is to parse tokens first, then group them into larger
@@ -5577,7 +6048,7 @@
 
 
 
-<H2><A NAME="SEC92" HREF="bison_toc.html#TOC92">Semantic Info in Token Types</A></H2>
+<H2><A NAME="SEC94" HREF="bison_toc.html#TOC94">Semantic Info in Token Types</A></H2>
 
 <P>
 The C language has a context dependency: the way an identifier is used
@@ -5673,9 +6144,9 @@
 
 
 
-<H2><A NAME="SEC93" HREF="bison_toc.html#TOC93">Lexical Tie-ins</A></H2>
+<H2><A NAME="SEC95" HREF="bison_toc.html#TOC95">Lexical Tie-ins</A></H2>
 <P>
-<A NAME="IDX203"></A>
+<A NAME="IDX220"></A>
 
 
 <P>
@@ -5724,19 +6195,18 @@
 
 
 <P>
-The declaration of <CODE>hexflag</CODE> shown in the C declarations section of
-the parser file is needed to make it accessible to the actions
-(see section <A HREF="bison.html#SEC41">The C Declarations Section</A>).  You must also write the code in <CODE>yylex</CODE>
-to obey the flag.
+The declaration of <CODE>hexflag</CODE> shown in the prologue of the parser file
+is needed to make it accessible to the actions (see section <A HREF="bison.html#SEC42">The prologue</A>).
+You must also write the code in <CODE>yylex</CODE> to obey the flag.
 
 
 
 
-<H2><A NAME="SEC94" HREF="bison_toc.html#TOC94">Lexical Tie-ins and Error Recovery</A></H2>
+<H2><A NAME="SEC96" HREF="bison_toc.html#TOC96">Lexical Tie-ins and Error Recovery</A></H2>
 
 <P>
 Lexical tie-ins make strict demands on any error recovery rules you have.
-See section <A HREF="bison.html#SEC90">Error Recovery</A>.
+See section <A HREF="bison.html#SEC92">Error Recovery</A>.
 
 
 <P>
@@ -5802,12 +6272,473 @@
 
 
 
-<H1><A NAME="SEC95" HREF="bison_toc.html#TOC95">Debugging Your Parser</A></H1>
+<H1><A NAME="SEC97" HREF="bison_toc.html#TOC97">Debugging Your Parser</A></H1>
+
 <P>
-<A NAME="IDX204"></A>
-<A NAME="IDX205"></A>
-<A NAME="IDX206"></A>
-<A NAME="IDX207"></A>
+Developing a parser can be a challenge, especially if you don't
+understand the algorithm (see section <A HREF="bison.html#SEC78">The Bison Parser Algorithm</A>).  Even so, sometimes a detailed description of the automaton
+can help (see section <A HREF="bison.html#SEC98">Understanding Your Parser</A>), or
+tracing the execution of the parser can give some insight on why it
+behaves improperly (see section <A HREF="bison.html#SEC99">Tracing Your Parser</A>).
+
+
+
+
+<H2><A NAME="SEC98" HREF="bison_toc.html#TOC98">Understanding Your Parser</A></H2>
+
+<P>
+As documented elsewhere (see section <A HREF="bison.html#SEC78">The Bison Parser Algorithm</A>)
+Bison parsers are <EM>shift/reduce automata</EM>.  In some cases (much more
+frequent than one would hope), looking at this automaton is required to
+tune or simply fix a parser.  Bison provides two different
+representation of it, either textually or graphically (as a VCG
+file).
+
+
+<P>
+The textual file is generated when the options @option{--report} or
+@option{--verbose} are specified, see See section <A HREF="bison.html#SEC100">Invoking Bison</A>.  Its name is made by removing <SAMP>`.tab.c'</SAMP> or <SAMP>`.c'</SAMP> from
+the parser output file name, and adding <SAMP>`.output'</SAMP> instead.
+Therefore, if the input file is <TT>`foo.y'</TT>, then the parser file is
+called <TT>`foo.tab.c'</TT> by default.  As a consequence, the verbose
+output file is called <TT>`foo.output'</TT>.
+
+
+<P>
+The following grammar file, <TT>`calc.y'</TT>, will be used in the sequel:
+
+
+
+<PRE>
+%token NUM STR
+%left '+' '-'
+%left '*'
+%%
+exp: exp '+' exp
+   | exp '-' exp
+   | exp '*' exp
+   | exp '/' exp
+   | NUM
+   ;
+useless: STR;
+%%
+</PRE>
+
+<P>
+@command{bison} reports:
+
+
+
+<PRE>
+calc.y: warning: 1 useless nonterminal and 1 useless rule
+calc.y:11.1-7: warning: useless nonterminal: useless
+calc.y:11.8-12: warning: useless rule: useless: STR
+calc.y contains 7 shift/reduce conflicts.
+</PRE>
+
+<P>
+When given @option{--report=state}, in addition to <TT>`calc.tab.c'</TT>, it
+creates a file <TT>`calc.output'</TT> with contents detailed below.  The
+order of the output and the exact presentation might vary, but the
+interpretation is the same.
+
+
+<P>
+The first section includes details on conflicts that were solved thanks
+to precedence and/or associativity:
+
+
+
+<PRE>
+Conflict in state 8 between rule 2 and token '+' resolved as reduce.
+Conflict in state 8 between rule 2 and token '-' resolved as reduce.
+Conflict in state 8 between rule 2 and token '*' resolved as shift.
+...
+</PRE>
+
+<P>
+The next section lists states that still have conflicts.
+
+
+
+<PRE>
+State 8 contains 1 shift/reduce conflict.
+State 9 contains 1 shift/reduce conflict.
+State 10 contains 1 shift/reduce conflict.
+State 11 contains 4 shift/reduce conflicts.
+</PRE>
+
+<P>
+<A NAME="IDX221"></A>
+<A NAME="IDX222"></A>
+<A NAME="IDX223"></A>
+<A NAME="IDX224"></A>
+<A NAME="IDX225"></A>
+<A NAME="IDX226"></A>
+The next section reports useless tokens, nonterminal and rules.  Useless
+nonterminals and rules are removed in order to produce a smaller parser,
+but useless tokens are preserved, since they might be used by the
+scanner (note the difference between "useless" and "not used"
+below):
+
+
+
+<PRE>
+Useless nonterminals:
+   useless
+
+Terminals which are not used:
+   STR
+
+Useless rules:
+#6     useless: STR;
+</PRE>
+
+<P>
+The next section reproduces the exact grammar that Bison used:
+
+
+
+<PRE>
+Grammar
+
+  Number, Line, Rule
+    0   5 $accept -&#62; exp $end
+    1   5 exp -&#62; exp '+' exp
+    2   6 exp -&#62; exp '-' exp
+    3   7 exp -&#62; exp '*' exp
+    4   8 exp -&#62; exp '/' exp
+    5   9 exp -&#62; NUM
+</PRE>
+
+<P>
+and reports the uses of the symbols:
+
+
+
+<PRE>
+Terminals, with rules where they appear
+
+$end (0) 0
+'*' (42) 3
+'+' (43) 1
+'-' (45) 2
+'/' (47) 4
+error (256)
+NUM (258) 5
+
+Nonterminals, with rules where they appear
+
+$accept (8)
+    on left: 0
+exp (9)
+    on left: 1 2 3 4 5, on right: 0 1 2 3 4
+</PRE>
+
+<P>
+<A NAME="IDX227"></A>
+<A NAME="IDX228"></A>
+<A NAME="IDX229"></A>
+Bison then proceeds onto the automaton itself, describing each state
+with it set of <EM>items</EM>, also known as <EM>pointed rules</EM>.  Each
+item is a production rule together with a point (marked by <SAMP>`.'</SAMP>)
+that the input cursor.
+
+
+
+<PRE>
+state 0
+
+    $accept  -&#62;  . exp $   (rule 0)
+
+    NUM         shift, and go to state 1
+
+    exp         go to state 2
+</PRE>
+
+<P>
+This reads as follows: "state 0 corresponds to being at the very
+beginning of the parsing, in the initial rule, right before the start
+symbol (here, <CODE>exp</CODE>).  When the parser returns to this state right
+after having reduced a rule that produced an <CODE>exp</CODE>, the control
+flow jumps to state 2.  If there is no such transition on a nonterminal
+symbol, and the lookahead is a <CODE>NUM</CODE>, then this token is shifted on
+the parse stack, and the control flow jumps to state 1.  Any other
+lookahead triggers a parse error."
+
+
+<P>
+<A NAME="IDX230"></A>
+<A NAME="IDX231"></A>
+<A NAME="IDX232"></A>
+<A NAME="IDX233"></A>
+Even though the only active rule in state 0 seems to be rule 0, the
+report lists <CODE>NUM</CODE> as a lookahead symbol because <CODE>NUM</CODE> can be
+at the beginning of any rule deriving an <CODE>exp</CODE>.  By default Bison
+reports the so-called <EM>core</EM> or <EM>kernel</EM> of the item set, but if
+you want to see more detail you can invoke @command{bison} with
+@option{--report=itemset} to list all the items, include those that can
+be derived:
+
+
+
+<PRE>
+state 0
+
+    $accept  -&#62;  . exp $   (rule 0)
+    exp  -&#62;  . exp '+' exp   (rule 1)
+    exp  -&#62;  . exp '-' exp   (rule 2)
+    exp  -&#62;  . exp '*' exp   (rule 3)
+    exp  -&#62;  . exp '/' exp   (rule 4)
+    exp  -&#62;  . NUM   (rule 5)
+
+    NUM         shift, and go to state 1
+
+    exp         go to state 2
+</PRE>
+
+<P>
+In the state 1...
+
+
+
+<PRE>
+state 1
+
+    exp  -&#62;  NUM .   (rule 5)
+
+    $default    reduce using rule 5 (exp)
+</PRE>
+
+<P>
+the rule 5, <SAMP>`exp: NUM;'</SAMP>, is completed.  Whatever the lookahead
+(<SAMP>`$default'</SAMP>), the parser will reduce it.  If it was coming from
+state 0, then, after this reduction it will return to state 0, and will
+jump to state 2 (<SAMP>`exp: go to state 2'</SAMP>).
+
+
+
+<PRE>
+state 2
+
+    $accept  -&#62;  exp . $   (rule 0)
+    exp  -&#62;  exp . '+' exp   (rule 1)
+    exp  -&#62;  exp . '-' exp   (rule 2)
+    exp  -&#62;  exp . '*' exp   (rule 3)
+    exp  -&#62;  exp . '/' exp   (rule 4)
+
+    $           shift, and go to state 3
+    '+'         shift, and go to state 4
+    '-'         shift, and go to state 5
+    '*'         shift, and go to state 6
+    '/'         shift, and go to state 7
+</PRE>
+
+<P>
+In state 2, the automaton can only shift a symbol.  For instance,
+because of the item <SAMP>`exp -&#62; exp . '+' exp'</SAMP>, if the lookahead if
+<SAMP>`+'</SAMP>, it will be shifted on the parse stack, and the automaton
+control will jump to state 4, corresponding to the item <SAMP>`exp -&#62; exp
+'+' . exp'</SAMP>.  Since there is no default action, any other token than
+those listed above will trigger a parse error.
+
+
+<P>
+The state 3 is named the <EM>final state</EM>, or the <EM>accepting
+state</EM>:
+
+
+
+<PRE>
+state 3
+
+    $accept  -&#62;  exp $ .   (rule 0)
+
+    $default    accept
+</PRE>
+
+<P>
+the initial rule is completed (the start symbol and the end
+of input were read), the parsing exits successfully.
+
+
+<P>
+The interpretation of states 4 to 7 is straightforward, and is left to
+the reader.
+
+
+
+<PRE>
+state 4
+
+    exp  -&#62;  exp '+' . exp   (rule 1)
+
+    NUM         shift, and go to state 1
+
+    exp         go to state 8
+
+state 5
+
+    exp  -&#62;  exp '-' . exp   (rule 2)
+
+    NUM         shift, and go to state 1
+
+    exp         go to state 9
+
+state 6
+
+    exp  -&#62;  exp '*' . exp   (rule 3)
+
+    NUM         shift, and go to state 1
+
+    exp         go to state 10
+
+state 7
+
+    exp  -&#62;  exp '/' . exp   (rule 4)
+
+    NUM         shift, and go to state 1
+
+    exp         go to state 11
+</PRE>
+
+<P>
+As was announced in beginning of the report, <SAMP>`State 8 contains 1
+shift/reduce conflict'</SAMP>:
+
+
+
+<PRE>
+state 8
+
+    exp  -&#62;  exp . '+' exp   (rule 1)
+    exp  -&#62;  exp '+' exp .   (rule 1)
+    exp  -&#62;  exp . '-' exp   (rule 2)
+    exp  -&#62;  exp . '*' exp   (rule 3)
+    exp  -&#62;  exp . '/' exp   (rule 4)
+
+    '*'         shift, and go to state 6
+    '/'         shift, and go to state 7
+
+    '/'         [reduce using rule 1 (exp)]
+    $default    reduce using rule 1 (exp)
+</PRE>
+
+<P>
+Indeed, there are two actions associated to the lookahead <SAMP>`/'</SAMP>:
+either shifting (and going to state 7), or reducing rule 1.  The
+conflict means that either the grammar is ambiguous, or the parser lacks
+information to make the right decision.  Indeed the grammar is
+ambiguous, as, since we did not specify the precedence of <SAMP>`/'</SAMP>, the
+sentence <SAMP>`NUM + NUM / NUM'</SAMP> can be parsed as <SAMP>`NUM + (NUM /
+NUM)'</SAMP>, which corresponds to shifting <SAMP>`/'</SAMP>, or as <SAMP>`(NUM + NUM) /
+NUM'</SAMP>, which corresponds to reducing rule 1.
+
+
+<P>
+Because in LALR(1) parsing a single decision can be made, Bison
+arbitrarily chose to disable the reduction, see section <A HREF="bison.html#SEC80">Shift/Reduce Conflicts</A>.  Discarded actions are reported in between
+square brackets.
+
+
+<P>
+Note that all the previous states had a single possible action: either
+shifting the next token and going to the corresponding state, or
+reducing a single rule.  In the other cases, i.e., when shifting
+<EM>and</EM> reducing is possible or when <EM>several</EM> reductions are
+possible, the lookahead is required to select the action.  State 8 is
+one such state: if the lookahead is <SAMP>`*'</SAMP> or <SAMP>`/'</SAMP> then the action
+is shifting, otherwise the action is reducing rule 1.  In other words,
+the first two items, corresponding to rule 1, are not eligible when the
+lookahead is <SAMP>`*'</SAMP>, since we specified that <SAMP>`*'</SAMP> has higher
+precedence that <SAMP>`+'</SAMP>.  More generally, some items are eligible only
+with some set of possible lookaheads.  When run with
+@option{--report=lookahead}, Bison specifies these lookaheads:
+
+
+
+<PRE>
+state 8
+
+    exp  -&#62;  exp . '+' exp  [$, '+', '-', '/']   (rule 1)
+    exp  -&#62;  exp '+' exp .  [$, '+', '-', '/']   (rule 1)
+    exp  -&#62;  exp . '-' exp   (rule 2)
+    exp  -&#62;  exp . '*' exp   (rule 3)
+    exp  -&#62;  exp . '/' exp   (rule 4)
+
+    '*'         shift, and go to state 6
+    '/'         shift, and go to state 7
+
+    '/'         [reduce using rule 1 (exp)]
+    $default    reduce using rule 1 (exp)
+</PRE>
+
+<P>
+The remaining states are similar:
+
+
+
+<PRE>
+state 9
+
+    exp  -&#62;  exp . '+' exp   (rule 1)
+    exp  -&#62;  exp . '-' exp   (rule 2)
+    exp  -&#62;  exp '-' exp .   (rule 2)
+    exp  -&#62;  exp . '*' exp   (rule 3)
+    exp  -&#62;  exp . '/' exp   (rule 4)
+
+    '*'         shift, and go to state 6
+    '/'         shift, and go to state 7
+
+    '/'         [reduce using rule 2 (exp)]
+    $default    reduce using rule 2 (exp)
+
+state 10
+
+    exp  -&#62;  exp . '+' exp   (rule 1)
+    exp  -&#62;  exp . '-' exp   (rule 2)
+    exp  -&#62;  exp . '*' exp   (rule 3)
+    exp  -&#62;  exp '*' exp .   (rule 3)
+    exp  -&#62;  exp . '/' exp   (rule 4)
+
+    '/'         shift, and go to state 7
+
+    '/'         [reduce using rule 3 (exp)]
+    $default    reduce using rule 3 (exp)
+
+state 11
+
+    exp  -&#62;  exp . '+' exp   (rule 1)
+    exp  -&#62;  exp . '-' exp   (rule 2)
+    exp  -&#62;  exp . '*' exp   (rule 3)
+    exp  -&#62;  exp . '/' exp   (rule 4)
+    exp  -&#62;  exp '/' exp .   (rule 4)
+
+    '+'         shift, and go to state 4
+    '-'         shift, and go to state 5
+    '*'         shift, and go to state 6
+    '/'         shift, and go to state 7
+
+    '+'         [reduce using rule 4 (exp)]
+    '-'         [reduce using rule 4 (exp)]
+    '*'         [reduce using rule 4 (exp)]
+    '/'         [reduce using rule 4 (exp)]
+    $default    reduce using rule 4 (exp)
+</PRE>
+
+<P>
+Observe that state 11 contains conflicts due to the lack of precedence
+of <SAMP>`/'</SAMP> wrt <SAMP>`+'</SAMP>, <SAMP>`-'</SAMP>, and <SAMP>`*'</SAMP>, but also because the
+associativity of <SAMP>`/'</SAMP> is not specified.
+
+
+
+
+<H2><A NAME="SEC99" HREF="bison_toc.html#TOC99">Tracing Your Parser</A></H2>
+<P>
+<A NAME="IDX234"></A>
+<A NAME="IDX235"></A>
+<A NAME="IDX236"></A>
 
 
 <P>
@@ -5816,18 +6747,44 @@
 
 
 <P>
-To enable compilation of trace facilities, you must define the macro
-<CODE>YYDEBUG</CODE> when you compile the parser.  You could use
+There are several means to enable compilation of trace facilities:
+
+
+<DL COMPACT>
+
+<DT>the macro <CODE>YYDEBUG</CODE>
+<DD>
+<A NAME="IDX237"></A>
+Define the macro <CODE>YYDEBUG</CODE> to a nonzero value when you compile the
+parser.  This is compliant with POSIX Yacc.  You could use
 <SAMP>`-DYYDEBUG=1'</SAMP> as a compiler option or you could put <SAMP>`#define
-YYDEBUG 1'</SAMP> in the C declarations section of the grammar file
-(see section <A HREF="bison.html#SEC41">The C Declarations Section</A>).  Alternatively, use the <SAMP>`-t'</SAMP> option when
-you run Bison (see section <A HREF="bison.html#SEC96">Invoking Bison</A>).  We always define <CODE>YYDEBUG</CODE> so that
-debugging is always possible.
+YYDEBUG 1'</SAMP> in the prologue of the grammar file (see section <A HREF="bison.html#SEC42">The prologue</A>).
+
+<DT>the option @option{-t, @option{--debug}}
+<DD>
+Use the <SAMP>`-t'</SAMP> option when you run Bison (see section <A HREF="bison.html#SEC100">Invoking Bison</A>).  This is POSIX compliant too.
 
+<DT>the directive <SAMP>`%debug'</SAMP>
+<DD>
+<A NAME="IDX238"></A>
+Add the <CODE>%debug</CODE> directive (see section <A HREF="bison.html#SEC67">Bison Declaration Summary</A>).  This is a Bison extension, which will prove
+useful when Bison will output parsers for languages that don't use a
+preprocessor.  Useless POSIX and Yacc portability matter to you, this is
+the preferred solution.
+</DL>
 
 <P>
-The trace facility uses <CODE>stderr</CODE>, so you must add <CODE>#include
-&#60;stdio.h&#62;</CODE> to the C declarations section unless it is already there.
+We suggest that you always enable the debug option so that debugging is
+always possible.
+
+
+<P>
+The trace facility outputs messages with macro calls of the form
+<CODE>YYFPRINTF (stderr, <VAR>format</VAR>, <VAR>args</VAR>)</CODE> where
+<VAR>format</VAR> and <VAR>args</VAR> are the usual <CODE>printf</CODE> format and
+arguments.  If you define <CODE>YYDEBUG</CODE> to a nonzero value but do not
+define <CODE>YYFPRINTF</CODE>, <CODE>&#60;stdio.h&#62;</CODE> is automatically included
+and <CODE>YYPRINTF</CODE> is defined to <CODE>fprintf</CODE>.
 
 
 <P>
@@ -5852,7 +6809,7 @@
 <LI>
 
 Each time a token is shifted, the depth and complete contents of the
-state stack (see section <A HREF="bison.html#SEC86">Parser States</A>).
+state stack (see section <A HREF="bison.html#SEC87">Parser States</A>).
 
 <LI>
 
@@ -5862,13 +6819,13 @@
 
 <P>
 To make sense of this information, it helps to refer to the listing file
-produced by the Bison <SAMP>`-v'</SAMP> option (see section <A HREF="bison.html#SEC96">Invoking Bison</A>).  This file
-shows the meaning of each state in terms of positions in various rules, and
-also what each state will do with each possible input token.  As you read
-the successive trace messages, you can see that the parser is functioning
-according to its specification in the listing file.  Eventually you will
-arrive at the place where something undesirable happens, and you will see
-which parts of the grammar are to blame.
+produced by the Bison <SAMP>`-v'</SAMP> option (see section <A HREF="bison.html#SEC100">Invoking Bison</A>).  This file shows the meaning of each state in terms of
+positions in various rules, and also what each state will do with each
+possible input token.  As you read the successive trace messages, you
+can see that the parser is functioning according to its specification in
+the listing file.  Eventually you will arrive at the place where
+something undesirable happens, and you will see which parts of the
+grammar are to blame.
 
 
 <P>
@@ -5880,7 +6837,7 @@
 
 
 <P>
-<A NAME="IDX208"></A>
+<A NAME="IDX239"></A>
 The debugging information normally gives the token type of each token
 read, but not its semantic value.  You can optionally define a macro
 named <CODE>YYPRINT</CODE> to provide a way to print the value.  If you define
@@ -5891,7 +6848,7 @@
 
 <P>
 Here is an example of <CODE>YYPRINT</CODE> suitable for the multi-function
-calculator (see section <A HREF="bison.html#SEC35">Declarations for <CODE>mfcalc</CODE></A>):
+calculator (see section <A HREF="bison.html#SEC36">Declarations for <CODE>mfcalc</CODE></A>):
 
 
 
@@ -5910,11 +6867,11 @@
 
 
 
-<H1><A NAME="SEC96" HREF="bison_toc.html#TOC96">Invoking Bison</A></H1>
+<H1><A NAME="SEC100" HREF="bison_toc.html#TOC100">Invoking Bison</A></H1>
 <P>
-<A NAME="IDX209"></A>
-<A NAME="IDX210"></A>
-<A NAME="IDX211"></A>
+<A NAME="IDX240"></A>
+<A NAME="IDX241"></A>
+<A NAME="IDX242"></A>
 
 
 <P>
@@ -5931,10 +6888,11 @@
 <SAMP>`.y'</SAMP>.  The parser file's name is made by replacing the <SAMP>`.y'</SAMP>
 with <SAMP>`.tab.c'</SAMP>.  Thus, the <SAMP>`bison foo.y'</SAMP> filename yields
 <TT>`foo.tab.c'</TT>, and the <SAMP>`bison hack/foo.y'</SAMP> filename yields
-<TT>`hack/foo.tab.c'</TT>. It's is also possible, in case you are writting
+<TT>`hack/foo.tab.c'</TT>.  It's also possible, in case you are writing
 C++ code instead of C in your grammar file, to name it <TT>`foo.ypp'</TT>
-or <TT>`foo.y++'</TT>. Then, the output files will take an extention like
-the given one as input (repectively <TT>`foo.tab.cpp'</TT> and <TT>`foo.tab.c++'</TT>).
+or <TT>`foo.y++'</TT>.  Then, the output files will take an extension like
+the given one as input (respectively <TT>`foo.tab.cpp'</TT> and
+<TT>`foo.tab.c++'</TT>).
 This feature takes effect with all options that manipulate filenames like
 <SAMP>`-o'</SAMP> or <SAMP>`-d'</SAMP>.
 
@@ -5949,12 +6907,12 @@
 </PRE>
 
 <P>
-will produce <TT>`infile.tab.cxx'</TT> and <TT>`infile.tab.hxx'</TT>. and
+will produce <TT>`infile.tab.cxx'</TT> and <TT>`infile.tab.hxx'</TT>, and
 
 
 
 <PRE>
-bison -d <VAR>infile.y</VAR> -o <VAR>output.c++</VAR>
+bison -d -o <VAR>output.c++</VAR> <VAR>infile.y</VAR>
 </PRE>
 
 <P>
@@ -5963,7 +6921,7 @@
 
 
 
-<H2><A NAME="SEC97" HREF="bison_toc.html#TOC97">Bison Options</A></H2>
+<H2><A NAME="SEC101" HREF="bison_toc.html#TOC101">Bison Options</A></H2>
 
 <P>
 Bison supports both traditional single-letter options and mnemonic long
@@ -6000,14 +6958,13 @@
 <DD>
 <DT>@option{--yacc}
 <DD>
-<DT>@option{--fixed-output-files}
-<DD>
 Equivalent to <SAMP>`-o y.tab.c'</SAMP>; the parser output file is called
 <TT>`y.tab.c'</TT>, and the other outputs are called <TT>`y.output'</TT> and
 <TT>`y.tab.h'</TT>.  The purpose of this option is to imitate Yacc's output
 file name conventions.  Thus, the following shell script can substitute
 for Yacc:
 
+
 <PRE>
 bison -y $*
 </PRE>
@@ -6031,26 +6988,20 @@
 <DD>
 <DT>@option{--debug}
 <DD>
-Output a definition of the macro <CODE>YYDEBUG</CODE> into the parser file, so
-that the debugging facilities are compiled.  See section <A HREF="bison.html#SEC95">Debugging Your Parser</A>.
+In the parser file, define the macro <CODE>YYDEBUG</CODE> to 1 if it is not
+already defined, so that the debugging facilities are compiled.
+See section <A HREF="bison.html#SEC99">Tracing Your Parser</A>.
 
 <DT>@option{--locations}
 <DD>
-Pretend that <CODE>%locactions</CODE> was specified.  See section <A HREF="bison.html#SEC66">Bison Declaration Summary</A>.
+Pretend that <CODE>%locations</CODE> was specified.  See section <A HREF="bison.html#SEC67">Bison Declaration Summary</A>.
 
 <DT>@option{-p <VAR>prefix</VAR>}
 <DD>
 <DT>@option{--name-prefix=<VAR>prefix</VAR>}
 <DD>
-Rename the external symbols used in the parser so that they start with
-<VAR>prefix</VAR> instead of <SAMP>`yy'</SAMP>.  The precise list of symbols renamed
-is <CODE>yyparse</CODE>, <CODE>yylex</CODE>, <CODE>yyerror</CODE>, <CODE>yynerrs</CODE>,
-<CODE>yylval</CODE>, <CODE>yychar</CODE> and <CODE>yydebug</CODE>.
-
-For example, if you use <SAMP>`-p c'</SAMP>, the names become <CODE>cparse</CODE>,
-<CODE>clex</CODE>, and so on.
-
-See section <A HREF="bison.html#SEC67">Multiple Parsers in the Same Program</A>.
+Pretend that <CODE>%name-prefix="<VAR>prefix</VAR>"</CODE> was specified.
+See section <A HREF="bison.html#SEC67">Bison Declaration Summary</A>.
 
 <DT>@option{-l}
 <DD>
@@ -6066,13 +7017,13 @@
 <DD>
 <DT>@option{--no-parser}
 <DD>
-Pretend that <CODE>%no_parser</CODE> was specified.  See section <A HREF="bison.html#SEC66">Bison Declaration Summary</A>.
+Pretend that <CODE>%no-parser</CODE> was specified.  See section <A HREF="bison.html#SEC67">Bison Declaration Summary</A>.
 
 <DT>@option{-k}
 <DD>
 <DT>@option{--token-table}
 <DD>
-Pretend that <CODE>%token_table</CODE> was specified.  See section <A HREF="bison.html#SEC66">Bison Declaration Summary</A>.
+Pretend that <CODE>%token-table</CODE> was specified.  See section <A HREF="bison.html#SEC67">Bison Declaration Summary</A>.
 </DL>
 
 <P>
@@ -6083,23 +7034,50 @@
 
 <DT>@option{-d}
 <DD>
-Pretend that <CODE>%verbose</CODE> was specified, i.e., write an extra output
+<DT>@option{--defines}
+<DD>
+Pretend that <CODE>%defines</CODE> was specified, i.e., write an extra output
 file containing macro definitions for the token type names defined in
 the grammar and the semantic value type <CODE>YYSTYPE</CODE>, as well as a few
-<CODE>extern</CODE> variable declarations.  See section <A HREF="bison.html#SEC66">Bison Declaration Summary</A>.
+<CODE>extern</CODE> variable declarations.  See section <A HREF="bison.html#SEC67">Bison Declaration Summary</A>.
 
 <DT>@option{--defines=<VAR>defines-file</VAR>}
 <DD>
-The behaviour of <VAR>--defines</VAR> is the same than <SAMP>`-d'</SAMP>. The only 
-difference is that it has an optionnal argument which is the name of
-the output filename.
+Same as above, but save in the file <VAR>defines-file</VAR>.
 
 <DT>@option{-b <VAR>file-prefix</VAR>}
 <DD>
 <DT>@option{--file-prefix=<VAR>prefix</VAR>}
 <DD>
-Specify a prefix to use for all Bison output file names.  The names are
-chosen as if the input file were named <TT>`<VAR>prefix</VAR>.c'</TT>.
+Pretend that <CODE>%verbose</CODE> was specified, i.e, specify prefix to use
+for all Bison output file names.  See section <A HREF="bison.html#SEC67">Bison Declaration Summary</A>.
+
+<DT>@option{-r <VAR>things</VAR>}
+<DD>
+<DT>@option{--report=<VAR>things</VAR>}
+<DD>
+Write an extra output file containing verbose description of the comma
+separated list of <VAR>things</VAR> among:
+
+<DL COMPACT>
+
+<DT><CODE>state</CODE>
+<DD>
+Description of the grammar, conflicts (resolved and unresolved), and
+LALR automaton.
+
+<DT><CODE>lookahead</CODE>
+<DD>
+Implies <CODE>state</CODE> and augments the description of the automaton with
+each rule's lookahead set.
+
+<DT><CODE>itemset</CODE>
+<DD>
+Implies <CODE>state</CODE> and augments the description of the automaton with
+the full set of items for each state, instead of its core only.
+</DL>
+
+For instance, on the following grammar
 
 <DT>@option{-v}
 <DD>
@@ -6107,66 +7085,33 @@
 <DD>
 Pretend that <CODE>%verbose</CODE> was specified, i.e, write an extra output
 file containing verbose descriptions of the grammar and
-parser. See section <A HREF="bison.html#SEC66">Bison Declaration Summary</A>, for more.
+parser.  See section <A HREF="bison.html#SEC67">Bison Declaration Summary</A>.
 
-<DT>@option{-o <VAR>outfile</VAR>}
+<DT>@option{-o <VAR>filename</VAR>}
 <DD>
-<DT>@option{--output-file=<VAR>outfile</VAR>}
+<DT>@option{--output=<VAR>filename</VAR>}
 <DD>
-Specify the name <VAR>outfile</VAR> for the parser file.
+Specify the <VAR>filename</VAR> for the parser file.
 
-The other output files' names are constructed from <VAR>outfile</VAR>
-as described under the <SAMP>`-v'</SAMP> and <SAMP>`-d'</SAMP> options.
+The other output files' names are constructed from <VAR>filename</VAR> as
+described under the <SAMP>`-v'</SAMP> and <SAMP>`-d'</SAMP> options.
 
 <DT>@option{-g}
 <DD>
 Output a VCG definition of the LALR(1) grammar automaton computed by
-Bison. If the grammar file is <TT>`foo.y'</TT>, the VCG output file will
+Bison.  If the grammar file is <TT>`foo.y'</TT>, the VCG output file will
 be <TT>`foo.vcg'</TT>.
 
 <DT>@option{--graph=<VAR>graph-file</VAR>}
 <DD>
-The behaviour of <VAR>--graph</VAR> is the same than <SAMP>`-g'</SAMP>. The only 
-difference is that it has an optionnal argument which is the name of
+The behavior of <VAR>--graph</VAR> is the same than <SAMP>`-g'</SAMP>.  The only
+difference is that it has an optional argument which is the name of
 the output graph filename.
 </DL>
 
 
 
-<H2><A NAME="SEC98" HREF="bison_toc.html#TOC98">Environment Variables</A></H2>
-<P>
-<A NAME="IDX212"></A>
-<A NAME="IDX213"></A>
-<A NAME="IDX214"></A>
-
-
-<P>
-Here is a list of environment variables which affect the way Bison
-runs.
-
-
-<DL COMPACT>
-
-<DT><SAMP>`BISON_SIMPLE'</SAMP>
-<DD>
-<DT><SAMP>`BISON_HAIRY'</SAMP>
-<DD>
-Much of the parser generated by Bison is copied verbatim from a file
-called <TT>`bison.simple'</TT>.  If Bison cannot find that file, or if you
-would like to direct Bison to use a different copy, setting the
-environment variable <CODE>BISON_SIMPLE</CODE> to the path of the file will
-cause Bison to use that copy instead.
-
-When the <SAMP>`%semantic_parser'</SAMP> declaration is used, Bison copies from
-a file called <TT>`bison.hairy'</TT> instead.  The location of this file can
-also be specified or overridden in a similar fashion, with the
-<CODE>BISON_HAIRY</CODE> environment variable.
-
-</DL>
-
-
-
-<H2><A NAME="SEC99" HREF="bison_toc.html#TOC99">Option Cross Key</A></H2>
+<H2><A NAME="SEC102" HREF="bison_toc.html#TOC102">Option Cross Key</A></H2>
 
 <P>
 Here is a list of options, alphabetized by long option, to help you find
@@ -6175,10 +7120,10 @@
 
 
 
-<H2><A NAME="SEC100" HREF="bison_toc.html#TOC100">Invoking Bison under VMS</A></H2>
+<H2><A NAME="SEC103" HREF="bison_toc.html#TOC103">Invoking Bison under VMS</A></H2>
 <P>
-<A NAME="IDX215"></A>
-<A NAME="IDX216"></A>
+<A NAME="IDX243"></A>
+<A NAME="IDX244"></A>
 
 
 <P>
@@ -6215,14 +7160,77 @@
 
 
 
-<H1><A NAME="SEC101" HREF="bison_toc.html#TOC101">Bison Symbols</A></H1>
+<H1><A NAME="SEC104" HREF="bison_toc.html#TOC104">Frequently Asked Questions</A></H1>
 <P>
-<A NAME="IDX217"></A>
-<A NAME="IDX218"></A>
+<A NAME="IDX245"></A>
+<A NAME="IDX246"></A>
+
+
+<P>
+Several questions about Bison come up occasionally.  Here some of them
+are addressed.
+
+
+
+
+<H2><A NAME="SEC105" HREF="bison_toc.html#TOC105">Parser Stack Overflow</A></H2>
+
+
+<PRE>
+My parser returns with error with a <SAMP>`parser stack overflow'</SAMP>
+message.  What can I do?
+</PRE>
+
+<P>
+This question is already addressed elsewhere, See section <A HREF="bison.html#SEC48">Recursive Rules</A>.
+
+
+
+
+<H1><A NAME="SEC106" HREF="bison_toc.html#TOC106">Bison Symbols</A></H1>
+<P>
+<A NAME="IDX247"></A>
+<A NAME="IDX248"></A>
 
 
 <DL COMPACT>
 
+<DT><CODE>@$</CODE>
+<DD>
+In an action, the location of the left-hand side of the rule.
+See section <A HREF="bison.html#SEC55">Tracking Locations</A>.
+
+<DT><CODE>@<VAR>n</VAR></CODE>
+<DD>
+In an action, the location of the <VAR>n</VAR>-th symbol of the right-hand
+side of the rule.  See section <A HREF="bison.html#SEC55">Tracking Locations</A>.
+
+<DT><CODE>$$</CODE>
+<DD>
+In an action, the semantic value of the left-hand side of the rule.
+See section <A HREF="bison.html#SEC52">Actions</A>.
+
+<DT><CODE>$<VAR>n</VAR></CODE>
+<DD>
+In an action, the semantic value of the <VAR>n</VAR>-th symbol of the
+right-hand side of the rule.  See section <A HREF="bison.html#SEC52">Actions</A>.
+
+<DT><CODE>$accept</CODE>
+<DD>
+The predefined nonterminal whose only rule is <SAMP>`$accept: <VAR>start</VAR>
+$end'</SAMP>, where <VAR>start</VAR> is the start symbol.  See section <A HREF="bison.html#SEC65">The Start-Symbol</A>.  It cannot be used in the grammar.
+
+<DT><CODE>$end</CODE>
+<DD>
+The predefined token marking the end of the token stream.  It cannot be
+used in the grammar.
+
+<DT><CODE>$undefined</CODE>
+<DD>
+The predefined token onto which all undefined values returned by
+<CODE>yylex</CODE> are mapped.  It cannot be used in the grammar, rather, use
+<CODE>error</CODE>.
+
 <DT><CODE>error</CODE>
 <DD>
 A token name reserved for error recovery.  This token may be used in
@@ -6232,31 +7240,35 @@
 token <CODE>error</CODE> becomes the current look-ahead token.  Actions
 corresponding to <CODE>error</CODE> are then executed, and the look-ahead
 token is reset to the token that originally caused the violation.
-See section <A HREF="bison.html#SEC90">Error Recovery</A>.
+See section <A HREF="bison.html#SEC92">Error Recovery</A>.
 
 <DT><CODE>YYABORT</CODE>
 <DD>
 Macro to pretend that an unrecoverable syntax error has occurred, by
 making <CODE>yyparse</CODE> return 1 immediately.  The error reporting
-function <CODE>yyerror</CODE> is not called.  See section <A HREF="bison.html#SEC69">The Parser Function <CODE>yyparse</CODE></A>.
+function <CODE>yyerror</CODE> is not called.  See section <A HREF="bison.html#SEC70">The Parser Function <CODE>yyparse</CODE></A>.
 
 <DT><CODE>YYACCEPT</CODE>
 <DD>
 Macro to pretend that a complete utterance of the language has been
 read, by making <CODE>yyparse</CODE> return 0 immediately.
-See section <A HREF="bison.html#SEC69">The Parser Function <CODE>yyparse</CODE></A>.
+See section <A HREF="bison.html#SEC70">The Parser Function <CODE>yyparse</CODE></A>.
 
 <DT><CODE>YYBACKUP</CODE>
 <DD>
 Macro to discard a value from the parser stack and fake a look-ahead
-token.  See section <A HREF="bison.html#SEC76">Special Features for Use in Actions</A>.
+token.  See section <A HREF="bison.html#SEC77">Special Features for Use in Actions</A>.
+
+<DT><CODE>YYDEBUG</CODE>
+<DD>
+Macro to define to equip the parser with tracing code.  See section <A HREF="bison.html#SEC99">Tracing Your Parser</A>.
 
 <DT><CODE>YYERROR</CODE>
 <DD>
 Macro to pretend that a syntax error has just been detected: call
 <CODE>yyerror</CODE> and then perform normal error recovery if possible
-(see section <A HREF="bison.html#SEC90">Error Recovery</A>), or (if recovery is impossible) make
-<CODE>yyparse</CODE> return 1.  See section <A HREF="bison.html#SEC90">Error Recovery</A>.
+(see section <A HREF="bison.html#SEC92">Error Recovery</A>), or (if recovery is impossible) make
+<CODE>yyparse</CODE> return 1.  See section <A HREF="bison.html#SEC92">Error Recovery</A>.
 
 <DT><CODE>YYERROR_VERBOSE</CODE>
 <DD>
@@ -6267,17 +7279,17 @@
 <DT><CODE>YYINITDEPTH</CODE>
 <DD>
 Macro for specifying the initial size of the parser stack.
-See section <A HREF="bison.html#SEC89">Stack Overflow, and How to Avoid It</A>.
+See section <A HREF="bison.html#SEC91">Stack Overflow, and How to Avoid It</A>.
 
 <DT><CODE>YYLEX_PARAM</CODE>
 <DD>
 Macro for specifying an extra argument (or list of extra arguments) for
-<CODE>yyparse</CODE> to pass to <CODE>yylex</CODE>.  See section <A HREF="bison.html#SEC74">Calling Conventions for Pure Parsers</A>.
+<CODE>yyparse</CODE> to pass to <CODE>yylex</CODE>.  See section <A HREF="bison.html#SEC75">Calling Conventions for Pure Parsers</A>.
 
 <DT><CODE>YYLTYPE</CODE>
 <DD>
 Macro for the data type of <CODE>yylloc</CODE>; a structure with four
-members.  See section <A HREF="bison.html#SEC55">Data Type of Locations</A>.
+members.  See section <A HREF="bison.html#SEC56">Data Type of Locations</A>.
 
 <DT><CODE>yyltype</CODE>
 <DD>
@@ -6286,70 +7298,70 @@
 <DT><CODE>YYMAXDEPTH</CODE>
 <DD>
 Macro for specifying the maximum size of the parser stack.
-See section <A HREF="bison.html#SEC89">Stack Overflow, and How to Avoid It</A>.
+See section <A HREF="bison.html#SEC91">Stack Overflow, and How to Avoid It</A>.
 
 <DT><CODE>YYPARSE_PARAM</CODE>
 <DD>
 Macro for specifying the name of a parameter that <CODE>yyparse</CODE> should
-accept.  See section <A HREF="bison.html#SEC74">Calling Conventions for Pure Parsers</A>.
+accept.  See section <A HREF="bison.html#SEC75">Calling Conventions for Pure Parsers</A>.
 
 <DT><CODE>YYRECOVERING</CODE>
 <DD>
 Macro whose value indicates whether the parser is recovering from a
-syntax error.  See section <A HREF="bison.html#SEC76">Special Features for Use in Actions</A>.
+syntax error.  See section <A HREF="bison.html#SEC77">Special Features for Use in Actions</A>.
 
 <DT><CODE>YYSTACK_USE_ALLOCA</CODE>
 <DD>
-Macro used to control the use of <CODE>alloca</CODE>. If defined to <SAMP>`0'</SAMP>,
+Macro used to control the use of <CODE>alloca</CODE>.  If defined to <SAMP>`0'</SAMP>,
 the parser will not use <CODE>alloca</CODE> but <CODE>malloc</CODE> when trying to
-grow its internal stacks. Do <EM>not</EM> define <CODE>YYSTACK_USE_ALLOCA</CODE>
+grow its internal stacks.  Do <EM>not</EM> define <CODE>YYSTACK_USE_ALLOCA</CODE>
 to anything else.
 
 <DT><CODE>YYSTYPE</CODE>
 <DD>
 Macro for the data type of semantic values; <CODE>int</CODE> by default.
-See section <A HREF="bison.html#SEC49">Data Types of Semantic Values</A>.
+See section <A HREF="bison.html#SEC50">Data Types of Semantic Values</A>.
 
 <DT><CODE>yychar</CODE>
 <DD>
 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</CODE>.)  Error-recovery rule actions may examine this variable.
-See section <A HREF="bison.html#SEC76">Special Features for Use in Actions</A>.
+See section <A HREF="bison.html#SEC77">Special Features for Use in Actions</A>.
 
 <DT><CODE>yyclearin</CODE>
 <DD>
 Macro used in error-recovery rule actions.  It clears the previous
-look-ahead token.  See section <A HREF="bison.html#SEC90">Error Recovery</A>.
+look-ahead token.  See section <A HREF="bison.html#SEC92">Error Recovery</A>.
 
 <DT><CODE>yydebug</CODE>
 <DD>
 External integer variable set to zero by default.  If <CODE>yydebug</CODE>
 is given a nonzero value, the parser will output information on input
-symbols and parser action.  See section <A HREF="bison.html#SEC95">Debugging Your Parser</A>.
+symbols and parser action.  See section <A HREF="bison.html#SEC99">Tracing Your Parser</A>.
 
 <DT><CODE>yyerrok</CODE>
 <DD>
 Macro to cause parser to recover immediately to its normal mode
-after a parse error.  See section <A HREF="bison.html#SEC90">Error Recovery</A>.
+after a parse error.  See section <A HREF="bison.html#SEC92">Error Recovery</A>.
 
 <DT><CODE>yyerror</CODE>
 <DD>
 User-supplied function to be called by <CODE>yyparse</CODE> on error.  The
 function receives one argument, a pointer to a character string
-containing an error message.  See section <A HREF="bison.html#SEC75">The Error Reporting Function <CODE>yyerror</CODE></A>.
+containing an error message.  See section <A HREF="bison.html#SEC76">The Error Reporting Function <CODE>yyerror</CODE></A>.
 
 <DT><CODE>yylex</CODE>
 <DD>
-User-supplied lexical analyzer function, called with no arguments
-to get the next token.  See section <A HREF="bison.html#SEC70">The Lexical Analyzer Function <CODE>yylex</CODE></A>.
+User-supplied lexical analyzer function, called with no arguments to get
+the next token.  See section <A HREF="bison.html#SEC71">The Lexical Analyzer Function <CODE>yylex</CODE></A>.
 
 <DT><CODE>yylval</CODE>
 <DD>
 External variable in which <CODE>yylex</CODE> should place the semantic
 value associated with a token.  (In a pure parser, it is a local
 variable within <CODE>yyparse</CODE>, and its address is passed to
-<CODE>yylex</CODE>.)  See section <A HREF="bison.html#SEC72">Semantic Values of Tokens</A>.
+<CODE>yylex</CODE>.)  See section <A HREF="bison.html#SEC73">Semantic Values of Tokens</A>.
 
 <DT><CODE>yylloc</CODE>
 <DD>
@@ -6357,80 +7369,108 @@
 numbers associated with a token.  (In a pure parser, it is a local
 variable within <CODE>yyparse</CODE>, and its address is passed to
 <CODE>yylex</CODE>.)  You can ignore this variable if you don't use the
-<SAMP>`@'</SAMP> feature in the grammar actions.  See section <A HREF="bison.html#SEC73">Textual Positions of Tokens</A>.
+<SAMP>`@'</SAMP> feature in the grammar actions.  See section <A HREF="bison.html#SEC74">Textual Positions of Tokens</A>.
 
 <DT><CODE>yynerrs</CODE>
 <DD>
 Global variable which Bison increments each time there is a parse error.
 (In a pure parser, it is a local variable within <CODE>yyparse</CODE>.)
-See section <A HREF="bison.html#SEC75">The Error Reporting Function <CODE>yyerror</CODE></A>.
+See section <A HREF="bison.html#SEC76">The Error Reporting Function <CODE>yyerror</CODE></A>.
 
 <DT><CODE>yyparse</CODE>
 <DD>
 The parser function produced by Bison; call this function to start
-parsing.  See section <A HREF="bison.html#SEC69">The Parser Function <CODE>yyparse</CODE></A>.
+parsing.  See section <A HREF="bison.html#SEC70">The Parser Function <CODE>yyparse</CODE></A>.
 
 <DT><CODE>%debug</CODE>
 <DD>
-Equip the parser for debugging.  See section <A HREF="bison.html#SEC66">Bison Declaration Summary</A>.
+Equip the parser for debugging.  See section <A HREF="bison.html#SEC67">Bison Declaration Summary</A>.
 
 <DT><CODE>%defines</CODE>
 <DD>
 Bison declaration to create a header file meant for the scanner.
-See section <A HREF="bison.html#SEC66">Bison Declaration Summary</A>.
+See section <A HREF="bison.html#SEC67">Bison Declaration Summary</A>.
+
+<DT><CODE>%dprec</CODE>
+<DD>
+Bison declaration to assign a precedence to a rule that is used at parse
+time to resolve reduce/reduce conflicts.  See section <A HREF="bison.html#SEC12">Writing GLR Parsers</A>.
+
+<DT><CODE>%file-prefix="<VAR>prefix</VAR>"</CODE>
+<DD>
+Bison declaration to set the prefix of the output files.  See section <A HREF="bison.html#SEC67">Bison Declaration Summary</A>.
+
+<DT><CODE>%glr-parser</CODE>
+<DD>
+Bison declaration to produce a GLR parser.  See section <A HREF="bison.html#SEC12">Writing GLR Parsers</A>.
 
 <DT><CODE>%left</CODE>
 <DD>
 Bison declaration to assign left associativity to token(s).
-See section <A HREF="bison.html#SEC60">Operator Precedence</A>.
+See section <A HREF="bison.html#SEC61">Operator Precedence</A>.
+
+<DT><CODE>%merge</CODE>
+<DD>
+Bison declaration to assign a merging function to a rule.  If there is a
+reduce/reduce conflict with a rule having the same merging function, the
+function is applied to the two semantic values to get a single result.
+See section <A HREF="bison.html#SEC12">Writing GLR Parsers</A>.
+
+<DT><CODE>%name-prefix="<VAR>prefix</VAR>"</CODE>
+<DD>
+Bison declaration to rename the external symbols.  See section <A HREF="bison.html#SEC67">Bison Declaration Summary</A>.
 
-<DT><CODE>%no_lines</CODE>
+<DT><CODE>%no-lines</CODE>
 <DD>
 Bison declaration to avoid generating <CODE>#line</CODE> directives in the
-parser file.  See section <A HREF="bison.html#SEC66">Bison Declaration Summary</A>.
+parser file.  See section <A HREF="bison.html#SEC67">Bison Declaration Summary</A>.
 
 <DT><CODE>%nonassoc</CODE>
 <DD>
 Bison declaration to assign non-associativity to token(s).
-See section <A HREF="bison.html#SEC60">Operator Precedence</A>.
+See section <A HREF="bison.html#SEC61">Operator Precedence</A>.
+
+<DT><CODE>%output="<VAR>filename</VAR>"</CODE>
+<DD>
+Bison declaration to set the name of the parser file.  See section <A HREF="bison.html#SEC67">Bison Declaration Summary</A>.
 
 <DT><CODE>%prec</CODE>
 <DD>
 Bison declaration to assign a precedence to a specific rule.
-See section <A HREF="bison.html#SEC85">Context-Dependent Precedence</A>.
+See section <A HREF="bison.html#SEC86">Context-Dependent Precedence</A>.
 
-<DT><CODE>%pure_parser</CODE>
+<DT><CODE>%pure-parser</CODE>
 <DD>
 Bison declaration to request a pure (reentrant) parser.
-See section <A HREF="bison.html#SEC65">A Pure (Reentrant) Parser</A>.
+See section <A HREF="bison.html#SEC66">A Pure (Reentrant) Parser</A>.
 
 <DT><CODE>%right</CODE>
 <DD>
 Bison declaration to assign right associativity to token(s).
-See section <A HREF="bison.html#SEC60">Operator Precedence</A>.
+See section <A HREF="bison.html#SEC61">Operator Precedence</A>.
 
 <DT><CODE>%start</CODE>
 <DD>
-Bison declaration to specify the start symbol.  See section <A HREF="bison.html#SEC64">The Start-Symbol</A>.
+Bison declaration to specify the start symbol.  See section <A HREF="bison.html#SEC65">The Start-Symbol</A>.
 
 <DT><CODE>%token</CODE>
 <DD>
 Bison declaration to declare token(s) without specifying precedence.
-See section <A HREF="bison.html#SEC59">Token Type Names</A>.
+See section <A HREF="bison.html#SEC60">Token Type Names</A>.
 
-<DT><CODE>%token_table</CODE>
+<DT><CODE>%token-table</CODE>
 <DD>
 Bison declaration to include a token name table in the parser file.
-See section <A HREF="bison.html#SEC66">Bison Declaration Summary</A>.
+See section <A HREF="bison.html#SEC67">Bison Declaration Summary</A>.
 
 <DT><CODE>%type</CODE>
 <DD>
-Bison declaration to declare nonterminals.  See section <A HREF="bison.html#SEC62">Nonterminal Symbols</A>.
+Bison declaration to declare nonterminals.  See section <A HREF="bison.html#SEC63">Nonterminal Symbols</A>.
 
 <DT><CODE>%union</CODE>
 <DD>
 Bison declaration to specify several possible data types for semantic
-values.  See section <A HREF="bison.html#SEC61">The Collection of Value Types</A>.
+values.  See section <A HREF="bison.html#SEC62">The Collection of Value Types</A>.
 </DL>
 
 <P>
@@ -6442,14 +7482,14 @@
 <DT><SAMP>`%%'</SAMP>
 <DD>
 Delimiter used to separate the grammar rule section from the
-Bison declarations section or the additional C code section.
-See section <A HREF="bison.html#SEC15">The Overall Layout of a Bison Grammar</A>.
+Bison declarations section or the epilogue.
+See section <A HREF="bison.html#SEC16">The Overall Layout of a Bison Grammar</A>.
 
 <DT><SAMP>`%{ %}'</SAMP>
 <DD>
 All code listed between <SAMP>`%{'</SAMP> and <SAMP>`%}'</SAMP> is copied directly to
-the output file uninterpreted.  Such code forms the "C declarations"
-section of the input file.  See section <A HREF="bison.html#SEC40">Outline of a Bison Grammar</A>.
+the output file uninterpreted.  Such code forms the prologue of the input
+file.  See section <A HREF="bison.html#SEC41">Outline of a Bison Grammar</A>.
 
 <DT><SAMP>`/*...*/'</SAMP>
 <DD>
@@ -6457,23 +7497,23 @@
 
 <DT><SAMP>`:'</SAMP>
 <DD>
-Separates a rule's result from its components.  See section <A HREF="bison.html#SEC46">Syntax of Grammar Rules</A>.
+Separates a rule's result from its components.  See section <A HREF="bison.html#SEC47">Syntax of Grammar Rules</A>.
 
 <DT><SAMP>`;'</SAMP>
 <DD>
-Terminates a rule.  See section <A HREF="bison.html#SEC46">Syntax of Grammar Rules</A>.
+Terminates a rule.  See section <A HREF="bison.html#SEC47">Syntax of Grammar Rules</A>.
 
 <DT><SAMP>`|'</SAMP>
 <DD>
 Separates alternate rules for the same result nonterminal.
-See section <A HREF="bison.html#SEC46">Syntax of Grammar Rules</A>.
+See section <A HREF="bison.html#SEC47">Syntax of Grammar Rules</A>.
 </DL>
 
 
 
-<H1><A NAME="SEC102" HREF="bison_toc.html#TOC102">Glossary</A></H1>
+<H1><A NAME="SEC107" HREF="bison_toc.html#TOC107">Glossary</A></H1>
 <P>
-<A NAME="IDX219"></A>
+<A NAME="IDX249"></A>
 
 
 <DL COMPACT>
@@ -6507,7 +7547,15 @@
 machine moves from state to state as specified by the logic of the
 machine.  In the case of the parser, the input is the language being
 parsed, and the states correspond to various stages in the grammar
-rules.  See section <A HREF="bison.html#SEC77">The Bison Parser Algorithm</A>.
+rules.  See section <A HREF="bison.html#SEC78">The Bison Parser Algorithm</A>.
+
+<DT>Generalized LR (GLR)
+<DD>
+A parsing algorithm that can handle all context-free grammars, including those
+that are not LALR(1).  It resolves situations that Bison's usual LALR(1)
+algorithm cannot by effectively splitting off multiple parsers, trying all
+possible parsers, and discarding those that fail in the light of additional
+right context.  See section <A HREF="bison.html#SEC90">Generalized LR (GLR) Parsing</A>.
 
 <DT>Grouping
 <DD>
@@ -6534,40 +7582,40 @@
 <DD>
 Operators having left associativity are analyzed from left to right:
 <SAMP>`a+b+c'</SAMP> first computes <SAMP>`a+b'</SAMP> and then combines with
-<SAMP>`c'</SAMP>.  See section <A HREF="bison.html#SEC80">Operator Precedence</A>.
+<SAMP>`c'</SAMP>.  See section <A HREF="bison.html#SEC81">Operator Precedence</A>.
 
 <DT>Left recursion
 <DD>
 A rule whose result symbol is also its first component symbol; for
-example, <SAMP>`expseq1 : expseq1 ',' exp;'</SAMP>.  See section <A HREF="bison.html#SEC47">Recursive Rules</A>.
+example, <SAMP>`expseq1 : expseq1 ',' exp;'</SAMP>.  See section <A HREF="bison.html#SEC48">Recursive Rules</A>.
 
 <DT>Left-to-right parsing
 <DD>
 Parsing a sentence of a language by analyzing it token by token from
-left to right.  See section <A HREF="bison.html#SEC77">The Bison Parser Algorithm</A>.
+left to right.  See section <A HREF="bison.html#SEC78">The Bison Parser Algorithm</A>.
 
 <DT>Lexical analyzer (scanner)
 <DD>
 A function that reads an input stream and returns tokens one by one.
-See section <A HREF="bison.html#SEC70">The Lexical Analyzer Function <CODE>yylex</CODE></A>.
+See section <A HREF="bison.html#SEC71">The Lexical Analyzer Function <CODE>yylex</CODE></A>.
 
 <DT>Lexical tie-in
 <DD>
 A flag, set by actions in the grammar rules, which alters the way
-tokens are parsed.  See section <A HREF="bison.html#SEC93">Lexical Tie-ins</A>.
+tokens are parsed.  See section <A HREF="bison.html#SEC95">Lexical Tie-ins</A>.
 
 <DT>Literal string token
 <DD>
-A token which consists of two or more fixed characters.  See section <A HREF="bison.html#SEC45">Symbols, Terminal and Nonterminal</A>.
+A token which consists of two or more fixed characters.  See section <A HREF="bison.html#SEC46">Symbols, Terminal and Nonterminal</A>.
 
 <DT>Look-ahead token
 <DD>
-A token already read but not yet shifted.  See section <A HREF="bison.html#SEC78">Look-Ahead Tokens</A>.
+A token already read but not yet shifted.  See section <A HREF="bison.html#SEC79">Look-Ahead Tokens</A>.
 
 <DT>LALR(1)
 <DD>
 The class of context-free grammars that Bison (like most other parser
-generators) can handle; a subset of LR(1).  See section <A HREF="bison.html#SEC88">Mysterious Reduce/Reduce Conflicts</A>.
+generators) can handle; a subset of LR(1).  See section <A HREF="bison.html#SEC89">Mysterious Reduce/Reduce Conflicts</A>.
 
 <DT>LR(1)
 <DD>
@@ -6578,12 +7626,12 @@
 <DD>
 A grammar symbol standing for a grammatical construct that can
 be expressed through rules in terms of smaller constructs; in other
-words, a construct that is not a token.  See section <A HREF="bison.html#SEC45">Symbols, Terminal and Nonterminal</A>.
+words, a construct that is not a token.  See section <A HREF="bison.html#SEC46">Symbols, Terminal and Nonterminal</A>.
 
 <DT>Parse error
 <DD>
 An error encountered during parsing of an input stream due to invalid
-syntax.  See section <A HREF="bison.html#SEC90">Error Recovery</A>.
+syntax.  See section <A HREF="bison.html#SEC92">Error Recovery</A>.
 
 <DT>Parser
 <DD>
@@ -6599,13 +7647,13 @@
 <DT>Reduction
 <DD>
 Replacing a string of nonterminals and/or terminals with a single
-nonterminal, according to a grammar rule.  See section <A HREF="bison.html#SEC77">The Bison Parser Algorithm</A>.
+nonterminal, according to a grammar rule.  See section <A HREF="bison.html#SEC78">The Bison Parser Algorithm</A>.
 
 <DT>Reentrant
 <DD>
 A reentrant subprogram is a subprogram which can be in invoked any
 number of times in parallel, without interference between the various
-invocations.  See section <A HREF="bison.html#SEC65">A Pure (Reentrant) Parser</A>.
+invocations.  See section <A HREF="bison.html#SEC66">A Pure (Reentrant) Parser</A>.
 
 <DT>Reverse polish notation
 <DD>
@@ -6614,19 +7662,19 @@
 <DT>Right recursion
 <DD>
 A rule whose result symbol is also its last component symbol; for
-example, <SAMP>`expseq1: exp ',' expseq1;'</SAMP>.  See section <A HREF="bison.html#SEC47">Recursive Rules</A>.
+example, <SAMP>`expseq1: exp ',' expseq1;'</SAMP>.  See section <A HREF="bison.html#SEC48">Recursive Rules</A>.
 
 <DT>Semantics
 <DD>
 In computer languages, the semantics are specified by the actions
 taken for each instance of the language, i.e., the meaning of
-each statement.  See section <A HREF="bison.html#SEC48">Defining Language Semantics</A>.
+each statement.  See section <A HREF="bison.html#SEC49">Defining Language Semantics</A>.
 
 <DT>Shift
 <DD>
 A parser is said to shift when it makes the choice of analyzing
 further input from the stream rather than reducing immediately some
-already-recognized rule.  See section <A HREF="bison.html#SEC77">The Bison Parser Algorithm</A>.
+already-recognized rule.  See section <A HREF="bison.html#SEC78">The Bison Parser Algorithm</A>.
 
 <DT>Single-character literal
 <DD>
@@ -6638,20 +7686,20 @@
 The nonterminal symbol that stands for a complete valid utterance in
 the language being parsed.  The start symbol is usually listed as the
 first nonterminal symbol in a language specification.
-See section <A HREF="bison.html#SEC64">The Start-Symbol</A>.
+See section <A HREF="bison.html#SEC65">The Start-Symbol</A>.
 
 <DT>Symbol table
 <DD>
 A data structure where symbol names and associated data are stored
 during parsing to allow for recognition and use of existing
-information in repeated uses of a symbol.  See section <A HREF="bison.html#SEC34">Multi-Function Calculator: <CODE>mfcalc</CODE></A>.
+information in repeated uses of a symbol.  See section <A HREF="bison.html#SEC35">Multi-Function Calculator: <CODE>mfcalc</CODE></A>.
 
 <DT>Token
 <DD>
 A basic, grammatically indivisible unit of a language.  The symbol
 that describes a token in the grammar is a terminal symbol.
 The input of the Bison parser is a stream of tokens which comes from
-the lexical analyzer.  See section <A HREF="bison.html#SEC45">Symbols, Terminal and Nonterminal</A>.
+the lexical analyzer.  See section <A HREF="bison.html#SEC46">Symbols, Terminal and Nonterminal</A>.
 
 <DT>Terminal symbol
 <DD>
@@ -6662,14 +7710,14 @@
 
 
 
-<H1><A NAME="SEC103" HREF="bison_toc.html#TOC103">Copying This Manual</A></H1>
+<H1><A NAME="SEC108" HREF="bison_toc.html#TOC108">Copying This Manual</A></H1>
 
 
 
-<H2><A NAME="SEC104" HREF="bison_toc.html#TOC104">GNU Free Documentation License</A></H2>
+<H2><A NAME="SEC109" HREF="bison_toc.html#TOC109">GNU Free Documentation License</A></H2>
 
 <P>
-<A NAME="IDX220"></A>
+<A NAME="IDX250"></A>
 Version 1.1, March 2000
 
 
@@ -7065,7 +8113,7 @@
 
 
 
-<H3><A NAME="SEC105" HREF="bison_toc.html#TOC105">ADDENDUM: How to use this License for your documents</A></H3>
+<H3><A NAME="SEC110" HREF="bison_toc.html#TOC110">ADDENDUM: How to use this License for your documents</A></H3>
 
 <P>
 To use this License in a document you have written, include a copy of
@@ -7101,7 +8149,7 @@
 
 
 
-<H1><A NAME="SEC106" HREF="bison_toc.html#TOC106">Index</A></H1>
+<H1><A NAME="SEC111" HREF="bison_toc.html#TOC111">Index</A></H1>
 
 <P>
 Jump to:
@@ -7127,6 +8175,8 @@
 -
 <A HREF="#cindex_i">i</A>
 -
+<A HREF="#cindex_k">k</A>
+-
 <A HREF="#cindex_l">l</A>
 -
 <A HREF="#cindex_m">m</A>
@@ -7137,6 +8187,8 @@
 -
 <A HREF="#cindex_p">p</A>
 -
+<A HREF="#cindex_q">q</A>
+-
 <A HREF="#cindex_r">r</A>
 -
 <A HREF="#cindex_s">s</A>
@@ -7155,295 +8207,322 @@
 <P>
 <H2><A NAME="cindex_$">$</A></H2>
 <DIR>
-<LI><A HREF="bison.html#IDX89">$$</A>
-<LI><A HREF="bison.html#IDX90">$<VAR>n</VAR></A>
+<LI><A HREF="bison.html#IDX102">$$</A>
+<LI><A HREF="bison.html#IDX103">$<VAR>n</VAR></A>
 </DIR>
 <H2><A NAME="cindex_%">%</A></H2>
 <DIR>
-<LI><A HREF="bison.html#IDX125">%expect</A>
-<LI><A HREF="bison.html#IDX176">%left</A>
-<LI><A HREF="bison.html#IDX178">%nonassoc</A>
-<LI><A HREF="bison.html#IDX183">%prec</A>
-<LI><A HREF="bison.html#IDX132">%pure_parser</A>
-<LI><A HREF="bison.html#IDX177">%right</A>
-<LI><A HREF="bison.html#IDX129">%start</A>
-<LI><A HREF="bison.html#IDX111">%token</A>
-<LI><A HREF="bison.html#IDX120">%type</A>
-<LI><A HREF="bison.html#IDX117">%union</A>
+<LI><A HREF="bison.html#IDX238">%debug</A>
+<LI><A HREF="bison.html#IDX138">%expect</A>
+<LI><A HREF="bison.html#IDX26">%glr-parser</A>
+<LI><A HREF="bison.html#IDX189">%left</A>
+<LI><A HREF="bison.html#IDX191">%nonassoc</A>
+<LI><A HREF="bison.html#IDX196">%prec</A>
+<LI><A HREF="bison.html#IDX145">%pure-parser</A>
+<LI><A HREF="bison.html#IDX190">%right</A>
+<LI><A HREF="bison.html#IDX142">%start</A>
+<LI><A HREF="bison.html#IDX124">%token</A>
+<LI><A HREF="bison.html#IDX133">%type</A>
+<LI><A HREF="bison.html#IDX130">%union</A>
 </DIR>
 <H2><A NAME="cindex_@">@</A></H2>
 <DIR>
-<LI><A HREF="bison.html#IDX103">@$</A>, <A HREF="bison.html#IDX159">@$</A>
-<LI><A HREF="bison.html#IDX104">@<VAR>n</VAR></A>, <A HREF="bison.html#IDX160">@<VAR>n</VAR></A>
+<LI><A HREF="bison.html#IDX116">@$</A>, <A HREF="bison.html#IDX172">@$</A>
+<LI><A HREF="bison.html#IDX117">@<VAR>n</VAR></A>, <A HREF="bison.html#IDX173">@<VAR>n</VAR></A>
 </DIR>
 <H2><A NAME="cindex_a">a</A></H2>
 <DIR>
-<LI><A HREF="bison.html#IDX88">action</A>
-<LI><A HREF="bison.html#IDX92">action data types</A>
-<LI><A HREF="bison.html#IDX155">action features summary</A>
-<LI><A HREF="bison.html#IDX94">actions in mid-rule</A>
-<LI><A HREF="bison.html#IDX102">actions, location</A>
-<LI><A HREF="bison.html#IDX17">actions, semantic</A>
-<LI><A HREF="bison.html#IDX62">additional C code section</A>
-<LI><A HREF="bison.html#IDX162">algorithm of parser</A>
-<LI><A HREF="bison.html#IDX175">associativity</A>
+<LI><A HREF="bison.html#IDX101">action</A>
+<LI><A HREF="bison.html#IDX105">action data types</A>
+<LI><A HREF="bison.html#IDX168">action features summary</A>
+<LI><A HREF="bison.html#IDX107">actions in mid-rule</A>
+<LI><A HREF="bison.html#IDX115">actions, location</A>
+<LI><A HREF="bison.html#IDX23">actions, semantic</A>
+<LI><A HREF="bison.html#IDX74">additional C code section</A>
+<LI><A HREF="bison.html#IDX175">algorithm of parser</A>
+<LI><A HREF="bison.html#IDX10">ambiguous grammars</A>, <A HREF="bison.html#IDX206">ambiguous grammars</A>
+<LI><A HREF="bison.html#IDX188">associativity</A>
 </DIR>
 <H2><A NAME="cindex_b">b</A></H2>
 <DIR>
 <LI><A HREF="bison.html#IDX5">Backus-Naur form</A>
-<LI><A HREF="bison.html#IDX133">Bison declaration summary</A>
-<LI><A HREF="bison.html#IDX107">Bison declarations</A>
-<LI><A HREF="bison.html#IDX58">Bison declarations (introduction)</A>
-<LI><A HREF="bison.html#IDX11">Bison grammar</A>
-<LI><A HREF="bison.html#IDX210">Bison invocation</A>
-<LI><A HREF="bison.html#IDX21">Bison parser</A>
-<LI><A HREF="bison.html#IDX161">Bison parser algorithm</A>
-<LI><A HREF="bison.html#IDX217">Bison symbols, table of</A>
-<LI><A HREF="bison.html#IDX22">Bison utility</A>
-<LI><A HREF="bison.html#IDX213">BISON_HAIRY</A>
-<LI><A HREF="bison.html#IDX214">BISON_SIMPLE</A>
+<LI><A HREF="bison.html#IDX146">Bison declaration summary</A>
+<LI><A HREF="bison.html#IDX120">Bison declarations</A>
+<LI><A HREF="bison.html#IDX70">Bison declarations (introduction)</A>
+<LI><A HREF="bison.html#IDX17">Bison grammar</A>
+<LI><A HREF="bison.html#IDX241">Bison invocation</A>
+<LI><A HREF="bison.html#IDX32">Bison parser</A>
+<LI><A HREF="bison.html#IDX174">Bison parser algorithm</A>
+<LI><A HREF="bison.html#IDX247">Bison symbols, table of</A>
+<LI><A HREF="bison.html#IDX33">Bison utility</A>
 <LI><A HREF="bison.html#IDX4">BNF</A>
 </DIR>
 <H2><A NAME="cindex_c">c</A></H2>
 <DIR>
-<LI><A HREF="bison.html#IDX63">C code, section for additional</A>
-<LI><A HREF="bison.html#IDX56">C declarations section</A>
-<LI><A HREF="bison.html#IDX136">C-language interface</A>
-<LI><A HREF="bison.html#IDX45"><CODE>calc</CODE></A>
-<LI><A HREF="bison.html#IDX46">calculator, infix notation</A>
-<LI><A HREF="bison.html#IDX50">calculator, location tracking</A>
-<LI><A HREF="bison.html#IDX53">calculator, multi-function</A>
-<LI><A HREF="bison.html#IDX36">calculator, simple</A>
-<LI><A HREF="bison.html#IDX68">character token</A>
-<LI><A HREF="bison.html#IDX43">compiling the parser</A>
-<LI><A HREF="bison.html#IDX169">conflicts</A>
-<LI><A HREF="bison.html#IDX188">conflicts, reduce/reduce</A>
-<LI><A HREF="bison.html#IDX124">conflicts, suppressing warnings of</A>
-<LI><A HREF="bison.html#IDX179">context-dependent precedence</A>
+<LI><A HREF="bison.html#IDX76">C code, section for additional</A>
+<LI><A HREF="bison.html#IDX149">C-language interface</A>
+<LI><A HREF="bison.html#IDX56"><CODE>calc</CODE></A>
+<LI><A HREF="bison.html#IDX57">calculator, infix notation</A>
+<LI><A HREF="bison.html#IDX61">calculator, location tracking</A>
+<LI><A HREF="bison.html#IDX64">calculator, multi-function</A>
+<LI><A HREF="bison.html#IDX47">calculator, simple</A>
+<LI><A HREF="bison.html#IDX81">character token</A>
+<LI><A HREF="bison.html#IDX54">compiling the parser</A>
+<LI><A HREF="bison.html#IDX27">conflicts</A>, <A HREF="bison.html#IDX182">conflicts</A>
+<LI><A HREF="bison.html#IDX201">conflicts, reduce/reduce</A>
+<LI><A HREF="bison.html#IDX137">conflicts, suppressing warnings of</A>
+<LI><A HREF="bison.html#IDX192">context-dependent precedence</A>
 <LI><A HREF="bison.html#IDX2">context-free grammar</A>
-<LI><A HREF="bison.html#IDX39">controlling function</A>
+<LI><A HREF="bison.html#IDX50">controlling function</A>
+<LI><A HREF="bison.html#IDX230">core, item set</A>
 </DIR>
 <H2><A NAME="cindex_d">d</A></H2>
 <DIR>
-<LI><A HREF="bison.html#IDX171">dangling <CODE>else</CODE></A>
-<LI><A HREF="bison.html#IDX99">data type of locations</A>
-<LI><A HREF="bison.html#IDX93">data types in actions</A>
-<LI><A HREF="bison.html#IDX86">data types of semantic values</A>
-<LI><A HREF="bison.html#IDX206">debugging</A>
-<LI><A HREF="bison.html#IDX134">declaration summary</A>
-<LI><A HREF="bison.html#IDX106">declarations, Bison</A>
-<LI><A HREF="bison.html#IDX59">declarations, Bison (introduction)</A>
-<LI><A HREF="bison.html#IDX57">declarations, C</A>
-<LI><A HREF="bison.html#IDX110">declaring literal string tokens</A>
-<LI><A HREF="bison.html#IDX113">declaring operator precedence</A>
-<LI><A HREF="bison.html#IDX126">declaring the start symbol</A>
-<LI><A HREF="bison.html#IDX108">declaring token type names</A>
-<LI><A HREF="bison.html#IDX115">declaring value types</A>
-<LI><A HREF="bison.html#IDX118">declaring value types, nonterminals</A>
-<LI><A HREF="bison.html#IDX91">default action</A>
-<LI><A HREF="bison.html#IDX87">default data type</A>
-<LI><A HREF="bison.html#IDX100">default location type</A>
-<LI><A HREF="bison.html#IDX195">default stack limit</A>
-<LI><A HREF="bison.html#IDX128">default start symbol</A>
-<LI><A HREF="bison.html#IDX82">defining language semantics</A>
+<LI><A HREF="bison.html#IDX184">dangling <CODE>else</CODE></A>
+<LI><A HREF="bison.html#IDX112">data type of locations</A>
+<LI><A HREF="bison.html#IDX106">data types in actions</A>
+<LI><A HREF="bison.html#IDX99">data types of semantic values</A>
+<LI><A HREF="bison.html#IDX235">debugging</A>
+<LI><A HREF="bison.html#IDX147">declaration summary</A>
+<LI><A HREF="bison.html#IDX69">declarations</A>
+<LI><A HREF="bison.html#IDX67">declarations section</A>
+<LI><A HREF="bison.html#IDX119">declarations, Bison</A>
+<LI><A HREF="bison.html#IDX71">declarations, Bison (introduction)</A>
+<LI><A HREF="bison.html#IDX123">declaring literal string tokens</A>
+<LI><A HREF="bison.html#IDX126">declaring operator precedence</A>
+<LI><A HREF="bison.html#IDX139">declaring the start symbol</A>
+<LI><A HREF="bison.html#IDX121">declaring token type names</A>
+<LI><A HREF="bison.html#IDX128">declaring value types</A>
+<LI><A HREF="bison.html#IDX131">declaring value types, nonterminals</A>
+<LI><A HREF="bison.html#IDX104">default action</A>
+<LI><A HREF="bison.html#IDX100">default data type</A>
+<LI><A HREF="bison.html#IDX113">default location type</A>
+<LI><A HREF="bison.html#IDX212">default stack limit</A>
+<LI><A HREF="bison.html#IDX141">default start symbol</A>
+<LI><A HREF="bison.html#IDX95">defining language semantics</A>
 </DIR>
 <H2><A NAME="cindex_e">e</A></H2>
 <DIR>
-<LI><A HREF="bison.html#IDX172"><CODE>else</CODE>, dangling</A>
-<LI><A HREF="bison.html#IDX212">environment variables</A>
-<LI><A HREF="bison.html#IDX199">error</A>
-<LI><A HREF="bison.html#IDX197">error recovery</A>
-<LI><A HREF="bison.html#IDX47">error recovery, simple</A>
-<LI><A HREF="bison.html#IDX148">error reporting function</A>
-<LI><A HREF="bison.html#IDX41">error reporting routine</A>
-<LI><A HREF="bison.html#IDX32">examples, simple</A>
-<LI><A HREF="bison.html#IDX55">exercises</A>
+<LI><A HREF="bison.html#IDX185"><CODE>else</CODE>, dangling</A>
+<LI><A HREF="bison.html#IDX75">epilogue</A>
+<LI><A HREF="bison.html#IDX216">error</A>
+<LI><A HREF="bison.html#IDX214">error recovery</A>
+<LI><A HREF="bison.html#IDX58">error recovery, simple</A>
+<LI><A HREF="bison.html#IDX161">error reporting function</A>
+<LI><A HREF="bison.html#IDX52">error reporting routine</A>
+<LI><A HREF="bison.html#IDX43">examples, simple</A>
+<LI><A HREF="bison.html#IDX66">exercises</A>
 </DIR>
 <H2><A NAME="cindex_f">f</A></H2>
 <DIR>
-<LI><A HREF="bison.html#IDX220">FDL, GNU Free Documentation License</A>
-<LI><A HREF="bison.html#IDX28">file format</A>
-<LI><A HREF="bison.html#IDX184">finite-state machine</A>
-<LI><A HREF="bison.html#IDX13">formal grammar</A>
-<LI><A HREF="bison.html#IDX29">format of grammar file</A>
+<LI><A HREF="bison.html#IDX250">FDL, GNU Free Documentation License</A>
+<LI><A HREF="bison.html#IDX39">file format</A>
+<LI><A HREF="bison.html#IDX197">finite-state machine</A>
+<LI><A HREF="bison.html#IDX19">formal grammar</A>
+<LI><A HREF="bison.html#IDX40">format of grammar file</A>
+<LI><A HREF="bison.html#IDX245">frequently asked questions</A>
 </DIR>
 <H2><A NAME="cindex_g">g</A></H2>
 <DIR>
-<LI><A HREF="bison.html#IDX219">glossary</A>
-<LI><A HREF="bison.html#IDX27">grammar file</A>
-<LI><A HREF="bison.html#IDX75">grammar rule syntax</A>
-<LI><A HREF="bison.html#IDX60">grammar rules section</A>
-<LI><A HREF="bison.html#IDX12">grammar, Bison</A>
+<LI><A HREF="bison.html#IDX9">generalized LR (GLR) parsing</A>, <A HREF="bison.html#IDX25">generalized LR (GLR) parsing</A>, <A HREF="bison.html#IDX205">generalized LR (GLR) parsing</A>
+<LI><A HREF="bison.html#IDX249">glossary</A>
+<LI><A HREF="bison.html#IDX8">GLR parsing</A>, <A HREF="bison.html#IDX24">GLR parsing</A>, <A HREF="bison.html#IDX204">GLR parsing</A>
+<LI><A HREF="bison.html#IDX38">grammar file</A>
+<LI><A HREF="bison.html#IDX88">grammar rule syntax</A>
+<LI><A HREF="bison.html#IDX72">grammar rules section</A>
+<LI><A HREF="bison.html#IDX18">grammar, Bison</A>
 <LI><A HREF="bison.html#IDX3">grammar, context-free</A>
-<LI><A HREF="bison.html#IDX9">grouping, syntactic</A>
+<LI><A HREF="bison.html#IDX15">grouping, syntactic</A>
 </DIR>
 <H2><A NAME="cindex_i">i</A></H2>
 <DIR>
-<LI><A HREF="bison.html#IDX44">infix notation calculator</A>
-<LI><A HREF="bison.html#IDX137">interface</A>
+<LI><A HREF="bison.html#IDX55">infix notation calculator</A>
+<LI><A HREF="bison.html#IDX150">interface</A>
 <LI><A HREF="bison.html#IDX1">introduction</A>
-<LI><A HREF="bison.html#IDX209">invoking Bison</A>
-<LI><A HREF="bison.html#IDX215">invoking Bison under VMS</A>
+<LI><A HREF="bison.html#IDX240">invoking Bison</A>
+<LI><A HREF="bison.html#IDX243">invoking Bison under VMS</A>
+<LI><A HREF="bison.html#IDX227">item</A>
+<LI><A HREF="bison.html#IDX231">item set core</A>, <A HREF="bison.html#IDX233">item set core</A>
+</DIR>
+<H2><A NAME="cindex_k">k</A></H2>
+<DIR>
+<LI><A HREF="bison.html#IDX232">kernel, item set</A>
 </DIR>
 <H2><A NAME="cindex_l">l</A></H2>
 <DIR>
-<LI><A HREF="bison.html#IDX190">LALR(1)</A>
-<LI><A HREF="bison.html#IDX83">language semantics, defining</A>
-<LI><A HREF="bison.html#IDX30">layout of Bison grammar</A>
-<LI><A HREF="bison.html#IDX79">left recursion</A>
-<LI><A HREF="bison.html#IDX142">lexical analyzer</A>
-<LI><A HREF="bison.html#IDX23">lexical analyzer, purpose</A>
-<LI><A HREF="bison.html#IDX38">lexical analyzer, writing</A>
-<LI><A HREF="bison.html#IDX203">lexical tie-in</A>
-<LI><A HREF="bison.html#IDX72">literal string token</A>
-<LI><A HREF="bison.html#IDX69">literal token</A>
-<LI><A HREF="bison.html#IDX18">location</A>, <A HREF="bison.html#IDX96">location</A>
-<LI><A HREF="bison.html#IDX101">location actions</A>
-<LI><A HREF="bison.html#IDX48">location tracking calculator</A>
-<LI><A HREF="bison.html#IDX167">look-ahead token</A>
-<LI><A HREF="bison.html#IDX189">LR(1)</A>
-<LI><A HREF="bison.html#IDX49"><CODE>ltcalc</CODE></A>
+<LI><A HREF="bison.html#IDX203">LALR(1)</A>
+<LI><A HREF="bison.html#IDX6">LALR(1) grammars</A>
+<LI><A HREF="bison.html#IDX96">language semantics, defining</A>
+<LI><A HREF="bison.html#IDX41">layout of Bison grammar</A>
+<LI><A HREF="bison.html#IDX92">left recursion</A>
+<LI><A HREF="bison.html#IDX155">lexical analyzer</A>
+<LI><A HREF="bison.html#IDX34">lexical analyzer, purpose</A>
+<LI><A HREF="bison.html#IDX49">lexical analyzer, writing</A>
+<LI><A HREF="bison.html#IDX220">lexical tie-in</A>
+<LI><A HREF="bison.html#IDX85">literal string token</A>
+<LI><A HREF="bison.html#IDX82">literal token</A>
+<LI><A HREF="bison.html#IDX29">location</A>, <A HREF="bison.html#IDX109">location</A>
+<LI><A HREF="bison.html#IDX114">location actions</A>
+<LI><A HREF="bison.html#IDX59">location tracking calculator</A>
+<LI><A HREF="bison.html#IDX180">look-ahead token</A>
+<LI><A HREF="bison.html#IDX202">LR(1)</A>
+<LI><A HREF="bison.html#IDX7">LR(1) grammars</A>
+<LI><A HREF="bison.html#IDX60"><CODE>ltcalc</CODE></A>
 </DIR>
 <H2><A NAME="cindex_m">m</A></H2>
 <DIR>
-<LI><A HREF="bison.html#IDX40">main function in simple example</A>
-<LI><A HREF="bison.html#IDX52"><CODE>mfcalc</CODE></A>
-<LI><A HREF="bison.html#IDX95">mid-rule actions</A>
-<LI><A HREF="bison.html#IDX51">multi-function calculator</A>
-<LI><A HREF="bison.html#IDX73">multicharacter literal</A>
-<LI><A HREF="bison.html#IDX81">mutual recursion</A>
+<LI><A HREF="bison.html#IDX51">main function in simple example</A>
+<LI><A HREF="bison.html#IDX63"><CODE>mfcalc</CODE></A>
+<LI><A HREF="bison.html#IDX108">mid-rule actions</A>
+<LI><A HREF="bison.html#IDX62">multi-function calculator</A>
+<LI><A HREF="bison.html#IDX86">multicharacter literal</A>
+<LI><A HREF="bison.html#IDX94">mutual recursion</A>
 </DIR>
 <H2><A NAME="cindex_n">n</A></H2>
 <DIR>
-<LI><A HREF="bison.html#IDX64">nonterminal symbol</A>
+<LI><A HREF="bison.html#IDX11">non-deterministic parsing</A>, <A HREF="bison.html#IDX207">non-deterministic parsing</A>
+<LI><A HREF="bison.html#IDX77">nonterminal symbol</A>
+<LI><A HREF="bison.html#IDX223">nonterminal, useless</A>
 </DIR>
 <H2><A NAME="cindex_o">o</A></H2>
 <DIR>
-<LI><A HREF="bison.html#IDX173">operator precedence</A>
-<LI><A HREF="bison.html#IDX114">operator precedence, declaring</A>
-<LI><A HREF="bison.html#IDX211">options for invoking Bison</A>
-<LI><A HREF="bison.html#IDX193">overflow of parser stack</A>
+<LI><A HREF="bison.html#IDX186">operator precedence</A>
+<LI><A HREF="bison.html#IDX127">operator precedence, declaring</A>
+<LI><A HREF="bison.html#IDX242">options for invoking Bison</A>
+<LI><A HREF="bison.html#IDX210">overflow of parser stack</A>
 </DIR>
 <H2><A NAME="cindex_p">p</A></H2>
 <DIR>
-<LI><A HREF="bison.html#IDX150">parse error</A>
-<LI><A HREF="bison.html#IDX24">parser</A>
-<LI><A HREF="bison.html#IDX165">parser stack</A>
-<LI><A HREF="bison.html#IDX192">parser stack overflow</A>
-<LI><A HREF="bison.html#IDX185">parser state</A>
-<LI><A HREF="bison.html#IDX34">polish notation calculator</A>
-<LI><A HREF="bison.html#IDX20">position, textual</A>, <A HREF="bison.html#IDX98">position, textual</A>
-<LI><A HREF="bison.html#IDX112">precedence declarations</A>
-<LI><A HREF="bison.html#IDX174">precedence of operators</A>
-<LI><A HREF="bison.html#IDX181">precedence, context-dependent</A>
-<LI><A HREF="bison.html#IDX182">precedence, unary operator</A>
-<LI><A HREF="bison.html#IDX122">preventing warnings about conflicts</A>
-<LI><A HREF="bison.html#IDX131">pure parser</A>
+<LI><A HREF="bison.html#IDX163">parse error</A>
+<LI><A HREF="bison.html#IDX35">parser</A>
+<LI><A HREF="bison.html#IDX178">parser stack</A>
+<LI><A HREF="bison.html#IDX209">parser stack overflow</A>
+<LI><A HREF="bison.html#IDX198">parser state</A>
+<LI><A HREF="bison.html#IDX228">pointed rule</A>
+<LI><A HREF="bison.html#IDX45">polish notation calculator</A>
+<LI><A HREF="bison.html#IDX31">position, textual</A>, <A HREF="bison.html#IDX111">position, textual</A>
+<LI><A HREF="bison.html#IDX125">precedence declarations</A>
+<LI><A HREF="bison.html#IDX187">precedence of operators</A>
+<LI><A HREF="bison.html#IDX194">precedence, context-dependent</A>
+<LI><A HREF="bison.html#IDX195">precedence, unary operator</A>
+<LI><A HREF="bison.html#IDX135">preventing warnings about conflicts</A>
+<LI><A HREF="bison.html#IDX68">Prologue</A>
+<LI><A HREF="bison.html#IDX144">pure parser</A>
+</DIR>
+<H2><A NAME="cindex_q">q</A></H2>
+<DIR>
+<LI><A HREF="bison.html#IDX246">questions</A>
 </DIR>
 <H2><A NAME="cindex_r">r</A></H2>
 <DIR>
-<LI><A HREF="bison.html#IDX198">recovery from errors</A>
-<LI><A HREF="bison.html#IDX78">recursive rule</A>
-<LI><A HREF="bison.html#IDX187">reduce/reduce conflict</A>
-<LI><A HREF="bison.html#IDX164">reduction</A>
-<LI><A HREF="bison.html#IDX130">reentrant parser</A>
-<LI><A HREF="bison.html#IDX33">reverse polish notation</A>
-<LI><A HREF="bison.html#IDX80">right recursion</A>
-<LI><A HREF="bison.html#IDX35"><CODE>rpcalc</CODE></A>
-<LI><A HREF="bison.html#IDX74">rule syntax</A>
-<LI><A HREF="bison.html#IDX61">rules section for grammar</A>
-<LI><A HREF="bison.html#IDX42">running Bison (introduction)</A>
+<LI><A HREF="bison.html#IDX215">recovery from errors</A>
+<LI><A HREF="bison.html#IDX91">recursive rule</A>
+<LI><A HREF="bison.html#IDX200">reduce/reduce conflict</A>
+<LI><A HREF="bison.html#IDX177">reduction</A>
+<LI><A HREF="bison.html#IDX143">reentrant parser</A>
+<LI><A HREF="bison.html#IDX44">reverse polish notation</A>
+<LI><A HREF="bison.html#IDX93">right recursion</A>
+<LI><A HREF="bison.html#IDX46"><CODE>rpcalc</CODE></A>
+<LI><A HREF="bison.html#IDX87">rule syntax</A>
+<LI><A HREF="bison.html#IDX229">rule, pointed</A>
+<LI><A HREF="bison.html#IDX225">rule, useless</A>
+<LI><A HREF="bison.html#IDX73">rules section for grammar</A>
+<LI><A HREF="bison.html#IDX53">running Bison (introduction)</A>
 </DIR>
 <H2><A NAME="cindex_s">s</A></H2>
 <DIR>
-<LI><A HREF="bison.html#IDX16">semantic actions</A>
-<LI><A HREF="bison.html#IDX14">semantic value</A>
-<LI><A HREF="bison.html#IDX84">semantic value type</A>
-<LI><A HREF="bison.html#IDX170">shift/reduce conflicts</A>
-<LI><A HREF="bison.html#IDX163">shifting</A>
-<LI><A HREF="bison.html#IDX31">simple examples</A>
-<LI><A HREF="bison.html#IDX70">single-character literal</A>
-<LI><A HREF="bison.html#IDX191">stack overflow</A>
-<LI><A HREF="bison.html#IDX166">stack, parser</A>
-<LI><A HREF="bison.html#IDX25">stages in using Bison</A>
-<LI><A HREF="bison.html#IDX10">start symbol</A>
-<LI><A HREF="bison.html#IDX127">start symbol, declaring</A>
-<LI><A HREF="bison.html#IDX186">state (of parser)</A>
-<LI><A HREF="bison.html#IDX71">string token</A>
-<LI><A HREF="bison.html#IDX154">summary, action features</A>
-<LI><A HREF="bison.html#IDX135">summary, Bison declaration</A>
-<LI><A HREF="bison.html#IDX121">suppressing conflict warnings</A>
-<LI><A HREF="bison.html#IDX67">symbol</A>
-<LI><A HREF="bison.html#IDX54">symbol table example</A>
-<LI><A HREF="bison.html#IDX6">symbols (abstract)</A>
-<LI><A HREF="bison.html#IDX218">symbols in Bison, table of</A>
-<LI><A HREF="bison.html#IDX8">syntactic grouping</A>
-<LI><A HREF="bison.html#IDX151">syntax error</A>
-<LI><A HREF="bison.html#IDX76">syntax of grammar rules</A>
+<LI><A HREF="bison.html#IDX22">semantic actions</A>
+<LI><A HREF="bison.html#IDX20">semantic value</A>
+<LI><A HREF="bison.html#IDX97">semantic value type</A>
+<LI><A HREF="bison.html#IDX28">shift/reduce conflicts</A>, <A HREF="bison.html#IDX183">shift/reduce conflicts</A>
+<LI><A HREF="bison.html#IDX176">shifting</A>
+<LI><A HREF="bison.html#IDX42">simple examples</A>
+<LI><A HREF="bison.html#IDX83">single-character literal</A>
+<LI><A HREF="bison.html#IDX208">stack overflow</A>
+<LI><A HREF="bison.html#IDX179">stack, parser</A>
+<LI><A HREF="bison.html#IDX36">stages in using Bison</A>
+<LI><A HREF="bison.html#IDX16">start symbol</A>
+<LI><A HREF="bison.html#IDX140">start symbol, declaring</A>
+<LI><A HREF="bison.html#IDX199">state (of parser)</A>
+<LI><A HREF="bison.html#IDX84">string token</A>
+<LI><A HREF="bison.html#IDX167">summary, action features</A>
+<LI><A HREF="bison.html#IDX148">summary, Bison declaration</A>
+<LI><A HREF="bison.html#IDX134">suppressing conflict warnings</A>
+<LI><A HREF="bison.html#IDX80">symbol</A>
+<LI><A HREF="bison.html#IDX65">symbol table example</A>
+<LI><A HREF="bison.html#IDX12">symbols (abstract)</A>
+<LI><A HREF="bison.html#IDX248">symbols in Bison, table of</A>
+<LI><A HREF="bison.html#IDX14">syntactic grouping</A>
+<LI><A HREF="bison.html#IDX164">syntax error</A>
+<LI><A HREF="bison.html#IDX89">syntax of grammar rules</A>
 </DIR>
 <H2><A NAME="cindex_t">t</A></H2>
 <DIR>
-<LI><A HREF="bison.html#IDX65">terminal symbol</A>
-<LI><A HREF="bison.html#IDX19">textual position</A>, <A HREF="bison.html#IDX97">textual position</A>
-<LI><A HREF="bison.html#IDX7">token</A>
-<LI><A HREF="bison.html#IDX66">token type</A>
-<LI><A HREF="bison.html#IDX109">token type names, declaring</A>
-<LI><A HREF="bison.html#IDX207">tracing the parser</A>
+<LI><A HREF="bison.html#IDX78">terminal symbol</A>
+<LI><A HREF="bison.html#IDX30">textual position</A>, <A HREF="bison.html#IDX110">textual position</A>
+<LI><A HREF="bison.html#IDX13">token</A>
+<LI><A HREF="bison.html#IDX79">token type</A>
+<LI><A HREF="bison.html#IDX122">token type names, declaring</A>
+<LI><A HREF="bison.html#IDX221">token, useless</A>
+<LI><A HREF="bison.html#IDX236">tracing the parser</A>
 </DIR>
 <H2><A NAME="cindex_u">u</A></H2>
 <DIR>
-<LI><A HREF="bison.html#IDX180">unary operator precedence</A>
-<LI><A HREF="bison.html#IDX26">using Bison</A>
+<LI><A HREF="bison.html#IDX193">unary operator precedence</A>
+<LI><A HREF="bison.html#IDX224">useless nonterminal</A>
+<LI><A HREF="bison.html#IDX226">useless rule</A>
+<LI><A HREF="bison.html#IDX222">useless token</A>
+<LI><A HREF="bison.html#IDX37">using Bison</A>
 </DIR>
 <H2><A NAME="cindex_v">v</A></H2>
 <DIR>
-<LI><A HREF="bison.html#IDX85">value type, semantic</A>
-<LI><A HREF="bison.html#IDX116">value types, declaring</A>
-<LI><A HREF="bison.html#IDX119">value types, nonterminals, declaring</A>
-<LI><A HREF="bison.html#IDX15">value, semantic</A>
-<LI><A HREF="bison.html#IDX216">VMS</A>
+<LI><A HREF="bison.html#IDX98">value type, semantic</A>
+<LI><A HREF="bison.html#IDX129">value types, declaring</A>
+<LI><A HREF="bison.html#IDX132">value types, nonterminals, declaring</A>
+<LI><A HREF="bison.html#IDX21">value, semantic</A>
+<LI><A HREF="bison.html#IDX244">VMS</A>
 </DIR>
 <H2><A NAME="cindex_w">w</A></H2>
 <DIR>
-<LI><A HREF="bison.html#IDX123">warnings, preventing</A>
-<LI><A HREF="bison.html#IDX37">writing a lexical analyzer</A>
+<LI><A HREF="bison.html#IDX136">warnings, preventing</A>
+<LI><A HREF="bison.html#IDX48">writing a lexical analyzer</A>
 </DIR>
 <H2><A NAME="cindex_y">y</A></H2>
 <DIR>
-<LI><A HREF="bison.html#IDX140">YYABORT</A>
-<LI><A HREF="bison.html#IDX139">YYACCEPT</A>
-<LI><A HREF="bison.html#IDX156">YYBACKUP</A>
-<LI><A HREF="bison.html#IDX168">yychar</A>
-<LI><A HREF="bison.html#IDX201">yyclearin</A>
-<LI><A HREF="bison.html#IDX204">YYDEBUG</A>
-<LI><A HREF="bison.html#IDX205">yydebug</A>
-<LI><A HREF="bison.html#IDX157">YYEMPTY</A>
-<LI><A HREF="bison.html#IDX200">yyerrok</A>
-<LI><A HREF="bison.html#IDX158">YYERROR</A>
-<LI><A HREF="bison.html#IDX149">yyerror</A>
-<LI><A HREF="bison.html#IDX152">YYERROR_VERBOSE</A>
-<LI><A HREF="bison.html#IDX196">YYINITDEPTH</A>
-<LI><A HREF="bison.html#IDX141">yylex</A>
-<LI><A HREF="bison.html#IDX147">YYLEX_PARAM</A>
-<LI><A HREF="bison.html#IDX144">yylloc</A>
-<LI><A HREF="bison.html#IDX105">YYLLOC_DEFAULT</A>
-<LI><A HREF="bison.html#IDX145">YYLTYPE</A>
-<LI><A HREF="bison.html#IDX143">yylval</A>
-<LI><A HREF="bison.html#IDX194">YYMAXDEPTH</A>
-<LI><A HREF="bison.html#IDX153">yynerrs</A>
-<LI><A HREF="bison.html#IDX138">yyparse</A>
-<LI><A HREF="bison.html#IDX146">YYPARSE_PARAM</A>
-<LI><A HREF="bison.html#IDX208">YYPRINT</A>
-<LI><A HREF="bison.html#IDX202">YYRECOVERING</A>
+<LI><A HREF="bison.html#IDX153">YYABORT</A>
+<LI><A HREF="bison.html#IDX152">YYACCEPT</A>
+<LI><A HREF="bison.html#IDX169">YYBACKUP</A>
+<LI><A HREF="bison.html#IDX181">yychar</A>
+<LI><A HREF="bison.html#IDX218">yyclearin</A>
+<LI><A HREF="bison.html#IDX234">yydebug</A>
+<LI><A HREF="bison.html#IDX237">YYDEBUG</A>
+<LI><A HREF="bison.html#IDX170">YYEMPTY</A>
+<LI><A HREF="bison.html#IDX217">yyerrok</A>
+<LI><A HREF="bison.html#IDX162">yyerror</A>
+<LI><A HREF="bison.html#IDX171">YYERROR</A>
+<LI><A HREF="bison.html#IDX165">YYERROR_VERBOSE</A>
+<LI><A HREF="bison.html#IDX213">YYINITDEPTH</A>
+<LI><A HREF="bison.html#IDX154">yylex</A>
+<LI><A HREF="bison.html#IDX160">YYLEX_PARAM</A>
+<LI><A HREF="bison.html#IDX157">yylloc</A>
+<LI><A HREF="bison.html#IDX118">YYLLOC_DEFAULT</A>
+<LI><A HREF="bison.html#IDX158">YYLTYPE</A>
+<LI><A HREF="bison.html#IDX156">yylval</A>
+<LI><A HREF="bison.html#IDX211">YYMAXDEPTH</A>
+<LI><A HREF="bison.html#IDX166">yynerrs</A>
+<LI><A HREF="bison.html#IDX151">yyparse</A>
+<LI><A HREF="bison.html#IDX159">YYPARSE_PARAM</A>
+<LI><A HREF="bison.html#IDX239">YYPRINT</A>
+<LI><A HREF="bison.html#IDX219">YYRECOVERING</A>
 </DIR>
 <H2><A NAME="cindex_|">|</A></H2>
 <DIR>
-<LI><A HREF="bison.html#IDX77">|</A>
+<LI><A HREF="bison.html#IDX90">|</A>
 </DIR>
 
 
 <P><HR><P>
-This document was generated on 4 November 2001 using
+This document was generated on 9 November 2002 using
 <A HREF="http://wwwinfo.cern.ch/dis/texi2html/">texi2html</A>&nbsp;1.56k.
 </BODY>
 </HTML>


ossp-adm/autotools/bison_toc.html -> 1.1

*** /dev/null    Sat Nov 23 06:11:26 2024
--- -    Sat Nov 23 06:11:29 2024
***************
*** 0 ****
--- 1,175 ----
+ <HTML>
+ <HEAD>
+ <!-- Created by texi2html 1.56k from bison.texinfo on 9 November 2002 -->
+ 
+ <TITLE>Bison 1.75 - Table of Contents</TITLE>
+ </HEAD>
+ <BODY>
+ <H1>Bison</H1>
+ <H2>The YACC-compatible Parser Generator</H2>
+ <H2>14 October 2002, Bison Version 1.75</H2>
+ <ADDRESS>by Charles Donnelly and Richard Stallman</ADDRESS>
+ <P>
+ <P><HR><P>
+ <UL>
+ <LI><A NAME="TOC1" HREF="bison.html#SEC1">Introduction</A>
+ <LI><A NAME="TOC2" HREF="bison.html#SEC2">Conditions for Using Bison</A>
+ <LI><A NAME="TOC3" HREF="bison.html#SEC3">GNU GENERAL PUBLIC LICENSE</A>
+ <UL>
+ <LI><A NAME="TOC4" HREF="bison.html#SEC4">Preamble</A>
+ <LI><A NAME="TOC5" HREF="bison.html#SEC5">TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION</A>
+ <LI><A NAME="TOC6" HREF="bison.html#SEC6">Appendix: How to Apply These Terms to Your New Programs</A>
+ </UL>
+ <LI><A NAME="TOC7" HREF="bison.html#SEC7">The Concepts of Bison</A>
+ <UL>
+ <LI><A NAME="TOC8" HREF="bison.html#SEC8">Languages and Context-Free Grammars</A>
+ <LI><A NAME="TOC9" HREF="bison.html#SEC9">From Formal Rules to Bison Input</A>
+ <LI><A NAME="TOC10" HREF="bison.html#SEC10">Semantic Values</A>
+ <LI><A NAME="TOC11" HREF="bison.html#SEC11">Semantic Actions</A>
+ <LI><A NAME="TOC12" HREF="bison.html#SEC12">Writing GLR Parsers</A>
+ <LI><A NAME="TOC13" HREF="bison.html#SEC13">Locations</A>
+ <LI><A NAME="TOC14" HREF="bison.html#SEC14">Bison Output: the Parser File</A>
+ <LI><A NAME="TOC15" HREF="bison.html#SEC15">Stages in Using Bison</A>
+ <LI><A NAME="TOC16" HREF="bison.html#SEC16">The Overall Layout of a Bison Grammar</A>
+ </UL>
+ <LI><A NAME="TOC17" HREF="bison.html#SEC17">Examples</A>
+ <UL>
+ <LI><A NAME="TOC18" HREF="bison.html#SEC18">Reverse Polish Notation Calculator</A>
+ <UL>
+ <LI><A NAME="TOC19" HREF="bison.html#SEC19">Declarations for <CODE>rpcalc</CODE></A>
+ <LI><A NAME="TOC20" HREF="bison.html#SEC20">Grammar Rules for <CODE>rpcalc</CODE></A>
+ <UL>
+ <LI><A NAME="TOC21" HREF="bison.html#SEC21">Explanation of <CODE>input</CODE></A>
+ <LI><A NAME="TOC22" HREF="bison.html#SEC22">Explanation of <CODE>line</CODE></A>
+ <LI><A NAME="TOC23" HREF="bison.html#SEC23">Explanation of <CODE>expr</CODE></A>
+ </UL>
+ <LI><A NAME="TOC24" HREF="bison.html#SEC24">The <CODE>rpcalc</CODE> Lexical Analyzer</A>
+ <LI><A NAME="TOC25" HREF="bison.html#SEC25">The Controlling Function</A>
+ <LI><A NAME="TOC26" HREF="bison.html#SEC26">The Error Reporting Routine</A>
+ <LI><A NAME="TOC27" HREF="bison.html#SEC27">Running Bison to Make the Parser</A>
+ <LI><A NAME="TOC28" HREF="bison.html#SEC28">Compiling the Parser File</A>
+ </UL>
+ <LI><A NAME="TOC29" HREF="bison.html#SEC29">Infix Notation Calculator: <CODE>calc</CODE></A>
+ <LI><A NAME="TOC30" HREF="bison.html#SEC30">Simple Error Recovery</A>
+ <LI><A NAME="TOC31" HREF="bison.html#SEC31">Location Tracking Calculator: <CODE>ltcalc</CODE></A>
+ <UL>
+ <LI><A NAME="TOC32" HREF="bison.html#SEC32">Declarations for <CODE>ltcalc</CODE></A>
+ <LI><A NAME="TOC33" HREF="bison.html#SEC33">Grammar Rules for <CODE>ltcalc</CODE></A>
+ <LI><A NAME="TOC34" HREF="bison.html#SEC34">The <CODE>ltcalc</CODE> Lexical Analyzer.</A>
+ </UL>
+ <LI><A NAME="TOC35" HREF="bison.html#SEC35">Multi-Function Calculator: <CODE>mfcalc</CODE></A>
+ <UL>
+ <LI><A NAME="TOC36" HREF="bison.html#SEC36">Declarations for <CODE>mfcalc</CODE></A>
+ <LI><A NAME="TOC37" HREF="bison.html#SEC37">Grammar Rules for <CODE>mfcalc</CODE></A>
+ <LI><A NAME="TOC38" HREF="bison.html#SEC38">The <CODE>mfcalc</CODE> Symbol Table</A>
+ </UL>
+ <LI><A NAME="TOC39" HREF="bison.html#SEC39">Exercises</A>
+ </UL>
+ <LI><A NAME="TOC40" HREF="bison.html#SEC40">Bison Grammar Files</A>
+ <UL>
+ <LI><A NAME="TOC41" HREF="bison.html#SEC41">Outline of a Bison Grammar</A>
+ <UL>
+ <LI><A NAME="TOC42" HREF="bison.html#SEC42">The prologue</A>
+ <LI><A NAME="TOC43" HREF="bison.html#SEC43">The Bison Declarations Section</A>
+ <LI><A NAME="TOC44" HREF="bison.html#SEC44">The Grammar Rules Section</A>
+ <LI><A NAME="TOC45" HREF="bison.html#SEC45">The epilogue</A>
+ </UL>
+ <LI><A NAME="TOC46" HREF="bison.html#SEC46">Symbols, Terminal and Nonterminal</A>
+ <LI><A NAME="TOC47" HREF="bison.html#SEC47">Syntax of Grammar Rules</A>
+ <LI><A NAME="TOC48" HREF="bison.html#SEC48">Recursive Rules</A>
+ <LI><A NAME="TOC49" HREF="bison.html#SEC49">Defining Language Semantics</A>
+ <UL>
+ <LI><A NAME="TOC50" HREF="bison.html#SEC50">Data Types of Semantic Values</A>
+ <LI><A NAME="TOC51" HREF="bison.html#SEC51">More Than One Value Type</A>
+ <LI><A NAME="TOC52" HREF="bison.html#SEC52">Actions</A>
+ <LI><A NAME="TOC53" HREF="bison.html#SEC53">Data Types of Values in Actions</A>
+ <LI><A NAME="TOC54" HREF="bison.html#SEC54">Actions in Mid-Rule</A>
+ </UL>
+ <LI><A NAME="TOC55" HREF="bison.html#SEC55">Tracking Locations</A>
+ <UL>
+ <LI><A NAME="TOC56" HREF="bison.html#SEC56">Data Type of Locations</A>
+ <LI><A NAME="TOC57" HREF="bison.html#SEC57">Actions and Locations</A>
+ <LI><A NAME="TOC58" HREF="bison.html#SEC58">Default Action for Locations</A>
+ </UL>
+ <LI><A NAME="TOC59" HREF="bison.html#SEC59">Bison Declarations</A>
+ <UL>
+ <LI><A NAME="TOC60" HREF="bison.html#SEC60">Token Type Names</A>
+ <LI><A NAME="TOC61" HREF="bison.html#SEC61">Operator Precedence</A>
+ <LI><A NAME="TOC62" HREF="bison.html#SEC62">The Collection of Value Types</A>
+ <LI><A NAME="TOC63" HREF="bison.html#SEC63">Nonterminal Symbols</A>
+ <LI><A NAME="TOC64" HREF="bison.html#SEC64">Suppressing Conflict Warnings</A>
+ <LI><A NAME="TOC65" HREF="bison.html#SEC65">The Start-Symbol</A>
+ <LI><A NAME="TOC66" HREF="bison.html#SEC66">A Pure (Reentrant) Parser</A>
+ <LI><A NAME="TOC67" HREF="bison.html#SEC67">Bison Declaration Summary</A>
+ </UL>
+ <LI><A NAME="TOC68" HREF="bison.html#SEC68">Multiple Parsers in the Same Program</A>
+ </UL>
+ <LI><A NAME="TOC69" HREF="bison.html#SEC69">Parser C-Language Interface</A>
+ <UL>
+ <LI><A NAME="TOC70" HREF="bison.html#SEC70">The Parser Function <CODE>yyparse</CODE></A>
+ <LI><A NAME="TOC71" HREF="bison.html#SEC71">The Lexical Analyzer Function <CODE>yylex</CODE></A>
+ <UL>
+ <LI><A NAME="TOC72" HREF="bison.html#SEC72">Calling Convention for <CODE>yylex</CODE></A>
+ <LI><A NAME="TOC73" HREF="bison.html#SEC73">Semantic Values of Tokens</A>
+ <LI><A NAME="TOC74" HREF="bison.html#SEC74">Textual Positions of Tokens</A>
+ <LI><A NAME="TOC75" HREF="bison.html#SEC75">Calling Conventions for Pure Parsers</A>
+ </UL>
+ <LI><A NAME="TOC76" HREF="bison.html#SEC76">The Error Reporting Function <CODE>yyerror</CODE></A>
+ <LI><A NAME="TOC77" HREF="bison.html#SEC77">Special Features for Use in Actions</A>
+ </UL>
+ <LI><A NAME="TOC78" HREF="bison.html#SEC78">The Bison Parser Algorithm</A>
+ <UL>
+ <LI><A NAME="TOC79" HREF="bison.html#SEC79">Look-Ahead Tokens</A>
+ <LI><A NAME="TOC80" HREF="bison.html#SEC80">Shift/Reduce Conflicts</A>
+ <LI><A NAME="TOC81" HREF="bison.html#SEC81">Operator Precedence</A>
+ <UL>
+ <LI><A NAME="TOC82" HREF="bison.html#SEC82">When Precedence is Needed</A>
+ <LI><A NAME="TOC83" HREF="bison.html#SEC83">Specifying Operator Precedence</A>
+ <LI><A NAME="TOC84" HREF="bison.html#SEC84">Precedence Examples</A>
+ <LI><A NAME="TOC85" HREF="bison.html#SEC85">How Precedence Works</A>
+ </UL>
+ <LI><A NAME="TOC86" HREF="bison.html#SEC86">Context-Dependent Precedence</A>
+ <LI><A NAME="TOC87" HREF="bison.html#SEC87">Parser States</A>
+ <LI><A NAME="TOC88" HREF="bison.html#SEC88">Reduce/Reduce Conflicts</A>
+ <LI><A NAME="TOC89" HREF="bison.html#SEC89">Mysterious Reduce/Reduce Conflicts</A>
+ <LI><A NAME="TOC90" HREF="bison.html#SEC90">Generalized LR (GLR) Parsing</A>
+ <LI><A NAME="TOC91" HREF="bison.html#SEC91">Stack Overflow, and How to Avoid It</A>
+ </UL>
+ <LI><A NAME="TOC92" HREF="bison.html#SEC92">Error Recovery</A>
+ <LI><A NAME="TOC93" HREF="bison.html#SEC93">Handling Context Dependencies</A>
+ <UL>
+ <LI><A NAME="TOC94" HREF="bison.html#SEC94">Semantic Info in Token Types</A>
+ <LI><A NAME="TOC95" HREF="bison.html#SEC95">Lexical Tie-ins</A>
+ <LI><A NAME="TOC96" HREF="bison.html#SEC96">Lexical Tie-ins and Error Recovery</A>
+ </UL>
+ <LI><A NAME="TOC97" HREF="bison.html#SEC97">Debugging Your Parser</A>
+ <UL>
+ <LI><A NAME="TOC98" HREF="bison.html#SEC98">Understanding Your Parser</A>
+ <LI><A NAME="TOC99" HREF="bison.html#SEC99">Tracing Your Parser</A>
+ </UL>
+ <LI><A NAME="TOC100" HREF="bison.html#SEC100">Invoking Bison</A>
+ <UL>
+ <LI><A NAME="TOC101" HREF="bison.html#SEC101">Bison Options</A>
+ <LI><A NAME="TOC102" HREF="bison.html#SEC102">Option Cross Key</A>
+ <LI><A NAME="TOC103" HREF="bison.html#SEC103">Invoking Bison under VMS</A>
+ </UL>
+ <LI><A NAME="TOC104" HREF="bison.html#SEC104">Frequently Asked Questions</A>
+ <UL>
+ <LI><A NAME="TOC105" HREF="bison.html#SEC105">Parser Stack Overflow</A>
+ </UL>
+ <LI><A NAME="TOC106" HREF="bison.html#SEC106">Bison Symbols</A>
+ <LI><A NAME="TOC107" HREF="bison.html#SEC107">Glossary</A>
+ <LI><A NAME="TOC108" HREF="bison.html#SEC108">Copying This Manual</A>
+ <UL>
+ <LI><A NAME="TOC109" HREF="bison.html#SEC109">GNU Free Documentation License</A>
+ <UL>
+ <LI><A NAME="TOC110" HREF="bison.html#SEC110">ADDENDUM: How to use this License for your documents</A>
+ </UL>
+ </UL>
+ <LI><A NAME="TOC111" HREF="bison.html#SEC111">Index</A>
+ </UL>
+ <P><HR><P>
+ This document was generated on 9 November 2002 using
+ <A HREF="http://wwwinfo.cern.ch/dis/texi2html/">texi2html</A>&nbsp;1.56k.
+ </BODY>
+ </HTML>


ossp-adm/autotools/flex.html 1.1 -> 1.2

--- flex.html    2002/07/10 08:46:25     1.1
+++ flex.html    2002/11/09 14:28:38     1.2
@@ -1,76 +1,147 @@
 <HTML>
 <HEAD>
-<!-- Created by texi2html 1.56k from flex.texi on 2 July 2002 -->
+<!-- Created by texi2html 1.56k from flex.texi on 9 November 2002 -->
 
-<TITLE>The Flex Manual</TITLE>
+<TITLE>flex: a fast lexical analyzer generator</TITLE>
 </HEAD>
 <BODY>
-<H1>The Flex Manual</H1>
+<H1>Flex, version 2.5.23</H1>
+<H2>A fast scanner generator</H2>
+<H2>Edition 2.5.23, 21 October 2002</H2>
+<ADDRESS>Vern Paxson</ADDRESS>
+<ADDRESS>W. L. Estes</ADDRESS>
+<ADDRESS>John Millaway</ADDRESS>
 <P>
 <P><HR><P>
 
 
-<H1><A NAME="SEC1" HREF="flex_toc.html#TOC1">Introduction</A></H1>
+<H1><A NAME="SEC1" HREF="flex_toc.html#TOC1">Copyright</A></H1>
 
 <P>
 <A NAME="IDX1"></A>
-<CODE>flex</CODE>
-is a tool for generating
-<EM>scanners</EM>.
-A scanner is a program which recognizes lexical patterns in text.
-The
-<CODE>flex</CODE>
-program
-reads
-the given input files, or its standard input if no file names are given,
-for a description of a scanner to generate.  The description is in
-the form of pairs
-of regular expressions and C code, called
-<EM>rules</EM>. <CODE>flex</CODE>
-generates as output a C source file,
-<TT>`lex.yy.c'</TT> by default,
-which defines a routine
-<B>yylex()</B>.
-This file is compiled and linked with the
-flex runtime library
-library to produce an executable.  When the executable is run,
-it analyzes its input for occurrences
-of the regular expressions.  Whenever it finds one, it executes
-the corresponding C code.
+<A NAME="IDX2"></A>
+
+
+<P>
+The flex manual is placed under the same licensing conditions as the
+rest of flex:
+
+
+<P>
+Copyright (C) 1990, 1997 The Regents of the University of California.
+All rights reserved.
+
+
+<P>
+This code is derived from software contributed to Berkeley by
+Vern Paxson.
+
+
+<P>
+The United States Government has rights in this work pursuant
+to contract no. DE-AC03-76SF00098 between the United States
+Department of Energy and the University of California.
+
+
+<P>
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions
+are met:
+
+
+
+<OL>
+<LI>
+
+ Redistributions of source code must retain the above copyright
+notice, this list of conditions and the following disclaimer.
+
+<LI>
+
+Redistributions in binary form must reproduce the above copyright
+notice, this list of conditions and the following disclaimer in the
+documentation and/or other materials provided with the distribution.
+</OL>
+
+<P>
+Neither the name of the University nor the names of its contributors
+may be used to endorse or promote products derived from this software
+without specific prior written permission.
+
+
+<P>
+THIS SOFTWARE IS PROVIDED "AS IS" AND WITHOUT ANY EXPRESS OR
+IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
+WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+PURPOSE.
+
+
+
 
+<H1><A NAME="SEC2" HREF="flex_toc.html#TOC2">Reporting Bugs</A></H1>
 
+<P>
+<A NAME="IDX3"></A>
+<A NAME="IDX4"></A>
+
+
+<P>
+If you have problems with <CODE>flex</CODE> or think you have found a bug,
+please send mail detailing your problem to
+<A HREF="mailto:help-flex@gnu.org">help-flex@gnu.org</A>. Patches are always welcome.
 
 
-<H1><A NAME="SEC2" HREF="flex_toc.html#TOC2">Some Simple Examples</A></H1>
+
+
+<H1><A NAME="SEC3" HREF="flex_toc.html#TOC3">Introduction</A></H1>
+
+<P>
+<A NAME="IDX5"></A>
+<CODE>flex</CODE> is a tool for generating <EM>scanners</EM>.  A scanner is a
+program which recognizes lexical patterns in text.  The <CODE>flex</CODE>
+program reads the given input files, or its standard input if no file
+names are given, for a description of a scanner to generate.  The
+description is in the form of pairs of regular expressions and C code,
+called <EM>rules</EM>. <CODE>flex</CODE> generates as output a C source file,
+<TT>`lex.yy.c'</TT> by default, which defines a routine <CODE>yylex()</CODE>.
+This file can be compiled and linked with the flex runtime library to
+produce an executable.  When the executable is run, it analyzes its
+input for occurrences of the regular expressions.  Whenever it finds
+one, it executes the corresponding C code.
+
+
+
+
+<H1><A NAME="SEC4" HREF="flex_toc.html#TOC4">Some Simple Examples</A></H1>
 
 <P>
 First some simple examples to get the flavor of how one uses
 <CODE>flex</CODE>.
-The following
-<CODE>flex</CODE>
-input specifies a scanner which whenever it encounters the string
-<SAMP>`username'</SAMP> will replace it with the user's login name:
 
 
 <P>
+<A NAME="IDX6"></A>
+The following <CODE>flex</CODE> input specifies a scanner which, when it
+encounters the string <SAMP>`username'</SAMP> will replace it with the user's
+login name:
+
+
+
+<PRE>
 @verbatim
     %%
     username    printf( "%s", getlogin() );
-
+</PRE>
 
 <P>
-<A NAME="IDX2"></A>
-By default, any text not matched by a
-<CODE>flex</CODE>
-scanner
-is copied to the output, so the net effect of this scanner is
-to copy its input file to its output with each occurrence
-of <SAMP>`username'</SAMP> expanded.
-In this input, there is just one rule.  <SAMP>`username'</SAMP> is the
-<EM>pattern</EM>
-and the <SAMP>`printf'</SAMP> is the
-<EM>action</EM>.
-The <SAMP>`%%'</SAMP> symbol marks the beginning of the rules.
+<A NAME="IDX7"></A>
+<A NAME="IDX8"></A>
+By default, any text not matched by a <CODE>flex</CODE> scanner is copied to
+the output, so the net effect of this scanner is to copy its input file
+to its output with each occurrence of <SAMP>`username'</SAMP> expanded.  In this
+input, there is just one rule.  <SAMP>`username'</SAMP> is the <EM>pattern</EM> and
+the <SAMP>`printf'</SAMP> is the <EM>action</EM>.  The <SAMP>`%%'</SAMP> symbol marks the
+beginning of the rules.
 
 
 <P>
@@ -78,7 +149,7 @@
 
 
 <P>
-<A NAME="IDX3"></A>
+<A NAME="IDX9"></A>
 
 <PRE>
 @verbatim
@@ -98,18 +169,15 @@
 </PRE>
 
 <P>
-This scanner counts the number of characters and the number
-of lines in its input (it produces no output other than the
-final report on the counts).  The first line
-declares two globals, <CODE>num_lines</CODE> and <CODE>num_chars</CODE>, which are accessible
-both inside
-<CODE>yylex()</CODE>
-and in the
-<CODE>main()</CODE>
-routine declared after the second <SAMP>`%%'</SAMP>.  There are two rules, one
-which matches a newline (<SAMP>`\n'</SAMP>) and increments both the line count and
-the character count, and one which matches any character other than
-a newline (indicated by the <SAMP>`.'</SAMP> regular expression).
+This scanner counts the number of characters and the number of lines in
+its input. It produces no output other than the final report on the
+character and line counts.  The first line declares two globals,
+<CODE>num_lines</CODE> and <CODE>num_chars</CODE>, which are accessible both inside
+<CODE>yylex()</CODE> and in the <CODE>main()</CODE> routine declared after the
+second <SAMP>`%%'</SAMP>.  There are two rules, one which matches a newline
+(<SAMP>`\n'</SAMP>) and increments both the line count and the character count,
+and one which matches any character other than a newline (indicated by
+the <SAMP>`.'</SAMP> regular expression).
 
 
 <P>
@@ -117,7 +185,7 @@
 
 
 <P>
-<A NAME="IDX4"></A>
+<A NAME="IDX10"></A>
 
 <PRE>
 @verbatim
@@ -168,16 +236,15 @@
                 yyin = fopen( argv[0], "r" );
         else
                 yyin = stdin;
-        
+
         yylex();
         }
 </PRE>
 
 <P>
-This is the beginnings of a simple scanner for a language like
-Pascal.  It identifies different types of
-<EM>tokens</EM>
-and reports on what it has seen.
+This is the beginnings of a simple scanner for a language like Pascal.
+It identifies different types of <EM>tokens</EM> and reports on what it has
+seen.
 
 
 <P>
@@ -187,24 +254,22 @@
 
 
 
-<H1><A NAME="SEC3" HREF="flex_toc.html#TOC3">Format of the Input File</A></H1>
+<H1><A NAME="SEC5" HREF="flex_toc.html#TOC5">Format of the Input File</A></H1>
 
 <P>
-<A NAME="IDX5"></A>
-<A NAME="IDX6"></A>
-<A NAME="IDX7"></A>
+<A NAME="IDX11"></A>
+<A NAME="IDX12"></A>
+<A NAME="IDX13"></A>
+<A NAME="IDX14"></A>
 
 
 <P>
-The
-<CODE>flex</CODE>
-input file consists of three sections, separated by a line with just
-<SAMP>`%%'</SAMP>
-in it:
+The <CODE>flex</CODE> input file consists of three sections, separated by a
+line containing only <SAMP>`%%'</SAMP>.
 
 
 <P>
-<A NAME="IDX8"></A>
+<A NAME="IDX15"></A>
 
 <PRE>
 @verbatim
@@ -217,25 +282,19 @@
 
 
 
-<H2><A NAME="SEC4" HREF="flex_toc.html#TOC4">Format of the Definitions Section</A></H2>
-<P>
-<A NAME="IDX9"></A>
-<A NAME="IDX10"></A>
-<A NAME="IDX11"></A>
-
+<H2><A NAME="SEC6" HREF="flex_toc.html#TOC6">Format of the Definitions Section</A></H2>
 
 <P>
-The
-<I>definitions</I>
-section contains declarations of simple
-<I>name</I>
+<A NAME="IDX16"></A>
+<A NAME="IDX17"></A>
+The <EM>definitions section</EM> contains declarations of simple <EM>name</EM>
 definitions to simplify the scanner specification, and declarations of
-<I>start conditions</I>,
-which are explained in a later section.
+<EM>start conditions</EM>, which are explained in a later section.
 
 
 <P>
-<A NAME="IDX12"></A>
+<A NAME="IDX18"></A>
+<A NAME="IDX19"></A>
 Name definitions have the form:
 
 
@@ -246,16 +305,17 @@
 </PRE>
 
 <P>
-The <SAMP>`name'</SAMP> is a word beginning with a letter or an underscore (<SAMP>`_'</SAMP>)
-followed by zero or more letters, digits, <SAMP>`_'</SAMP>, or <SAMP>`-'</SAMP> (dash).
-The definition is taken to begin at the first non-whitespace character
-following the name and continuing to the end of the line.
-The definition can subsequently be referred to using <SAMP>`{name}'</SAMP>, which
-will expand to <SAMP>`(definition)'</SAMP>.  For example,
+The <SAMP>`name'</SAMP> is a word beginning with a letter or an underscore
+(<SAMP>`_'</SAMP>) followed by zero or more letters, digits, <SAMP>`_'</SAMP>, or
+<SAMP>`-'</SAMP> (dash).  The definition is taken to begin at the first
+non-whitespace character following the name and continuing to the end of
+the line.  The definition can subsequently be referred to using
+<SAMP>`{name}'</SAMP>, which will expand to <SAMP>`(definition)'</SAMP>.  For example,
 
 
 <P>
-<A NAME="IDX13"></A>
+<A NAME="IDX20"></A>
+<A NAME="IDX21"></A>
 
 <PRE>
 @verbatim
@@ -264,15 +324,13 @@
 </PRE>
 
 <P>
-Defines <SAMP>`DIGIT'</SAMP> to be a regular expression which matches a
-single digit, and
-<SAMP>`ID'</SAMP> to be a regular expression which matches a letter
-followed by zero-or-more letters-or-digits.
-A subsequent reference to
+Defines <SAMP>`DIGIT'</SAMP> to be a regular expression which matches a single
+digit, and <SAMP>`ID'</SAMP> to be a regular expression which matches a letter
+followed by zero-or-more letters-or-digits.  A subsequent reference to
 
 
 <P>
-<A NAME="IDX14"></A>
+<A NAME="IDX22"></A>
 
 <PRE>
 @verbatim
@@ -290,46 +348,36 @@
 </PRE>
 
 <P>
-and matches one-or-more digits followed by a '.' followed
-by zero-or-more digits.
+and matches one-or-more digits followed by a <SAMP>`.'</SAMP> followed by
+zero-or-more digits.
 
 
 <P>
+<A NAME="IDX23"></A>
 An unindented comment (i.e., a line
 beginning with <SAMP>`/*'</SAMP>) is copied verbatim to the output up
 to the next <SAMP>`*/'</SAMP>.
 
 
 <P>
-<A NAME="IDX15"></A>
-<A NAME="IDX16"></A>
-<A NAME="IDX17"></A>
- 
-Any
-<EM>indented</EM>
-text or text enclosed in
-<SAMP>`%{'</SAMP>
-and
-<SAMP>`%}'</SAMP>
-is also copied verbatim to the output (with the %{ and %} symbols removed).
-The %{ and %} symbols must appear unindented on lines by themselves.
-
+<A NAME="IDX24"></A>
+<A NAME="IDX25"></A>
+<A NAME="IDX26"></A>
+Any <EM>indented</EM> text or text enclosed in <SAMP>`%{'</SAMP> and <SAMP>`%}'</SAMP>
+is also copied verbatim to the output (with the %{ and %} symbols
+removed).  The %{ and %} symbols must appear unindented on lines by
+themselves.
 
 
 
-<H2><A NAME="SEC5" HREF="flex_toc.html#TOC5">Format of the Rules Section</A></H2>
-<P>
-<A NAME="IDX18"></A>
-<A NAME="IDX19"></A>
-<A NAME="IDX20"></A>
 
+<H2><A NAME="SEC7" HREF="flex_toc.html#TOC7">Format of the Rules Section</A></H2>
 
 <P>
-The
-<I>rules</I>
-section of the
-<CODE>flex</CODE>
-input contains a series of rules of the form:
+<A NAME="IDX27"></A>
+<A NAME="IDX28"></A>
+The <EM>rules</EM> section of the <CODE>flex</CODE> input contains a series of
+rules of the form:
 
 
 
@@ -341,93 +389,78 @@
 <P>
 where the pattern must be unindented and the action must begin
 on the same line.
+See section <A HREF="flex.html#SEC10">Patterns</A>, for a further description of patterns and actions.
 
 
 <P>
-See section <A HREF="flex.html#SEC8">Patterns</A>, for a further description of patterns and actions.
+In the rules section, any indented or %{ %} enclosed text appearing
+before the first rule may be used to declare variables which are local
+to the scanning routine and (after the declarations) code which is to be
+executed whenever the scanning routine is entered.  Other indented or
+%{ %} text in the rule section is still copied to the output, but its
+meaning is not well-defined and it may well cause compile-time errors
+(this feature is present for @acronym{POSIX} compliance. See section <A HREF="flex.html#SEC42">Incompatibilities with Lex and Posix</A>, for other such features).
 
 
 <P>
-In the rules section,
-any indented or %{ %} enclosed text appearing before the
-first rule may be used to declare variables
-which are local to the scanning routine and (after the declarations)
-code which is to be executed whenever the scanning routine is entered.
-Other indented or %{ %} text in the rule section is still copied to the output,
-but its meaning is not well-defined and it may well cause compile-time
-errors (this feature is present for
-<I>POSIX</I>
-compliance. See section <A HREF="flex.html#SEC36">Incompatibilities with Lex and Posix</A>, for other such features).
-
-
-<P>
-Any
-<EM>indented</EM>
-text or text enclosed in
-<SAMP>`%{'</SAMP>
-and
-<SAMP>`%}'</SAMP>
+Any <EM>indented</EM> text or text enclosed in <SAMP>`%{'</SAMP> and <SAMP>`%}'</SAMP>
 is copied verbatim to the output (with the %{ and %} symbols removed).
 The %{ and %} symbols must appear unindented on lines by themselves.
 
 
 
 
-<H2><A NAME="SEC6" HREF="flex_toc.html#TOC6">Format of the User Code Section</A></H2>
-<P>
-<A NAME="IDX21"></A>
-<A NAME="IDX22"></A>
-<A NAME="IDX23"></A>
-
+<H2><A NAME="SEC8" HREF="flex_toc.html#TOC8">Format of the User Code Section</A></H2>
 
 <P>
-The user code section is simply copied to
-<TT>`lex.yy.c'</TT>
-verbatim.
-It is used for companion routines which call or are called
-by the scanner.  The presence of this section is optional;
-if it is missing, the second
-<SAMP>`%%'</SAMP>
-in the input file may be skipped, too.
-
+<A NAME="IDX29"></A>
+<A NAME="IDX30"></A>
+The user code section is simply copied to <TT>`lex.yy.c'</TT> verbatim.  It
+is used for companion routines which call or are called by the scanner.
+The presence of this section is optional; if it is missing, the second
+<SAMP>`%%'</SAMP> in the input file may be skipped, too.
 
 
 
-<H2><A NAME="SEC7" HREF="flex_toc.html#TOC7">Comments in the Input</A></H2>
-<P>
-<A NAME="IDX24"></A>
 
+<H2><A NAME="SEC9" HREF="flex_toc.html#TOC9">Comments in the Input</A></H2>
 
 <P>
+<A NAME="IDX31"></A>
 Flex supports C-style comments, that is, anything between /* and */ is
-considered a comment. Whenever flex encounters a comment, it copies
-the entire comment verbatim to the generated source code. Comments
-may appear just about anywhere, but with the following exceptions:
+considered a comment. Whenever flex encounters a comment, it copies the
+entire comment verbatim to the generated source code. Comments may
+appear just about anywhere, but with the following exceptions:
 
 
 
 <UL>
-<LI>Comments may not appear in the Rules Section wherever flex is expecting
+<LI>
 
-a regular expression. This means comments may not appear at the beginning of
-a line, or immediately following a list of scanner states.
-<LI>Comments may not appear on an <SAMP>`%option'</SAMP> line in the Definitions Section.
+<A NAME="IDX32"></A>
+ 
+Comments may not appear in the Rules Section wherever flex is expecting
+a regular expression. This means comments may not appear at the
+beginning of a line, or immediately following a list of scanner states.
+<LI>
 
+Comments may not appear on an <SAMP>`%option'</SAMP> line in the Definitions
+Section.
 </UL>
 
 <P>
-If you want to follow a simple rule, then always begin a comment on a new line,
-with one or more whitespace characters before the initial <SAMP>`/*'</SAMP>).
-This rule will work anywhere in the input file.
+If you want to follow a simple rule, then always begin a comment on a
+new line, with one or more whitespace characters before the initial
+<SAMP>`/*'</SAMP>).  This rule will work anywhere in the input file.
 
 
 <P>
-All the comments in the following example are OK:
+All the comments in the following example are valid:
 
 
 <P>
-<A NAME="IDX25"></A>
-<A NAME="IDX26"></A>
+<A NAME="IDX33"></A>
+<A NAME="IDX34"></A>
 
 <PRE>
 @verbatim
@@ -456,19 +489,18 @@
 
 
 
-<H1><A NAME="SEC8" HREF="flex_toc.html#TOC8">Patterns</A></H1>
-<P>
-<A NAME="IDX27"></A>
-
+<H1><A NAME="SEC10" HREF="flex_toc.html#TOC10">Patterns</A></H1>
 
 <P>
-The patterns in the input are written using an extended set of regular
-expressions.  These are:
+<A NAME="IDX35"></A>
+<A NAME="IDX36"></A>
+The patterns in the input (see section <A HREF="flex.html#SEC7">Format of the Rules Section</A>) are written using an
+extended set of regular expressions.  These are:
 
 
 <P>
-<A NAME="IDX28"></A>
-<A NAME="IDX29"></A>
+<A NAME="IDX37"></A>
+<A NAME="IDX38"></A>
 <DL COMPACT>
 
 <DT><SAMP>`x'</SAMP>
@@ -479,23 +511,23 @@
 <DD>
 any character (byte) except newline
 
-<A NAME="IDX30"></A>
-<A NAME="IDX31"></A>
+<A NAME="IDX39"></A>
+<A NAME="IDX40"></A>
+<A NAME="IDX41"></A>
 <DT><SAMP>`[xyz]'</SAMP>
 <DD>
 a <EM>character class</EM>; in this case, the pattern
 matches either an 'x', a 'y', or a 'z'
 
-<A NAME="IDX32"></A>
-<A NAME="IDX33"></A>
+<A NAME="IDX42"></A>
 <DT><SAMP>`[abj-oZ]'</SAMP>
 <DD>
 a "character class" with a range in it; matches
 an 'a', a 'b', any letter from 'j' through 'o',
 or a 'Z'
 
-<A NAME="IDX34"></A>
-<A NAME="IDX35"></A>
+<A NAME="IDX43"></A>
+<A NAME="IDX44"></A>
 <DT><SAMP>`[^A-Z]'</SAMP>
 <DD>
 a "negated character class", i.e., any character
@@ -519,6 +551,7 @@
 <DD>
 zero or one r's (that is, "an optional r")
 
+<A NAME="IDX45"></A>
 <DT><SAMP>`r{2,5}'</SAMP>
 <DD>
 anywhere from two to five r's
@@ -531,31 +564,31 @@
 <DD>
 exactly 4 r's
 
-<A NAME="IDX36"></A>
+<A NAME="IDX46"></A>
 <DT><SAMP>`{name}'</SAMP>
 <DD>
 the expansion of the <SAMP>`name'</SAMP> definition
-(see section <A HREF="flex.html#SEC3">Format of the Input File</A>).
+(see section <A HREF="flex.html#SEC5">Format of the Input File</A>).
 
-<A NAME="IDX37"></A>
-<A NAME="IDX38"></A>
+<A NAME="IDX47"></A>
+<A NAME="IDX48"></A>
 <DT><SAMP>`"[xyz]\"foo"'</SAMP>
 <DD>
 the literal string: <SAMP>`[xyz]"foo'</SAMP>
 
-<A NAME="IDX39"></A>
+<A NAME="IDX49"></A>
 <DT><SAMP>`\X'</SAMP>
 <DD>
-if X is <SAMP>`a'</SAMP>, <SAMP>`b'</SAMP>, <SAMP>`f'</SAMP>, <SAMP>`n'</SAMP>, <SAMP>`r'</SAMP>, <SAMP>`t'</SAMP>, or <SAMP>`v'</SAMP>,
-then the ANSI-C interpretation of <SAMP>`\x'</SAMP>.
-Otherwise, a literal <SAMP>`X'</SAMP> (used to escape
-operators such as <SAMP>`*'</SAMP>)
+if X is <SAMP>`a'</SAMP>, <SAMP>`b'</SAMP>, <SAMP>`f'</SAMP>, <SAMP>`n'</SAMP>, <SAMP>`r'</SAMP>, <SAMP>`t'</SAMP>, or
+<SAMP>`v'</SAMP>, then the ANSI-C interpretation of <SAMP>`\x'</SAMP>.  Otherwise, a
+literal <SAMP>`X'</SAMP> (used to escape operators such as <SAMP>`*'</SAMP>)
 
-<A NAME="IDX40"></A>
+<A NAME="IDX50"></A>
 <DT><SAMP>`\0'</SAMP>
 <DD>
 a NUL character (ASCII code 0)
 
+<A NAME="IDX51"></A>
 <DT><SAMP>`\123'</SAMP>
 <DD>
 the character with octal value 123
@@ -566,75 +599,73 @@
 
 <DT><SAMP>`(r)'</SAMP>
 <DD>
-match an r; parentheses are used to override
-                 precedence (see below)
+match an <SAMP>`r'</SAMP>; parentheses are used to override precedence (see below)
 
+<A NAME="IDX52"></A>
 <DT><SAMP>`rs'</SAMP>
 <DD>
-the regular expression r followed by the
-regular expression s; called <EM>concatenation</EM>
+the regular expression <SAMP>`r'</SAMP> followed by the regular expression <SAMP>`s'</SAMP>; called
+<EM>concatenation</EM>
 
 <DT><SAMP>`r|s'</SAMP>
 <DD>
-either an r or an s
+either an <SAMP>`r'</SAMP> or an <SAMP>`s'</SAMP>
 
-<A NAME="IDX41"></A>
+<A NAME="IDX53"></A>
 <DT><SAMP>`r/s'</SAMP>
 <DD>
-an r but only if it is followed by an s.  The
-text matched by s is included when determining
-whether this rule is the longest match,
-but is then returned to the input before
-the action is executed.  So the action only
-sees the text matched by r.  This type
-of pattern is called <EM>trailing context</EM>.
-(There are some combinations of r/s that flex
-cannot match correctly. See section <A HREF="flex.html#SEC38">Limitations</A>,
-regarding
-dangerous trailing context.)
+an <SAMP>`r'</SAMP> but only if it is followed by an <SAMP>`s'</SAMP>.  The text matched by <SAMP>`s'</SAMP> is
+included when determining whether this rule is the longest match, but is
+then returned to the input before the action is executed.  So the action
+only sees the text matched by <SAMP>`r'</SAMP>.  This type of pattern is called
+<EM>trailing context</EM>.  (There are some combinations of <SAMP>`r/s'</SAMP> that flex
+cannot match correctly. See section <A HREF="flex.html#SEC52">Limitations</A>, regarding dangerous trailing
+context.)
 
-<A NAME="IDX42"></A>
+<A NAME="IDX54"></A>
+<A NAME="IDX55"></A>
 <DT><SAMP>`^r'</SAMP>
 <DD>
-an r, but only at the beginning of a line (i.e.,
+an <SAMP>`r'</SAMP>, but only at the beginning of a line (i.e.,
 when just starting to scan, or right after a
 newline has been scanned).
 
-<A NAME="IDX43"></A>
+<A NAME="IDX56"></A>
+<A NAME="IDX57"></A>
 <DT><SAMP>`r$'</SAMP>
 <DD>
-an r, but only at the end of a line (i.e., just
-before a newline).  Equivalent to <SAMP>`r/\n'</SAMP>.
+an <SAMP>`r'</SAMP>, but only at the end of a line (i.e., just before a
+newline).  Equivalent to <SAMP>`r/\n'</SAMP>.
 
+<A NAME="IDX58"></A>
 Note that <CODE>flex</CODE>'s notion of "newline" is exactly
 whatever the C compiler used to compile <CODE>flex</CODE>
 interprets <SAMP>`\n'</SAMP> as; in particular, on some DOS
 systems you must either filter out <SAMP>`\r'</SAMP>s in the
 input yourself, or explicitly use <SAMP>`r/\r\n'</SAMP> for <SAMP>`r$'</SAMP>.
 
-<A NAME="IDX44"></A>
+<A NAME="IDX59"></A>
 <DT><SAMP>`&#60;s&#62;r'</SAMP>
 <DD>
-an r, but only in start condition s (see
-section <A HREF="flex.html#SEC12">Start Conditions</A> for discussion of start conditions).
+an <SAMP>`r'</SAMP>, but only in start condition <CODE>s</CODE> (see section <A HREF="flex.html#SEC14">Start Conditions</A> for discussion of start conditions).
 
 <DT><SAMP>`&#60;s1,s2,s3&#62;r'</SAMP>
 <DD>
-same, but in any of start conditions s1,
-s2, or s3.
+same, but in any of start conditions <CODE>s1</CODE>, <CODE>s2</CODE>, or <CODE>s3</CODE>.
 
 <DT><SAMP>`&#60;*&#62;r'</SAMP>
 <DD>
-an r in any start condition, even an exclusive one.
+an <SAMP>`r'</SAMP> in any start condition, even an exclusive one.
 
-<A NAME="IDX45"></A>
+<A NAME="IDX60"></A>
+<A NAME="IDX61"></A>
 <DT><SAMP>`&#60;&#60;EOF&#62;&#62;'</SAMP>
 <DD>
 an end-of-file.
 
 <DT><SAMP>`&#60;s1,s2&#62;&#60;&#60;EOF&#62;&#62;'</SAMP>
 <DD>
-an end-of-file when in start condition s1 or s2
+an end-of-file when in start condition <CODE>s1</CODE> or <CODE>s2</CODE>
 </DL>
 
 <P>
@@ -644,7 +675,7 @@
 
 
 <P>
-<A NAME="IDX46"></A>
+<A NAME="IDX62"></A>
 The regular expressions listed above are grouped according to
 precedence, from highest precedence at the top to lowest at the bottom.
 Those grouped together have equal precedence (see special note on the
@@ -653,7 +684,7 @@
 
 
 <P>
-<A NAME="IDX47"></A>
+<A NAME="IDX63"></A>
 
 <PRE>
 @verbatim
@@ -671,11 +702,11 @@
 </PRE>
 
 <P>
-since the '*' operator has higher precedence than concatenation, and
-concatenation higher than alternation ('|').  This pattern therefore
-matches <EM>either</EM> the string <SAMP>`foo'</SAMP> <EM>or</EM> the string
-<SAMP>`ba'</SAMP> followed by zero-or-more r's.  To match <SAMP>`foo'</SAMP> or
-zero-or-more repetitions of the string <SAMP>`bar'</SAMP>, use:
+since the <SAMP>`*'</SAMP> operator has higher precedence than concatenation,
+and concatenation higher than alternation (<SAMP>`|'</SAMP>).  This pattern
+therefore matches <EM>either</EM> the string <SAMP>`foo'</SAMP> <EM>or</EM> the
+string <SAMP>`ba'</SAMP> followed by zero-or-more <SAMP>`r'</SAMP>'s.  To match
+<SAMP>`foo'</SAMP> or zero-or-more repetitions of the string <SAMP>`bar'</SAMP>, use:
 
 
 
@@ -690,7 +721,7 @@
 
 
 <P>
-<A NAME="IDX48"></A>
+<A NAME="IDX64"></A>
 
 <PRE>
 @verbatim
@@ -698,7 +729,7 @@
 </PRE>
 
 <P>
-<A NAME="IDX49"></A>
+<A NAME="IDX65"></A>
 In addition to characters and ranges of characters, character classes
 can also contain <EM>character class expressions</EM>.  These are
 expressions enclosed inside <SAMP>`['</SAMP>: and <SAMP>`:]'</SAMP> delimiters (which
@@ -708,7 +739,7 @@
 
 
 <P>
-<A NAME="IDX50"></A>
+<A NAME="IDX66"></A>
 
 <PRE>
 @verbatim
@@ -719,19 +750,12 @@
 </PRE>
 
 <P>
-These expressions all designate a set of characters equivalent to
-the corresponding standard C
-<CODE>isXXX</CODE>
-function.  For example,
-<SAMP>`[:alnum:]'</SAMP>
-designates those characters for which
-<CODE>isalnum()</CODE>
-returns true - i.e., any alphabetic or numeric character.
-Some systems don't provide
-<CODE>isblank()</CODE>,
-so flex defines
-<SAMP>`[:blank:]'</SAMP>
-as a blank or a tab.
+These expressions all designate a set of characters equivalent to the
+corresponding standard C <CODE>isXXX</CODE> function.  For example,
+<SAMP>`[:alnum:]'</SAMP> designates those characters for which <CODE>isalnum()</CODE>
+returns true - i.e., any alphabetic or numeric character.  Some systems
+don't provide <CODE>isblank()</CODE>, so flex defines <SAMP>`[:blank:]'</SAMP> as a
+blank or a tab.
 
 
 <P>
@@ -739,8 +763,8 @@
 
 
 <P>
-<A NAME="IDX51"></A>
-<A NAME="IDX52"></A>
+<A NAME="IDX67"></A>
+<A NAME="IDX68"></A>
 
 <PRE>
 @verbatim
@@ -751,35 +775,35 @@
 </PRE>
 
 <P>
-<A NAME="IDX53"></A>
+<A NAME="IDX69"></A>
 If your scanner is case-insensitive (the <SAMP>`-i'</SAMP> flag), then
 <SAMP>`[:upper:]'</SAMP> and <SAMP>`[:lower:]'</SAMP> are equivalent to
 <SAMP>`[:alpha:]'</SAMP>.
 
 
 <P>
-Some notes on patterns:
-<A NAME="IDX54"></A>
-<A NAME="IDX55"></A>
-<A NAME="IDX56"></A>
-<A NAME="IDX57"></A>
+Some notes on patterns are in order.
 
 
 
 <UL>
 <LI>
 
-A negated character class such as the example <SAMP>`[^A-Z]'</SAMP>
-above
-<EM>will match a newline</EM>
-unless <SAMP>`\n'</SAMP> (or an equivalent escape sequence) is one of the
-characters explicitly present in the negated character class
-(e.g., <SAMP>`[^A-Z\n]'</SAMP>).  This is unlike how many other regular
-expression tools treat negated character classes, but unfortunately
-the inconsistency is historically entrenched.
-Matching newlines means that a pattern like <SAMP>`[^"]*'</SAMP> can match the entire
+<A NAME="IDX70"></A>
+ <A NAME="IDX71"></A>
+ 
+A negated character class such as the example <SAMP>`[^A-Z]'</SAMP> above
+<EM>will</EM> match a newline unless <SAMP>`\n'</SAMP> (or an equivalent escape
+sequence) is one of the characters explicitly present in the negated
+character class (e.g., <SAMP>`[^A-Z\n]'</SAMP>).  This is unlike how many other
+regular expression tools treat negated character classes, but
+unfortunately the inconsistency is historically entrenched.  Matching
+newlines means that a pattern like <SAMP>`[^"]*'</SAMP> can match the entire
 input unless there's another quote in the input.
 
+<A NAME="IDX72"></A>
+<A NAME="IDX73"></A>
+<A NAME="IDX74"></A>
 <LI>
 
 A rule can have at most one instance of trailing context (the <SAMP>`/'</SAMP> operator
@@ -793,7 +817,7 @@
 
 The following are invalid:
 
-<A NAME="IDX58"></A>
+<A NAME="IDX75"></A>
 
 <PRE>
 @verbatim
@@ -807,7 +831,7 @@
 
 The following will result in <SAMP>`$'</SAMP> or <SAMP>`^'</SAMP> being treated as a normal character:
 
-<A NAME="IDX59"></A>
+<A NAME="IDX76"></A>
 
 <PRE>
 @verbatim
@@ -817,9 +841,9 @@
 
 If the desired meaning is a <SAMP>`foo'</SAMP> or a
 <SAMP>`bar'</SAMP>-followed-by-a-newline, the following could be used (the
-special <CODE>|</CODE> action is explained below, see section <A HREF="flex.html#SEC10">Actions</A>):
+special <CODE>|</CODE> action is explained below, see section <A HREF="flex.html#SEC12">Actions</A>):
 
-<A NAME="IDX60"></A>
+<A NAME="IDX77"></A>
 
 <PRE>
 @verbatim
@@ -827,18 +851,21 @@
     bar$     /* action goes here */
 </PRE>
 
-A similar trick will work for matching a foo or a
-bar-at-the-beginning-of-a-line.
+A similar trick will work for matching a <SAMP>`foo'</SAMP> or a
+<SAMP>`bar'</SAMP>-at-the-beginning-of-a-line.
 </UL>
 
 
 
-<H1><A NAME="SEC9" HREF="flex_toc.html#TOC9">How the Input Is Matched</A></H1>
-<P>
-<A NAME="IDX61"></A>
-
+<H1><A NAME="SEC11" HREF="flex_toc.html#TOC11">How the Input Is Matched</A></H1>
 
 <P>
+<A NAME="IDX78"></A>
+<A NAME="IDX79"></A>
+<A NAME="IDX80"></A>
+<A NAME="IDX81"></A>
+<A NAME="IDX82"></A>
+<A NAME="IDX83"></A>
 When the generated scanner is run, it analyzes its input looking for
 strings which match any of its patterns.  If it finds more than one
 match, it takes the one matching the most text (for trailing context
@@ -849,26 +876,26 @@
 
 
 <P>
+<A NAME="IDX84"></A>
+<A NAME="IDX85"></A>
+<A NAME="IDX86"></A>
 Once the match is determined, the text corresponding to the match
 (called the <EM>token</EM>) is made available in the global character
-pointer <CODE>yytext</CODE>, and its length in the global integer <CODE>yyleng</CODE>.
-The <EM>action</EM> corresponding to the matched pattern is then executed
-(see section <A HREF="flex.html#SEC10">Actions</A>), and then the remaining input is scanned for another
-match.
+pointer <CODE>yytext</CODE>, and its length in the global integer
+<CODE>yyleng</CODE>.  The <EM>action</EM> corresponding to the matched pattern is
+then executed (see section <A HREF="flex.html#SEC12">Actions</A>), and then the remaining input is scanned
+for another match.
 
 
 <P>
-<A NAME="IDX62"></A>
-If no match is found, then the
-<EM>default rule</EM>
-is executed: the next character in the input is considered matched and
-copied to the standard output.  Thus, the simplest valid
-<CODE>flex</CODE>
-input is:
+<A NAME="IDX87"></A>
+If no match is found, then the <EM>default rule</EM> is executed: the next
+character in the input is considered matched and copied to the standard
+output.  Thus, the simplest valid <CODE>flex</CODE> input is:
 
 
 <P>
-<A NAME="IDX63"></A>
+<A NAME="IDX88"></A>
 
 <PRE>
 @verbatim
@@ -876,20 +903,17 @@
 </PRE>
 
 <P>
-which generates a scanner that simply copies its input (one character
-at a time) to its output.
-
-
-<P>
-<A NAME="IDX64"></A>
-<A NAME="IDX65"></A>
-<A NAME="IDX66"></A>
+which generates a scanner that simply copies its input (one character at
+a time) to its output.
 
 
 <P>
-<A NAME="IDX67"></A>
-Note that <CODE>yytext</CODE> can be defined in two different ways: either as a
-character <EM>pointer</EM> or as a character <EM>array</EM>. You can
+<A NAME="IDX89"></A>
+<A NAME="IDX90"></A>
+<A NAME="IDX91"></A>
+<A NAME="IDX92"></A>
+Note that <CODE>yytext</CODE> can be defined in two different ways: either as
+a character <EM>pointer</EM> or as a character <EM>array</EM>. You can
 control which definition <CODE>flex</CODE> uses by including one of the
 special directives <CODE>%pointer</CODE> or <CODE>%array</CODE> in the first
 (definitions) section of your flex input.  The default is
@@ -898,26 +922,19 @@
 <CODE>%pointer</CODE> is substantially faster scanning and no buffer overflow
 when matching very large tokens (unless you run out of dynamic memory).
 The disadvantage is that you are restricted in how your actions can
-modify <CODE>yytext</CODE> (see section <A HREF="flex.html#SEC10">Actions</A>), and calls to the <CODE>unput()</CODE>
+modify <CODE>yytext</CODE> (see section <A HREF="flex.html#SEC12">Actions</A>), and calls to the <CODE>unput()</CODE>
 function destroys the present contents of <CODE>yytext</CODE>, which can be a
 considerable porting headache when moving between different <CODE>lex</CODE>
 versions.
 
 
 <P>
-The advantage of
-<CODE>%array</CODE>
-is that you can then modify
-<CODE>yytext</CODE>
-to your heart's content, and calls to
-<CODE>unput()</CODE>
-do not destroy
-<CODE>yytext</CODE>
-(see section <A HREF="flex.html#SEC10">Actions</A>).  Furthermore, existing
-<CODE>lex</CODE>
-programs sometimes access
-<CODE>yytext</CODE>
-externally using declarations of the form:
+<A NAME="IDX93"></A>
+The advantage of <CODE>%array</CODE> is that you can then modify <CODE>yytext</CODE>
+to your heart's content, and calls to <CODE>unput()</CODE> do not destroy
+<CODE>yytext</CODE> (see section <A HREF="flex.html#SEC12">Actions</A>).  Furthermore, existing <CODE>lex</CODE>
+programs sometimes access <CODE>yytext</CODE> externally using declarations of
+the form:
 
 
 
@@ -940,23 +957,23 @@
 large tokens.  While this means your <CODE>%pointer</CODE> scanner can
 accommodate very large tokens (such as matching entire blocks of
 comments), bear in mind that each time the scanner must resize
-<CODE>yytext</CODE> it also must rescan the entire token from the beginning, so
-matching such tokens can prove slow.  <CODE>yytext</CODE> presently does
+<CODE>yytext</CODE> it also must rescan the entire token from the beginning,
+so matching such tokens can prove slow.  <CODE>yytext</CODE> presently does
 <EM>not</EM> dynamically grow if a call to <CODE>unput()</CODE> results in too
 much text being pushed back; instead, a run-time error results.
 
 
 <P>
-<A NAME="IDX68"></A>
+<A NAME="IDX94"></A>
 Also note that you cannot use <CODE>%array</CODE> with C++ scanner classes
-(see section <A HREF="flex.html#SEC21">Generating C++ Scanners</A>).
+(see section <A HREF="flex.html#SEC28">Generating C++ Scanners</A>).
 
 
 
 
-<H1><A NAME="SEC10" HREF="flex_toc.html#TOC10">Actions</A></H1>
+<H1><A NAME="SEC12" HREF="flex_toc.html#TOC12">Actions</A></H1>
 <P>
-<A NAME="IDX69"></A>
+<A NAME="IDX95"></A>
 
 
 <P>
@@ -969,7 +986,7 @@
 
 
 <P>
-<A NAME="IDX70"></A>
+<A NAME="IDX96"></A>
 
 <PRE>
 @verbatim
@@ -988,8 +1005,8 @@
 
 
 <P>
-<A NAME="IDX71"></A>
-<A NAME="IDX72"></A>
+<A NAME="IDX97"></A>
+<A NAME="IDX98"></A>
 
 <PRE>
 @verbatim
@@ -999,11 +1016,11 @@
 </PRE>
 
 <P>
-<A NAME="IDX73"></A>
-<A NAME="IDX74"></A>
-<A NAME="IDX75"></A>
-<A NAME="IDX76"></A>
-<A NAME="IDX77"></A>
+<A NAME="IDX99"></A>
+<A NAME="IDX100"></A>
+<A NAME="IDX101"></A>
+<A NAME="IDX102"></A>
+<A NAME="IDX103"></A>
 
 
 <P>
@@ -1032,17 +1049,17 @@
 
 
 <P>
-<A NAME="IDX78"></A>
+<A NAME="IDX104"></A>
 Actions are free to modify <CODE>yytext</CODE> except for lengthening it
 (adding characters to its end--these will overwrite later characters in
 the input stream).  This however does not apply when using <CODE>%array</CODE>
-(see section <A HREF="flex.html#SEC9">How the Input Is Matched</A>). In that case, <CODE>yytext</CODE> may be freely modified in
+(see section <A HREF="flex.html#SEC11">How the Input Is Matched</A>). In that case, <CODE>yytext</CODE> may be freely modified in
 any way.
 
 
 <P>
-<A NAME="IDX79"></A>
-<A NAME="IDX80"></A>
+<A NAME="IDX105"></A>
+<A NAME="IDX106"></A>
 Actions are free to modify
 <CODE>yyleng</CODE>
 except they should not do so if the action also includes use of
@@ -1051,7 +1068,7 @@
 
 
 <P>
-<A NAME="IDX81"></A>
+<A NAME="IDX107"></A>
 
 
 <P>
@@ -1063,30 +1080,30 @@
 
 <DT><CODE>ECHO</CODE>
 <DD>
-<A NAME="IDX82"></A>
+<A NAME="IDX108"></A>
  
 copies yytext to the scanner's output.
 
-<A NAME="IDX83"></A>
+<A NAME="IDX109"></A>
 <DT><CODE>BEGIN</CODE>
 <DD>
 followed by the name of a start condition places the scanner in the
 corresponding start condition (see below).
 
-<A NAME="IDX84"></A>
+<A NAME="IDX110"></A>
 <DT><CODE>REJECT</CODE>
 <DD>
 directs the scanner to proceed on to the "second best" rule which
 matched the input (or a prefix of the input).  The rule is chosen as
-described above in section <A HREF="flex.html#SEC9">How the Input Is Matched</A>, and <CODE>yytext</CODE> and <CODE>yyleng</CODE> set
+described above in section <A HREF="flex.html#SEC11">How the Input Is Matched</A>, and <CODE>yytext</CODE> and <CODE>yyleng</CODE> set
 up appropriately.  It may either be one which matched as much text as
 the originally chosen rule but came later in the <CODE>flex</CODE> input file,
 or one which matched less text.  For example, the following will both
 count the words in the input and call the routine <CODE>special()</CODE>
 whenever <SAMP>`frob'</SAMP> is seen:
 
-<A NAME="IDX85"></A>
-<A NAME="IDX86"></A>
+<A NAME="IDX111"></A>
+<A NAME="IDX112"></A>
 
 <PRE>
 @verbatim
@@ -1104,7 +1121,7 @@
 example, when the following scanner scans the token <SAMP>`abcd'</SAMP>, it will
 write <SAMP>`abcdabcaba'</SAMP> to the output:
 
-<A NAME="IDX87"></A>
+<A NAME="IDX113"></A>
 
 <PRE>
 @verbatim
@@ -1130,13 +1147,13 @@
 <SAMP>`-Cf'</SAMP>
 or
 <SAMP>`-CF'</SAMP>
-options (see section <A HREF="flex.html#SEC18">Invoking Flex</A>).
+options (see section <A HREF="flex.html#SEC20">Scanner Options</A>).
 
 Note also that unlike the other special actions, <CODE>REJECT</CODE> is a
 <EM>branch</EM>.  code immediately following it in the action will
 <EM>not</EM> be executed.
 
-<A NAME="IDX88"></A>
+<A NAME="IDX114"></A>
 <DT><CODE>yymore()</CODE>
 <DD>
 tells the scanner that the next time it matches a rule, the
@@ -1145,8 +1162,8 @@
 <SAMP>`mega-kludge'</SAMP> the following will write <SAMP>`mega-mega-kludge'</SAMP> to
 the output:
 
-<A NAME="IDX89"></A>
-<A NAME="IDX90"></A>
+<A NAME="IDX115"></A>
+<A NAME="IDX116"></A>
 
 <PRE>
 @verbatim
@@ -1174,7 +1191,7 @@
 
 
 <P>
-<A NAME="IDX91"></A>
+<A NAME="IDX117"></A>
 <CODE>yyless(n)</CODE> returns all but the first <CODE>n</CODE> characters of the
 current token back to the input stream, where they will be rescanned
 when the scanner looks for the next match.  <CODE>yytext</CODE> and
@@ -1184,9 +1201,9 @@
 
 
 <P>
-<A NAME="IDX92"></A>
-<A NAME="IDX93"></A>
-<A NAME="IDX94"></A>
+<A NAME="IDX118"></A>
+<A NAME="IDX119"></A>
+<A NAME="IDX120"></A>
 
 <PRE>
 @verbatim
@@ -1212,8 +1229,8 @@
 
 
 <P>
-<A NAME="IDX95"></A>
-<A NAME="IDX96"></A>
+<A NAME="IDX121"></A>
+<A NAME="IDX122"></A>
 <CODE>unput(c)</CODE>
 puts the character
 <CODE>c</CODE>
@@ -1223,7 +1240,7 @@
 
 
 <P>
-<A NAME="IDX97"></A>
+<A NAME="IDX123"></A>
 
 <PRE>
 @verbatim
@@ -1246,8 +1263,8 @@
 
 
 <P>
-<A NAME="IDX98"></A>
-<A NAME="IDX99"></A>
+<A NAME="IDX124"></A>
+<A NAME="IDX125"></A>
 
 
 <P>
@@ -1267,25 +1284,25 @@
 (as in the above example),
 you must either first copy it elsewhere, or build your scanner using
 <CODE>%array</CODE>
-instead (see section <A HREF="flex.html#SEC9">How the Input Is Matched</A>).
+instead (see section <A HREF="flex.html#SEC11">How the Input Is Matched</A>).
 
 
 <P>
-<A NAME="IDX100"></A>
-<A NAME="IDX101"></A>
+<A NAME="IDX126"></A>
+<A NAME="IDX127"></A>
 Finally, note that you cannot put back <SAMP>`EOF'</SAMP> to attempt to mark the
 input stream with an end-of-file.
 
 
 <P>
-<A NAME="IDX102"></A>
+<A NAME="IDX128"></A>
 <CODE>input()</CODE> reads the next character from the input stream.  For
 example, the following is one way to eat up C comments:
 
 
 <P>
-<A NAME="IDX103"></A>
-<A NAME="IDX104"></A>
+<A NAME="IDX129"></A>
+<A NAME="IDX130"></A>
 
 <PRE>
 @verbatim
@@ -1317,7 +1334,7 @@
 </PRE>
 
 <P>
-<A NAME="IDX105"></A>
+<A NAME="IDX131"></A>
 (Note that if the scanner is compiled using <CODE>C++</CODE>, then
 <CODE>input()</CODE> is instead referred to as <B>yyinput()</B>, in order to
 avoid a name clash with the <CODE>C++</CODE> stream by the name of
@@ -1325,24 +1342,24 @@
 
 
 <P>
-<A NAME="IDX106"></A>
+<A NAME="IDX132"></A>
 <CODE>YY_FLUSH_BUFFER()</CODE>
 flushes the scanner's internal buffer
 so that the next time the scanner attempts to match a token, it will
 first refill the buffer using
 <CODE>YY_INPUT()</CODE>
-(see section <A HREF="flex.html#SEC11">The Generated Scanner</A>).  This action is a special case
+(see section <A HREF="flex.html#SEC13">The Generated Scanner</A>).  This action is a special case
 of the more general
 <CODE>yy_flush_buffer()</CODE>
-function, described below (see section <A HREF="flex.html#SEC13">Multiple Input Buffers</A>)
+function, described below (see section <A HREF="flex.html#SEC15">Multiple Input Buffers</A>)
 
 
 <P>
-<A NAME="IDX107"></A>
-<A NAME="IDX108"></A>
-<A NAME="IDX109"></A>
-<A NAME="IDX110"></A>
-<A NAME="IDX111"></A>
+<A NAME="IDX133"></A>
+<A NAME="IDX134"></A>
+<A NAME="IDX135"></A>
+<A NAME="IDX136"></A>
+<A NAME="IDX137"></A>
 
 
 <P>
@@ -1357,10 +1374,10 @@
 
 
 
-<H1><A NAME="SEC11" HREF="flex_toc.html#TOC11">The Generated Scanner</A></H1>
+<H1><A NAME="SEC13" HREF="flex_toc.html#TOC13">The Generated Scanner</A></H1>
 
 <P>
-<A NAME="IDX112"></A>
+<A NAME="IDX138"></A>
 The output of <CODE>flex</CODE> is the file <TT>`lex.yy.c'</TT>, which contains
 the scanning routine <CODE>yylex()</CODE>, a number of tables used by it for
 matching tokens, and a number of auxiliary routines and macros.  By
@@ -1377,7 +1394,7 @@
 </PRE>
 
 <P>
-<A NAME="IDX113"></A>
+<A NAME="IDX139"></A>
 (If your environment supports function prototypes, then it will
 be
  <CODE>int yylex( void )</CODE>.)  This definition may be changed by defining
@@ -1385,7 +1402,7 @@
 
 
 <P>
-<A NAME="IDX114"></A>
+<A NAME="IDX140"></A>
 
 <PRE>
 @verbatim
@@ -1400,7 +1417,19 @@
 
 
 <P>
-<A NAME="IDX115"></A>
+<CODE>flex</CODE> generates <SAMP>`C99'</SAMP> function definitions by default. However flex
+does have the ability to generate obsolete, er, <SAMP>`traditional'</SAMP>, function
+definitions. This is to support bootstrapping gcc on old systems.
+Unfortunately, traditional definitions prevent us from using any standard data
+types smaller than int (such as short, char, or bool) as function arguments.
+For this reason, future versions of <CODE>flex</CODE> may generate standard C99 code
+only, leaving K&#38;R-style functions to the historians.  Currently, if you do
+<STRONG>not</STRONG> want <SAMP>`C99'</SAMP> definitions, then you must define
+<CODE>YY_TRADITIONAL_FUNC_DEFS</CODE>.
+
+
+<P>
+<A NAME="IDX141"></A>
 Whenever <CODE>yylex()</CODE> is called, it scans tokens from the global input
 file <TT>`yyin'</TT> (which defaults to stdin).  It continues until it
 either reaches an end-of-file (at which point it returns the value 0) or
@@ -1408,7 +1437,7 @@
 
 
 <P>
-<A NAME="IDX116"></A>
+<A NAME="IDX142"></A>
 If the scanner reaches an end-of-file, subsequent calls are undefined
 unless either <TT>`yyin'</TT> is pointed at a new input file (in which case
 scanning continues from that file), or <CODE>yyrestart()</CODE> is called.
@@ -1421,13 +1450,13 @@
 <CODE>flex</CODE>, and because it can be used to switch input files in the
 middle of scanning.  It can also be used to throw away the current input
 buffer, by calling it with an argument of <TT>`yyin'</TT>; but it would be
-better to use <CODE>YY_FLUSH_BUFFER</CODE> (see section <A HREF="flex.html#SEC10">Actions</A>).  Note that
+better to use <CODE>YY_FLUSH_BUFFER</CODE> (see section <A HREF="flex.html#SEC12">Actions</A>).  Note that
 <CODE>yyrestart()</CODE> does <EM>not</EM> reset the start condition to
-<CODE>INITIAL</CODE> (see section <A HREF="flex.html#SEC12">Start Conditions</A>).
+<CODE>INITIAL</CODE> (see section <A HREF="flex.html#SEC14">Start Conditions</A>).
 
 
 <P>
-<A NAME="IDX117"></A>
+<A NAME="IDX143"></A>
 If
 <CODE>yylex()</CODE>
 stops scanning due to executing a
@@ -1450,13 +1479,13 @@
 
 
 <P>
-<A NAME="IDX118"></A>
+<A NAME="IDX144"></A>
 Here is a sample definition of <CODE>YY_INPUT</CODE> (in the definitions
 section of the input file):
 
 
 <P>
-<A NAME="IDX119"></A>
+<A NAME="IDX145"></A>
 
 <PRE>
 @verbatim
@@ -1475,7 +1504,7 @@
 
 
 <P>
-<A NAME="IDX120"></A>
+<A NAME="IDX146"></A>
 When the scanner receives an end-of-file indication from YY_INPUT, it
 then checks the <CODE>yywrap()</CODE> function.  If <CODE>yywrap()</CODE> returns
 false (zero), then it is assumed that the function has gone ahead and
@@ -1496,7 +1525,7 @@
 <P>
 For scanning from in-memory buffers (e.g., scanning strings), see
 @xref{Scanning Strings}
-See section <A HREF="flex.html#SEC13">Multiple Input Buffers</A>.
+See section <A HREF="flex.html#SEC15">Multiple Input Buffers</A>.
 
 
 <P>
@@ -1512,10 +1541,10 @@
 
 
 
-<H1><A NAME="SEC12" HREF="flex_toc.html#TOC12">Start Conditions</A></H1>
+<H1><A NAME="SEC14" HREF="flex_toc.html#TOC14">Start Conditions</A></H1>
 
 <P>
-<A NAME="IDX121"></A>
+<A NAME="IDX147"></A>
 <CODE>flex</CODE>
 provides a mechanism for conditionally activating rules.  Any rule
 whose pattern is prefixed with <SAMP>`&#60;sc&#62;'</SAMP> will only be active when
@@ -1523,7 +1552,7 @@
 
 
 <P>
-<A NAME="IDX122"></A>
+<A NAME="IDX148"></A>
 
 <PRE>
 @verbatim
@@ -1538,7 +1567,7 @@
 
 
 <P>
-<A NAME="IDX123"></A>
+<A NAME="IDX149"></A>
 
 <PRE>
 @verbatim
@@ -1553,7 +1582,7 @@
 
 
 <P>
-<A NAME="IDX124"></A>
+<A NAME="IDX150"></A>
 Start conditions are declared in the definitions (first) section of the
 input using unindented lines beginning with either <SAMP>`%s'</SAMP> or
 <SAMP>`%x'</SAMP> followed by a list of names.  The former declares
@@ -1579,7 +1608,7 @@
 
 
 <P>
-<A NAME="IDX125"></A>
+<A NAME="IDX151"></A>
 
 <PRE>
 @verbatim
@@ -1596,7 +1625,7 @@
 
 
 <P>
-<A NAME="IDX126"></A>
+<A NAME="IDX152"></A>
 
 <PRE>
 @verbatim
@@ -1619,7 +1648,7 @@
 
 
 <P>
-<A NAME="IDX127"></A>
+<A NAME="IDX153"></A>
 Also note that the special start-condition specifier
 <CODE>&#60;*&#62;</CODE>
 matches every start condition.  Thus, the above example could also
@@ -1627,7 +1656,7 @@
 
 
 <P>
-<A NAME="IDX128"></A>
+<A NAME="IDX154"></A>
 
 <PRE>
 @verbatim
@@ -1645,7 +1674,7 @@
 
 
 <P>
-<A NAME="IDX129"></A>
+<A NAME="IDX155"></A>
 
 <PRE>
 @verbatim
@@ -1653,9 +1682,9 @@
 </PRE>
 
 <P>
-<A NAME="IDX130"></A>
-<A NAME="IDX131"></A>
-<A NAME="IDX132"></A>
+<A NAME="IDX156"></A>
+<A NAME="IDX157"></A>
+<A NAME="IDX158"></A>
 <CODE>BEGIN(0)</CODE> returns to the original state where only the rules with
 no start conditions are active.  This state can also be referred to as
 the start-condition <CODE>INITIAL</CODE>, so <CODE>BEGIN(INITIAL)</CODE> is
@@ -1671,7 +1700,7 @@
 
 
 <P>
-<A NAME="IDX133"></A>
+<A NAME="IDX159"></A>
 
 <PRE>
 @verbatim
@@ -1696,7 +1725,7 @@
 
 
 <P>
-<A NAME="IDX134"></A>
+<A NAME="IDX160"></A>
 
 <PRE>
 @verbatim
@@ -1730,13 +1759,13 @@
 </PRE>
 
 <P>
-<A NAME="IDX135"></A>
+<A NAME="IDX161"></A>
 Here is a scanner which recognizes (and discards) C comments while
 maintaining a count of the current input line.
 
 
 <P>
-<A NAME="IDX136"></A>
+<A NAME="IDX162"></A>
 
 <PRE>
 @verbatim
@@ -1766,8 +1795,8 @@
 
 
 <P>
-<A NAME="IDX137"></A>
-<A NAME="IDX138"></A>
+<A NAME="IDX163"></A>
+<A NAME="IDX164"></A>
 
 <PRE>
 @verbatim
@@ -1795,14 +1824,14 @@
 </PRE>
 
 <P>
-<A NAME="IDX139"></A>
+<A NAME="IDX165"></A>
 Furthermore, you can access the current start condition using the
 integer-valued <CODE>YY_START</CODE> macro.  For example, the above
 assignments to <CODE>comment_caller</CODE> could instead be written
 
 
 <P>
-<A NAME="IDX140"></A>
+<A NAME="IDX166"></A>
 
 <PRE>
 @verbatim
@@ -1810,14 +1839,16 @@
 </PRE>
 
 <P>
-<A NAME="IDX141"></A>
+<A NAME="IDX167"></A>
 Flex provides <CODE>YYSTATE</CODE> as an alias for <CODE>YY_START</CODE> (since that
 is what's used by AT&#38;T <CODE>lex</CODE>).
 
 
 <P>
-Note that start conditions do not have their own name-space; %s's and %x's
-declare names in the same fashion as #define's.
+For historical reasons, start conditions do not have their own
+name-space within the generated scanner. The start condition names are
+unmodified in the generated scanner and generated header.
+@xref{option-header}. @xref{option-prefix}.
 
 
 <P>
@@ -1827,7 +1858,7 @@
 
 
 <P>
-<A NAME="IDX142"></A>
+<A NAME="IDX168"></A>
 
 <PRE>
 @verbatim
@@ -1887,7 +1918,7 @@
 </PRE>
 
 <P>
-<A NAME="IDX143"></A>
+<A NAME="IDX169"></A>
 Often, such as in some of the examples above, you wind up writing a
 whole bunch of rules all preceded by the same start condition(s).  Flex
 makes this a little easier and cleaner by introducing a notion of start
@@ -1908,7 +1939,7 @@
 
 
 <P>
-<A NAME="IDX144"></A>
+<A NAME="IDX170"></A>
 
 <PRE>
 @verbatim
@@ -1938,8 +1969,8 @@
 
 
 <P>
-<A NAME="IDX145"></A>
-<A NAME="IDX146"></A>
+<A NAME="IDX171"></A>
+<A NAME="IDX172"></A>
 
 
 <P>
@@ -1949,7 +1980,7 @@
 <P>
 <DL>
 <DT><U>Function:</U> void <B>yy_push_state</B> <I>( int <CODE>new_state</CODE> )</I>
-<DD><A NAME="IDX147"></A>
+<DD><A NAME="IDX173"></A>
 pushes the current start condition onto the top of the start condition
 stack and switches to
 <CODE>new_state</CODE>
@@ -1962,7 +1993,7 @@
 <P>
 <DL>
 <DT><U>Function:</U> void <B>yy_pop_state</B> <I>()</I>
-<DD><A NAME="IDX148"></A>
+<DD><A NAME="IDX174"></A>
 pops the top of the stack and switches to it via
 <CODE>BEGIN</CODE>.
 </DL>
@@ -1971,28 +2002,28 @@
 <P>
 <DL>
 <DT><U>Function:</U> int <B>yy_top_state</B> <I>()</I>
-<DD><A NAME="IDX149"></A>
+<DD><A NAME="IDX175"></A>
 returns the top of the stack without altering the stack's contents.
 </DL>
 
 
 <P>
-<A NAME="IDX150"></A>
+<A NAME="IDX176"></A>
 The start condition stack grows dynamically and so has no built-in size
 limitation.  If memory is exhausted, program execution aborts.
 
 
 <P>
 To use start condition stacks, your scanner must include a <CODE>%option
-stack</CODE> directive (see section <A HREF="flex.html#SEC18">Invoking Flex</A>).
+stack</CODE> directive (see section <A HREF="flex.html#SEC20">Scanner Options</A>).
 
 
 
 
-<H1><A NAME="SEC13" HREF="flex_toc.html#TOC13">Multiple Input Buffers</A></H1>
+<H1><A NAME="SEC15" HREF="flex_toc.html#TOC15">Multiple Input Buffers</A></H1>
 
 <P>
-<A NAME="IDX151"></A>
+<A NAME="IDX177"></A>
 Some scanners (such as those which support "include" files) require
 reading from several input streams.  As <CODE>flex</CODE> scanners do a large
 amount of buffering, one cannot control where the next input will be
@@ -2010,10 +2041,10 @@
 
 
 <P>
-<A NAME="IDX152"></A>
+<A NAME="IDX178"></A>
 <DL>
 <DT><U>Function:</U> YY_BUFFER_STATE <B>yy_create_buffer</B> <I>( FILE *file, int size )</I>
-<DD><A NAME="IDX153"></A>
+<DD><A NAME="IDX179"></A>
 </DL>
 
 
@@ -2022,8 +2053,8 @@
 associated with the given file and large enough to hold <CODE>size</CODE>
 characters (when in doubt, use <CODE>YY_BUF_SIZE</CODE> for the size).  It
 returns a <CODE>YY_BUFFER_STATE</CODE> handle, which may then be passed to
-other routines (see below).  
-<A NAME="IDX154"></A>
+other routines (see below).
+<A NAME="IDX180"></A>
 The <CODE>YY_BUFFER_STATE</CODE> type is a
 pointer to an opaque <CODE>struct yy_buffer_state</CODE> structure, so you may
 safely initialize <CODE>YY_BUFFER_STATE</CODE> variables to <CODE>((YY_BUFFER_STATE)
@@ -2040,7 +2071,7 @@
 <P>
 <DL>
 <DT><U>Function:</U> void <B>yy_switch_to_buffer</B> <I>( YY_BUFFER_STATE new_buffer )</I>
-<DD><A NAME="IDX155"></A>
+<DD><A NAME="IDX181"></A>
 </DL>
 
 
@@ -2054,10 +2085,10 @@
 
 
 <P>
-<A NAME="IDX156"></A>
+<A NAME="IDX182"></A>
 <DL>
 <DT><U>Function:</U> void <B>yy_delete_buffer</B> <I>( YY_BUFFER_STATE buffer )</I>
-<DD><A NAME="IDX157"></A>
+<DD><A NAME="IDX183"></A>
 </DL>
 
 
@@ -2068,11 +2099,11 @@
 
 
 <P>
-<A NAME="IDX158"></A>
-<A NAME="IDX159"></A>
+<A NAME="IDX184"></A>
+<A NAME="IDX185"></A>
 <DL>
 <DT><U>Function:</U> void <B>yy_flush_buffer</B> <I>( YY_BUFFER_STATE buffer )</I>
-<DD><A NAME="IDX160"></A>
+<DD><A NAME="IDX186"></A>
 </DL>
 
 
@@ -2086,7 +2117,7 @@
 <P>
 <DL>
 <DT><U>Function:</U> YY_BUFFER_STATE <B>yy_new_buffer</B> <I>( FILE *file, int size )</I>
-<DD><A NAME="IDX161"></A>
+<DD><A NAME="IDX187"></A>
 </DL>
 
 
@@ -2097,13 +2128,13 @@
 
 
 <P>
-<A NAME="IDX162"></A>
+<A NAME="IDX188"></A>
 Finally, the macro <CODE>YY_CURRENT_BUFFER</CODE> macro returns a
 <CODE>YY_BUFFER_STATE</CODE> handle to the current buffer.
 
 
 <P>
-<A NAME="IDX163"></A>
+<A NAME="IDX189"></A>
 Here is an example of using these features for writing a scanner
 which expands include files (the
 <CODE>&#60;&#60;EOF&#62;&#62;</CODE>
@@ -2111,7 +2142,7 @@
 
 
 <P>
-<A NAME="IDX164"></A>
+<A NAME="IDX190"></A>
 
 <PRE>
 @verbatim
@@ -2171,7 +2202,7 @@
 
 <P>
 @anchor{Scanning Strings}
-<A NAME="IDX165"></A>
+<A NAME="IDX191"></A>
 The following routines are available for setting up input buffers for
 scanning in-memory strings instead of files.  All of them create a new
 input buffer for scanning the string, and return a corresponding
@@ -2184,7 +2215,7 @@
 <P>
 <DL>
 <DT><U>Function:</U> YY_BUFFER_STATE <B>yy_scan_string</B> <I>( const char *str )</I>
-<DD><A NAME="IDX166"></A>
+<DD><A NAME="IDX192"></A>
 scans a NUL-terminated string.
 </DL>
 
@@ -2192,7 +2223,7 @@
 <P>
 <DL>
 <DT><U>Function:</U> YY_BUFFER_STATE <B>yy_scan_bytes</B> <I>( const char *bytes, int len )</I>
-<DD><A NAME="IDX167"></A>
+<DD><A NAME="IDX193"></A>
 scans <CODE>len</CODE> bytes (including possibly <CODE>NUL</CODE>s) starting at location
 <CODE>bytes</CODE>.
 </DL>
@@ -2206,10 +2237,10 @@
 
 
 <P>
-<A NAME="IDX168"></A>
+<A NAME="IDX194"></A>
 <DL>
 <DT><U>Function:</U> YY_BUFFER_STATE <B>yy_scan_buffer</B> <I>(char *base, yy_size_t size)</I>
-<DD><A NAME="IDX169"></A>
+<DD><A NAME="IDX195"></A>
 which scans in place the buffer starting at <CODE>base</CODE>, consisting of
 <CODE>size</CODE> bytes, the last two bytes of which <EM>must</EM> be
 <CODE>YY_END_OF_BUFFER_CHAR</CODE> (ASCII NUL).  These last two bytes are not
@@ -2227,7 +2258,7 @@
 <P>
 <DL>
 <DT><U>Data type:</U> <B>yy_size_t</B>
-<DD><A NAME="IDX170"></A>
+<DD><A NAME="IDX196"></A>
 is an integral type to which you can cast an integer expression
 reflecting the size of the buffer.
 </DL>
@@ -2235,10 +2266,10 @@
 
 
 
-<H1><A NAME="SEC14" HREF="flex_toc.html#TOC14">End-of-File Rules</A></H1>
+<H1><A NAME="SEC16" HREF="flex_toc.html#TOC16">End-of-File Rules</A></H1>
 
 <P>
-<A NAME="IDX171"></A>
+<A NAME="IDX197"></A>
 The special rule <CODE>&#60;&#60;EOF&#62;&#62;</CODE> indicates
 actions which are to be taken when an end-of-file is
 encountered and <CODE>yywrap()</CODE> returns non-zero (i.e., indicates
@@ -2250,7 +2281,7 @@
 <UL>
 <LI>
 
-<A NAME="IDX172"></A>
+<A NAME="IDX198"></A>
 assigning <TT>`yyin'</TT> to a new input file (in previous versions of
 <CODE>flex</CODE>, after doing the assignment you had to call the special
 action <CODE>YY_NEW_FILE</CODE>.  This is no longer necessary.)
@@ -2289,7 +2320,7 @@
 
 
 <P>
-<A NAME="IDX173"></A>
+<A NAME="IDX199"></A>
 
 <PRE>
 @verbatim
@@ -2312,10 +2343,10 @@
 
 
 
-<H1><A NAME="SEC15" HREF="flex_toc.html#TOC15">Miscellaneous Macros</A></H1>
+<H1><A NAME="SEC17" HREF="flex_toc.html#TOC17">Miscellaneous Macros</A></H1>
 
 <P>
-<A NAME="IDX174"></A>
+<A NAME="IDX200"></A>
 The macro <CODE>YY_USER_ACTION</CODE> can be defined to provide an action
 which is always executed prior to the matched rule's action.  For
 example, it could be #define'd to call a routine to convert yytext to
@@ -2326,7 +2357,7 @@
 
 
 <P>
-<A NAME="IDX175"></A>
+<A NAME="IDX201"></A>
 
 <PRE>
 @verbatim
@@ -2334,7 +2365,7 @@
 </PRE>
 
 <P>
-<A NAME="IDX176"></A>
+<A NAME="IDX202"></A>
 where <CODE>ctr</CODE> is an array to hold the counts for the different rules.
 Note that the macro <CODE>YY_NUM_RULES</CODE> gives the total number of rules
 (including the default rule), even if you use <SAMP>`-s)'</SAMP>, so a correct
@@ -2348,7 +2379,7 @@
 </PRE>
 
 <P>
-<A NAME="IDX177"></A>
+<A NAME="IDX203"></A>
 The macro <CODE>YY_USER_INIT</CODE> may be defined to provide an action which
 is always executed before the first scan (and before the scanner's
 internal initializations are done).  For example, it could be used to
@@ -2356,23 +2387,23 @@
 
 
 <P>
-<A NAME="IDX178"></A>
+<A NAME="IDX204"></A>
 The macro <CODE>yy_set_interactive(is_interactive)</CODE> can be used to
 control whether the current buffer is considered <EM>interactive</EM>.  An
 interactive buffer is processed more slowly, but must be used when the
 scanner's input source is indeed interactive to avoid problems due to
 waiting to fill buffers (see the discussion of the <SAMP>`-I'</SAMP> flag in
-section <A HREF="flex.html#SEC18">Invoking Flex</A>).  A non-zero value in the macro invocation marks
+section <A HREF="flex.html#SEC20">Scanner Options</A>).  A non-zero value in the macro invocation marks
 the buffer as interactive, a zero value as non-interactive.  Note that
 use of this macro overrides <CODE>%option always-interactive</CODE> or
-<CODE>%option never-interactive</CODE> (see section <A HREF="flex.html#SEC18">Invoking Flex</A>).
+<CODE>%option never-interactive</CODE> (see section <A HREF="flex.html#SEC20">Scanner Options</A>).
 <CODE>yy_set_interactive()</CODE> must be invoked prior to beginning to scan
 the buffer that is (or is not) to be considered interactive.
 
 
 <P>
-<A NAME="IDX179"></A>
-<A NAME="IDX180"></A>
+<A NAME="IDX205"></A>
+<A NAME="IDX206"></A>
 The macro <CODE>yy_set_bol(at_bol)</CODE> can be used to control whether the
 current buffer's scanning context for the next token match is done as
 though at the beginning of a line.  A non-zero macro argument makes
@@ -2381,15 +2412,15 @@
 
 
 <P>
-<A NAME="IDX181"></A>
-<A NAME="IDX182"></A>
+<A NAME="IDX207"></A>
+<A NAME="IDX208"></A>
 The macro <CODE>YY_AT_BOL()</CODE> returns true if the next token scanned from
 the current buffer will have <SAMP>`^'</SAMP> rules active, false otherwise.
 
 
 <P>
-<A NAME="IDX183"></A>
-<A NAME="IDX184"></A>
+<A NAME="IDX209"></A>
+<A NAME="IDX210"></A>
 In the generated scanner, the actions are all gathered in one large
 switch statement and separated using <CODE>YY_BREAK</CODE>, which may be
 redefined.  By default, it is simply a <CODE>break</CODE>, to separate each
@@ -2403,7 +2434,7 @@
 
 
 
-<H1><A NAME="SEC16" HREF="flex_toc.html#TOC16">Values Available To the User</A></H1>
+<H1><A NAME="SEC18" HREF="flex_toc.html#TOC18">Values Available To the User</A></H1>
 
 <P>
 This chapter summarizes the various values available to the user in the
@@ -2414,14 +2445,14 @@
 
 <DT><CODE>char *yytext</CODE>
 <DD>
-<A NAME="IDX185"></A>
+<A NAME="IDX211"></A>
  
 holds the text of the current token.  It may be modified but not
 lengthened (you cannot append characters to the end).
 
-<A NAME="IDX186"></A>
-<A NAME="IDX187"></A>
-<A NAME="IDX188"></A>
+<A NAME="IDX212"></A>
+<A NAME="IDX213"></A>
+<A NAME="IDX214"></A>
 If the special directive <CODE>%array</CODE> appears in the first section of
 the scanner description, then <CODE>yytext</CODE> is instead declared
 <CODE>char yytext[YYLMAX]</CODE>, where <CODE>YYLMAX</CODE> is a macro definition
@@ -2432,16 +2463,16 @@
 a character pointer.  The opposite of <CODE>%array</CODE> is <CODE>%pointer</CODE>,
 which is the default.
 
-<A NAME="IDX189"></A>
+<A NAME="IDX215"></A>
 You cannot use <CODE>%array</CODE> when generating C++ scanner classes (the
 <SAMP>`-+'</SAMP> flag).
 
-<A NAME="IDX190"></A>
+<A NAME="IDX216"></A>
 <DT><CODE>int yyleng</CODE>
 <DD>
 holds the length of the current token.
 
-<A NAME="IDX191"></A>
+<A NAME="IDX217"></A>
 <DT><CODE>FILE *yyin</CODE>
 <DD>
 is the file which by default <CODE>flex</CODE> reads from.  It may be
@@ -2452,7 +2483,7 @@
 end-of-file has been seen, you can assign <TT>`yyin'</TT> at the new input
 file and then call the scanner again to continue scanning.
 
-<A NAME="IDX192"></A>
+<A NAME="IDX218"></A>
 <DT><CODE>void yyrestart( FILE *new_file )</CODE>
 <DD>
 may be called to point <TT>`yyin'</TT> at the new input file.  The
@@ -2461,18 +2492,18 @@
 as an argument thus throws away the current input buffer and continues
 scanning the same input file.
 
-<A NAME="IDX193"></A>
+<A NAME="IDX219"></A>
 <DT><CODE>FILE *yyout</CODE>
 <DD>
 is the file to which <CODE>ECHO</CODE> actions are done.  It can be reassigned
 by the user.
 
-<A NAME="IDX194"></A>
+<A NAME="IDX220"></A>
 <DT><CODE>YY_CURRENT_BUFFER</CODE>
 <DD>
 returns a <CODE>YY_BUFFER_STATE</CODE> handle to the current buffer.
 
-<A NAME="IDX195"></A>
+<A NAME="IDX221"></A>
 <DT><CODE>YY_START</CODE>
 <DD>
 returns an integer value corresponding to the current start condition.
@@ -2482,14 +2513,14 @@
 
 
 
-<H1><A NAME="SEC17" HREF="flex_toc.html#TOC17">Interfacing with Yacc</A></H1>
+<H1><A NAME="SEC19" HREF="flex_toc.html#TOC19">Interfacing with Yacc</A></H1>
 
 <P>
-<A NAME="IDX196"></A>
+<A NAME="IDX222"></A>
 
 
 <P>
-<A NAME="IDX197"></A>
+<A NAME="IDX223"></A>
 One of the main uses of <CODE>flex</CODE> is as a companion to the <CODE>yacc</CODE>
 parser-generator.  <CODE>yacc</CODE> parsers expect to call a routine named
 <CODE>yylex()</CODE> to find the next input token.  The routine is supposed to
@@ -2503,7 +2534,7 @@
 
 
 <P>
-<A NAME="IDX198"></A>
+<A NAME="IDX224"></A>
 
 <PRE>
 @verbatim
@@ -2518,138 +2549,203 @@
 
 
 
-<H1><A NAME="SEC18" HREF="flex_toc.html#TOC18">Invoking Flex</A></H1>
+<H1><A NAME="SEC20" HREF="flex_toc.html#TOC20">Scanner Options</A></H1>
 
 <P>
-<A NAME="IDX199"></A>
-<A NAME="IDX200"></A>
-<A NAME="IDX201"></A>
+<A NAME="IDX225"></A>
+<A NAME="IDX226"></A>
+<A NAME="IDX227"></A>
 
 
 <P>
-<CODE>flex</CODE>
-has the following options.
+The various <CODE>flex</CODE> options are categorized by function in the following
+menu. If you want to lookup a particular option by name, See section <A HREF="flex.html#SEC163">Index of Scanner Options</A>.
 
 
-<DL COMPACT>
+<P>
+Even though there are many scanner options, a typical scanner might only
+specify the following options:
 
-<DT><SAMP>`-b, --backup'</SAMP>
-<DD>
-Generate backing-up information to <TT>`lex.backup'</TT>.  This is a list of
-scanner states which require backing up and the input characters on
-which they do so.  By adding rules one can remove backing-up states.  If
-<EM>all</EM> backing-up states are eliminated and <SAMP>`-Cf'</SAMP> or <CODE>-CF</CODE>
-is used, the generated scanner will run faster (see the <SAMP>`--perf-report'</SAMP> flag).
-Only users who wish to squeeze every last cycle out of their scanners
-need worry about this option.  (see section <A HREF="flex.html#SEC20">Performance Considerations</A>).
 
-<DT><SAMP>`-c'</SAMP>
-<DD>
-is a do-nothing option included for POSIX compliance.
 
-<DT><SAMP>`-d, --debug'</SAMP>
-<DD>
-makes the generated scanner run in <EM>debug</EM> mode.  Whenever a pattern
-is recognized and the global variable <CODE>yy_flex_debug</CODE> is non-zero
-(which is the default), the scanner will write to <TT>`stderr'</TT> a line
-of the form:
+<PRE>
+@verbatim
+%option   8-bit reentrant bison-bridge 
+%option   warn nodefault
+%option   yylineno
+%option   outfile="scanner.c" header-file="scanner.h"
+</PRE>
+
+<P>
+The first line specifies the general type of scanner we want. The second line
+specifies that we are being careful. The third line asks flex to track line
+numbers. The last line tells flex what to name the files. (The options can be
+specified in any order. We just dividied them.)
+
+
+<P>
+<CODE>flex</CODE> also provides a mechanism for controlling options within the
+scanner specification itself, rather than from the flex command-line.
+This is done by including <CODE>%option</CODE> directives in the first section
+of the scanner specification.  You can specify multiple options with a
+single <CODE>%option</CODE> directive, and multiple directives in the first
+section of your flex input file.
+
+
+<P>
+Most options are given simply as names, optionally preceded by the
+word <SAMP>`no'</SAMP> (with no intervening whitespace) to negate their meaning.
+The names are the same as their long-option equivalents (but without the
+leading <SAMP>`--'</SAMP> ).
+
+
+<P>
+<CODE>flex</CODE> scans your rule actions to determine whether you use the
+<CODE>REJECT</CODE> or <CODE>yymore()</CODE> features.  The <CODE>REJECT</CODE> and
+<CODE>yymore</CODE> options are available to override its decision as to
+whether you use the options, either by setting them (e.g., <CODE>%option
+reject)</CODE> to indicate the feature is indeed used, or unsetting them to
+indicate it actually is not used (e.g., <CODE>%option noyymore)</CODE>.
+
+
+<P>
+A number of options are available for lint purists who want to suppress
+the appearance of unneeded routines in the generated scanner.  Each of
+the following, if unset (e.g., <CODE>%option nounput</CODE>), results in the
+corresponding routine not appearing in the generated scanner:
+
 
 
 <PRE>
 @verbatim
-    -accepting rule at line 53 ("the matched text")
+    input, unput
+    yy_push_state, yy_pop_state, yy_top_state
+    yy_scan_buffer, yy_scan_bytes, yy_scan_string
+
+    yyget_extra, yyset_extra, yyget_leng, yyget_text,
+    yyget_lineno, yyset_lineno, yyget_in, yyset_in,
+    yyget_out, yyset_out, yyget_lval, yyset_lval,
+    yyget_lloc, yyset_lloc, yyget_debug, yyset_debug
 </PRE>
 
-The line number refers to the location of the rule in the file defining
-the scanner (i.e., the file that was fed to flex).  Messages are also
-generated when the scanner backs up, accepts the default rule, reaches
-the end of its input buffer (or encounters a NUL; at this point, the two
-look the same as far as the scanner's concerned), or reaches an
-end-of-file.
+<P>
+(though <CODE>yy_push_state()</CODE> and friends won't appear anyway unless
+you use <CODE>%option stack)</CODE>.
 
-<DT><SAMP>`-f, --full'</SAMP>
-<DD>
-specifies
-<EM>fast scanner</EM>.
-No table compression is done and <CODE>stdio</CODE> is bypassed.
-The result is large but fast.  This option is equivalent to
-<SAMP>`--Cfr'</SAMP>
 
-<DT><SAMP>`-h, -?, --help'</SAMP>
-<DD>
-generates a "help" summary of <CODE>flex</CODE>'s options to <TT>`stdout'</TT>
-and then exits.
 
-<DT><SAMP>`--header=FILE'</SAMP>
+
+<H2><A NAME="SEC21" HREF="flex_toc.html#TOC21">Options for Specifing Filenames</A></H2>
+
+<DL COMPACT>
+
+@anchor{option-header}
+<DT><SAMP>`--header-file=FILE, <CODE>%option header-file="FILE"</CODE>'</SAMP>
 <DD>
+<A NAME="IDX228"></A>
+ <A NAME="IDX229"></A>
+ 
 instructs flex to write a C header to <TT>`FILE'</TT>. This file contains
-function prototypes, extern variables, and macros used by the scanner.
-It is meant to be included in other C files to avoid compiler warnings.
-The <SAMP>`--header'</SAMP> option is not compatible with the <SAMP>`--c++'</SAMP> option,
+function prototypes, extern variables, and types used by the scanner.
+Only the external API is exported by the header file. Many macros that
+are usable from within scanner actions are not exported to the header
+file. This is due to namespace problems and the goal of a clean
+external API.
+
+While in the header, the macro <CODE>yyIN_HEADER</CODE> is defined, where <SAMP>`yy'</SAMP>
+is substituted with the appropriate prefix.
+
+The <SAMP>`--header-file'</SAMP> option is not compatible with the <SAMP>`--c++'</SAMP> option,
 since the C++ scanner provides its own header in <TT>`yyFlexLexer.h'</TT>.
 
-<DT><SAMP>`-i, --case-insensitive'</SAMP>
+@anchor{option-outfile}
+<A NAME="IDX230"></A>
+<A NAME="IDX231"></A>
+<A NAME="IDX232"></A>
+<DT><SAMP>`-oFILE, --outfile=FILE, <CODE>%option outfile="FILE"</CODE>'</SAMP>
 <DD>
-instructs <CODE>flex</CODE> to generate a <EM>case-insensitive</EM> scanner.  The
-case of letters given in the <CODE>flex</CODE> input patterns will be ignored,
-and tokens in the input will be matched regardless of case.  The matched
-text given in <CODE>yytext</CODE> will have the preserved case (i.e., it will
-not be folded).
+directs flex to write the scanner to the file <TT>`FILE'</TT> instead of
+<TT>`lex.yy.c'</TT>.  If you combine <SAMP>`--outfile'</SAMP> with the <SAMP>`--stdout'</SAMP> option,
+then the scanner is written to <TT>`stdout'</TT> but its <CODE>#line</CODE>
+directives (see the <SAMP>`-l'</SAMP> option above) refer to the file
+<TT>`FILE'</TT>.
 
-<DT><SAMP>`-l, --lex-compat'</SAMP>
+@anchor{option-stdout}
+<A NAME="IDX233"></A>
+<A NAME="IDX234"></A>
+<A NAME="IDX235"></A>
+<DT><SAMP>`-t, --stdout, <CODE>%option stdout</CODE>'</SAMP>
 <DD>
-turns on maximum compatibility with the original AT&#38;T <CODE>lex</CODE>
-implementation.  Note that this does not mean <EM>full</EM> compatibility.
-Use of this option costs a considerable amount of performance, and it
-cannot be used with the <SAMP>`--c++'</SAMP>, <SAMP>`--full'</SAMP>, <SAMP>`--fast'</SAMP>, <SAMP>`-Cf'</SAMP>, or
-<SAMP>`-CF'</SAMP> options.  For details on the compatibilities it provides, see
-section <A HREF="flex.html#SEC36">Incompatibilities with Lex and Posix</A>.  This option also results in the name
-<CODE>YY_FLEX_LEX_COMPAT</CODE> being <CODE>#define</CODE>'d in the generated scanner.
+instructs <CODE>flex</CODE> to write the scanner it generates to standard
+output instead of <TT>`lex.yy.c'</TT>.
 
-<DT><SAMP>`-n'</SAMP>
+<A NAME="IDX236"></A>
+<DT><SAMP>`-SFILE, --skel=FILE'</SAMP>
 <DD>
-is another do-nothing option included only for
-POSIX compliance.
+overrides the default skeleton file from which
+<CODE>flex</CODE>
+constructs its scanners.  You'll never need this option unless you are doing
+<CODE>flex</CODE>
+maintenance or development.
 
-<DT><SAMP>`-p, --perf-report'</SAMP>
+<A NAME="IDX237"></A>
+<A NAME="IDX238"></A>
+<DT><SAMP>`--tables-file=FILE'</SAMP>
 <DD>
-generates a performance report to <TT>`stderr'</TT>.  The report consists of
-comments regarding features of the <CODE>flex</CODE> input file which will
-cause a serious loss of performance in the resulting scanner.  If you
-give the flag twice, you will also get comments regarding features that
-lead to minor performance losses.
-
-Note that the use of <CODE>REJECT</CODE>, <CODE>%option yylineno</CODE>, and
-variable trailing context (see section <A HREF="flex.html#SEC38">Limitations</A>) entails a substantial
-performance penalty; use of <CODE>yymore()</CODE>, the <SAMP>`^'</SAMP> operator, and
-the <SAMP>`--interactive'</SAMP> flag entail minor performance penalties.
+Write serialized scanner dfa tables to FILE. The generated scanner will not
+contain the tables, and requires them to be loaded at runtime.
+@xref{serialization}.
 
-<DT><SAMP>`-s, --nodefault'</SAMP>
+<A NAME="IDX239"></A>
+<A NAME="IDX240"></A>
+<DT><SAMP>`--tables-verify'</SAMP>
 <DD>
-causes the <EM>default rule</EM> (that unmatched scanner input is echoed
-to <TT>`stdout)'</TT> to be suppressed.  If the scanner encounters input
-that does not match any of its rules, it aborts with an error.  This
-option is useful for finding holes in a scanner's rule set.
+This option is for flex development. We document it here in case you stumble
+upon it by accident or in case you suspect some inconsistency in the serialized
+tables.  Flex will serialize the scanner dfa tables but will also generate the
+in-code tables as it normally does. At runtime, the scanner will verify that
+the serialized tables match the in-code tables, instead of loading them. 
+
+</DL>
+
 
-<DT><SAMP>`-t, --stdout'</SAMP>
-<DD>
-instructs <CODE>flex</CODE> to write the scanner it generates to standard
-output instead of <TT>`lex.yy.c'</TT>.
 
-<DT><SAMP>`-v, --verbose'</SAMP>
+<H2><A NAME="SEC22" HREF="flex_toc.html#TOC22">Options Affecting Scanner Behavior</A></H2>
+
+<DL COMPACT>
+
+@anchor{option-case-insensitive}
+<DT><SAMP>`-i, --case-insensitive, <CODE>%option case-insensitive</CODE>'</SAMP>
 <DD>
-specifies that <CODE>flex</CODE> should write to <TT>`stderr'</TT> a summary of
-statistics regarding the scanner it generates.  Most of the statistics
-are meaningless to the casual <CODE>flex</CODE> user, but the first line
-identifies the version of <CODE>flex</CODE> (same as reported by <SAMP>`--version'</SAMP>),
-and the next line the flags used when generating the scanner, including
-those that are on by default.
+<A NAME="IDX241"></A>
+ <A NAME="IDX242"></A>
+ <A NAME="IDX243"></A>
+ 
+instructs <CODE>flex</CODE> to generate a <EM>case-insensitive</EM> scanner.  The
+case of letters given in the <CODE>flex</CODE> input patterns will be ignored,
+and tokens in the input will be matched regardless of case.  The matched
+text given in <CODE>yytext</CODE> will have the preserved case (i.e., it will
+not be folded).
 
-<DT><SAMP>`-w, --nowarn'</SAMP>
+@anchor{option-lex-compat}
+<A NAME="IDX244"></A>
+<A NAME="IDX245"></A>
+<A NAME="IDX246"></A>
+<DT><SAMP>`-l, --lex-compat, <CODE>%option lex-compat</CODE>'</SAMP>
 <DD>
-suppresses warning messages.
+turns on maximum compatibility with the original AT&#38;T <CODE>lex</CODE>
+implementation.  Note that this does not mean <EM>full</EM> compatibility.
+Use of this option costs a considerable amount of performance, and it
+cannot be used with the <SAMP>`--c++'</SAMP>, <SAMP>`--full'</SAMP>, <SAMP>`--fast'</SAMP>, <SAMP>`-Cf'</SAMP>, or
+<SAMP>`-CF'</SAMP> options.  For details on the compatibilities it provides, see
+section <A HREF="flex.html#SEC42">Incompatibilities with Lex and Posix</A>.  This option also results in the name
+<CODE>YY_FLEX_LEX_COMPAT</CODE> being <CODE>#define</CODE>'d in the generated scanner.
 
-<DT><SAMP>`-B, --batch'</SAMP>
+@anchor{option-batch}
+<A NAME="IDX247"></A>
+<A NAME="IDX248"></A>
+<A NAME="IDX249"></A>
+<DT><SAMP>`-B, --batch, <CODE>%option batch</CODE>'</SAMP>
 <DD>
 instructs <CODE>flex</CODE> to generate a <EM>batch</EM> scanner, the opposite of
 <EM>interactive</EM> scanners generated by <SAMP>`--interactive'</SAMP> (see below).  In
@@ -2660,34 +2756,11 @@
 <SAMP>`-Cf'</SAMP> or <SAMP>`-CF'</SAMP> options, which turn on <SAMP>`--batch'</SAMP> automatically
 anyway.
 
-<DT><SAMP>`-F, --fast'</SAMP>
-<DD>
-specifies that the <EM>fast</EM> scanner table representation should be
-used (and <CODE>stdio</CODE> bypassed).  This representation is about as fast
-as the full table representation <SAMP>`--full'</SAMP>, and for some sets of
-patterns will be considerably smaller (and for others, larger).  In
-general, if the pattern set contains both <EM>keywords</EM> and a
-catch-all, <EM>identifier</EM> rule, such as in the set:
-
-
-<PRE>
-@verbatim
-    "case"    return TOK_CASE;
-    "switch"  return TOK_SWITCH;
-    ...
-    "default" return TOK_DEFAULT;
-    [a-z]+    return TOK_ID;
-</PRE>
-
-then you're better off using the full table representation.  If only
-the <EM>identifier</EM> rule is present and you then use a hash table or some such
-to detect the keywords, you're better off using
-<SAMP>`--fast'</SAMP>.
-
-This option is equivalent to <SAMP>`-CFr'</SAMP> (see below).  It cannot be used
-with <SAMP>`--c++'</SAMP>.
-
-<DT><SAMP>`-I, --interactive'</SAMP>
+@anchor{option-interactive}
+<A NAME="IDX250"></A>
+<A NAME="IDX251"></A>
+<A NAME="IDX252"></A>
+<DT><SAMP>`-I, --interactive, <CODE>%option interactive</CODE>'</SAMP>
 <DD>
 instructs <CODE>flex</CODE> to generate an <I>interactive</I> scanner.  An
 interactive scanner is one that only looks ahead to decide what token
@@ -2701,7 +2774,7 @@
 
 <CODE>flex</CODE> scanners default to <CODE>interactive</CODE> unless you use the
 <SAMP>`-Cf'</SAMP> or <SAMP>`-CF'</SAMP> table-compression options
-(see section <A HREF="flex.html#SEC20">Performance Considerations</A>).  That's because if you're looking for
+(see section <A HREF="flex.html#SEC27">Performance Considerations</A>).  That's because if you're looking for
 high-performance you should be using one of these options, so if you
 didn't, <CODE>flex</CODE> assumes you'd rather trade off a bit of run-time
 performance for intuitive interactive behavior.  Note also that you
@@ -2714,67 +2787,79 @@
 be interactive by using
 <SAMP>`--batch'</SAMP>
 
-<DT><SAMP>`-L, --noline'</SAMP>
+@anchor{option-7bit}
+<A NAME="IDX253"></A>
+<A NAME="IDX254"></A>
+<A NAME="IDX255"></A>
+<DT><SAMP>`-7, --7bit, <CODE>%option 7bit</CODE>'</SAMP>
 <DD>
-instructs
-<CODE>flex</CODE>
-not to generate
-<CODE>#line</CODE>
-directives.  Without this option,
-<CODE>flex</CODE>
-peppers the generated scanner
-with <CODE>#line</CODE> directives so error messages in the actions will be correctly
-located with respect to either the original
-<CODE>flex</CODE>
-input file (if the errors are due to code in the input file), or
-<TT>`lex.yy.c'</TT>
-(if the errors are
-<CODE>flex</CODE>'s
-fault -- you should report these sorts of errors to the email address
-given in section <A HREF="flex.html#SEC41">Reporting Bugs</A>).
+instructs <CODE>flex</CODE> to generate a 7-bit scanner, i.e., one which can
+only recognize 7-bit characters in its input.  The advantage of using
+<SAMP>`--7bit'</SAMP> is that the scanner's tables can be up to half the size of
+those generated using the <SAMP>`--8bit'</SAMP>.  The disadvantage is that such
+scanners often hang or crash if their input contains an 8-bit character.
 
-<DT><SAMP>`-R, --reentrant'</SAMP>
-<DD>
-instructs flex to generate a reentrant C scanner.  The generated scanner
-may safely be used in a multi-threaded environment. The API for a
-reentrant scanner is different than for a non-reentrant scanner
-see section <A HREF="flex.html#SEC22">Reentrant C Scanners</A>).  Because of the API difference between
-reentrant and non-reentrant <CODE>flex</CODE> scanners, non-reentrant flex
-code must be modified before it is suitable for use with this option.
-This option is not compatible with the <SAMP>`--c++'</SAMP> option.
+Note, however, that unless you generate your scanner using the
+<SAMP>`-Cf'</SAMP> or <SAMP>`-CF'</SAMP> table compression options, use of <SAMP>`--7bit'</SAMP>
+will save only a small amount of table space, and make your scanner
+considerably less portable.  <CODE>Flex</CODE>'s default behavior is to
+generate an 8-bit scanner unless you use the <SAMP>`-Cf'</SAMP> or <SAMP>`-CF'</SAMP>,
+in which case <CODE>flex</CODE> defaults to generating 7-bit scanners unless
+your site was always configured to generate 8-bit scanners (as will
+often be the case with non-USA sites).  You can tell whether flex
+generated a 7-bit or an 8-bit scanner by inspecting the flag summary in
+the <SAMP>`--verbose'</SAMP> output as described above.
 
-<DT><SAMP>`-Rb, --reentrant-bison'</SAMP>
+Note that if you use <SAMP>`-Cfe'</SAMP> or <SAMP>`-CFe'</SAMP> <CODE>flex</CODE> still
+defaults to generating an 8-bit scanner, since usually with these
+compression options full 8-bit tables are not much more expensive than
+7-bit tables.
+
+@anchor{option-8bit}
+<A NAME="IDX256"></A>
+<A NAME="IDX257"></A>
+<A NAME="IDX258"></A>
+<DT><SAMP>`-8, --8bit, <CODE>%option 8bit</CODE>'</SAMP>
 <DD>
-instructs flex to generate a reentrant C scanner that is
-meant to be called by a
-<CODE>GNU bison</CODE>
-pure parser. The scanner is the same as the scanner generated by the
-<SAMP>`--reentrant'</SAMP>
-option, but with minor API changes for
-<CODE>bison</CODE>
-compatibility. In particular, the declaration of
-<CODE>yylex</CODE>
-is modified, and support for
-<CODE>yylval</CODE>
-and
-<CODE>yylloc</CODE>
-is incorporated. See section <A HREF="flex.html#SEC34">Reentrant C Scanners with Bison Pure Parsers</A>.
+instructs <CODE>flex</CODE> to generate an 8-bit scanner, i.e., one which can
+recognize 8-bit characters.  This flag is only needed for scanners
+generated using <SAMP>`-Cf'</SAMP> or <SAMP>`-CF'</SAMP>, as otherwise flex defaults to
+generating an 8-bit scanner anyway.
 
-The options <SAMP>`--reentrant'</SAMP> and <SAMP>`--reentrant-bison'</SAMP> do not affect the performance of
-the scanner.
+See the discussion of
+<SAMP>`--7bit'</SAMP>
+above for <CODE>flex</CODE>'s default behavior and the tradeoffs between 7-bit
+and 8-bit scanners.
 
-<DT><SAMP>`-T, --trace'</SAMP>
+@anchor{option-default}
+<A NAME="IDX259"></A>
+<A NAME="IDX260"></A>
+<DT><SAMP>`--default, <CODE>%option default</CODE>'</SAMP>
 <DD>
-makes <CODE>flex</CODE> run in <EM>trace</EM> mode.  It will generate a lot of
-messages to <TT>`stderr'</TT> concerning the form of the input and the
-resultant non-deterministic and deterministic finite automata.  This
-option is mostly for use in maintaining <CODE>flex</CODE>.
+generate the default rule.
 
-<DT><SAMP>`-V, --version'</SAMP>
+@anchor{option-always-interactive}
+<A NAME="IDX261"></A>
+<A NAME="IDX262"></A>
+<DT><SAMP>`--always-interactive, <CODE>%option always-interactive</CODE>'</SAMP>
 <DD>
-prints the version number to <TT>`stdout'</TT> and exits. 
+instructs flex to generate a scanner which always considers its input
+<EM>interactive</EM>.  Normally, on each new input file the scanner calls
+<CODE>isatty()</CODE> in an attempt to determine whether the scanner's input
+source is interactive and thus should be read a character at a time.
+When this option is used, however, then no such call is made.
 
-<DT><SAMP>`-X, --posix'</SAMP>
+<A NAME="IDX263"></A>
+<DT><SAMP>`--never-interactive, <CODE>--never-interactive</CODE>'</SAMP>
+<DD>
+instructs flex to generate a scanner which never considers its input
+interactive.  This is the opposite of <CODE>always-interactive</CODE>.
+
+@anchor{option-posix}
+<A NAME="IDX264"></A>
+<A NAME="IDX265"></A>
+<A NAME="IDX266"></A>
+<DT><SAMP>`-X, --posix, <CODE>%option posix</CODE>'</SAMP>
 <DD>
 turns on maximum compatibility with the POSIX 1003.2-1992 definition of
 <CODE>lex</CODE>.  Since <CODE>flex</CODE> was originally designed to implement the
@@ -2798,54 +2883,260 @@
 where concatenation has higher precedence than the repeat operator.
 </UL>
 
-<DT><SAMP>`-7, --7bit'</SAMP>
+@anchor{option-stack}
+<A NAME="IDX267"></A>
+<A NAME="IDX268"></A>
+<DT><SAMP>`--stack, <CODE>%option stack</CODE>'</SAMP>
 <DD>
-instructs <CODE>flex</CODE> to generate a 7-bit scanner, i.e., one which can
-only recognize 7-bit characters in its input.  The advantage of using
-<SAMP>`--7bit'</SAMP> is that the scanner's tables can be up to half the size of
-those generated using the <SAMP>`--8bit'</SAMP>.  The disadvantage is that such
-scanners often hang or crash if their input contains an 8-bit character.
+enables the use of
+start condition stacks (see section <A HREF="flex.html#SEC14">Start Conditions</A>).
 
-Note, however, that unless you generate your scanner using the
-<SAMP>`-Cf'</SAMP> or <SAMP>`-CF'</SAMP> table compression options, use of <SAMP>`--7bit'</SAMP>
-will save only a small amount of table space, and make your scanner
-considerably less portable.  <CODE>Flex</CODE>'s default behavior is to
-generate an 8-bit scanner unless you use the <SAMP>`-Cf'</SAMP> or <SAMP>`-CF'</SAMP>,
-in which case <CODE>flex</CODE> defaults to generating 7-bit scanners unless
-your site was always configured to generate 8-bit scanners (as will
-often be the case with non-USA sites).  You can tell whether flex
-generated a 7-bit or an 8-bit scanner by inspecting the flag summary in
-the <SAMP>`--verbose'</SAMP> output as described above.
+@anchor{option-stdinit}
+<A NAME="IDX269"></A>
+<A NAME="IDX270"></A>
+<DT><SAMP>`--stdinit, <CODE>%option stdinit</CODE>'</SAMP>
+<DD>
+if set (i.e., <B>%option stdinit)</B> initializes <CODE>yyin</CODE> and
+<CODE>yyout</CODE> to <TT>`stdin'</TT> and <TT>`stdout'</TT>, instead of the default of
+<TT>`nil'</TT>.  Some existing <CODE>lex</CODE> programs depend on this behavior,
+even though it is not compliant with ANSI C, which does not require
+<TT>`stdin'</TT> and <TT>`stdout'</TT> to be compile-time constant. In a
+reentrant scanner, however, this is not a problem since initialization
+is performed in <CODE>yylex_init</CODE> at runtime.
 
-Note that if you use <SAMP>`-Cfe'</SAMP> or <SAMP>`-CFe'</SAMP> <CODE>flex</CODE> still
-defaults to generating an 8-bit scanner, since usually with these
-compression options full 8-bit tables are not much more expensive than
-7-bit tables.
+@anchor{option-yylineno}
+<A NAME="IDX271"></A>
+<A NAME="IDX272"></A>
+<DT><SAMP>`--yylineno, <CODE>%option yylineno</CODE>'</SAMP>
+<DD>
+directs <CODE>flex</CODE> to generate a scanner
+that maintains the number of the current line read from its input in the
+global variable <CODE>yylineno</CODE>.  This option is implied by <CODE>%option
+lex-compat</CODE>.  In a reentrant C scanner, the macro <CODE>yylineno</CODE> is
+accessible regardless of the value of <CODE>%option yylineno</CODE>, however, its
+value is not modified by <CODE>flex</CODE> unless <CODE>%option yylineno</CODE> is enabled.
 
-<DT><SAMP>`-8, --8bit'</SAMP>
+@anchor{option-yywrap}
+<A NAME="IDX273"></A>
+<A NAME="IDX274"></A>
+<DT><SAMP>`--yywrap, <CODE>%option yywrap</CODE>'</SAMP>
 <DD>
-instructs <CODE>flex</CODE> to generate an 8-bit scanner, i.e., one which can
-recognize 8-bit characters.  This flag is only needed for scanners
-generated using <SAMP>`-Cf'</SAMP> or <SAMP>`-CF'</SAMP>, as otherwise flex defaults to
-generating an 8-bit scanner anyway.
+if unset (i.e., <CODE>--noyywrap)</CODE>, makes the scanner not call
+<CODE>yywrap()</CODE> upon an end-of-file, but simply assume that there are no
+more files to scan (until the user points <TT>`yyin'</TT> at a new file and
+calls <CODE>yylex()</CODE> again).
 
-See the discussion of
-<SAMP>`--7bit'</SAMP>
-above for <CODE>flex</CODE>'s default behavior and the tradeoffs between 7-bit
-and 8-bit scanners.
+</DL>
+
+
+
+<H2><A NAME="SEC23" HREF="flex_toc.html#TOC23">Code-Level And API Options</A></H2>
+
+<DL COMPACT>
 
-<DT><SAMP>`-+, --c++'</SAMP>
+@anchor{option-bison-bridge}
+<DT><SAMP>`--bison-bridge, <CODE>%option bison-bridge</CODE>'</SAMP>
+<DD>
+<A NAME="IDX275"></A>
+ <A NAME="IDX276"></A>
+ 
+instructs flex to generate a C scanner that is
+meant to be called by a
+<CODE>GNU bison</CODE>
+parser. The scanner has minor API changes for
+<CODE>bison</CODE>
+compatibility. In particular, the declaration of
+<CODE>yylex</CODE>
+is modified, and support for
+<CODE>yylval</CODE>
+and
+<CODE>yylloc</CODE>
+is incorporated. See section <A HREF="flex.html#SEC156">C Scanners with Bison Parsers</A>.
+
+@anchor{option-noline}
+<A NAME="IDX277"></A>
+<A NAME="IDX278"></A>
+<A NAME="IDX279"></A>
+<DT><SAMP>`-L, --noline, <CODE>%option noline</CODE>'</SAMP>
+<DD>
+instructs
+<CODE>flex</CODE>
+not to generate
+<CODE>#line</CODE>
+directives.  Without this option,
+<CODE>flex</CODE>
+peppers the generated scanner
+with <CODE>#line</CODE> directives so error messages in the actions will be correctly
+located with respect to either the original
+<CODE>flex</CODE>
+input file (if the errors are due to code in the input file), or
+<TT>`lex.yy.c'</TT>
+(if the errors are
+<CODE>flex</CODE>'s
+fault -- you should report these sorts of errors to the email address
+given in section <A HREF="flex.html#SEC2">Reporting Bugs</A>).
+
+@anchor{option-reentrant}
+<A NAME="IDX280"></A>
+<A NAME="IDX281"></A>
+<A NAME="IDX282"></A>
+<DT><SAMP>`-R, --reentrant, <CODE>%option reentrant</CODE>'</SAMP>
+<DD>
+instructs flex to generate a reentrant C scanner.  The generated scanner
+may safely be used in a multi-threaded environment. The API for a
+reentrant scanner is different than for a non-reentrant scanner
+see section <A HREF="flex.html#SEC29">Reentrant C Scanners</A>).  Because of the API difference between
+reentrant and non-reentrant <CODE>flex</CODE> scanners, non-reentrant flex
+code must be modified before it is suitable for use with this option.
+This option is not compatible with the <SAMP>`--c++'</SAMP> option.
+
+The option <SAMP>`--reentrant'</SAMP> does not affect the performance of
+the scanner.
+
+@anchor{option-c++}
+<A NAME="IDX283"></A>
+<A NAME="IDX284"></A>
+<A NAME="IDX285"></A>
+<DT><SAMP>`-+, --c++, <CODE>%option c++</CODE>'</SAMP>
 <DD>
 specifies that you want flex to generate a C++
-scanner class.  See section <A HREF="flex.html#SEC21">Generating C++ Scanners</A>, for
+scanner class.  See section <A HREF="flex.html#SEC28">Generating C++ Scanners</A>, for
 details.
 
+@anchor{option-array}
+<A NAME="IDX286"></A>
+<A NAME="IDX287"></A>
+<DT><SAMP>`--array, <CODE>%option array</CODE>'</SAMP>
+<DD>
+specifies that you want yytext to be an array instead of a char*
+
+@anchor{option-pointer}
+<A NAME="IDX288"></A>
+<A NAME="IDX289"></A>
+<DT><SAMP>`--pointer, <CODE>%option pointer</CODE>'</SAMP>
+<DD>
+specify that  <CODE>yytext</CODE> should be a <CODE>char *</CODE>, not an array.
+This default is <CODE>char *</CODE>.
+
+@anchor{option-prefix}
+<A NAME="IDX290"></A>
+<A NAME="IDX291"></A>
+<A NAME="IDX292"></A>
+<DT><SAMP>`-PPREFIX, --prefix=PREFIX, <CODE>%option prefix="PREFIX"</CODE>'</SAMP>
+<DD>
+changes the default <SAMP>`yy'</SAMP> prefix used by <CODE>flex</CODE> for all
+globally-visible variable and function names to instead be
+<SAMP>`PREFIX'</SAMP>.  For example, <SAMP>`--prefix=foo'</SAMP> changes the name of
+<CODE>yytext</CODE> to <CODE>footext</CODE>.  It also changes the name of the default
+output file from <TT>`lex.yy.c'</TT> to <TT>`lex.foo.c'</TT>.  Here is a partial
+list of the names affected:
+
+
+<PRE>
+@verbatim
+    yy_create_buffer
+    yy_delete_buffer
+    yy_flex_debug
+    yy_init_buffer
+    yy_flush_buffer
+    yy_load_buffer_state
+    yy_switch_to_buffer
+    yyin
+    yyleng
+    yylex
+    yylineno
+    yyout
+    yyrestart
+    yytext
+    yywrap
+    yyalloc
+    yyrealloc
+    yyfree
+</PRE>
+
+(If you are using a C++ scanner, then only <CODE>yywrap</CODE> and
+<CODE>yyFlexLexer</CODE> are affected.)  Within your scanner itself, you can
+still refer to the global variables and functions using either version
+of their name; but externally, they have the modified name.
+
+This option lets you easily link together multiple
+<CODE>flex</CODE>
+programs into the same executable.  Note, though, that using this
+option also renames
+<CODE>yywrap()</CODE>,
+so you now
+<EM>must</EM>
+either
+provide your own (appropriately-named) version of the routine for your
+scanner, or use
+<CODE>%option noyywrap</CODE>,
+as linking with
+<SAMP>`-lfl'</SAMP>
+no longer provides one for you by default.
+
+@anchor{option-main}
+<A NAME="IDX293"></A>
+<A NAME="IDX294"></A>
+<DT><SAMP>`--main, <CODE>%option main</CODE>'</SAMP>
+<DD>
+ directs flex to provide a default <CODE>main()</CODE> program for the
+scanner, which simply calls <CODE>yylex()</CODE>.  This option implies
+<CODE>noyywrap</CODE> (see below).
+
+@anchor{option-nounistd}
+<A NAME="IDX295"></A>
+<A NAME="IDX296"></A>
+<DT><SAMP>`--nounistd, <CODE>%option nounistd</CODE>'</SAMP>
+<DD>
+suppresses inclusion of the non-ANSI header file <TT>`unistd.h'</TT>. This option
+is meant to target environments in which <TT>`unistd.h'</TT> does not exist. Be aware
+that certain options may cause flex to generate code that relies on functions
+normally found in <TT>`unistd.h'</TT>, (e.g. <CODE>isatty()</CODE>, <CODE>read()</CODE>.)
+If you wish to use these functions, you will have to inform your compiler where
+to find them.
+@xref{option-always-interactive}. @xref{option-read}.
+
+@anchor{option-yyclass}
+<A NAME="IDX297"></A>
+<A NAME="IDX298"></A>
+<DT><SAMP>`--yyclass, <CODE>%option yyclass="NAME"</CODE>'</SAMP>
+<DD>
+only applies when generating a C++ scanner (the <SAMP>`--c++'</SAMP> option).  It
+informs <CODE>flex</CODE> that you have derived <CODE>foo</CODE> as a subclass of
+<CODE>yyFlexLexer</CODE>, so <CODE>flex</CODE> will place your actions in the member
+function <CODE>foo::yylex()</CODE> instead of <CODE>yyFlexLexer::yylex()</CODE>.  It
+also generates a <CODE>yyFlexLexer::yylex()</CODE> member function that emits
+a run-time error (by invoking <CODE>yyFlexLexer::LexerError())</CODE> if
+called.  See section <A HREF="flex.html#SEC28">Generating C++ Scanners</A>.
+
+</DL>
+
+
+
+<H2><A NAME="SEC24" HREF="flex_toc.html#TOC24">Options for Scanner Speed and Size</A></H2>
+
+<DL COMPACT>
+
 <DT><SAMP>`-C[aefFmr]'</SAMP>
 <DD>
 controls the degree of table compression and, more generally, trade-offs
 between small scanners and fast scanners.
 
-<DT><SAMP>`-Ca, --align'</SAMP>
+<DL COMPACT>
+
+<DT><SAMP>`-C'</SAMP>
+<DD>
+<A NAME="IDX299"></A>
+ 
+A lone <SAMP>`-C'</SAMP> specifies that the scanner tables should be compressed
+but neither equivalence classes nor meta-equivalence classes should be
+used.
+
+@anchor{option-align}
+<A NAME="IDX300"></A>
+<A NAME="IDX301"></A>
+<A NAME="IDX302"></A>
+<DT><SAMP>`-Ca, --align, <CODE>%option align</CODE>'</SAMP>
 <DD>
 ("align") instructs flex to trade off larger tables in the
 generated scanner for faster performance because the elements of
@@ -2854,7 +3145,11 @@
 than with smaller-sized units such as shortwords.  This option can
 quadruple the size of the tables used by your scanner.
 
-<DT><SAMP>`-Ce, --ecs'</SAMP>
+@anchor{option-ecs}
+<A NAME="IDX303"></A>
+<A NAME="IDX304"></A>
+<A NAME="IDX305"></A>
+<DT><SAMP>`-Ce, --ecs, <CODE>%option ecs</CODE>'</SAMP>
 <DD>
 directs <CODE>flex</CODE> to construct <EM>equivalence classes</EM>, i.e., sets
 of characters which have identical lexical properties (for example, if
@@ -2865,19 +3160,25 @@
 factor of 2-5) and are pretty cheap performance-wise (one array look-up
 per character scanned).
 
+<A NAME="IDX306"></A>
 <DT><SAMP>`-Cf'</SAMP>
 <DD>
 specifies that the <EM>full</EM> scanner tables should be generated -
 <CODE>flex</CODE> should not compress the tables by taking advantages of
 similar transition functions for different states.
 
+<A NAME="IDX307"></A>
 <DT><SAMP>`-CF'</SAMP>
 <DD>
 specifies that the alternate fast scanner representation (described
 above under the <SAMP>`--fast'</SAMP> flag) should be used.  This option cannot be
 used with <SAMP>`--c++'</SAMP>.
 
-<DT><SAMP>`-Cm, --meta-ecs'</SAMP>
+@anchor{option-meta-ecs}
+<A NAME="IDX308"></A>
+<A NAME="IDX309"></A>
+<A NAME="IDX310"></A>
+<DT><SAMP>`-Cm, --meta-ecs, <CODE>%option meta-ecs</CODE>'</SAMP>
 <DD>
 directs
 <CODE>flex</CODE>
@@ -2889,8 +3190,11 @@
 have a moderate performance impact (one or two <CODE>if</CODE> tests and one
 array look-up per character scanned).
 
-@anchor{Option-Read}
-<DT><SAMP>`-Cr, --read'</SAMP>
+@anchor{option-read}
+<A NAME="IDX311"></A>
+<A NAME="IDX312"></A>
+<A NAME="IDX313"></A>
+<DT><SAMP>`-Cr, --read, <CODE>%option read</CODE>'</SAMP>
 <DD>
 causes the generated scanner to <EM>bypass</EM> use of the standard I/O
 library (<CODE>stdio</CODE>) for input.  Instead of calling <CODE>fread()</CODE> or
@@ -2901,13 +3205,8 @@
 example, you read from <TT>`yyin'</TT> using <CODE>stdio</CODE> prior to calling
 the scanner (because the scanner will miss whatever text your previous
 reads left in the <CODE>stdio</CODE> input buffer).  <SAMP>`-Cr'</SAMP> has no effect
-if you define <CODE>YY_INPUT()</CODE> (see section <A HREF="flex.html#SEC11">The Generated Scanner</A>).
-
-<DT><SAMP>`-C'</SAMP>
-<DD>
-A lone <SAMP>`-C'</SAMP> specifies that the scanner tables should be compressed
-but neither equivalence classes nor meta-equivalence classes should be
-used.
+if you define <CODE>YY_INPUT()</CODE> (see section <A HREF="flex.html#SEC13">The Generated Scanner</A>).
+</DL>
 
 The options <SAMP>`-Cf'</SAMP> or <SAMP>`-CF'</SAMP> and <SAMP>`-Cm'</SAMP> do not make sense
 together - there is no opportunity for meta-equivalence classes if the
@@ -2941,245 +3240,207 @@
 <SAMP>`-Cfe'</SAMP> is often a good compromise between speed and size for
 production scanners.
 
-<DT><SAMP>`-oFILE, --outfile=FILE'</SAMP>
+@anchor{option-full}
+<A NAME="IDX314"></A>
+<A NAME="IDX315"></A>
+<A NAME="IDX316"></A>
+<DT><SAMP>`-f, --full, <CODE>%option full</CODE>'</SAMP>
 <DD>
-directs flex to write the scanner to the file <TT>`FILE'</TT> instead of
-<TT>`lex.yy.c'</TT>.  If you combine <SAMP>`--outfile'</SAMP> with the <SAMP>`--stdout'</SAMP> option,
-then the scanner is written to <TT>`stdout'</TT> but its <CODE>#line</CODE>
-directives (see the <SAMP>`-l'</SAMP> option above) refer to the file
-<TT>`FILE'</TT>.
+specifies
+<EM>fast scanner</EM>.
+No table compression is done and <CODE>stdio</CODE> is bypassed.
+The result is large but fast.  This option is equivalent to
+<SAMP>`--Cfr'</SAMP>
 
-<DT><SAMP>`-PPREFIX, --prefix=PREFIX'</SAMP>
+@anchor{option-fast}
+<A NAME="IDX317"></A>
+<A NAME="IDX318"></A>
+<A NAME="IDX319"></A>
+<DT><SAMP>`-F, --fast, <CODE>%option fast</CODE>'</SAMP>
 <DD>
-changes the default <SAMP>`yy'</SAMP> prefix used by <CODE>flex</CODE> for all
-globally-visible variable and function names to instead be
-<SAMP>`PREFIX'</SAMP>.  For example, <SAMP>`--prefix=foo'</SAMP> changes the name of
-<CODE>yytext</CODE> to <CODE>footext</CODE>.  It also changes the name of the default
-output file from <TT>`lex.yy.c'</TT> to <TT>`lex.foo.c'</TT>.  Here are all of
-the names affected:
+specifies that the <EM>fast</EM> scanner table representation should be
+used (and <CODE>stdio</CODE> bypassed).  This representation is about as fast
+as the full table representation <SAMP>`--full'</SAMP>, and for some sets of
+patterns will be considerably smaller (and for others, larger).  In
+general, if the pattern set contains both <EM>keywords</EM> and a
+catch-all, <EM>identifier</EM> rule, such as in the set:
 
 
 <PRE>
 @verbatim
-    yy_create_buffer
-    yy_delete_buffer
-    yy_flex_debug
-    yy_init_buffer
-    yy_flush_buffer
-    yy_load_buffer_state
-    yy_switch_to_buffer
-    yyin
-    yyleng
-    yylex
-    yylineno
-    yyout
-    yyrestart
-    yytext
-    yywrap
+    "case"    return TOK_CASE;
+    "switch"  return TOK_SWITCH;
+    ...
+    "default" return TOK_DEFAULT;
+    [a-z]+    return TOK_ID;
 </PRE>
 
-(If you are using a C++ scanner, then only <CODE>yywrap</CODE> and
-<CODE>yyFlexLexer</CODE> are affected.)  Within your scanner itself, you can
-still refer to the global variables and functions using either version
-of their name; but externally, they have the modified name.
-
-This option lets you easily link together multiple
-<CODE>flex</CODE>
-programs into the same executable.  Note, though, that using this
-option also renames
-<CODE>yywrap()</CODE>,
-so you now
-<EM>must</EM>
-either
-provide your own (appropriately-named) version of the routine for your
-scanner, or use
-<CODE>%option noyywrap</CODE>,
-as linking with
-<SAMP>`-lfl'</SAMP>
-no longer provides one for you by default.
-
-<DT><SAMP>`-SFILE, --skel=FILE'</SAMP>
-<DD>
-overrides the default skeleton file from which
-<CODE>flex</CODE>
-constructs its scanners.  You'll never need this option unless you are doing
-<CODE>flex</CODE>
-maintenance or development.
+then you're better off using the full table representation.  If only
+the <EM>identifier</EM> rule is present and you then use a hash table or some such
+to detect the keywords, you're better off using
+<SAMP>`--fast'</SAMP>.
 
-@anchor{Option-Always-Interactive}
-<DT><SAMP>`--always-interactive'</SAMP>
-<DD>
-instructs flex to generate a scanner which always considers its input
-<EM>interactive</EM>.  Normally, on each new input file the scanner calls
-<CODE>isatty()</CODE> in an attempt to determine whether the scanner's input
-source is interactive and thus should be read a character at a time.
-When this option is used, however, then no such call is made.
+This option is equivalent to <SAMP>`-CFr'</SAMP> (see below).  It cannot be used
+with <SAMP>`--c++'</SAMP>.
 
-<DT><SAMP>`--main'</SAMP>
-<DD>
- directs flex to provide a default <CODE>main()</CODE> program for the
-scanner, which simply calls <CODE>yylex()</CODE>.  This option implies
-<CODE>noyywrap</CODE> (see below).
+</DL>
 
-<DT><SAMP>`--never-interactive'</SAMP>
-<DD>
-instructs flex to generate a scanner which never considers its input
-interactive.  This is the opposite of <CODE>always-interactive</CODE>.
 
-<DT><SAMP>`--nounistd'</SAMP>
-<DD>
-suppresses inclusion of the non-ANSI header file <TT>`unistd.h'</TT>. This option
-is meant to target environments in which <TT>`unistd.h'</TT> does not exist. Be aware
-that certain options may cause flex to generate code that relies on functions
-normally found in <TT>`unistd.h'</TT>, (e.g. <CODE>isatty()</CODE>, <CODE>read()</CODE>.)
-If you wish to use these functions, you will have to inform your compiler where
-to find them.
-@xref{Option-Always-Interactive}. @xref{Option-Read}.
 
-<DT><SAMP>`--stack'</SAMP>
-<DD>
-enables the use of
-start condition stacks (see section <A HREF="flex.html#SEC12">Start Conditions</A>).  
+<H2><A NAME="SEC25" HREF="flex_toc.html#TOC25">Debugging Options</A></H2>
 
-<DT><SAMP>`--stdinit'</SAMP>
-<DD>
-if set (i.e., <B>%option stdinit)</B> initializes <CODE>yyin</CODE> and
-<CODE>yyout</CODE> to <TT>`stdin'</TT> and <TT>`stdout'</TT>, instead of the default of
-<TT>`nil'</TT>.  Some existing <CODE>lex</CODE> programs depend on this behavior,
-even though it is not compliant with ANSI C, which does not require
-<TT>`stdin'</TT> and <TT>`stdout'</TT> to be compile-time constant. In a
-reentrant scanner, however, this is not a problem since initialization
-is performed in <CODE>yylex_init</CODE> at runtime.
+<DL COMPACT>
 
-<DT><SAMP>`--yylineno'</SAMP>
+@anchor{option-backup}
+<DT><SAMP>`-b, --backup, <CODE>%option backup</CODE>'</SAMP>
 <DD>
-directs <CODE>flex</CODE> to generate a scanner
-that maintains the number of the current line read from its input in the
-global variable <CODE>yylineno</CODE>.  This option is implied by <CODE>%option
-lex-compat</CODE>.  In a reentrant C scanner, the macro <CODE>yylineno</CODE> is
-accessible regardless of the value of <CODE>%option yylineno</CODE>, however, its
-value is not modified by <CODE>flex</CODE> unless <CODE>%option yylineno</CODE> is enabled.
+<A NAME="IDX320"></A>
+ <A NAME="IDX321"></A>
+ <A NAME="IDX322"></A>
+ 
+Generate backing-up information to <TT>`lex.backup'</TT>.  This is a list of
+scanner states which require backing up and the input characters on
+which they do so.  By adding rules one can remove backing-up states.  If
+<EM>all</EM> backing-up states are eliminated and <SAMP>`-Cf'</SAMP> or <CODE>-CF</CODE>
+is used, the generated scanner will run faster (see the <SAMP>`--perf-report'</SAMP> flag).
+Only users who wish to squeeze every last cycle out of their scanners
+need worry about this option.  (see section <A HREF="flex.html#SEC27">Performance Considerations</A>).
 
-<DT><SAMP>`--yywrap'</SAMP>
+@anchor{option-debug}
+<A NAME="IDX323"></A>
+<A NAME="IDX324"></A>
+<A NAME="IDX325"></A>
+<DT><SAMP>`-d, --debug, <CODE>%option debug</CODE>'</SAMP>
 <DD>
-if unset (i.e., <CODE>--noyywrap)</CODE>, makes the scanner not call
-<CODE>yywrap()</CODE> upon an end-of-file, but simply assume that there are no
-more files to scan (until the user points <TT>`yyin'</TT> at a new file and
-calls <CODE>yylex()</CODE> again).
-</DL>
-
+makes the generated scanner run in <EM>debug</EM> mode.  Whenever a pattern
+is recognized and the global variable <CODE>yy_flex_debug</CODE> is non-zero
+(which is the default), the scanner will write to <TT>`stderr'</TT> a line
+of the form:
 
 
-<H1><A NAME="SEC19" HREF="flex_toc.html#TOC19">Option Directives Within Scanners</A></H1>
+<PRE>
+@verbatim
+    -accepting rule at line 53 ("the matched text")
+</PRE>
 
-<P>
-<CODE>flex</CODE> also provides a mechanism for controlling options within the
-scanner specification itself, rather than from the flex command-line.
-This is done by including <CODE>%option</CODE> directives in the first section
-of the scanner specification.  You can specify multiple options with a
-single <CODE>%option</CODE> directive, and multiple directives in the first
-section of your flex input file.
+The line number refers to the location of the rule in the file defining
+the scanner (i.e., the file that was fed to flex).  Messages are also
+generated when the scanner backs up, accepts the default rule, reaches
+the end of its input buffer (or encounters a NUL; at this point, the two
+look the same as far as the scanner's concerned), or reaches an
+end-of-file.
 
+@anchor{option-perf-report}
+<A NAME="IDX326"></A>
+<A NAME="IDX327"></A>
+<A NAME="IDX328"></A>
+<DT><SAMP>`-p, --perf-report, <CODE>%option perf-report</CODE>'</SAMP>
+<DD>
+generates a performance report to <TT>`stderr'</TT>.  The report consists of
+comments regarding features of the <CODE>flex</CODE> input file which will
+cause a serious loss of performance in the resulting scanner.  If you
+give the flag twice, you will also get comments regarding features that
+lead to minor performance losses.
 
-<P>
-Most options are given simply as names, optionally preceded by the
-word <SAMP>`no'</SAMP> (with no intervening whitespace) to negate their meaning.
-The names are the same as their long-option equivalents (but without the
-leading <SAMP>`--'</SAMP> ).
+Note that the use of <CODE>REJECT</CODE>, and
+variable trailing context (see section <A HREF="flex.html#SEC52">Limitations</A>) entails a substantial
+performance penalty; use of <CODE>yymore()</CODE>, the <SAMP>`^'</SAMP> operator, and
+the <SAMP>`--interactive'</SAMP> flag entail minor performance penalties.
 
+@anchor{option-nodefault}
+<A NAME="IDX329"></A>
+<A NAME="IDX330"></A>
+<A NAME="IDX331"></A>
+<DT><SAMP>`-s, --nodefault, <CODE>%option nodefault</CODE>'</SAMP>
+<DD>
+causes the <EM>default rule</EM> (that unmatched scanner input is echoed
+to <TT>`stdout)'</TT> to be suppressed.  If the scanner encounters input
+that does not match any of its rules, it aborts with an error.  This
+option is useful for finding holes in a scanner's rule set.
 
+@anchor{option-trace}
+<A NAME="IDX332"></A>
+<A NAME="IDX333"></A>
+<A NAME="IDX334"></A>
+<DT><SAMP>`-T, --trace, <CODE>%option trace</CODE>'</SAMP>
+<DD>
+makes <CODE>flex</CODE> run in <EM>trace</EM> mode.  It will generate a lot of
+messages to <TT>`stderr'</TT> concerning the form of the input and the
+resultant non-deterministic and deterministic finite automata.  This
+option is mostly for use in maintaining <CODE>flex</CODE>.
 
-<PRE>
-@verbatim
-    7bit            -7   --7bit
-    8bit            -8   --8bit
-    align           -Ca  --align
-    array                --array   equivalent to "%array"
-    backup          -b   --backup
-    batch           -B   --batch
-    c++             -+   --c++
-
-    caseful or
-    case-sensitive  (default)
-
-    case-insensitive or
-    caseless        -i   --case-insensitive
-
-    debug           -d   --debug
-    default              --default
-    ecs             -Ce  --ecs
-    fast            -F   --fast
-    full            -f   --full
-    header="FILE"        --header=FILE
-    interactive     -I   --interactive
-    lex-compat      -l   --lex-compat
-    meta-ecs        -Cm  --meta-ecs
-    nounistd             --nounistd
-    perf-report     -p   --perf-report
-    pointer              --pointer equivalent to "%pointer" (default)
-    prefix="PREFIX" -P   --prefix
-    outfile="FILE"  -o   --outfile=FILE
-    read            -Cr  --read
-    reentrant       -R   --reentrant
-    reentrant-bison -Rb  --reentrant-bison
-    stdout          -t   --stdout
-    verbose         -v   --verbose
-    warn                 --warn (use "%option nowarn" for -w)
-    yyclass="NAME"       --yyclass=NAME
+@anchor{option-nowarn}
+<A NAME="IDX335"></A>
+<A NAME="IDX336"></A>
+<A NAME="IDX337"></A>
+<DT><SAMP>`-w, --nowarn, <CODE>%option nowarn</CODE>'</SAMP>
+<DD>
+suppresses warning messages.
 
-</PRE>
+@anchor{option-verbose}
+<A NAME="IDX338"></A>
+<A NAME="IDX339"></A>
+<A NAME="IDX340"></A>
+<DT><SAMP>`-v, --verbose, <CODE>%option verbose</CODE>'</SAMP>
+<DD>
+specifies that <CODE>flex</CODE> should write to <TT>`stderr'</TT> a summary of
+statistics regarding the scanner it generates.  Most of the statistics
+are meaningless to the casual <CODE>flex</CODE> user, but the first line
+identifies the version of <CODE>flex</CODE> (same as reported by <SAMP>`--version'</SAMP>),
+and the next line the flags used when generating the scanner, including
+those that are on by default.
 
-<P>
-<CODE>flex</CODE> scans your rule actions to determine whether you use the
-<CODE>REJECT</CODE> or <CODE>yymore()</CODE> features.  The <CODE>REJECT</CODE> and
-<CODE>yymore</CODE> options are available to override its decision as to
-whether you use the options, either by setting them (e.g., <CODE>%option
-reject)</CODE> to indicate the feature is indeed used, or unsetting them to
-indicate it actually is not used (e.g., <CODE>%option noyymore)</CODE>.
+@anchor{option-warn}
+<A NAME="IDX341"></A>
+<A NAME="IDX342"></A>
+<DT><SAMP>`--warn, <CODE>%option warn</CODE>'</SAMP>
+<DD>
+warn about certain things. In particular, if the default rule can be
+matched but no defualt rule has been given, the flex will warn you.
+We recommend using this option always.
 
+</DL>
 
-<P>
-<CODE>%option yyclass</CODE>
-only applies when generating a C++ scanner (the <SAMP>`--c++'</SAMP> option).  It
-informs <CODE>flex</CODE> that you have derived <CODE>foo</CODE> as a subclass of
-<CODE>yyFlexLexer</CODE>, so <CODE>flex</CODE> will place your actions in the member
-function <CODE>foo::yylex()</CODE> instead of <CODE>yyFlexLexer::yylex()</CODE>.  It
-also generates a <CODE>yyFlexLexer::yylex()</CODE> member function that emits
-a run-time error (by invoking <CODE>yyFlexLexer::LexerError())</CODE> if
-called.  See section <A HREF="flex.html#SEC21">Generating C++ Scanners</A>.
 
 
-<P>
-A number of options are available for lint purists who want to suppress
-the appearance of unneeded routines in the generated scanner.  Each of
-the following, if unset (e.g., <CODE>%option nounput</CODE>), results in the
-corresponding routine not appearing in the generated scanner:
+<H2><A NAME="SEC26" HREF="flex_toc.html#TOC26">Miscellaneous Options</A></H2>
 
+<DL COMPACT>
 
+<DT><SAMP>`-c'</SAMP>
+<DD>
+<A NAME="IDX343"></A>
+ 
+is a do-nothing option included for POSIX compliance.
 
-<PRE>
-@verbatim
-    input, unput
-    yy_push_state, yy_pop_state, yy_top_state
-    yy_scan_buffer, yy_scan_bytes, yy_scan_string
+<A NAME="IDX344"></A>
+<A NAME="IDX345"></A>
+generates
+<DT><SAMP>`-h, -?, --help'</SAMP>
+<DD>
+generates a "help" summary of <CODE>flex</CODE>'s options to <TT>`stdout'</TT>
+and then exits.
 
-    yyget_extra, yyset_extra, yyget_leng, yyget_text, 
-    yyget_lineno, yyset_lineno, yyget_in, yyset_in,
-    yyget_out, yyset_out, yyget_lval, yyset_lval,
-    yyget_lloc, yyset_lloc,
-</PRE>
+<A NAME="IDX346"></A>
+<DT><SAMP>`-n'</SAMP>
+<DD>
+is another do-nothing option included only for
+POSIX compliance.
 
-<P>
-(though <CODE>yy_push_state()</CODE> and friends won't appear anyway unless
-you use <CODE>%option stack)</CODE>.
+<A NAME="IDX347"></A>
+<A NAME="IDX348"></A>
+<DT><SAMP>`-V, --version'</SAMP>
+<DD>
+prints the version number to <TT>`stdout'</TT> and exits.
 
+</DL>
 
 
 
-<H1><A NAME="SEC20" HREF="flex_toc.html#TOC20">Performance Considerations</A></H1>
+<H1><A NAME="SEC27" HREF="flex_toc.html#TOC27">Performance Considerations</A></H1>
 
 <P>
-<A NAME="IDX202"></A>
+<A NAME="IDX349"></A>
 The main design goal of <CODE>flex</CODE> is that it generate high-performance
 scanners.  It has been optimized for dealing well with large sets of
 rules.  Aside from the effects on scanner speed of the table compression
@@ -3188,18 +3449,19 @@
 
 
 <P>
-<A NAME="IDX203"></A>
-<A NAME="IDX204"></A>
-<A NAME="IDX205"></A>
+<A NAME="IDX350"></A>
+<A NAME="IDX351"></A>
+<A NAME="IDX352"></A>
 
 <PRE>
 @verbatim
     REJECT
-    %option yylineno
     arbitrary trailing context
 
     pattern sets that require backing up
+    %option yylineno
     %array
+
     %option interactive
     %option always-interactive
 
@@ -3208,7 +3470,7 @@
 </PRE>
 
 <P>
-with the first three all being quite expensive and the last two being
+with the first two all being quite expensive and the last two being
 quite cheap.  Note also that <CODE>unput()</CODE> is implemented as a routine
 call that potentially does quite a bit of work, while <CODE>yyless()</CODE> is
 a quite-cheap macro. So if you are just putting back some excess text
@@ -3221,9 +3483,32 @@
 
 
 <P>
-<A NAME="IDX206"></A>
-<A NAME="IDX207"></A>
-<A NAME="IDX208"></A>
+There is one case when <CODE>%option yylineno</CODE> can be expensive. That is when
+your patterns match long tokens that could <EM>possibly</EM> contain a newline
+character. There is no performance penalty for rules that can not possibly
+match newlines, since flex does not need to check them for newlines.  In
+general, you should avoid rules such as <CODE>[^f]+</CODE>, which match very long
+tokens, including newlines, and may possibly match your entire file! A better
+approach is to separate <CODE>[^f]+</CODE> into two rules:
+
+
+
+<PRE>
+@verbatim
+%option yylineno
+%%
+    [^f\n]+
+    \n+
+</PRE>
+
+<P>
+The above scanner does not incur a performance penalty.
+
+
+<P>
+<A NAME="IDX353"></A>
+<A NAME="IDX354"></A>
+<A NAME="IDX355"></A>
 Getting rid of backing up is messy and often may be an enormous amount
 of work for a complicated scanner.  In principal, one begins by using
 the <SAMP>`-b'</SAMP> flag to generate a <TT>`lex.backup'</TT> file.  For example,
@@ -3231,7 +3516,7 @@
 
 
 <P>
-<A NAME="IDX209"></A>
+<A NAME="IDX356"></A>
 
 <PRE>
 @verbatim
@@ -3297,12 +3582,12 @@
 
 
 <P>
-<A NAME="IDX210"></A>
+<A NAME="IDX357"></A>
 The way to remove the backing up is to add "error" rules:
 
 
 <P>
-<A NAME="IDX211"></A>
+<A NAME="IDX358"></A>
 
 <PRE>
 @verbatim
@@ -3324,7 +3609,7 @@
 
 
 <P>
-<A NAME="IDX212"></A>
+<A NAME="IDX359"></A>
 
 <PRE>
 @verbatim
@@ -3362,7 +3647,7 @@
 
 
 <P>
-<A NAME="IDX213"></A>
+<A NAME="IDX360"></A>
 
 <PRE>
 @verbatim
@@ -3396,7 +3681,7 @@
 
 <P>
 Note that here the special '|' action does <EM>not</EM> provide any
-savings, and can even make things worse (see section <A HREF="flex.html#SEC38">Limitations</A>).
+savings, and can even make things worse (see section <A HREF="flex.html#SEC52">Limitations</A>).
 
 
 <P>
@@ -3410,7 +3695,7 @@
 
 
 <P>
-<A NAME="IDX214"></A>
+<A NAME="IDX361"></A>
 
 <PRE>
 @verbatim
@@ -3457,8 +3742,8 @@
 
 
 <P>
-<A NAME="IDX215"></A>
-<A NAME="IDX216"></A>
+<A NAME="IDX362"></A>
+<A NAME="IDX363"></A>
 A final example in speeding up a scanner: suppose you want to scan
 through a file containing identifiers and keywords, one per line
 and with no other extraneous characters, and recognize all the
@@ -3466,7 +3751,7 @@
 
 
 <P>
-<A NAME="IDX217"></A>
+<A NAME="IDX364"></A>
 
 <PRE>
 @verbatim
@@ -3569,7 +3854,7 @@
 
 <P>
 Another final note regarding performance: as mentioned in
-section <A HREF="flex.html#SEC9">How the Input Is Matched</A>, dynamically resizing <CODE>yytext</CODE> to accommodate huge
+section <A HREF="flex.html#SEC11">How the Input Is Matched</A>, dynamically resizing <CODE>yytext</CODE> to accommodate huge
 tokens is a slow process because it presently requires that the (huge)
 token be rescanned from the beginning.  Thus if performance is vital,
 you should attempt to match "large" quantities of text but not
@@ -3579,16 +3864,23 @@
 
 
 
-<H1><A NAME="SEC21" HREF="flex_toc.html#TOC21">Generating C++ Scanners</A></H1>
+<H1><A NAME="SEC28" HREF="flex_toc.html#TOC28">Generating C++ Scanners</A></H1>
 
 <P>
-<A NAME="IDX218"></A>
-<A NAME="IDX219"></A>
-<A NAME="IDX220"></A>
+<A NAME="IDX365"></A>
+<A NAME="IDX366"></A>
+<STRONG>IMPORTANT</STRONG>: the present form of the scanning class is <EM>experimental</EM>
+and may change considerably between major releases.
+
+
+<P>
+<A NAME="IDX367"></A>
+<A NAME="IDX368"></A>
+<A NAME="IDX369"></A>
 <CODE>flex</CODE> provides two different ways to generate scanners for use
 with C++.  The first way is to simply compile a scanner generated by
 <CODE>flex</CODE> using a C++ compiler instead of a C compiler.  You should
-not encounter any compilation errors (see section <A HREF="flex.html#SEC41">Reporting Bugs</A>).  You can
+not encounter any compilation errors (see section <A HREF="flex.html#SEC2">Reporting Bugs</A>).  You can
 then use C++ code in your rule actions instead of C code.  Note that the
 default input source for your scanner remains <TT>`yyin'</TT>, and default
 echoing is still done to <TT>`yyout'</TT>.  Both of these remain <CODE>FILE
@@ -3616,32 +3908,32 @@
 
 <DT><CODE>const char* YYText()</CODE>
 <DD>
-<A NAME="IDX221"></A>
+<A NAME="IDX370"></A>
  
 returns the text of the most recently matched token, the equivalent of
 <CODE>yytext</CODE>.
 
-<A NAME="IDX222"></A>
+<A NAME="IDX371"></A>
 <DT><CODE>int YYLeng()</CODE>
 <DD>
 returns the length of the most recently matched token, the equivalent of
 <CODE>yyleng</CODE>.
 
-<A NAME="IDX223"></A>
+<A NAME="IDX372"></A>
 <DT><CODE>int lineno() const</CODE>
 <DD>
 returns the current input line number (see <CODE>%option yylineno)</CODE>, or
 <CODE>1</CODE> if <CODE>%option yylineno</CODE> was not used.
 
-<A NAME="IDX224"></A>
+<A NAME="IDX373"></A>
 <DT><CODE>void set_debug( int flag )</CODE>
 <DD>
 sets the debugging flag for the scanner, equivalent to assigning to
-<CODE>yy_flex_debug</CODE> (see section <A HREF="flex.html#SEC18">Invoking Flex</A>).  Note that you must build
+<CODE>yy_flex_debug</CODE> (see section <A HREF="flex.html#SEC20">Scanner Options</A>).  Note that you must build
 the scannerusing <CODE>%option debug</CODE> to include debugging information
 in it.
 
-<A NAME="IDX225"></A>
+<A NAME="IDX374"></A>
 <DT><CODE>int debug() const</CODE>
 <DD>
 returns the current setting of the debugging flag.
@@ -3657,8 +3949,8 @@
 
 
 <P>
-<A NAME="IDX226"></A>
-<A NAME="IDX227"></A>
+<A NAME="IDX375"></A>
+<A NAME="IDX376"></A>
 The second class defined in <TT>`FlexLexer.h'</TT> is <CODE>yyFlexLexer</CODE>,
 which is derived from <CODE>FlexLexer</CODE>.  It defines the following
 additional member functions:
@@ -3668,13 +3960,13 @@
 
 <DT><CODE>yyFlexLexer( istream* arg_yyin = 0, ostream* arg_yyout = 0 )</CODE>
 <DD>
-<A NAME="IDX228"></A>
+<A NAME="IDX377"></A>
  
 constructs a <CODE>yyFlexLexer</CODE> object using the given streams for input
 and output.  If not specified, the streams default to <CODE>cin</CODE> and
 <CODE>cout</CODE>, respectively.
 
-<A NAME="IDX229"></A>
+<A NAME="IDX378"></A>
 <DT><CODE>virtual int yylex()</CODE>
 <DD>
 performs the same role is <CODE>yylex()</CODE> does for ordinary <CODE>flex</CODE>
@@ -3688,7 +3980,7 @@
 (and also generates a dummy <CODE>yyFlexLexer::yylex()</CODE> that calls
 <CODE>yyFlexLexer::LexerError()</CODE> if called).
 
-<A NAME="IDX230"></A>
+<A NAME="IDX379"></A>
 <DT><CODE>virtual void switch_streams(istream* new_in = 0, ostream* new_out = 0)</CODE>
 <DD>
 reassigns <CODE>yyin</CODE> to <CODE>new_in</CODE> (if non-nil) and <CODE>yyout</CODE> to
@@ -3711,26 +4003,26 @@
 
 <DT><CODE>virtual int LexerInput( char* buf, int max_size )</CODE>
 <DD>
-<A NAME="IDX231"></A>
+<A NAME="IDX380"></A>
  
 reads up to <CODE>max_size</CODE> characters into <CODE>buf</CODE> and returns the
 number of characters read.  To indicate end-of-input, return 0
 characters.  Note that <CODE>interactive</CODE> scanners (see the <SAMP>`-B'</SAMP>
-and <SAMP>`-I'</SAMP> flags in section <A HREF="flex.html#SEC18">Invoking Flex</A>) define the macro
+and <SAMP>`-I'</SAMP> flags in section <A HREF="flex.html#SEC20">Scanner Options</A>) define the macro
 <CODE>YY_INTERACTIVE</CODE>.  If you redefine <CODE>LexerInput()</CODE> and need to
 take different actions depending on whether or not the scanner might be
 scanning an interactive input source, you can test for the presence of
 this name via <CODE>#ifdef</CODE> statements.
 
-<A NAME="IDX232"></A>
+<A NAME="IDX381"></A>
 <DT><CODE>virtual void LexerOutput( const char* buf, int size )</CODE>
 <DD>
 writes out <CODE>size</CODE> characters from the buffer <CODE>buf</CODE>, which, while
 <CODE>NUL</CODE>-terminated, may also contain internal <CODE>NUL</CODE>s if the
 scanner's rules can match text with <CODE>NUL</CODE>s in them.
 
-<A NAME="IDX233"></A>
-<A NAME="IDX234"></A>
+<A NAME="IDX382"></A>
+<A NAME="IDX383"></A>
 <DT><CODE>virtual void LexerError( const char* msg )</CODE>
 <DD>
 reports a fatal error message.  The default version of this function
@@ -3740,10 +4032,10 @@
 <P>
 Note that a <CODE>yyFlexLexer</CODE> object contains its <EM>entire</EM>
 scanning state.  Thus you can use such objects to create reentrant
-scanners.  You can instantiate multiple instances of the same
-<CODE>yyFlexLexer</CODE> class, and you can also combine multiple C++ scanner
-classes together in the same program using the <SAMP>`-P'</SAMP> option
-discussed above.
+scanners, but see also section <A HREF="flex.html#SEC29">Reentrant C Scanners</A>.  You can instantiate multiple
+instances of the same <CODE>yyFlexLexer</CODE> class, and you can also combine
+multiple C++ scanner classes together in the same program using the
+<SAMP>`-P'</SAMP> option discussed above.
 
 
 <P>
@@ -3756,7 +4048,7 @@
 
 
 <P>
-<A NAME="IDX235"></A>
+<A NAME="IDX384"></A>
 
 <PRE>
 @verbatim
@@ -3819,7 +4111,7 @@
 </PRE>
 
 <P>
-<A NAME="IDX236"></A>
+<A NAME="IDX385"></A>
 If you want to create multiple (different) lexer classes, you use the
 <SAMP>`-P'</SAMP> flag (or the <CODE>prefix=</CODE> option) to rename each
 <CODE>yyFlexLexer</CODE> to some other <SAMP>`xxFlexLexer'</SAMP>.  You then can
@@ -3828,9 +4120,9 @@
 
 
 <P>
-<A NAME="IDX237"></A>
-<A NAME="IDX238"></A>
-<A NAME="IDX239"></A>
+<A NAME="IDX386"></A>
+<A NAME="IDX387"></A>
+<A NAME="IDX388"></A>
 
 <PRE>
 @verbatim
@@ -3848,30 +4140,23 @@
 scanners and <CODE>%option prefix="zz"</CODE> for the other.
 
 
-<P>
-IMPORTANT: the present form of the scanning class is <EM>experimental</EM>
-and may change considerably between major releases.
-
-
 
 
-<H1><A NAME="SEC22" HREF="flex_toc.html#TOC22">Reentrant C Scanners</A></H1>
+<H1><A NAME="SEC29" HREF="flex_toc.html#TOC29">Reentrant C Scanners</A></H1>
 
 <P>
-<A NAME="IDX240"></A>
+<A NAME="IDX389"></A>
 <CODE>flex</CODE> has the ability to generate a reentrant C scanner. This is
-accomplished by specifying <CODE>%option reentrant</CODE> (<SAMP>`-R'</SAMP>) or
-<CODE>%option reentrant-bison</CODE> (<SAMP>`-Rb'</SAMP>).  The generated scanner is
-both portable, and safe to use in one or more separate threads of
+accomplished by specifying <CODE>%option reentrant</CODE> (<SAMP>`-R'</SAMP>) The generated
+scanner is both portable, and safe to use in one or more separate threads of
 control.  The most common use for reentrant scanners is from within
-multi-threaded applications.  Any thread may create and execute a
-reentrant <CODE>flex</CODE> scanner without the need for synchronization with
-other threads.
+multi-threaded applications.  Any thread may create and execute a reentrant
+<CODE>flex</CODE> scanner without the need for synchronization with other threads.
 
 
 
 
-<H2><A NAME="SEC23" HREF="flex_toc.html#TOC23">Uses for Reentrant Scanners</A></H2>
+<H2><A NAME="SEC30" HREF="flex_toc.html#TOC30">Uses for Reentrant Scanners</A></H2>
 
 <P>
 However, there are other uses for a reentrant scanner.  For example, you
@@ -3880,7 +4165,7 @@
 
 
 <P>
-<A NAME="IDX241"></A>
+<A NAME="IDX390"></A>
 
 <PRE>
 @verbatim
@@ -3901,7 +4186,7 @@
 <P>
 Another use for a reentrant scanner is recursion.
 (Note that a recursive scanner can also be created using a non-reentrant scanner and
-buffer states. See section <A HREF="flex.html#SEC13">Multiple Input Buffers</A>.)
+buffer states. See section <A HREF="flex.html#SEC15">Multiple Input Buffers</A>.)
 
 
 <P>
@@ -3910,7 +4195,7 @@
 
 
 <P>
-<A NAME="IDX242"></A>
+<A NAME="IDX391"></A>
 
 <PRE>
 @verbatim
@@ -3919,12 +4204,12 @@
     %option reentrant
 
     %%
-    "eval(".+")"  {  
+    "eval(".+")"  {
                       yyscan_t scanner;
                       YY_BUFFER_STATE buf;
 
                       yylex_init( &#38;scanner );
-                      yytext[yyleng-1] = ' '; 
+                      yytext[yyleng-1] = ' ';
 
                       buf = yy_scan_string( yytext + 5, scanner );
                       yylex( scanner );
@@ -3938,10 +4223,10 @@
 
 
 
-<H2><A NAME="SEC24" HREF="flex_toc.html#TOC24">An Overview of the Reentrant API</A></H2>
+<H2><A NAME="SEC31" HREF="flex_toc.html#TOC31">An Overview of the Reentrant API</A></H2>
 
 <P>
-<A NAME="IDX243"></A>
+<A NAME="IDX392"></A>
 The API for reentrant scanners is different than for non-reentrant
 scanners. Here is a quick overview of the API:
 
@@ -3952,7 +4237,7 @@
 
 <LI>
 
-All functions take one additional argument: <CODE>yy_globals</CODE>
+All functions take one additional argument: <CODE>yyscanner</CODE>
 
 <LI>
 
@@ -3976,11 +4261,11 @@
 
 
 
-<H2><A NAME="SEC25" HREF="flex_toc.html#TOC25">Reentrant Example</A></H2>
+<H2><A NAME="SEC32" HREF="flex_toc.html#TOC32">Reentrant Example</A></H2>
 
 <P>
 First, an example of a reentrant scanner:
-<A NAME="IDX244"></A>
+<A NAME="IDX393"></A>
 
 <PRE>
 @verbatim
@@ -3988,15 +4273,15 @@
     %option reentrant stack
     %x COMMENT
     %%
-    "//"                 yy_push_state( COMMENT, yy_globals);
+    "//"                 yy_push_state( COMMENT, yyscanner);
     .|\n
-    &#60;COMMENT&#62;\n          yy_pop_state( yy_globals );
+    &#60;COMMENT&#62;\n          yy_pop_state( yyscanner );
     &#60;COMMENT&#62;[^\n]+      fprintf( yyout, "%s\n", yytext);
     %%
-    int main ( int argc, char * argv[] ) 
+    int main ( int argc, char * argv[] )
     {
         yyscan_t scanner;
-        
+
         yylex_init ( &#38;scanner );
         yylex ( scanner );
         yylex_destroy ( scanner );
@@ -4006,7 +4291,7 @@
 
 
 
-<H2><A NAME="SEC26" HREF="flex_toc.html#TOC26">The Reentrant API in Detail</A></H2>
+<H2><A NAME="SEC33" HREF="flex_toc.html#TOC33">The Reentrant API in Detail</A></H2>
 
 <P>
 Here are the things you need to do or know to use the reentrant C API of
@@ -4015,7 +4300,7 @@
 
 
 
-<H3><A NAME="SEC27" HREF="flex_toc.html#TOC27">Declaring a Scanner As Reentrant</A></H3>
+<H3><A NAME="SEC34" HREF="flex_toc.html#TOC34">Declaring a Scanner As Reentrant</A></H3>
 
 <P>
  %option reentrant (--reentrant) must be specified.
@@ -4023,7 +4308,7 @@
 
 <P>
 Notice that <CODE>%option reentrant</CODE> is specified in the above example
-(see section <A HREF="flex.html#SEC25">Reentrant Example</A>. Had this option not been specified,
+(see section <A HREF="flex.html#SEC32">Reentrant Example</A>. Had this option not been specified,
 <CODE>flex</CODE> would have happily generated a non-reentrant scanner without
 complaining. You may explicitly specify <CODE>%option noreentrant</CODE>, if
 you do <EM>not</EM> want a reentrant scanner, although it is not
@@ -4032,17 +4317,17 @@
 
 
 
-<H3><A NAME="SEC28" HREF="flex_toc.html#TOC28">The Extra Argument</A></H3>
+<H3><A NAME="SEC35" HREF="flex_toc.html#TOC35">The Extra Argument</A></H3>
 
 <P>
-<A NAME="IDX245"></A>
-<A NAME="IDX246"></A>
-All functions take one additional argument: <CODE>yy_globals</CODE>.
+<A NAME="IDX394"></A>
+<A NAME="IDX395"></A>
+All functions take one additional argument: <CODE>yyscanner</CODE>.
 
 
 <P>
 Notice that the calls to <CODE>yy_push_state</CODE> and <CODE>yy_pop_state</CODE>
-both have an argument, <CODE>yy_globals</CODE> , that is not present in a
+both have an argument, <CODE>yyscanner</CODE> , that is not present in a
 non-reentrant scanner.  Here are the declarations of
 <CODE>yy_push_state</CODE> and <CODE>yy_pop_state</CODE> in the generated scanner:
 
@@ -4050,30 +4335,30 @@
 
 <PRE>
 @verbatim
-    static void yy_push_state  ( int new_state , yyscan_t yy_globals ) ;
-    static void yy_pop_state  ( yyscan_t yy_globals  ) ;
+    static void yy_push_state  ( int new_state , yyscan_t yyscanner ) ;
+    static void yy_pop_state  ( yyscan_t yyscanner  ) ;
 </PRE>
 
 <P>
-Notice that the argument <CODE>yy_globals</CODE> appears in the declaration of
+Notice that the argument <CODE>yyscanner</CODE> appears in the declaration of
 both functions.  In fact, all <CODE>flex</CODE> functions in a reentrant
 scanner have this additional argument.  It is always the last argument
 in the argument list, it is always of type <CODE>yyscan_t</CODE> (which is
 typedef'd to <CODE>void *</CODE>) and it is
-always named <CODE>yy_globals</CODE>.  As you may have guessed,
-<CODE>yy_globals</CODE> is a pointer to an opaque data structure encapsulating
+always named <CODE>yyscanner</CODE>.  As you may have guessed,
+<CODE>yyscanner</CODE> is a pointer to an opaque data structure encapsulating
 the current state of the scanner.  For a list of function declarations,
-see section <A HREF="flex.html#SEC35">Functions and Macros Available in Reentrant C Scanners</A>. Note that preprocessor macros, such as
+see section <A HREF="flex.html#SEC41">Functions and Macros Available in Reentrant C Scanners</A>. Note that preprocessor macros, such as
 <CODE>BEGIN</CODE>, <CODE>ECHO</CODE>, and <CODE>REJECT</CODE>, do not take this
 additional argument.
 
 
 
 
-<H3><A NAME="SEC29" HREF="flex_toc.html#TOC29">Global Variables Replaced By Macros</A></H3>
+<H3><A NAME="SEC36" HREF="flex_toc.html#TOC36">Global Variables Replaced By Macros</A></H3>
 
 <P>
-<A NAME="IDX247"></A>
+<A NAME="IDX396"></A>
 All global variables in traditional flex have been replaced by macro equivalents.
 
 
@@ -4091,7 +4376,7 @@
 
 <PRE>
 @verbatim
-#define yytext (((struct yy_globals_t*)yy_globals)-&#62;yytext_r)
+#define yytext (((struct yyguts_t*)yyscanner)-&#62;yytext_r)
 </PRE>
 
 <P>
@@ -4101,20 +4386,20 @@
 <CODE>yytext</CODE>
 is not a global variable in a reentrant
 scanner, you can not access it directly from outside an action or from
-other functions. You must use an accessor method, e.g., 
-<CODE>yyget_text</CODE>, 
+other functions. You must use an accessor method, e.g.,
+<CODE>yyget_text</CODE>,
 to accomplish this. (See below).
 
 
 
 
-<H3><A NAME="SEC30" HREF="flex_toc.html#TOC30">Init and Destroy Functions</A></H3>
+<H3><A NAME="SEC37" HREF="flex_toc.html#TOC37">Init and Destroy Functions</A></H3>
 
 <P>
-<A NAME="IDX248"></A>
-<A NAME="IDX249"></A>
-<A NAME="IDX250"></A>
-<A NAME="IDX251"></A>
+<A NAME="IDX397"></A>
+<A NAME="IDX398"></A>
+<A NAME="IDX399"></A>
+<A NAME="IDX400"></A>
 
 
 <P>
@@ -4126,8 +4411,8 @@
 <PRE>
 @verbatim
     int yylex_init ( yyscan_t * ptr_yy_globals ) ;
-    int yylex ( yyscan_t yy_globals ) ;
-    int yylex_destroy ( yyscan_t yy_globals ) ;
+    int yylex ( yyscan_t yyscanner ) ;
+    int yylex_destroy ( yyscan_t yyscanner ) ;
 </PRE>
 
 <P>
@@ -4142,13 +4427,28 @@
 <CODE>yylex</CODE> should be familiar to you by now. The reentrant version
 takes one argument, which is the value returned (via an argument) by
 <CODE>yylex_init</CODE>.  Otherwise, it behaves the same as the non-reentrant
-version of <CODE>yylex</CODE>. 
+version of <CODE>yylex</CODE>.
+
+
+<P>
+<CODE>yylex_init</CODE> returns 0 (zero) on success, or non-zero on failure,
+in which case, errno is set to one of the following values:
+
 
 
+<UL>
+<LI>ENOMEM
+
+Memory allocation error. @xref{memory-management}.
+<LI>EINVAL
+
+Invalid argument.
+</UL>
+
 <P>
 The function <CODE>yylex_destroy</CODE> should be
 called to free resources used by the scanner. After <CODE>yylex_destroy</CODE>
-is called, the contents of <CODE>yy_globals</CODE> should not be used.  Of
+is called, the contents of <CODE>yyscanner</CODE> should not be used.  Of
 course, there is no need to destroy a scanner if you plan to reuse it.
 A <CODE>flex</CODE> scanner (both reentrant and non-reentrant) may be
 restarted by calling <CODE>yyrestart</CODE>.
@@ -4179,10 +4479,10 @@
 
 
 
-<H3><A NAME="SEC31" HREF="flex_toc.html#TOC31">Accessing Variables with Reentrant Scanners</A></H3>
+<H3><A NAME="SEC38" HREF="flex_toc.html#TOC38">Accessing Variables with Reentrant Scanners</A></H3>
 
 <P>
-<A NAME="IDX252"></A>
+<A NAME="IDX401"></A>
 Accessor methods (get/set functions) provide access to common
 <CODE>flex</CODE> variables.
 
@@ -4200,15 +4500,15 @@
 
 
 <P>
-<A NAME="IDX253"></A>
+<A NAME="IDX402"></A>
 
 <PRE>
 @verbatim
     /* Set the last character of yytext to NULL. */
     void chop ( yyscan_t scanner )
     {
-        int len = yyget_leng( scanner );        
-        yyget_text( scanner )[len - 1] = '\0';        
+        int len = yyget_leng( scanner );
+        yyget_text( scanner )[len - 1] = '\0';
     }
 </PRE>
 
@@ -4220,16 +4520,21 @@
 <PRE>
 @verbatim
     %%
-    .+\n    { chop( yy_globals );}
+    .+\n    { chop( yyscanner );}
 </PRE>
 
+<P>
+You may find that <CODE>%option header-file</CODE> is particularly useful for generating
+prototypes of all the accessor functions. @xref{option-header}.
+
 
 
-<H3><A NAME="SEC32" HREF="flex_toc.html#TOC32">Extra Data</A></H3>
+
+<H3><A NAME="SEC39" HREF="flex_toc.html#TOC39">Extra Data</A></H3>
 
 <P>
-<A NAME="IDX254"></A>
-<A NAME="IDX255"></A>
+<A NAME="IDX403"></A>
+<A NAME="IDX404"></A>
 User-specific data can be stored in <CODE>yyextra</CODE>.
 
 
@@ -4253,9 +4558,9 @@
 
 
 <P>
-<A NAME="IDX256"></A>
-<A NAME="IDX257"></A>
-<A NAME="IDX258"></A>
+<A NAME="IDX405"></A>
+<A NAME="IDX406"></A>
+<A NAME="IDX407"></A>
 
 <PRE>
 @verbatim
@@ -4273,19 +4578,19 @@
 
 
 <P>
-<A NAME="IDX259"></A>
+<A NAME="IDX408"></A>
 
 <PRE>
 @verbatim
     /* An example of overriding YY_EXTRA_TYPE. */
-    %{    
+    %{
     #include &#60;sys/stat.h&#62;
     #include &#60;unistd.h&#62;
     #define YY_EXTRA_TYPE  struct stat*
     %}
     %option reentrant
     %%
-          
+
     __filesize__     printf( "%ld", yyextra-&#62;st_size  );
     __lastmod__      printf( "%ld", yyextra-&#62;st_mtime );
     %%
@@ -4293,10 +4598,10 @@
     {
         yyscan_t scanner;
         struct stat buf;
-        
+
         yylex_init ( &#38;scanner );
         yyset_in( fopen(filename,"r"), scanner );
-        
+
         stat( filename, &#38;buf);
         yyset_extra( &#38;buf, scanner );
         yylex ( scanner );
@@ -4306,10 +4611,10 @@
 
 
 
-<H3><A NAME="SEC33" HREF="flex_toc.html#TOC33">About yyscan_t</A></H3>
+<H3><A NAME="SEC40" HREF="flex_toc.html#TOC40">About yyscan_t</A></H3>
 
 <P>
-<A NAME="IDX260"></A>
+<A NAME="IDX409"></A>
 <CODE>yyscan_t</CODE> is defined as:
 
 
@@ -4328,156 +4633,25 @@
 
 
 
-<H2><A NAME="SEC34" HREF="flex_toc.html#TOC34">Reentrant C Scanners with Bison Pure Parsers</A></H2>
-
-<P>
-<A NAME="IDX261"></A>
-<A NAME="IDX262"></A>
-<A NAME="IDX263"></A>
-<A NAME="IDX264"></A>
-<A NAME="IDX265"></A>
-
-
-<P>
-This section describes the <CODE>flex</CODE> features useful when integrating
-<CODE>flex</CODE> with <CODE>GNU bison</CODE><A NAME="DOCF1" HREF="flex_foot.html#FOOT1">(1)</A>.
-Skip this section if you are not using
-<CODE>bison</CODE> with your scanner.  Here we discuss only the <CODE>flex</CODE>
-half of the <CODE>flex</CODE> and <CODE>bison</CODE> pair.  We do not discuss
-<CODE>bison</CODE> in any detail.  For more information about generating pure
-<CODE>bison</CODE> parsers, see section `Top' in <CITE>the GNU Bison Manual</CITE>.
-
-
-<P>
-A <CODE>bison</CODE>-compatible scanner is generated by declaring <SAMP>`%option
-reentrant-bison'</SAMP> or by supplying <SAMP>`--reentrant-bison'</SAMP> when invoking <CODE>flex</CODE>
-from the command line.  This instructs <CODE>flex</CODE> that the macros
-<CODE>yylval</CODE> and <CODE>yylloc</CODE> may be used. The data types for
-<CODE>yylval</CODE> and <CODE>yylloc</CODE>, (<CODE>YYSTYPE</CODE> and <CODE>YYLTYPE</CODE>,
-are typically defined in a header file, included in section 1 of the
-<CODE>flex</CODE> input file.  <CODE>%option reentrant-bison</CODE> implies
-<CODE>%option reentrant</CODE>.  If <CODE>%option reentrant-bison</CODE> is
-specified, <CODE>flex</CODE> provides support for the functions
-<CODE>yyget_lval</CODE>, <CODE>yyset_lval</CODE>, <CODE>yyget_lloc</CODE>, and
-<CODE>yyset_lloc</CODE>, defined below, and the corresponding macros
-<CODE>yylval</CODE> and <CODE>yylloc</CODE>, for use within actions.
-
-
-<P>
-<DL>
-<DT><U>Function:</U> YYSTYPE* <B>yyget_lval</B> <I>( yyscan_t scanner )</I>
-<DD><A NAME="IDX266"></A>
-</DL>
-<DL>
-<DT><U>Function:</U> YYLTYPE* <B>yyget_lloc</B> <I>( yyscan_t scanner )</I>
-<DD><A NAME="IDX267"></A>
-</DL>
-
-
-<P>
-<DL>
-<DT><U>Function:</U> void <B>yyset_lval</B> <I>( YYSTYPE* lvalp, yyscan_t scanner )</I>
-<DD><A NAME="IDX268"></A>
-</DL>
-<DL>
-<DT><U>Function:</U> void <B>yyset_lloc</B> <I>( YYLTYPE* llocp, yyscan_t scanner )</I>
-<DD><A NAME="IDX269"></A>
-</DL>
-
-
-<P>
-Accordingly, the declaration of yylex becomes one of the following:
-
-
-<P>
-<A NAME="IDX270"></A>
-
-<PRE>
-@verbatim
-      int yylex ( YYSTYPE * lvalp, yyscan_t scanner );
-      int yylex ( YYSTYPE * lvalp, YYLTYPE * llocp, yyscan_t scanner );
-</PRE>
-
-<P>
-Note that the macros <CODE>yylval</CODE> and <CODE>yylloc</CODE> evaluate to
-pointers.  Support for <CODE>yylloc</CODE> is optional in <CODE>bison</CODE>, so it
-is optional in <CODE>flex</CODE> as well. This support is automatically
-handled by <CODE>flex</CODE>.  Specifically, support for <CODE>yyloc</CODE> is only
-present in a <CODE>flex</CODE> scanner if the preprocessor symbol
-<CODE>YYLTYPE</CODE> is defined.  The following is an example of a <CODE>flex</CODE>
-scanner that is <CODE>bison</CODE>-compatible.
-
-
-<P>
-<A NAME="IDX271"></A>
-
-<PRE>
-@verbatim
-    /* Scanner for "C" assignment statements... sort of. */
-    %{
-    #include "y.tab.h"  /* Generated by bison. */
-    %}
-  
-    %option reentrant-bison
-    %
-   
-    [[:digit:]]+  { yylval-&#62;num = atoi(yytext);   return NUMBER;}
-    [[:alnum:]]+  { yylval-&#62;str = strdup(yytext); return STRING;}
-    "="|";"       { return yytext[0];}
-    .  {}
-    %
-</PRE>
-
-<P>
-As you can see, there really is no magic here. We just use
-<CODE>yylval</CODE> as we would any other variable. The data type of
-<CODE>yylval</CODE> is generated by <CODE>bison</CODE>, and included in the file
-<TT>`y.tab.h'</TT>. Here is the corresponding <CODE>bison</CODE> parser:
-
-
-<P>
-<A NAME="IDX272"></A>
-
-<PRE>
-@verbatim
-    /* Parser to convert "C" assignments to lisp. */
-    %{
-    /* Pass the argument to yyparse through to yylex. */
-    #define YYPARSE_PARAM scanner
-    #define YYLEX_PARAM   scanner
-    %}
-    %pure_parser
-    %union {
-        int num;
-        char* str;
-    }
-    %token &#60;str&#62; STRING
-    %token &#60;num&#62; NUMBER 
-    %%
-    assignment:
-        STRING '=' NUMBER ';' {
-            printf( "(setf %s %d)", $1, $3 );
-       }
-    ;
-</PRE>
-
-
-
-<H2><A NAME="SEC35" HREF="flex_toc.html#TOC35">Functions and Macros Available in Reentrant C Scanners</A></H2>
+<H2><A NAME="SEC41" HREF="flex_toc.html#TOC41">Functions and Macros Available in Reentrant C Scanners</A></H2>
 
 <P>
 The following Functions are available in a reentrant scanner:
 
 
 <P>
-<A NAME="IDX273"></A>
-<A NAME="IDX274"></A>
-<A NAME="IDX275"></A>
-<A NAME="IDX276"></A>
-<A NAME="IDX277"></A>
-<A NAME="IDX278"></A>
-<A NAME="IDX279"></A>
-<A NAME="IDX280"></A>
+<A NAME="IDX410"></A>
+<A NAME="IDX411"></A>
+<A NAME="IDX412"></A>
+<A NAME="IDX413"></A>
+<A NAME="IDX414"></A>
+<A NAME="IDX415"></A>
+<A NAME="IDX416"></A>
+<A NAME="IDX417"></A>
+<A NAME="IDX418"></A>
+<A NAME="IDX419"></A>
+<A NAME="IDX420"></A>
+<A NAME="IDX421"></A>
 
 
 
@@ -4489,7 +4663,9 @@
     FILE *yyget_out ( yyscan_t scanner );
     int yyget_lineno ( yyscan_t scanner );
     YY_EXTRA_TYPE yyget_extra ( yyscan_t scanner );
+    int  yyget_debug ( yyscan_t scanner );
 
+    void yyset_debug ( int flag, yyscan_t scanner );
     void yyset_in  ( FILE * in_str , yyscan_t scanner );
     void yyset_out  ( FILE * out_str , yyscan_t scanner );
     void yyset_lineno ( int line_number , yyscan_t scanner );
@@ -4514,10 +4690,11 @@
     yyout
     yylineno
     yyextra
+    yy_flex_debug
 </PRE>
 
 <P>
-<A NAME="IDX281"></A>
+<A NAME="IDX422"></A>
 In a reentrant C scanner, support for yylineno is always present
 (i.e., you may access yylineno), but the value is never modified by
 <CODE>flex</CODE> unless <CODE>%option yylineno</CODE> is enabled. This is to allow
@@ -4526,7 +4703,7 @@
 
 <P>
 The following functions and macros are made available when <CODE>%option
-reentrant-bison</CODE> (<SAMP>`--reentrant-bison'</SAMP>) is specified:
+bison-bridge</CODE> (<SAMP>`--bison-bridge'</SAMP>) is specified:
 
 
 
@@ -4550,11 +4727,11 @@
 
 
 
-<H1><A NAME="SEC36" HREF="flex_toc.html#TOC36">Incompatibilities with Lex and Posix</A></H1>
+<H1><A NAME="SEC42" HREF="flex_toc.html#TOC42">Incompatibilities with Lex and Posix</A></H1>
 
 <P>
-<A NAME="IDX282"></A>
-<A NAME="IDX283"></A>
+<A NAME="IDX423"></A>
+<A NAME="IDX424"></A>
 
 
 <P>
@@ -4622,7 +4799,7 @@
 which long-jumps out of the scanner, and the scanner is subsequently
 called again, you may get the following message:
 
-<A NAME="IDX284"></A>
+<A NAME="IDX425"></A>
 
 <PRE>
 @verbatim
@@ -4631,7 +4808,7 @@
 
 To reenter the scanner, first use:
 
-<A NAME="IDX285"></A>
+<A NAME="IDX426"></A>
 
 <PRE>
 @verbatim
@@ -4639,7 +4816,7 @@
 </PRE>
 
 Note that this call will throw away any buffered input; usually this
-isn't a problem with an interactive scanner. See section <A HREF="flex.html#SEC22">Reentrant C Scanners</A>, for
+isn't a problem with an interactive scanner. See section <A HREF="flex.html#SEC29">Reentrant C Scanners</A>, for
 <CODE>flex</CODE>'s reentrant API.
 
 <LI>
@@ -4647,7 +4824,7 @@
 Also note that <CODE>flex</CODE> C++ scanner classes
 <EM>are</EM>
 reentrant, so if using C++ is an option for you, you should use
-them instead.  See section <A HREF="flex.html#SEC21">Generating C++ Scanners</A>, and section <A HREF="flex.html#SEC22">Reentrant C Scanners</A>  for details.
+them instead.  See section <A HREF="flex.html#SEC28">Generating C++ Scanners</A>, and section <A HREF="flex.html#SEC29">Reentrant C Scanners</A>  for details.
 
 <LI>
 
@@ -4668,7 +4845,7 @@
 When definitions are expanded, <CODE>flex</CODE> encloses them in parentheses.
 With <CODE>lex</CODE>, the following:
 
-<A NAME="IDX286"></A>
+<A NAME="IDX427"></A>
 
 <PRE>
 @verbatim
@@ -4706,7 +4883,7 @@
 Some implementations of <CODE>lex</CODE> allow a rule's action to begin on a
 separate line, if the rule's pattern has trailing whitespace:
 
-<A NAME="IDX287"></A>
+<A NAME="IDX428"></A>
 
 <PRE>
 @verbatim
@@ -4756,48 +4933,88 @@
 
 The name <CODE>FLEX_SCANNER</CODE> is <CODE>#define</CODE>'d so scanners may be
 written for use with either <CODE>flex</CODE> or <CODE>lex</CODE>.  Scanners also
-include <CODE>YY_FLEX_MAJOR_VERSION</CODE> and <CODE>YY_FLEX_MINOR_VERSION</CODE>
-indicating which version of <CODE>flex</CODE> generated the scanner (for
-example, for the 2.5 release, these defines would be 2 and 5
-respectively).
+include <CODE>YY_FLEX_MAJOR_VERSION</CODE>,  <CODE>YY_FLEX_MINOR_VERSION</CODE>
+and <CODE>YY_FLEX_SUBMINOR_VERSION</CODE>
+indicating which version of <CODE>flex</CODE> generated the scanner. For
+example, for the 2.5.22 release, these defines would be 2,  5 and 22
+respectively. If the version of <CODE>flex</CODE> being used is a beta
+version, then the symbol <CODE>FLEX_BETA</CODE> is defined.
 </UL>
 
 <P>
-<A NAME="IDX288"></A>
-
-
-<P>
+<A NAME="IDX429"></A>
+<A NAME="IDX430"></A>
 The following <CODE>flex</CODE> features are not included in <CODE>lex</CODE> or the
 POSIX specification:
 
 
 
-<PRE>
-@verbatim
-    C++ scanners
-    %option
-    start condition scopes
-    start condition stacks
-    interactive/non-interactive scanners
-    yy_scan_string() and friends
-    yyterminate()
-    yy_set_interactive()
-    yy_set_bol()
-    YY_AT_BOL()
+<UL>
+<LI>
+
+C++ scanners
+<LI>
+
+%option
+<LI>
+
+start condition scopes
+<LI>
+
+start condition stacks
+<LI>
+
+interactive/non-interactive scanners
+<LI>
+
+yy_scan_string() and friends
+<LI>
+
+yyterminate()
+<LI>
+
+yy_set_interactive()
+<LI>
+
+yy_set_bol()
+<LI>
+
+YY_AT_BOL()
    &#60;&#60;EOF&#62;&#62;
-    &#60;*&#62;
-    YY_DECL
-    YY_START
-    YY_USER_ACTION
-    YY_USER_INIT
-    #line directives
-    %{}'s around actions
-    reentrant C API
-    multiple actions on a line
-</PRE>
+<LI>
+
+&#60;*&#62;
+<LI>
+
+YY_DECL
+<LI>
+
+YY_START
+<LI>
+
+YY_USER_ACTION
+<LI>
+
+YY_USER_INIT
+<LI>
+
+#line directives
+<LI>
+
+%{}'s around actions
+<LI>
+
+reentrant C API
+<LI>
+
+multiple actions on a line
+<LI>
+
+almost all of the <CODE>flex</CODE> command-line options
+</UL>
 
 <P>
-plus almost all of the <CODE>flex</CODE> flags.  The last feature in the list
+The feature "multiple actions on a line"
 refers to the fact that with <CODE>flex</CODE> you can put multiple actions on
 the same line, separated with semi-colons, while with <CODE>lex</CODE>, the
 following:
@@ -4826,11 +5043,577 @@
 
 
 
-<H1><A NAME="SEC37" HREF="flex_toc.html#TOC37">Diagnostics</A></H1>
+<H1><A NAME="SEC43" HREF="flex_toc.html#TOC43">Memory Management</A></H1>
 
 <P>
-<A NAME="IDX289"></A>
-<A NAME="IDX290"></A>
+<A NAME="IDX431"></A>
+@anchor{memory-management}
+This chapter describes how flex handles dynamic memory, and how you can
+override the default behavior.
+
+
+
+
+<H2><A NAME="SEC44" HREF="flex_toc.html#TOC44">The Default Memory Management</A></H2>
+
+<P>
+Flex allocates dynamic memory during initialization, and once in a while from
+within a call to yylex(). Initialization takes place during the first call to
+yylex(). Thereafter, flex may reallocate more memory if it needs to enlarge a
+buffer. As of version 2.5.9 Flex will clean up all memory when you call <CODE>yylex_destroy</CODE>
+@xref{faq-memory-leak}.
+
+
+<P>
+Flex allocates dynamic memory for four purposes, listed below <A NAME="DOCF1" HREF="flex_foot.html#FOOT1">(1)</A> 
+
+
+<DL COMPACT>
+
+<DT>16kB for the input buffer.
+<DD>
+Flex allocates memory for the character buffer used to perform pattern
+matching.  Flex must read ahead from the input stream and store it in a large
+character buffer.  This buffer is typically the largest chunk of dynamic memory
+flex consumes. This buffer will grow if necessary, doubling the size each time.
+Flex frees this memory when you call yylex_destroy().  The default size of this
+buffer (16384 bytes) is almost always too large.  The ideal size for this
+buffer is the length of the longest token expected.  Flex will allocate a few
+extra bytes for housekeeping.
+
+<DT>16kb for the REJECT state. This will only be allocated if you use REJECT.
+<DD>
+The size is the same as the input buffer, so if you override the size of the
+input buffer, then you automatically override the size of this buffer as well.
+
+<DT>100 bytes for the start condition stack.
+<DD>
+Flex allocates memory for the start condition stack. This is the stack used
+for pushing start states, i.e., with yy_push_state(). It will grow if
+necessary.  Since the states are simply integers, this stack doesn't consume
+much memory.  This stack is not present if <CODE>%option stack</CODE> is not
+specified.  You will rarely need to tune this buffer. The ideal size for this
+stack is the maximum depth expected.  The memory for this stack is
+automatically destroyed when you call yylex_destroy(). @xref{option-stack}.
+
+<DT>40 bytes for each YY_BUFFER_STATE.
+<DD>
+Flex allocates memory for each YY_BUFFER_STATE. The buffer state itself
+is about 40 bytes, plus an additional large character buffer (described above.)
+The initial buffer state is created during initialization, and with each call
+to yy_create_buffer(). You can't tune the size of this, but you can tune the
+character buffer as described above. Any buffer state that you explicitly
+create by calling yy_create_buffer() is <EM>NOT</EM> destroyed automatically. You
+must call yy_delete_buffer() to free the memory. The exception to this rule is
+that flex will delete the current buffer automatically when you call
+yylex_destroy(). If you delete the current buffer, be sure to set it to NULL.
+That way, flex will not try to delete the buffer a second time (possibly
+crashing your program!) At the time of this writing, flex does not provide a
+growable stack for the buffer states.  You have to manage that yourself.
+See section <A HREF="flex.html#SEC15">Multiple Input Buffers</A>.
+
+<DT>84 bytes for the reentrant scanner guts
+<DD>
+Flex allocates about 84 bytes for the reentrant scanner structure when
+you call yylex_init(). It is destroyed when the user calls yylex_destroy().
+
+</DL>
+
+
+
+<H2><A NAME="SEC45" HREF="flex_toc.html#TOC45">Overriding The Default Memory Management</A></H2>
+
+<P>
+<A NAME="IDX432"></A>
+<A NAME="IDX433"></A>
+<A NAME="IDX434"></A>
+
+
+<P>
+Flex calls the functions <CODE>yyalloc</CODE>, <CODE>yyrealloc</CODE>, and <CODE>yyfree</CODE>
+when it needs to allocate or free memory. By default, these functions are
+wrappers around the standard C functions, <CODE>malloc</CODE>, <CODE>realloc</CODE>, and
+<CODE>free</CODE>, respectively. You can override the default implementations by telling
+flex that you will provide your own implementations.
+
+
+<P>
+To override the default implementations, you must do two things:
+
+
+
+<OL>
+
+<LI>Suppress the default implementations by specifying one or more of the
+
+following options:
+
+
+<UL>
+<LI><CODE>%option noyyalloc</CODE>
+
+<A NAME="IDX435"></A>
+ 
+<LI><CODE>%option noyyrealloc</CODE>
+
+<LI><CODE>%option noyyfree</CODE>.
+
+</UL>
+
+<LI>Provide your own implementation of the following functions: <A NAME="DOCF2" HREF="flex_foot.html#FOOT2">(2)</A>
+
+
+<PRE>
+@verbatim
+// For a non-reentrant scanner
+void * yyalloc (size_t bytes);
+void * yyrealloc (void * ptr, size_t bytes);
+void   yyfree (void * ptr);
+
+// For a reentrant scanner
+void * yyalloc (size_t bytes, void * yyscanner);
+void * yyrealloc (void * ptr, size_t bytes, void * yyscanner);
+void   yyfree (void * ptr, void * yyscanner);
+</PRE>
+
+</OL>
+
+<P>
+In the following example, we will override all three memory routines. We assume
+that there is a custom allocator with garbage collection. In order to make this
+example interesting, we will use a reentrant scanner, passing a pointer to the
+custom allocator through <CODE>yyextra</CODE>.
+
+
+<P>
+<A NAME="IDX436"></A>
+
+<PRE>
+@verbatim
+%{
+#include "some_allocator.h"
+%}
+
+/* Suppress the default implementations. */
+%option noyyalloc noyyrealloc noyyfree
+%option reentrant
+
+/* Initialize the allocator. */
+#define YY_EXTRA_TYPE  struct allocator*
+#define YY_USER_INIT  yyextra = allocator_create();
+
+%%
+.|\n   ;
+%%
+
+/* Provide our own implementations. */
+void * yyalloc (size_t bytes, void* yyscanner) {
+    return allocator_alloc (yyextra, bytes);
+}
+
+void * yyrealloc (void * ptr, size_t bytes, void* yyscanner) {
+    return allocator_realloc (yyextra, bytes);
+}
+
+void yyfree (void * ptr, void * yyscanner) {      
+    /* Do nothing -- we leave it to the garbage collector. */
+}
+
+</PRE>
+
+
+
+<H2><A NAME="SEC46" HREF="flex_toc.html#TOC46">A Note About yytext And Memory</A></H2>
+
+<P>
+<A NAME="IDX437"></A>
+
+
+<P>
+When flex finds a match, <CODE>yytext</CODE> points to the first character of the
+match in the input buffer. The string itself is part of the input buffer, and
+is <EM>NOT</EM> allocated separately. The value of yytext will be overwritten the next
+time yylex() is called. In short, the value of yytext is only valid from within
+the matched rule's action.
+
+
+<P>
+Often, you want the value of yytext to persist for later processing, i.e., by a
+parser with non-zero lookahead. In order to preserve yytext, you will have to
+copy it with strdup() or a similar function. But this introduces some headache
+because your parser is now responsible for freeing the copy of yytext. If you
+use a yacc or bison parser, (commonly used with flex), you will discover that
+the error recovery mechanisms can cause memory to be leaked.
+
+
+<P>
+To prevent memory leaks from strdup'd yytext, you will have to track the memory
+somehow. Our experience has shown that a garbage collection mechanism or a
+pooled memory mechanism will save you a lot of grief when writing parsers.
+
+
+
+
+<H1><A NAME="SEC47" HREF="flex_toc.html#TOC47">Serialized Tables</A></H1>
+<P>
+<A NAME="IDX438"></A>
+<A NAME="IDX439"></A>
+
+
+<P>
+@anchor{serialization}
+A <CODE>flex</CODE> scanner has the ability to save the DFA tables to a file, and
+load them at runtime when needed.  The motivation for this feature is to reduce
+the runtime memory footprint.  Traditionally, these tables have been compiled into
+the scanner as C arrays, and are sometimes quite large.  Since the tables are
+compiled into the scanner, the memory used by the tables can never be freed.
+This is a waste of memory, especially if an application uses several scanners,
+but none of them at the same time.
+
+
+<P>
+The serialization feature allows the tables to be loaded at runtime, before
+scanning begins. The tables may be discarded when scanning is finished.
+
+
+
+
+<H2><A NAME="SEC48" HREF="flex_toc.html#TOC48">Creating Serialized Tables</A></H2>
+<P>
+<A NAME="IDX440"></A>
+<A NAME="IDX441"></A>
+
+
+<P>
+You may create a scanner with serialized tables by specifying:
+
+
+
+<PRE>
+@verbatim
+    %option tables-file=FILE
+or
+    --tables-file=FILE
+</PRE>
+
+<P>
+These options instruct flex to save the DFA tables to the file <VAR>FILE</VAR>. The tables
+will <EM>not</EM> be embedded in the generated scanner. The scanner will not
+function on its own. The scanner will be dependent upon the serialized tables. You must
+load the tables from this file at runtime before you can scan anything. 
+
+
+<P>
+If you do not specify a filename to <CODE>--tables-file</CODE>, the tables will be
+saved to <TT>`lex.yy.tables'</TT>, where <SAMP>`yy'</SAMP> is the appropriate prefix.
+
+
+<P>
+If your project uses several different scanners, you can concatenate the
+serialized tables into one file, and flex will find the correct set of tables,
+using the scanner prefix as part of the lookup key. An example follows:
+
+
+<P>
+<A NAME="IDX442"></A>
+
+<PRE>
+@verbatim
+$ flex --tables-file --prefix=cpp cpp.l
+$ flex --tables-file --prefix=c   c.l
+$ cat lex.cpp.tables lex.c.tables  &#62;  all.tables
+</PRE>
+
+<P>
+The above example created two scanners, <SAMP>`cpp'</SAMP>, and <SAMP>`c'</SAMP>. Since we did
+not specify a filename, the tables were serialized to <TT>`lex.c.tables'</TT> and
+<TT>`lex.cpp.tables'</TT>, respectively. Then, we concatenated the two files
+together into <TT>`all.tables'</TT>, which we will distribute with our project. At
+runtime, we will open the file and tell flex to load the tables from it.  Flex
+will find the correct tables automatically. (See next section).
+
+
+
+
+<H2><A NAME="SEC49" HREF="flex_toc.html#TOC49">Loading and Unloading Serialized Tables</A></H2>
+<P>
+<A NAME="IDX443"></A>
+<A NAME="IDX444"></A>
+<A NAME="IDX445"></A>
+<A NAME="IDX446"></A>
+<A NAME="IDX447"></A>
+
+
+<P>
+If you've built your scanner with <CODE>%option tables-file</CODE>, then you must
+load the scanner tables at runtime. This can be accomplished with the following
+function:
+
+
+<P>
+<DL>
+<DT><U>Function:</U> int <B>yytables_fload</B> <I>(FILE* <VAR>fp</VAR> [, yyscan_t <VAR>scanner</VAR>])</I>
+<DD><A NAME="IDX448"></A>
+Locates scanner tables in the stream pointed to by <VAR>fp</VAR> and loads them.
+Memory for the tables is allocated via <CODE>yyalloc</CODE>.  You must call this
+function before the first call to <CODE>yylex</CODE>. The argument <VAR>scanner</VAR>
+only appears in the reentrant scanner.
+This function returns <SAMP>`0'</SAMP> (zero) on success, or non-zero on error.
+</DL>
+
+
+<P>
+The loaded tables are <STRONG>not</STRONG> automatically destroyed (unloaded) when you
+call <CODE>yylex_destroy</CODE>. The reason is that you may create several scanners
+of the same type (in a reentrant scanner), each of which needs access to these
+tables.  To avoid a nasty memory leak, you must call the following function:
+
+
+<P>
+<DL>
+<DT><U>Function:</U> int <B>yytables_destroy</B> <I>([yyscan_t <VAR>scanner</VAR>])</I>
+<DD><A NAME="IDX449"></A>
+Unloads the scanner tables. The tables must be loaded again before you can scan
+any more data.  The argument <VAR>scanner</VAR> only appears in the reentrant
+scanner.  This function returns <SAMP>`0'</SAMP> (zero) on success, or non-zero on
+error.
+</DL>
+
+
+<P>
+<STRONG>The functions <CODE>yytables_fload</CODE> and <CODE>yytables_destroy</CODE> are not
+thread-safe.</STRONG> You must ensure that these functions are called exactly once (for
+each scanner type) in a threaded program, before any thread calls <CODE>yylex</CODE>.
+After the tables are loaded, they are never written to, and no thread
+protection is required thereafter -- until you destroy them.
+
+
+
+
+<H2><A NAME="SEC50" HREF="flex_toc.html#TOC50">Tables File Format</A></H2>
+<P>
+<A NAME="IDX450"></A>
+<A NAME="IDX451"></A>
+
+
+<P>
+This section defines the file format of serialized <CODE>flex</CODE> tables.
+
+
+<P>
+The tables format allows for one or more sets of tables to be
+specified, where each set corresponds to a given scanner. Scanners are
+indexed by name, as described below. The file format is as follows:
+
+
+
+<PRE>
+@verbatim
+                 TABLE SET 1
+                +-------------------------------+
+        Header  | uint32          th_magic;     |
+                | uint32          th_hsize;     |
+                | uint32          th_ssize;     |
+                | uint16          th_flags;     |
+                | char            th_version[]; |
+                | char            th_name[];    |
+                | uint8           th_pad64[];   |
+                +-------------------------------+
+        Table 1 | uint16          td_id;        |
+                | uint16          td_flags;     |
+                | uint32          td_lolen;     |
+                | uint32          td_hilen;     |
+                | void            td_data[];    |
+                | uint8           td_pad64[];   |
+                +-------------------------------+
+        Table 2 |                               |
+           .    .                               .
+           .    .                               .
+           .    .                               .
+           .    .                               .
+        Table n |                               |
+                +-------------------------------+
+                 TABLE SET 2
+                      .
+                      .
+                      .
+                 TABLE SET N
+</PRE>
+
+<P>
+The above diagram shows that a complete set of tables consists of a header
+followed by multiple individual tables. Furthermore, multiple complete sets may
+be present in the same file, each set with its own header and tables. The sets
+are contiguous in the file. The only way to know if another set follows is to
+check the next four bytes for the magic number (or check for EOF). The header
+and tables sections are padded to 64-bit boundaries. Below we describe each
+field in detail. This format does not specify how the scanner will expand the
+given data, i.e., data may be serialized as int8, but expanded to an int32
+array at runtime. This is to reduce the size of the serialized data where
+possible.  Remember, <EM>all integer values are in network byte order</EM>. 
+
+
+<P>
+Fields of a table header:
+
+
+<DL COMPACT>
+
+<DT><CODE>th_magic</CODE>
+<DD>
+Magic number, always 0xF13C57B1.
+
+<DT><CODE>th_hsize</CODE>
+<DD>
+Size of this entire header, in bytes, including all fields plus any padding.
+
+<DT><CODE>th_ssize</CODE>
+<DD>
+Size of this entire set, in bytes, including the header, all tables, plus
+any padding.
+
+<DT><CODE>th_flags</CODE>
+<DD>
+Bit flags for this table set. Currently unused.
+
+<DT><CODE>th_version[]</CODE>
+<DD>
+Flex version in NULL-termninated string format. e.g., <SAMP>`2.5.13a'</SAMP>. This is
+the version of flex that was used to create the serialized tables.
+
+<DT><CODE>th_name[]</CODE>
+<DD>
+Contains the name of this table set. The default is <SAMP>`yytables'</SAMP>,
+and is prefixed accordingly, e.g., <SAMP>`footables'</SAMP>. Must be NULL-terminated.
+
+<DT><CODE>th_pad64[]</CODE>
+<DD>
+Zero or more NULL bytes, padding the entire header to the next 64-bit boundary
+as calculated from the beginning of the header.
+</DL>
+
+<P>
+Fields of a table:
+
+
+<DL COMPACT>
+
+<DT><CODE>td_id</CODE>
+<DD>
+Specifies the table identifier. Possible values are:
+<DL COMPACT>
+
+<DT><CODE>YYTD_ID_ACCEPT (0x01)</CODE>
+<DD>
+<CODE>yy_accept</CODE>
+<DT><CODE>YYTD_ID_BASE   (0x02)</CODE>
+<DD>
+<CODE>yy_base</CODE>
+<DT><CODE>YYTD_ID_CHK    (0x03)</CODE>
+<DD>
+<CODE>yy_chk</CODE>
+<DT><CODE>YYTD_ID_DEF    (0x04)</CODE>
+<DD>
+<CODE>yy_def</CODE>
+<DT><CODE>YYTD_ID_EC     (0x05)</CODE>
+<DD>
+<CODE>yy_ec </CODE>
+<DT><CODE>YYTD_ID_META   (0x06)</CODE>
+<DD>
+<CODE>yy_meta</CODE>
+<DT><CODE>YYTD_ID_NUL_TRANS (0x07)</CODE>
+<DD>
+<CODE>yy_NUL_trans</CODE>
+<DT><CODE>YYTD_ID_NXT (0x08)</CODE>
+<DD>
+<CODE>yy_nxt</CODE>. This array may be two dimensional. See the <CODE>td_hilen</CODE>
+field below.
+<DT><CODE>YYTD_ID_RULE_CAN_MATCH_EOL (0x09)</CODE>
+<DD>
+<CODE>yy_rule_can_match_eol</CODE>
+<DT><CODE>YYTD_ID_START_STATE_LIST (0x0A)</CODE>
+<DD>
+<CODE>yy_start_state_list</CODE>. This array is handled specially because it is an
+array of pointers to structs. See the <CODE>td_flags</CODE> field below.
+<DT><CODE>YYTD_ID_TRANSITION (0x0B)</CODE>
+<DD>
+<CODE>yy_transition</CODE>. This array is handled specially because it is an array of
+structs. See the <CODE>td_lolen</CODE> field below.
+<DT><CODE>YYTD_ID_ACCLIST (0x0C)</CODE>
+<DD>
+<CODE>yy_acclist</CODE>
+</DL>
+
+<DT><CODE>td_flags</CODE>
+<DD>
+Bit flags describing how to interpret the data in <CODE>td_data</CODE>.
+The data arrays are one-dimensional by default, but may be
+two dimensional as specified in the <CODE>td_hilen</CODE> field.
+
+<DL COMPACT>
+
+<DT><CODE>YYTD_DATA8 (0x01)</CODE>
+<DD>
+The data is serialized as an array of type int8.
+<DT><CODE>YYTD_DATA16 (0x02)</CODE>
+<DD>
+The data is serialized as an array of type int16.
+<DT><CODE>YYTD_DATA32 (0x04)</CODE>
+<DD>
+The data is serialized as an array of type int32.
+<DT><CODE>YYTD_PTRANS (0x08)</CODE>
+<DD>
+The data is a list of indexes of entries in the expanded <CODE>yy_transition</CODE>
+array.  Each index should be expanded to a pointer to the corresponding entry
+in the <CODE>yy_transition</CODE> array. We count on the fact that the
+<CODE>yy_transition</CODE> array has already been seen.
+<DT><CODE>YYTD_STRUCT (0x10)</CODE>
+<DD>
+The data is a list of yy_trans_info structs, each of which consists of
+two integers. There is no padding between struct elements or between structs.
+The type of each member is determined by the <CODE>YYTD_DATA*</CODE> bits.
+</DL>
+
+<DT><CODE>td_lolen</CODE>
+<DD>
+Specifies the number of elements in the lowest dimension array. If this is
+a one-dimensional array, then it is simply the number of elements in this array.
+The element size is determined by the <CODE>td_flags</CODE> field.
+
+<DT><CODE>td_hilen</CODE>
+<DD>
+If <CODE>td_hilen</CODE> is non-zero, then the data is a two-dimensional array.
+Otherwise, the data is a one-dimensional array. <CODE>td_hilen</CODE> contains the
+number of elements in the higher dimensional array, and <CODE>td_lolen</CODE> contains
+the number of elements in the lowest dimension.
+
+Conceptually, <CODE>td_data</CODE> is either <CODE>sometype td_data[td_lolen]</CODE>, or
+<CODE>sometype td_data[td_hilen][td_lolen]</CODE>, where <CODE>sometype</CODE> is specified
+by the <CODE>td_flags</CODE> field.  It is possible for both <CODE>td_lolen</CODE> and
+<CODE>td_hilen</CODE> to be zero, in which case <CODE>td_data</CODE> is a zero length
+array, and no data is loaded, i.e., this table is simply skipped. Flex does not
+currently generate tables of zero length.
+
+<DT><CODE>td_data[]</CODE>
+<DD>
+The table data. This array may be a one- or two-dimensional array, of type
+<CODE>int8</CODE>, <CODE>int16</CODE>, <CODE>int32</CODE>, <CODE>struct yy_trans_info</CODE>, or
+<CODE>struct yy_trans_info*</CODE>,  depending upon the values in the
+<CODE>td_flags</CODE>, <CODE>td_lolen</CODE>, and <CODE>td_hilen</CODE> fields.
+
+<DT><CODE>td_pad64[]</CODE>
+<DD>
+Zero or more NULL bytes, padding the entire table to the next 64-bit boundary as
+calculated from the beginning of this table.
+</DL>
+
+
+
+<H1><A NAME="SEC51" HREF="flex_toc.html#TOC51">Diagnostics</A></H1>
+
+<P>
+<A NAME="IDX452"></A>
+<A NAME="IDX453"></A>
 
 
 <P>
@@ -4846,7 +5629,7 @@
 the same text as it.  For example, in the following <SAMP>`foo'</SAMP> cannot be
 matched because it comes after an identifier "catch-all" rule:
 
-<A NAME="IDX291"></A>
+<A NAME="IDX454"></A>
 
 <PRE>
 @verbatim
@@ -4862,7 +5645,7 @@
 that it is possible (perhaps only in a particular start condition) that
 the default rule (match any single character) is the only one that will
 match a particular input.  Since <SAMP>`-s'</SAMP> was given, presumably this is
-not intended.  
+not intended.
 
 <LI>
 
@@ -4896,7 +5679,7 @@
 specification includes recognizing the 8-bit character <SAMP>`'x''</SAMP> and
 you did not specify the -8 flag, and your scanner defaulted to 7-bit
 because you used the <SAMP>`-Cf'</SAMP> or <SAMP>`-CF'</SAMP> table compression options.
-See the discussion of the <SAMP>`-7'</SAMP> flag, section <A HREF="flex.html#SEC18">Invoking Flex</A>, for
+See the discussion of the <SAMP>`-7'</SAMP> flag, section <A HREF="flex.html#SEC20">Scanner Options</A>, for
 details.
 
 <LI>
@@ -4937,10 +5720,10 @@
 
 
 
-<H1><A NAME="SEC38" HREF="flex_toc.html#TOC38">Limitations</A></H1>
+<H1><A NAME="SEC52" HREF="flex_toc.html#TOC52">Limitations</A></H1>
 
 <P>
-<A NAME="IDX292"></A>
+<A NAME="IDX455"></A>
 
 
 <P>
@@ -4960,7 +5743,7 @@
 
 
 <P>
-<A NAME="IDX293"></A>
+<A NAME="IDX456"></A>
 
 <PRE>
 @verbatim
@@ -4992,7 +5775,7 @@
 
 
 
-<H1><A NAME="SEC39" HREF="flex_toc.html#TOC39">Additional Reading</A></H1>
+<H1><A NAME="SEC53" HREF="flex_toc.html#TOC53">Additional Reading</A></H1>
 
 <P>
 You may wish to read more about the following programs:
@@ -5032,107 +5815,28 @@
 
 
 
-<H1><A NAME="SEC40" HREF="flex_toc.html#TOC40">Copyright</A></H1>
-
-<P>
-<A NAME="IDX294"></A>
-<A NAME="IDX295"></A>
-
-
-<P>
-The flex manual is placed under the same licensing conditions as the
-rest of flex:
-
-
-<P>
-Copyright (C) 1990, 1997 The Regents of the University of California.
-All rights reserved.
-
+<H1><A NAME="SEC54" HREF="flex_toc.html#TOC54">FAQ</A></H1>
 
 <P>
-This code is derived from software contributed to Berkeley by
-Vern Paxson.
-
+From time to time, the <CODE>flex</CODE> maintainer receives certain
+questions. Rather than repeat answers to well-understood problems, we
+publish them here.
 
-<P>
-The United States Government has rights in this work pursuant
-to contract no. DE-AC03-76SF00098 between the United States
-Department of Energy and the University of California.
 
 
-<P>
-Redistribution and use in source and binary forms, with or without
-modification, are permitted provided that the following conditions
-are met:
-
-
-
-<OL>
-<LI>
-
-Redistributions of source code must retain the above copyright
-notice, this list of conditions and the following disclaimer.
-
-<LI>
-
-Redistributions in binary form must reproduce the above copyright
-notice, this list of conditions and the following disclaimer in the
-documentation and/or other materials provided with the distribution.
-</OL>
-
-<P>
-Neither the name of the University nor the names of its contributors
-may be used to endorse or promote products derived from this software
-without specific prior written permission.
-
-
-<P>
-THIS SOFTWARE IS PROVIDED "AS IS" AND WITHOUT ANY EXPRESS OR
-IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
-WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
-PURPOSE.
-
-
-
-
-<H1><A NAME="SEC41" HREF="flex_toc.html#TOC41">Reporting Bugs</A></H1>
-
-<P>
-<A NAME="IDX296"></A>
-
-
-<P>
-If you have problems with <CODE>flex</CODE> or think you have found a bug,
-please send mail detailing your problem to
-<A HREF="mailto:help-flex@gnu.org">help-flex@gnu.org</A>. Patches are always welcome.
-
-
-
-
-<H1><A NAME="SEC42" HREF="flex_toc.html#TOC42">FAQ</A></H1>
-
-
-
-<H2><A NAME="SEC43" HREF="flex_toc.html#TOC43">When was flex born?</A></H2>
-
-<P>
-When was flex born?
 
+<H2><A NAME="SEC55" HREF="flex_toc.html#TOC55">When was flex born?</A></H2>
 
 <P>
 Vern Paxson took over
-the Software Tools lex project from Jef Poskanzer in 1982.  At that point it
+the <CITE>Software Tools</CITE> lex project from Jef Poskanzer in 1982.  At that point it
 was written in Ratfor.  Around 1987 or so, Paxson translated it into C, and
 a legend was born :-).
 
 
 
 
-<H2><A NAME="SEC44" HREF="flex_toc.html#TOC44">How do I expand \ escape sequences in C-style quoted strings?</A></H2>
-
-<P>
-How do I expand \ escape sequences in C-style quoted strings?
-
+<H2><A NAME="SEC56" HREF="flex_toc.html#TOC56">How do I expand \ escape sequences in C-style quoted strings?</A></H2>
 
 <P>
 A key point when scanning quoted strings is that you cannot (easily) write
@@ -5143,41 +5847,36 @@
 
 
 <P>
-Instead you use exclusive start conditions and a set of rules, one for
+Instead you can use exclusive start conditions and a set of rules, one for
 matching non-escaped text, one for matching a single escape, one for
 matching an embedded newline, and one for recognizing the end of the
 string.  Each of these rules is then faced with the question of where to
 put its intermediary results.  The best solution is for the rules to
-append their local value of yytext to the end of a "string literal"
+append their local value of <CODE>yytext</CODE> to the end of a "string literal"
 buffer.  A rule like the escape-matcher will append to the buffer the
-meaning of the escape sequence rather than the literal text in yytext.
-In this way, yytext does not need to be modified at all.
+meaning of the escape sequence rather than the literal text in <CODE>yytext</CODE>.
+In this way, <CODE>yytext</CODE> does not need to be modified at all.
 
 
 
 
-<H2><A NAME="SEC45" HREF="flex_toc.html#TOC45">Why do flex scanners call fileno if it is not ANSI compatible?</A></H2>
+<H2><A NAME="SEC57" HREF="flex_toc.html#TOC57">Why do flex scanners call fileno if it is not ANSI compatible?</A></H2>
 
 <P>
-Why do flex scanners call fileno if it is not ANSI compatible?
+Flex scanners call <CODE>fileno()</CODE> in order to get the file descriptor
+corresponding to <CODE>yyin</CODE>. The file descriptor may be passed to
+<CODE>isatty()</CODE> or <CODE>read()</CODE>, depending upon which <CODE>%options</CODE> you specified.
+If your system does not have <CODE>fileno()</CODE> support, to get rid of the
+<CODE>read()</CODE> call, do not specify <CODE>%option read</CODE>. To get rid of the <CODE>isatty()</CODE>
+call, you must specify one of <CODE>%option always-interactive</CODE> or
+<CODE>%option never-interactive</CODE>.
 
 
-<P>
-Flex scanners call fileno() in order to get the file descriptor
-corresponding to yyin. The file descriptor may be passed to
-isatty() or read(), depending upon which %options you specified.
-If your system does not have fileno() support. To get rid of the
-read() call, do not specify %option read. To get rid of the isatty()
-call, you must specify one of %option always-interactive or 
-%option never-interactive.
 
 
-
-
-<H2><A NAME="SEC46" HREF="flex_toc.html#TOC46">Does flex support recursive pattern definitions?</A></H2>
+<H2><A NAME="SEC58" HREF="flex_toc.html#TOC58">Does flex support recursive pattern definitions?</A></H2>
 
 <P>
-Does flex support recursive pattern definitions?
 e.g.,
 
 
@@ -5189,39 +5888,31 @@
 </PRE>
 
 <P>
-No. You cannot have recursive definitions.  The pattern-matching power of 
+No. You cannot have recursive definitions.  The pattern-matching power of
 regular expressions in general (and therefore flex scanners, too) is
 limited.  In particular, regular expressions cannot "balance" parentheses
 to an arbitrary degree.  For example, it's impossible to write a regular
 expression that matches all strings containing the same number of '{'s
 as '}'s.  For more powerful pattern matching, you need a parser, such
-as GNU bison. 
-
+as <CITE>GNU bison</CITE>.
 
 
 
-<H2><A NAME="SEC47" HREF="flex_toc.html#TOC47">How do skip huge chunks of input (tens of megabytes) while using flex?</A></H2>
-
-<P>
-How do skip huge chunks of input (tens of megabytes) while using flex?
 
+<H2><A NAME="SEC59" HREF="flex_toc.html#TOC59">How do I skip huge chunks of input (tens of megabytes) while using flex?</A></H2>
 
 <P>
-Use fseek (or lseek) to position yyin, then call yyrestart().
+Use <CODE>fseek()</CODE> (or <CODE>lseek()</CODE>) to position yyin, then call <CODE>yyrestart()</CODE>.
 
 
 
 
-<H2><A NAME="SEC48" HREF="flex_toc.html#TOC48">Flex is not matching my patterns in the same order that I defined them.</A></H2>
+<H2><A NAME="SEC60" HREF="flex_toc.html#TOC60">Flex is not matching my patterns in the same order that I defined them.</A></H2>
 
 <P>
-Flex is not matching my patterns in the same order that I defined them.
-
-
-<P>
-This is indeed the natural way to expect it to work, however, flex picks the
+<CODE>flex</CODE> picks the
 rule that matches the most text (i.e., the longest possible input string).
-This is because flex uses an entirely different matching technique
+This is because <CODE>flex</CODE> uses an entirely different matching technique
 ("deterministic finite automata") that actually does all of the matching
 simultaneously, in parallel.  (Seems impossible, but it's actually a fairly
 simple technique once you understand the principles.)
@@ -5229,13 +5920,12 @@
 
 <P>
 A side-effect of this parallel matching is that when the input matches more
-than one rule, flex scanners pick the rule that matched the *most* text. This
-is explained further in the manual, in the section "How the input
-is Matched".
+than one rule, <CODE>flex</CODE> scanners pick the rule that matched the <EM>most</EM> text. This
+is explained further in the manual, in the section See section <A HREF="flex.html#SEC11">How the Input Is Matched</A>.
 
 
 <P>
-If you want flex to choose a shorter match, then you can work around this
+If you want <CODE>flex</CODE> to choose a shorter match, then you can work around this
 behavior by expanding your short
 rule to match more text, then put back the extra:
 
@@ -5248,26 +5938,21 @@
 
 <P>
 Another fix would be to make the second rule active only during the
-&#60;BLOCKIDSTATE&#62; start condition, and make that start condition exclusive
-by declaring it with %x instead of %s.
+<CODE>&#60;BLOCKIDSTATE&#62;</CODE> start condition, and make that start condition exclusive
+by declaring it with <CODE>%x</CODE> instead of <CODE>%s</CODE>.
 
 
 <P>
 A final fix is to change the input language so that the ambiguity for
-data_ is removed, by adding characters to it that don't match the
-identifier rule, or by removing characters (such as '_') from the
-identifier rule so it no longer matches "data_".  (Of course, you might
-also not have the option of changing the input language ...)
-
+<SAMP>`data_'</SAMP> is removed, by adding characters to it that don't match the
+identifier rule, or by removing characters (such as <SAMP>`_'</SAMP>) from the
+identifier rule so it no longer matches <SAMP>`data_'</SAMP>.  (Of course, you might
+also not have the option of changing the input language.)
 
 
 
-<H2><A NAME="SEC49" HREF="flex_toc.html#TOC49">My actions are executing out of order or sometimes not at all.</A></H2>
-
-<P>
-My actions are executing out of order or sometimes not at all. What's
-happening?
 
+<H2><A NAME="SEC61" HREF="flex_toc.html#TOC61">My actions are executing out of order or sometimes not at all.</A></H2>
 
 <P>
 Most likely, you have (in error) placed the opening <SAMP>`{'</SAMP> of the action
@@ -5278,13 +5963,13 @@
 <PRE>
 @verbatim
 ^(foo|bar)
-   {  &#60;&#60;&#60;--- WRONG!
+{  &#60;&#60;&#60;--- WRONG!
 
-   }
+}
 </PRE>
 
 <P>
-flex requires that the opening <SAMP>`{'</SAMP> of an action associated with a rule
+<CODE>flex</CODE> requires that the opening <SAMP>`{'</SAMP> of an action associated with a rule
 begin on the same line as does the rule.  You need instead to write your rules
 as follows:
 
@@ -5294,79 +5979,70 @@
 @verbatim
 ^(foo|bar)   {  // CORRECT!
 
-    }
+}
 </PRE>
 
 
 
-<H2><A NAME="SEC50" HREF="flex_toc.html#TOC50">How can I have multiple input sources feed into the same scanner at the same time?</A></H2>
-
-<P>
-How can I have multiple input sources feed into the same scanner at
-the same time?
-
+<H2><A NAME="SEC62" HREF="flex_toc.html#TOC62">How can I have multiple input sources feed into the same scanner at the same time?</A></H2>
 
 <P>
-If...
+If ...
 
 <UL>
 <LI>
 
-your scanner is free of backtracking (verified using flex's -b flag),
+your scanner is free of backtracking (verified using <CODE>flex</CODE>'s <SAMP>`-b'</SAMP> flag),
 <LI>
 
-AND you run it interactively (-I option; default unless using special table
+AND you run your scanner interactively (<SAMP>`-I'</SAMP> option; default unless using special table
 compression options),
 <LI>
 
-AND you feed it one character at a time by redefining YY_INPUT to do so,
+AND you feed it one character at a time by redefining <CODE>YY_INPUT</CODE> to do so,
 </UL>
 
 <P>
 then every time it matches a token, it will have exhausted its input
 buffer (because the scanner is free of backtracking).  This means you
-can safely use select() at the point and only call yylex() for another
-token if select() indicates there's data available.
+can safely use <CODE>select()</CODE> at the point and only call <CODE>yylex()</CODE> for another
+token if <CODE>select()</CODE> indicates there's data available.
 
 
 <P>
-That is, move the select() out from the input function to a point where
-it determines whether yylex() gets called for the next token.
+That is, move the <CODE>select()</CODE> out from the input function to a point where
+it determines whether <CODE>yylex()</CODE> gets called for the next token.
 
 
 <P>
 With this approach, you will still have problems if your input can arrive
-piecemeal; select() could inform you that the beginning of a token is
-available, you call yylex() to get it, but it winds up blocking waiting
+piecemeal; <CODE>select()</CODE> could inform you that the beginning of a token is
+available, you call <CODE>yylex()</CODE> to get it, but it winds up blocking waiting
 for the later characters in the token.
 
 
 <P>
-Here's another way:  Move your input multiplexing inside of YY_INPUT.  That
-is, whenever YY_INPUT is called, it select()'s to see where input is
+Here's another way:  Move your input multiplexing inside of <CODE>YY_INPUT</CODE>.  That
+is, whenever <CODE>YY_INPUT</CODE> is called, it <CODE>select()</CODE>'s to see where input is
 available.  If input is available for the scanner, it reads and returns the
 next byte.  If input is available from another source, it calls whatever
 function is responsible for reading from that source.  (If no input is
-available, it blocks until some is.)  I've used this technique in an
-interpreter I wrote that both reads keyboard input using a flex scanner and
+available, it blocks until some input is available.)  I've used this technique in an
+interpreter I wrote that both reads keyboard input using a <CODE>flex</CODE> scanner and
 IPC traffic from sockets, and it works fine.
 
 
 
 
-<H2><A NAME="SEC51" HREF="flex_toc.html#TOC51">Can I build nested parsers that work with the same input file?</A></H2>
-
-<P>
-Can I build nested parsers that work with the same input file?
-
+<H2><A NAME="SEC63" HREF="flex_toc.html#TOC63">Can I build nested parsers that work with the same input file?</A></H2>
 
 <P>
 This is not going to work without some additional effort.  The reason is
-that flex block-buffers the input it reads from yyin.  This means that the
-"outermost" yylex(), when called, will automatically slurp up the first 8K
-of input available on yyin, and subsequent calls to other yylex()'s won't
+that <CODE>flex</CODE> block-buffers the input it reads from <CODE>yyin</CODE>.  This means that the
+"outermost" <CODE>yylex()</CODE>, when called, will automatically slurp up the first 8K
+of input available on yyin, and subsequent calls to other <CODE>yylex()</CODE>'s won't
 see that input.  You might be tempted to work around this problem by
-redefining YY_INPUT to only return a small amount of text, but it turns out
+redefining <CODE>YY_INPUT</CODE> to only return a small amount of text, but it turns out
 that that approach is quite difficult.  Instead, the best solution is to
 combine all of your scanners into one large scanner, using a different
 exclusive start condition for each.
@@ -5374,19 +6050,15 @@
 
 
 
-<H2><A NAME="SEC52" HREF="flex_toc.html#TOC52">How can I match text only at the end of a file?</A></H2>
-
-<P>
-How can I match text only at the end of a file?
-
+<H2><A NAME="SEC64" HREF="flex_toc.html#TOC64">How can I match text only at the end of a file?</A></H2>
 
 <P>
 There is no way to write a rule which is "match this text, but only if
 it comes at the end of the file".  You can fake it, though, if you happen
 to have a character lying around that you don't allow in your input.
-Then you redefine YY_INPUT to call your own routine which, if it sees
-an EOF, returns the magic character first (and remembers to return a
-real EOF next time it's called).  Then you could write:
+Then you redefine <CODE>YY_INPUT</CODE> to call your own routine which, if it sees
+an <SAMP>`EOF'</SAMP>, returns the magic character first (and remembers to return a
+real <CODE>EOF</CODE> next time it's called).  Then you could write:
 
 
 
@@ -5397,16 +6069,12 @@
 
 
 
-<H2><A NAME="SEC53" HREF="flex_toc.html#TOC53">How can I make REJECT cascade across start condition boundaries?</A></H2>
-
-<P>
-How can I make REJECT cascade across start condition boundaries?
-
+<H2><A NAME="SEC65" HREF="flex_toc.html#TOC65">How can I make REJECT cascade across start condition boundaries?</A></H2>
 
 <P>
-You can do this as follows.  Suppose you have a start condition A, and
-after exhausting all of the possible matches in &#60;A&#62;, you want to try
-matches in &#60;INITIAL&#62;.  Then you could use the following:
+You can do this as follows.  Suppose you have a start condition <SAMP>`A'</SAMP>, and
+after exhausting all of the possible matches in <SAMP>`&#60;A&#62;'</SAMP>, you want to try
+matches in <SAMP>`&#60;INITIAL&#62;'</SAMP>.  Then you could use the following:
 
 
 
@@ -5419,29 +6087,25 @@
 &#60;A&#62;etc.
 ...
 &#60;A&#62;.|\n  {
-            /* Shortest and last rule in &#60;A&#62;, so
-             * cascaded REJECT's will eventually
-             * wind up matching this rule.  We want
-             * to now switch to the initial state
-             * and try matching from there instead.
-             */
-            yyless(0);    /* put back matched text */
-            BEGIN(INITIAL);
-         }
+/* Shortest and last rule in &#60;A&#62;, so
+* cascaded REJECT's will eventually
+* wind up matching this rule.  We want
+* to now switch to the initial state
+* and try matching from there instead.
+*/
+yyless(0);    /* put back matched text */
+BEGIN(INITIAL);
+}
 </PRE>
 
 
 
-<H2><A NAME="SEC54" HREF="flex_toc.html#TOC54">Why can't I use fast or full tables with interactive mode?</A></H2>
-
-<P>
-Why can't I use fast or full tables with interactive mode?
-
+<H2><A NAME="SEC66" HREF="flex_toc.html#TOC66">Why can't I use fast or full tables with interactive mode?</A></H2>
 
 <P>
 One of the assumptions
-flex makes is that interactive applications are inherently slow (for just
-that reason, they're waiting on a human).  
+flex makes is that interactive applications are inherently slow (they're
+waiting on a human after all).
 It has to do with how the scanner detects that it must be finished scanning
 a token.  For interactive scanners, after scanning each character the current
 state is looked up in a table (essentially) to see whether there's a chance
@@ -5456,16 +6120,12 @@
 Still, it seems reasonable to allow the user to choose to trade off a bit
 of performance in this area to gain the corresponding flexibility.  There
 might be another reason, though, why fast scanners don't support the
-interactive option 
+interactive option.
 
 
 
 
-<H2><A NAME="SEC55" HREF="flex_toc.html#TOC55">How much faster is -F or -f than -C?</A></H2>
-
-<P>
-How much faster is -F or -f than -C?
-
+<H2><A NAME="SEC67" HREF="flex_toc.html#TOC67">How much faster is -F or -f than -C?</A></H2>
 
 <P>
 Much faster (factor of 2-3).
@@ -5473,11 +6133,7 @@
 
 
 
-<H2><A NAME="SEC56" HREF="flex_toc.html#TOC56">If I have a simple grammar can't I just parse it with flex?</A></H2>
-
-<P>
-If I have a simple grammar, can't I just parse it with flex?
-
+<H2><A NAME="SEC68" HREF="flex_toc.html#TOC68">If I have a simple grammar can't I just parse it with flex?</A></H2>
 
 <P>
 Is your grammar recursive? That's almost always a sign that you're
@@ -5485,26 +6141,20 @@
 alone.
 
 
-<H2><A NAME="SEC57" HREF="flex_toc.html#TOC57">Why doesn't yyrestart() set the start state back to INITIAL?</A></H2>
 
-<P>
-Why doesn't yyrestart() set the start state back to INITIAL?
 
+<H2><A NAME="SEC69" HREF="flex_toc.html#TOC69">Why doesn't yyrestart() set the start state back to INITIAL?</A></H2>
 
 <P>
 There are two reasons.  The first is that there might
 be programs that rely on the start state not changing across file changes.
-The second is that with flex 2.4, use of yyrestart() is no longer required,
-so fixing the problem there doesn't solve the more general problem.  
-
+The second is that beginning with <CODE>flex</CODE> version 2.4, use of <CODE>yyrestart()</CODE> is no longer required,
+so fixing the problem there doesn't solve the more general problem.
 
 
 
-<H2><A NAME="SEC58" HREF="flex_toc.html#TOC58">How can I match C-style comments?</A></H2>
-
-<P>
-How can I match C-style comments?
 
+<H2><A NAME="SEC70" HREF="flex_toc.html#TOC70">How can I match C-style comments?</A></H2>
 
 <P>
 You might be tempted to try something like this:
@@ -5533,7 +6183,7 @@
 
 <PRE>
 @verbatim
-    /* a comment */ do_my_thing( "oops */" );
+/* a comment */ do_my_thing( "oops */" );
 </PRE>
 
 <P>
@@ -5544,23 +6194,19 @@
 <PRE>
 @verbatim
 &#60;INITIAL&#62;{
-    "/*"              BEGIN(IN_COMMENT);
+"/*"              BEGIN(IN_COMMENT);
 }
 &#60;IN_COMMENT&#62;{
-    "*/"      BEGIN(INITIAL);
-    [^*\n]+   // eat comment in chunks
-    "*"       // eat the lone star
-    \n        yylineno++;
+"*/"      BEGIN(INITIAL);
+[^*\n]+   // eat comment in chunks
+"*"       // eat the lone star
+\n        yylineno++;
 }
 </PRE>
 
 
 
-<H2><A NAME="SEC59" HREF="flex_toc.html#TOC59">The '.' isn't working the way I expected.</A></H2>
-
-<P>
-The '.' (dot) isn't working the way I expected.
-
+<H2><A NAME="SEC71" HREF="flex_toc.html#TOC71">The '.' isn't working the way I expected.</A></H2>
 
 <P>
 Here are some tips for using <SAMP>`.'</SAMP>:
@@ -5574,47 +6220,37 @@
 you really meant to place the parenthesis BEFORE the operator, e.g., you
 probably want this <CODE>(foo|bar)+</CODE> and NOT this <CODE>(foo|bar+)</CODE>.
 
-The first pattern matches the words <CODE>foo</CODE> or <CODE>bar</CODE> any number of
-times, e.g., it matches the text <CODE>barfoofoobarfoo</CODE>. The
+The first pattern matches the words <SAMP>`foo'</SAMP> or <SAMP>`bar'</SAMP> any number of
+times, e.g., it matches the text <SAMP>`barfoofoobarfoo'</SAMP>. The
 second pattern matches a single instance of <CODE>foo</CODE> or a single instance of
-<CODE>ba</CODE> followed by one or more <SAMP>`r'</SAMP>s, e.g., it matches the text <CODE>barrrr</CODE> .
+<CODE>bar</CODE> followed by one or more <SAMP>`r'</SAMP>s, e.g., it matches the text <CODE>barrrr</CODE> .
 <LI>
 
-A <SAMP>`.'</SAMP> inside []'s just means a literal<SAMP>`.'</SAMP> (period),
+A <SAMP>`.'</SAMP> inside <SAMP>`[]'</SAMP>'s just means a literal<SAMP>`.'</SAMP> (period),
 and NOT "any character except newline".
 <LI>
 
-Remember that <SAMP>`.'</SAMP> matches any character EXCEPT <SAMP>`\n'</SAMP> (and EOF).
+Remember that <SAMP>`.'</SAMP> matches any character EXCEPT <SAMP>`\n'</SAMP> (and <SAMP>`EOF'</SAMP>).
 If you really want to match ANY character, including newlines, then use <CODE>(.|\n)</CODE>
---- Beware that the regex <CODE>(.|\n)+</CODE> will match your entire input!
+Beware that the regex <CODE>(.|\n)+</CODE> will match your entire input!
 <LI>
 
-Finally, if you want to match a literal <SAMP>`.'</SAMP> (a period), then use [.] or "."
+Finally, if you want to match a literal <SAMP>`.'</SAMP> (a period), then use <SAMP>`[.]'</SAMP> or <SAMP>`"."'</SAMP>
 </UL>
 
 
 
-<H2><A NAME="SEC60" HREF="flex_toc.html#TOC60">Can I get the flex manual in another format?</A></H2>
+<H2><A NAME="SEC72" HREF="flex_toc.html#TOC72">Can I get the flex manual in another format?</A></H2>
 
 <P>
-Can I get the flex manual in another format?
+The <CODE>flex</CODE> source distribution  includes a texinfo manual. You are
+free to convert that texinfo into whatever format you desire. The
+<CODE>texinfo</CODE> package includes tools for conversion to a number of formats.
 
 
-<P>
-As of flex 2.5, the manual is distributed in texinfo format.
-You can use the "texi2*" tools to convert the manual to any format
-you desire (e.g., <SAMP>`texi2html'</SAMP>).
 
 
-
-
-<H2><A NAME="SEC61" HREF="flex_toc.html#TOC61">Does there exist a "faster" NDFA-&#62;DFA algorithm?</A></H2>
-
-<P>
-Does there exist a "faster" NDFA-&#62;DFA algorithm? Most standard texts (e.g.,
-Aho), imply that NDFA-&#62;DFA can take exponential time, since there are
-exponential number of potential states in NDFA.
-
+<H2><A NAME="SEC73" HREF="flex_toc.html#TOC73">Does there exist a "faster" NDFA-&#62;DFA algorithm?</A></H2>
 
 <P>
 There's no way around the potential exponential running time - it
@@ -5625,14 +6261,10 @@
 
 
 
-<H2><A NAME="SEC62" HREF="flex_toc.html#TOC62">How does flex compile the DFA so quickly?</A></H2>
+<H2><A NAME="SEC74" HREF="flex_toc.html#TOC74">How does flex compile the DFA so quickly?</A></H2>
 
 <P>
-How does flex compile the DFA so quickly?
-
-
-<P>
-There are two big speed wins that flex uses:
+There are two big speed wins that <CODE>flex</CODE> uses:
 
 
 
@@ -5654,16 +6286,12 @@
 
 
 
-<H2><A NAME="SEC63" HREF="flex_toc.html#TOC63">How can I use more than 8192 rules?</A></H2>
-
-<P>
-How can I use more than 8192 rules?
-
+<H2><A NAME="SEC75" HREF="flex_toc.html#TOC75">How can I use more than 8192 rules?</A></H2>
 
 <P>
-Flex is compiled with an upper limit of 8192 rules per scanner. 
-If you need more than 8192 rules in your scanner, you'll have to recompile flex
-with the following changes in flexdef.h:
+<CODE>Flex</CODE> is compiled with an upper limit of 8192 rules per scanner.
+If you need more than 8192 rules in your scanner, you'll have to recompile <CODE>flex</CODE>
+with the following changes in <TT>`flexdef.h'</TT>:
 
 
 
@@ -5682,150 +6310,117 @@
 is the best way to solve your problem.
 
 
-
-
-<H2><A NAME="SEC64" HREF="flex_toc.html#TOC64">How do I abandon a file in the middle of a scan and switch to a new file?</A></H2>
-
-<P>
-How do I abandon a file in the middle of a scan and switch to a new file?
-
-
-<P>
-Just all yyrestart(newfile). Be sure to reset the start state if you want a
-"fresh" start, since yyrestart does NOT reset the start state back to INITIAL.
-
-
-
-
-<H2><A NAME="SEC65" HREF="flex_toc.html#TOC65">How do I execute code only during initialization (only before the first scan)?</A></H2>
-
 <P>
-How do I execute code only during initialization (only before the first scan)?
+The following may also be relevant:
 
 
 <P>
-You can specify an initial action by defining the macro YY_USER_INIT (though
-note that yyout may not be available at the time this macro is executed).  Or you
-can add to the beginning of your rules section:
+With luck, you should be able to increase the definitions in flexdef.h for:
 
 
 
 <PRE>
 @verbatim
-%%
-    /* Must be indented! */
-    static int did_init = 0;
-
-    if ( ! did_init ){
-        do_my_init();
-        did_init = 1;
-    }
+#define JAMSTATE -32766 /* marks a reference to the state that always jams */
+#define MAXIMUM_MNS 31999
+#define BAD_SUBSCRIPT -32767
 </PRE>
 
-
-
-<H2><A NAME="SEC66" HREF="flex_toc.html#TOC66">How do I execute code at termination?</A></H2>
-
 <P>
-How do I execute code at termination (i.e., only after the last scan?)
-
-
-<P>
-You can specifiy an action for the &#60;&#60;EOF&#62;&#62; rule.
+recompile everything, and it'll all work.  Flex only has these 16-bit-like
+values built into it because a long time ago it was developed on a machine
+with 16-bit ints.  I've given this advice to others in the past but haven't
+heard back from them whether it worked okay or not...
 
 
-<H2><A NAME="SEC67" HREF="flex_toc.html#TOC67">Where else can I find help?</A></H2>
 
-<P>
-Where else can I find help?
 
+<H2><A NAME="SEC76" HREF="flex_toc.html#TOC76">How do I abandon a file in the middle of a scan and switch to a new file?</A></H2>
 
 <P>
-The <CODE>help-flex</CODE> email list is served by GNU. See http://www.gnu.org/ for
-details how to subscribe or search the archives.
+Just call <CODE>yyrestart(newfile)</CODE>. Be sure to reset the start state if you want a
+"fresh start, since <CODE>yyrestart</CODE> does NOT reset the start state back to <CODE>INITIAL</CODE>.
 
 
 
 
-<H2><A NAME="SEC68" HREF="flex_toc.html#TOC68">Can I include comments in the "rules" section of the file file?</A></H2>
+<H2><A NAME="SEC77" HREF="flex_toc.html#TOC77">How do I execute code only during initialization (only before the first scan)?</A></H2>
 
 <P>
-Can I include comments in the "rules" section of the file file?
-
+You can specify an initial action by defining the macro <CODE>YY_USER_INIT</CODE> (though
+note that <CODE>yyout</CODE> may not be available at the time this macro is executed).  Or you
+can add to the beginning of your rules section:
 
-<P>
-Yes, just about anywhere you want to. See the manual for the specific syntax.
 
 
+<PRE>
+@verbatim
+%%
+/* Must be indented! */
+static int did_init = 0;
 
+if ( ! did_init ){
+do_my_init();
+did_init = 1;
+}
+</PRE>
 
-<H2><A NAME="SEC69" HREF="flex_toc.html#TOC69">I get an error about undefined yywrap().</A></H2>
 
-<P>
-I get an error about undefined yywrap().
 
+<H2><A NAME="SEC78" HREF="flex_toc.html#TOC78">How do I execute code at termination?</A></H2>
 
 <P>
-You must supply a yywrap() function of your own, or link to libfl.a
-(which provides one), or use
+You can specify an action for the <CODE>&#60;&#60;EOF&#62;&#62;</CODE> rule.
 
 
-<P>
-    %option noyywrap
 
 
-<P>
-in your source to say you don't want a yywrap() function.
-See the manual page for more details concerning yywrap().
-
+<H2><A NAME="SEC79" HREF="flex_toc.html#TOC79">Where else can I find help?</A></H2>
 
+<P>
+The <CODE>help-flex</CODE> email list is served by GNU. See <A HREF="http://www.gnu.org/">http://www.gnu.org/</A> for
+details on how to subscribe or search the archives.
 
 
-<H2><A NAME="SEC70" HREF="flex_toc.html#TOC70">How can I change the matching pattern at run time?</A></H2>
 
-<P>
-How can I change the matching pattern at run time?
 
+<H2><A NAME="SEC80" HREF="flex_toc.html#TOC80">Can I include comments in the "rules" section of the file?</A></H2>
 
 <P>
-You can't, it's compiled into a static table when flex builds the scanner.
-
-
+Yes, just about anywhere you want to. See the manual for the specific syntax.
 
 
-<H2><A NAME="SEC71" HREF="flex_toc.html#TOC71">Is there a way to increase the rules (NFA states to a bigger number?)</A></H2>
 
-<P>
-Is there a way to increase the rules (NFA states to a bigger number?)
 
+<H2><A NAME="SEC81" HREF="flex_toc.html#TOC81">I get an error about undefined yywrap().</A></H2>
 
 <P>
-With luck, you should be able to increase the definitions in flexdef.h for:
+You must supply a <CODE>yywrap()</CODE> function of your own, or link to <TT>`libfl.a'</TT>
+(which provides one), or use
 
 
 
 <PRE>
 @verbatim
-#define JAMSTATE -32766 /* marks a reference to the state that always jams */
-#define MAXIMUM_MNS 31999
-#define BAD_SUBSCRIPT -32767
+%option noyywrap
 </PRE>
 
 <P>
-recompile everything, and it'll all work.  Flex only has these 16-bit-like
-values built into it because a long time ago it was developed on a machine
-with 16-bit ints.  I've given this advice to others in the past but haven't
-heard back from them whether it worked okay or not...
+in your source to say you don't want a <CODE>yywrap()</CODE> function.
 
 
 
 
-<H2><A NAME="SEC72" HREF="flex_toc.html#TOC72">How can I expand macros in the input?</A></H2>
+<H2><A NAME="SEC82" HREF="flex_toc.html#TOC82">How can I change the matching pattern at run time?</A></H2>
 
 <P>
-How can I expand macros in the input?
+You can't, it's compiled into a static table when flex builds the scanner.
+
+
 
 
+<H2><A NAME="SEC83" HREF="flex_toc.html#TOC83">How can I expand macros in the input?</A></H2>
+
 <P>
 The best way to approach this problem is at a higher level, e.g., in the parser.
 
@@ -5839,24 +6434,24 @@
 @verbatim
 %%
 macro/[a-z]+    {
-    /* Saw the macro "macro" followed by extra stuff. */
-    main_buffer = YY_CURRENT_BUFFER;
-    expansion_buffer = yy_scan_string(expand(yytext));
-    yy_switch_to_buffer(expansion_buffer);
-    }
+/* Saw the macro "macro" followed by extra stuff. */
+main_buffer = YY_CURRENT_BUFFER;
+expansion_buffer = yy_scan_string(expand(yytext));
+yy_switch_to_buffer(expansion_buffer);
+}
 
 &#60;&#60;EOF&#62;&#62; {
-    if ( expansion_buffer )
-        {
-        // We were doing an expansion, return to where
-        // we were.
-        yy_switch_to_buffer(main_buffer);
-        yy_delete_buffer(expansion_buffer);
-        expansion_buffer = 0;
-        }
-    else
-        yyterminate();
-    }
+if ( expansion_buffer )
+{
+// We were doing an expansion, return to where
+// we were.
+yy_switch_to_buffer(main_buffer);
+yy_delete_buffer(expansion_buffer);
+expansion_buffer = 0;
+}
+else
+yyterminate();
+}
 </PRE>
 
 <P>
@@ -5866,11 +6461,7 @@
 
 
 
-<H2><A NAME="SEC73" HREF="flex_toc.html#TOC73">How can I build a two-pass scanner?</A></H2>
-
-<P>
-How can I build a two-pass scanner?
-
+<H2><A NAME="SEC84" HREF="flex_toc.html#TOC84">How can I build a two-pass scanner?</A></H2>
 
 <P>
 One way to do it is to filter the first pass to a temporary file,
@@ -5890,16 +6481,12 @@
 
 
 
-<H2><A NAME="SEC74" HREF="flex_toc.html#TOC74">How do I match any string not matched in the preceding rules?</A></H2>
-
-<P>
-How do I match any string not matched in the preceding rules?
-
+<H2><A NAME="SEC85" HREF="flex_toc.html#TOC85">How do I match any string not matched in the preceding rules?</A></H2>
 
 <P>
 One way to assign precedence, is to place the more specific rules first. If
 two rules would match the same input (same sequence of characters) then the
-first rule listed in the flex input wins. e.g.,
+first rule listed in the <CODE>flex</CODE> input wins. e.g.,
 
 
 
@@ -5914,47 +6501,35 @@
 <P>
 Note that the rule <CODE>[a-zA-Z_]+</CODE> must come *after* the others.  It will match the
 same amount of text as the more specific rules, and in that case the
-flex scanner will pick the first rule listed in your scanner as the
+<CODE>flex</CODE> scanner will pick the first rule listed in your scanner as the
 one to match.
 
 
 
 
-<H2><A NAME="SEC75" HREF="flex_toc.html#TOC75">I am trying to port code from AT&#38;T lex that uses yysptr and yysbuf.</A></H2>
-
-<P>
-I am trying to port code from AT&#38;T lex that uses yysptr and yysbuf.
-
+<H2><A NAME="SEC86" HREF="flex_toc.html#TOC86">I am trying to port code from AT&#38;T lex that uses yysptr and yysbuf.</A></H2>
 
 <P>
 Those are internal variables pointing into the AT&#38;T scanner's input buffer.  I
-imagine they're being manipulated in user versions of the input() and unput()
+imagine they're being manipulated in user versions of the <CODE>input()</CODE> and <CODE>unput()</CODE>
 functions.  If so, what you need to do is analyze those functions to figure out
-what they're doing, and then replace input() with an appropriate definition of
-YY_INPUT (see the flex man page).  You shouldn't need to (and must not) replace
-flex's unput() function.
+what they're doing, and then replace <CODE>input()</CODE> with an appropriate definition of
+<CODE>YY_INPUT</CODE>.  You shouldn't need to (and must not) replace
+<CODE>flex</CODE>'s <CODE>unput()</CODE> function.
 
 
 
 
-<H2><A NAME="SEC76" HREF="flex_toc.html#TOC76">Is there a way to make flex treat NULL like a regular character?</A></H2>
+<H2><A NAME="SEC87" HREF="flex_toc.html#TOC87">Is there a way to make flex treat NULL like a regular character?</A></H2>
 
 <P>
-Is there a way to make flex treat NULL like a regular character?
+Yes, <SAMP>`\0'</SAMP> and <SAMP>`\x00'</SAMP> should both do the trick.  Perhaps you have an ancient
+version of <CODE>flex</CODE>.  The latest release is version 2.5.23.
 
 
-<P>
-Yes, \0 and \x00 should both do the trick.  Perhaps you have an ancient
-version of flex.  The latest release is version 2.5.8.
 
 
-
-
-<H2><A NAME="SEC77" HREF="flex_toc.html#TOC77">Whenever flex can not match the input it says "flex scanner jammed".</A></H2>
-
-<P>
-Whenever flex can not match the input it says "flex scanner jammed".
-
+<H2><A NAME="SEC88" HREF="flex_toc.html#TOC88">Whenever flex can not match the input it says "flex scanner jammed".</A></H2>
 
 <P>
 You need to add a rule that matches the otherwise-unmatched text.
@@ -5972,16 +6547,12 @@
 </PRE>
 
 <P>
-See %option default for more information.
+See <CODE>%option default</CODE> for more information.
 
 
 
 
-<H2><A NAME="SEC78" HREF="flex_toc.html#TOC78">Why doesn't flex have non-greedy operators like perl does?</A></H2>
-
-<P>
-Why doesn't flex have non-greedy operators like perl does?
-
+<H2><A NAME="SEC89" HREF="flex_toc.html#TOC89">Why doesn't flex have non-greedy operators like perl does?</A></H2>
 
 <P>
 A DFA can do a non-greedy match by stopping
@@ -5996,14 +6567,14 @@
 sign that you're trying to make the scanner do some parsing.  That's
 generally the wrong approach, since it lacks the power to do a decent job.
 Better is to either introduce a separate parser, or to split the scanner
-into multiple scanners using (exclusive) start conditions.  
+into multiple scanners using (exclusive) start conditions.
 
 
 <P>
 You might have
-a separate start state once you've seen the BEGIN. In that state, you
-might then have a regex that will match END (to kick you out of the
-state), and perhaps (.|\n) to get a single character within the chunk ...
+a separate start state once you've seen the <SAMP>`BEGIN'</SAMP>. In that state, you
+might then have a regex that will match <SAMP>`END'</SAMP> (to kick you out of the
+state), and perhaps <SAMP>`(.|\n)'</SAMP> to get a single character within the chunk ...
 
 
 <P>
@@ -6012,14 +6583,2137 @@
 
 
 
-<H1><A NAME="SEC79" HREF="flex_toc.html#TOC79">Appendices</A></H1>
+<H2><A NAME="SEC90" HREF="flex_toc.html#TOC90">Memory leak - 16386 bytes allocated by malloc.</A></H2>
+<P>
+@anchor{faq-memory-leak}
 
 
+<P>
+UPDATED 2002-07-10: As of <CODE>flex</CODE> version 2.5.9, this leak means that you did not
+call <CODE>yylex_destroy()</CODE>. If you are using an earlier version of <CODE>flex</CODE>, then read
+on.
 
-<H2><A NAME="SEC80" HREF="flex_toc.html#TOC80">Makefiles and Flex</A></H2>
 
 <P>
-<A NAME="IDX297"></A>
+The leak is about 16426 bytes.  That is, (8192 * 2 + 2) for the read-buffer, and
+about 40 for <CODE>struct yy_buffer_state</CODE> (depending upon alignment). The leak is in
+the non-reentrant C scanner only (NOT in the reentrant scanner, NOT in the C++
+scanner). Since <CODE>flex</CODE> doesn't know when you are done, the buffer is never freed.
+
+
+<P>
+However, the leak won't multiply since the buffer is reused no matter how many
+times you call <CODE>yylex()</CODE>.
+
+
+<P>
+If you want to reclaim the memory when you are completely done scanning, then
+you might try this:
+
+
+
+<PRE>
+@verbatim
+/* For non-reentrant C scanner only. */
+yy_delete_buffer(yy_current_buffer);
+yy_init = 1;
+</PRE>
+
+<P>
+Note: <CODE>yy_init</CODE> is an "internal variable", and hasn't been tested in this
+situation. It is possible that some other globals may need resetting as well.
+
+
+
+
+<H2><A NAME="SEC91" HREF="flex_toc.html#TOC91">How do I track the byte offset for lseek()?</A></H2>
+
+
+<PRE>
+@verbatim
+&#62;   We thought that it would be possible to have this number through the
+&#62;   evaluation of the following expression:
+&#62;
+&#62;   seek_position = (no_buffers)*YY_READ_BUF_SIZE + yy_c_buf_p - yy_current_buffer-&#62;yy_ch_buf
+</PRE>
+
+<P>
+While this is the right idea, it has two problems.  The first is that
+it's possible that <CODE>flex</CODE> will request less than <CODE>YY_READ_BUF_SIZE</CODE> during
+an invocation of <CODE>YY_INPUT</CODE> (or that your input source will return less
+even though <CODE>YY_READ_BUF_SIZE</CODE> bytes were requested).  The second problem
+is that when refilling its internal buffer, <CODE>flex</CODE> keeps some characters
+from the previous buffer (because usually it's in the middle of a match,
+and needs those characters to construct <CODE>yytext</CODE> for the match once it's
+done).  Because of this, <CODE>yy_c_buf_p - yy_current_buffer-&#62;yy_ch_buf</CODE> won't
+be exactly the number of characters already read from the current buffer.
+
+
+<P>
+An alternative solution is to count the number of characters you've matched
+since starting to scan.  This can be done by using <CODE>YY_USER_ACTION</CODE>.  For
+example,
+
+
+
+<PRE>
+@verbatim
+#define YY_USER_ACTION num_chars += yyleng;
+</PRE>
+
+<P>
+(You need to be careful to update your bookkeeping if you use <CODE>yymore(</CODE>),
+<CODE>yyless()</CODE>, <CODE>unput()</CODE>, or <CODE>input()</CODE>.)
+
+
+
+
+<H2><A NAME="SEC92" HREF="flex_toc.html#TOC92">How do I use my own I/O classes in a C++ scanner?</A></H2>
+
+<P>
+When the flex C++ scanning class rewrite finally happens, then this sort of thing should become much easier.
+
+
+<P>
+<A NAME="IDX457"></A>
+<A NAME="IDX458"></A>
+<A NAME="IDX459"></A>
+<A NAME="IDX460"></A>
+<A NAME="IDX461"></A>
+<A NAME="IDX462"></A>
+You can do this by passing the various functions (such as <CODE>LexerInput()</CODE>
+and <CODE>LexerOutput()</CODE>) nil <CODE>iostream*</CODE>'s, and then
+dealing with your own I/O classes surreptitiously (i.e., stashing them in
+special member variables).  This works because the only assumption about
+the lexer regarding what's done with the iostream's is that they're
+ultimately passed to <CODE>LexerInput()</CODE> and <CODE>LexerOutput</CODE>, which then do whatever
+is necessary with them.
+
+
+
+
+<H2><A NAME="SEC93" HREF="flex_toc.html#TOC93">How do I skip as many chars as possible?</A></H2>
+
+<P>
+How do I skip as many chars as possible -- without interfering with the other
+patterns?
+
+
+<P>
+In the example below, we want to skip over characters until we see the phrase
+"endskip". The following will <EM>NOT</EM> work correctly (do you see why not?)
+
+
+
+<PRE>
+@verbatim
+/* INCORRECT SCANNER */
+%x SKIP
+%%
+&#60;INITIAL&#62;startskip   BEGIN(SKIP);
+...
+&#60;SKIP&#62;"endskip"       BEGIN(INITIAL);
+&#60;SKIP&#62;.*             ;
+</PRE>
+
+<P>
+The problem is that the pattern .* will eat up the word "endskip."
+The simplest (but slow) fix is:
+
+
+
+<PRE>
+@verbatim
+&#60;SKIP&#62;"endskip"      BEGIN(INITIAL);
+&#60;SKIP&#62;.              ;
+</PRE>
+
+<P>
+The fix involves making the second rule match more, without
+making it match "endskip" plus something else.  So for example:
+
+
+
+<PRE>
+@verbatim
+&#60;SKIP&#62;"endskip"     BEGIN(INITIAL);
+&#60;SKIP&#62;[^e]+         ;
+&#60;SKIP&#62;.                 ;/* so you eat up e's, too */
+</PRE>
+
+
+
+<H2><A NAME="SEC94" HREF="flex_toc.html#TOC94">unnamed-faq-33</A></H2>
+
+<PRE>
+@verbatim
+QUESTION:
+When was flex born?
+
+Vern Paxson took over
+the Software Tools lex project from Jef Poskanzer in 1982.  At that point it
+was written in Ratfor.  Around 1987 or so, Paxson translated it into C, and
+a legend was born :-).
+</PRE>
+
+
+
+<H2><A NAME="SEC95" HREF="flex_toc.html#TOC95">unnamed-faq-42</A></H2>
+
+<PRE>
+@verbatim
+To: Adoram Rogel &#60;adoram@orna.hybridge.com&#62;
+Subject: Re: Flex 2.5.2 performance questions
+In-reply-to: Your message of Wed, 18 Sep 96 11:12:17 EDT.
+Date: Wed, 18 Sep 96 10:51:02 PDT
+From: Vern Paxson &#60;vern&#62;
+
+[Note, the most recent flex release is 2.5.4, which you can get from
+ftp.ee.lbl.gov.  It has bug fixes over 2.5.2 and 2.5.3.]
+
+&#62; 1. Using the pattern
+&#62;    ([Ff](oot)?)?[Nn](ote)?(\.)?
+&#62;    instead of
+&#62;    (((F|f)oot(N|n)ote)|((N|n)ote)|((N|n)\.)|((F|f)(N|n)(\.)))
+&#62;    (in a very complicated flex program) caused the program to slow from
+&#62;    300K+/min to 100K/min (no other changes were done).
+
+These two are not equivalent.  For example, the first can match "footnote."
+but the second can only match "footnote".  This is almost certainly the
+cause in the discrepancy - the slower scanner run is matching more tokens,
+and/or having to do more backing up.
+
+&#62; 2. Which of these two are better: [Ff]oot or (F|f)oot ?
+
+From a performance point of view, they're equivalent (modulo presumably
+minor effects such as memory cache hit rates; and the presence of trailing
+context, see below).  From a space point of view, the first is slightly
+preferable.
+
+&#62; 3. I have a pattern that look like this:
+&#62;    pats {p1}|{p2}|{p3}|...|{p50}     (50 patterns ORd)
+&#62;
+&#62;    running yet another complicated program that includes the following rule:
+&#62;    &#60;snext&#62;{and}/{no4}{bb}{pats}
+&#62;
+&#62;    gets me to "too complicated - over 32,000 states"...
+
+I can't tell from this example whether the trailing context is variable-length
+or fixed-length (it could be the latter if {and} is fixed-length).  If it's
+variable length, which flex -p will tell you, then this reflects a basic
+performance problem, and if you can eliminate it by restructuring your
+scanner, you will see significant improvement.
+
+&#62;    so I divided {pats} to {pats1}, {pats2},..., {pats5} each consists of about
+&#62;    10 patterns and changed the rule to be 5 rules.
+&#62;    This did compile, but what is the rule of thumb here ?
+
+The rule is to avoid trailing context other than fixed-length, in which for
+a/b, either the 'a' pattern or the 'b' pattern have a fixed length.  Use
+of the '|' operator automatically makes the pattern variable length, so in
+this case '[Ff]oot' is preferred to '(F|f)oot'.
+
+&#62; 4. I changed a rule that looked like this:
+&#62;    &#60;snext8&#62;{and}{bb}/{ROMAN}[^A-Za-z] { BEGIN...
+&#62;
+&#62;    to the next 2 rules:
+&#62;    &#60;snext8&#62;{and}{bb}/{ROMAN}[A-Za-z] { ECHO;}
+&#62;    &#60;snext8&#62;{and}{bb}/{ROMAN}         { BEGIN...
+&#62;
+&#62;    Again, I understand the using [^...] will cause a great performance loss
+
+Actually, it doesn't cause any sort of performance loss.  It's a surprising
+fact about regular expressions that they always match in linear time
+regardless of how complex they are.
+
+&#62;    but are there any specific rules about it ?
+
+See the "Performance Considerations" section of the man page, and also
+the example in MISC/fastwc/.
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC96" HREF="flex_toc.html#TOC96">unnamed-faq-43</A></H2>
+
+<PRE>
+@verbatim
+To: Adoram Rogel &#60;adoram@hybridge.com&#62;
+Subject: Re: Flex 2.5.2 performance questions
+In-reply-to: Your message of Thu, 19 Sep 96 10:16:04 EDT.
+Date: Thu, 19 Sep 96 09:58:00 PDT
+From: Vern Paxson &#60;vern&#62;
+
+&#62; a lot about the backing up problem.
+&#62; I believe that there lies my biggest problem, and I'll try to improve
+&#62; it.
+
+Since you have variable trailing context, this is a bigger performance
+problem.  Fixing it is usually easier than fixing backing up, which in a
+complicated scanner (yours seems to fit the bill) can be extremely
+difficult to do correctly.
+
+You also don't mention what flags you are using for your scanner.
+-f makes a large speed difference, and -Cfe buys you nearly as much
+speed but the resulting scanner is considerably smaller.
+
+&#62; I have an | operator in {and} and in {pats} so both of them are variable
+&#62; length.
+
+-p should have reported this.
+
+&#62; Is changing one of them to fixed-length is enough ?
+
+Yes.
+
+&#62; Is it possible to change the 32,000 states limit ?
+
+Yes.  I've appended instructions on how.  Before you make this change,
+though, you should think about whether there are ways to fundamentally
+simplify your scanner - those are certainly preferable!
+
+                Vern
+
+To increase the 32K limit (on a machine with 32 bit integers), you increase
+the magnitude of the following in flexdef.h:
+
+#define JAMSTATE -32766 /* marks a reference to the state that always jams */
+#define MAXIMUM_MNS 31999
+#define BAD_SUBSCRIPT -32767
+#define MAX_SHORT 32700
+
+Adding a 0 or two after each should do the trick.
+</PRE>
+
+
+
+<H2><A NAME="SEC97" HREF="flex_toc.html#TOC97">unnamed-faq-44</A></H2>
+
+<PRE>
+@verbatim
+To: Heeman_Lee@hp.com
+Subject: Re: flex - multi-byte support?
+In-reply-to: Your message of Thu, 03 Oct 1996 17:24:04 PDT.
+Date: Fri, 04 Oct 1996 11:42:18 PDT
+From: Vern Paxson &#60;vern&#62;
+
+&#62;      I assume as long as my *.l file defines the
+&#62;      range of expected character code values (in octal format), flex will
+&#62;      scan the file and read multi-byte characters correctly. But I have no
+&#62;      confidence in this assumption.
+
+Your lack of confidence is justified - this won't work.
+
+Flex has in it a widespread assumption that the input is processed
+one byte at a time.  Fixing this is on the to-do list, but is involved,
+so it won't happen any time soon.  In the interim, the best I can suggest
+(unless you want to try fixing it yourself) is to write your rules in
+terms of pairs of bytes, using definitions in the first section:
+
+        X       \xfe\xc2
+        ...
+        %%
+        foo{X}bar       found_foo_fe_c2_bar();
+
+etc.  Definitely a pain - sorry about that.
+
+By the way, the email address you used for me is ancient, indicating you
+have a very old version of flex.  You can get the most recent, 2.5.4, from
+ftp.ee.lbl.gov.
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC98" HREF="flex_toc.html#TOC98">unnamed-faq-45</A></H2>
+
+<PRE>
+@verbatim
+To: moleary@primus.com
+Subject: Re: Flex / Unicode compatibility question
+In-reply-to: Your message of Tue, 22 Oct 1996 10:15:42 PDT.
+Date: Tue, 22 Oct 1996 11:06:13 PDT
+From: Vern Paxson &#60;vern&#62;
+
+Unfortunately flex at the moment has a widespread assumption within it
+that characters are processed 8 bits at a time.  I don't see any easy
+fix for this (other than writing your rules in terms of double characters -
+a pain).  I also don't know of a wider lex, though you might try surfing
+the Plan 9 stuff because I know it's a Unicode system, and also the PCCT
+toolkit (try searching say Alta Vista for "Purdue Compiler Construction
+Toolkit").
+
+Fixing flex to handle wider characters is on the long-term to-do list.
+But since flex is a strictly spare-time project these days, this probably
+won't happen for quite a while, unless someone else does it first.
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC99" HREF="flex_toc.html#TOC99">unnamed-faq-46</A></H2>
+
+<PRE>
+@verbatim
+To: Johan Linde &#60;jl@theophys.kth.se&#62;
+Subject: Re: translation of flex
+In-reply-to: Your message of Sun, 10 Nov 1996 09:16:36 PST.
+Date: Mon, 11 Nov 1996 10:33:50 PST
+From: Vern Paxson &#60;vern&#62;
+
+&#62; I'm working for the Swedish team translating GNU program, and I'm currently
+&#62; working with flex. I have a few questions about some of the messages which
+&#62; I hope you can answer.
+
+All of the things you're wondering about, by the way, concerning flex
+internals - probably the only person who understands what they mean in
+English is me!  So I wouldn't worry too much about getting them right.
+That said ...
+
+&#62; #: main.c:545
+&#62; msgid "  %d protos created\n"
+&#62;
+&#62; Does proto mean prototype?
+
+Yes - prototypes of state compression tables.
+
+&#62; #: main.c:539
+&#62; msgid "  %d/%d (peak %d) template nxt-chk entries created\n"
+&#62;
+&#62; Here I'm mainly puzzled by 'nxt-chk'. I guess it means 'next-check'. (?)
+&#62; However, 'template next-check entries' doesn't make much sense to me. To be
+&#62; able to find a good translation I need to know a little bit more about it.
+
+There is a scheme in the Aho/Sethi/Ullman compiler book for compressing
+scanner tables.  It involves creating two pairs of tables.  The first has
+"base" and "default" entries, the second has "next" and "check" entries.
+The "base" entry is indexed by the current state and yields an index into
+the next/check table.  The "default" entry gives what to do if the state
+transition isn't found in next/check.  The "next" entry gives the next
+state to enter, but only if the "check" entry verifies that this entry is
+correct for the current state.  Flex creates templates of series of
+next/check entries and then encodes differences from these templates as a
+way to compress the tables.
+
+&#62; #: main.c:533
+&#62; msgid "  %d/%d base-def entries created\n"
+&#62;
+&#62; The same problem here for 'base-def'.
+
+See above.
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC100" HREF="flex_toc.html#TOC100">unnamed-faq-47</A></H2>
+
+<PRE>
+@verbatim
+To: Xinying Li &#60;xli@npac.syr.edu&#62;
+Subject: Re: FLEX ?
+In-reply-to: Your message of Wed, 13 Nov 1996 17:28:38 PST.
+Date: Wed, 13 Nov 1996 19:51:54 PST
+From: Vern Paxson &#60;vern&#62;
+
+&#62; "unput()" them to input flow, question occurs. If I do this after I scan
+&#62; a carriage, the variable "yy_current_buffer-&#62;yy_at_bol" is changed. That
+&#62; means the carriage flag has gone.
+
+You can control this by calling yy_set_bol().  It's described in the manual.
+
+&#62;      And if in pre-reading it goes to the end of file, is anything done
+&#62; to control the end of curren buffer and end of file?
+
+No, there's no way to put back an end-of-file.
+
+&#62;      By the way I am using flex 2.5.2 and using the "-l".
+
+The latest release is 2.5.4, by the way.  It fixes some bugs in 2.5.2 and
+2.5.3.  You can get it from ftp.ee.lbl.gov.
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC101" HREF="flex_toc.html#TOC101">unnamed-faq-48</A></H2>
+
+<PRE>
+@verbatim
+To: Alain.ISSARD@st.com
+Subject: Re: Start condition with FLEX
+In-reply-to: Your message of Mon, 18 Nov 1996 09:45:02 PST.
+Date: Mon, 18 Nov 1996 10:41:34 PST
+From: Vern Paxson &#60;vern&#62;
+
+&#62; I am not able to use the start condition scope and to use the | (OR) with
+&#62; rules having start conditions.
+
+The problem is that if you use '|' as a regular expression operator, for
+example "a|b" meaning "match either 'a' or 'b'", then it must *not* have
+any blanks around it.  If you instead want the special '|' *action* (which
+from your scanner appears to be the case), which is a way of giving two
+different rules the same action:
+
+        foo     |
+        bar     matched_foo_or_bar();
+
+then '|' *must* be separated from the first rule by whitespace and *must*
+be followed by a new line.  You *cannot* write it as:
+
+        foo | bar       matched_foo_or_bar();
+
+even though you might think you could because yacc supports this syntax.
+The reason for this unfortunately incompatibility is historical, but it's
+unlikely to be changed.
+
+Your problems with start condition scope are simply due to syntax errors
+from your use of '|' later confusing flex.
+
+Let me know if you still have problems.
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC102" HREF="flex_toc.html#TOC102">unnamed-faq-49</A></H2>
+
+<PRE>
+@verbatim
+To: Gregory Margo &#60;gmargo@newton.vip.best.com&#62;
+Subject: Re: flex-2.5.3 bug report
+In-reply-to: Your message of Sat, 23 Nov 1996 16:50:09 PST.
+Date: Sat, 23 Nov 1996 17:07:32 PST
+From: Vern Paxson &#60;vern&#62;
+
+&#62; Enclosed is a lex file that "real" lex will process, but I cannot get
+&#62; flex to process it.  Could you try it and maybe point me in the right direction?
+
+Your problem is that some of the definitions in the scanner use the '/'
+trailing context operator, and have it enclosed in ()'s.  Flex does not
+allow this operator to be enclosed in ()'s because doing so allows undefined
+regular expressions such as "(a/b)+".  So the solution is to remove the
+parentheses.  Note that you must also be building the scanner with the -l
+option for AT&#38;T lex compatibility.  Without this option, flex automatically
+encloses the definitions in parentheses.
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC103" HREF="flex_toc.html#TOC103">unnamed-faq-50</A></H2>
+
+<PRE>
+@verbatim
+To: Thomas Hadig &#60;hadig@toots.physik.rwth-aachen.de&#62;
+Subject: Re: Flex Bug ?
+In-reply-to: Your message of Tue, 26 Nov 1996 14:35:01 PST.
+Date: Tue, 26 Nov 1996 11:15:05 PST
+From: Vern Paxson &#60;vern&#62;
+
+&#62; In my lexer code, i have the line :
+&#62; ^\*.*          { }
+&#62;
+&#62; Thus all lines starting with an astrix (*) are comment lines.
+&#62; This does not work !
+
+I can't get this problem to reproduce - it works fine for me.  Note
+though that if what you have is slightly different:
+
+        COMMENT ^\*.*
+        %%
+        {COMMENT}       { }
+
+then it won't work, because flex pushes back macro definitions enclosed
+in ()'s, so the rule becomes
+
+        (^\*.*)         { }
+
+and now that the '^' operator is not at the immediate beginning of the
+line, it's interpreted as just a regular character.  You can avoid this
+behavior by using the "-l" lex-compatibility flag, or "%option lex-compat".
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC104" HREF="flex_toc.html#TOC104">unnamed-faq-51</A></H2>
+
+<PRE>
+@verbatim
+To: Adoram Rogel &#60;adoram@hybridge.com&#62;
+Subject: Re: Flex 2.5.4 BOF ???
+In-reply-to: Your message of Tue, 26 Nov 1996 16:10:41 PST.
+Date: Wed, 27 Nov 1996 10:56:25 PST
+From: Vern Paxson &#60;vern&#62;
+
+&#62;     Organization(s)?/[a-z]
+&#62;
+&#62; This matched "Organizations" (looking in debug mode, the trailing s
+&#62; was matched with trailing context instead of the optional (s) in the
+&#62; end of the word.
+
+That should only happen with lex.  Flex can properly match this pattern.
+(That might be what you're saying, I'm just not sure.)
+
+&#62; Is there a way to avoid this dangerous trailing context problem ?
+
+Unfortunately, there's no easy way.  On the other hand, I don't see why
+it should be a problem.  Lex's matching is clearly wrong, and I'd hope
+that usually the intent remains the same as expressed with the pattern,
+so flex's matching will be correct.
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC105" HREF="flex_toc.html#TOC105">unnamed-faq-52</A></H2>
+
+<PRE>
+@verbatim
+To: Cameron MacKinnon &#60;mackin@interlog.com&#62;
+Subject: Re: Flex documentation bug
+In-reply-to: Your message of Mon, 02 Dec 1996 00:07:08 PST.
+Date: Sun, 01 Dec 1996 22:29:39 PST
+From: Vern Paxson &#60;vern&#62;
+
+&#62; I'm not sure how or where to submit bug reports (documentation or
+&#62; otherwise) for the GNU project stuff ...
+
+Well, strictly speaking flex isn't part of the GNU project.  They just
+distribute it because no one's written a decent GPL'd lex replacement.
+So you should send bugs directly to me.  Those sent to the GNU folks
+sometimes find there way to me, but some may drop between the cracks.
+
+&#62; In GNU Info, under the section 'Start Conditions', and also in the man
+&#62; page (mine's dated April '95) is a nice little snippet showing how to
+&#62; parse C quoted strings into a buffer, defined to be MAX_STR_CONST in
+&#62; size. Unfortunately, no overflow checking is ever done ...
+
+This is already mentioned in the manual:
+
+Finally, here's an example of how to  match  C-style  quoted
+strings using exclusive start conditions, including expanded
+escape sequences (but not including checking  for  a  string
+that's too long):
+
+The reason for not doing the overflow checking is that it will needlessly
+clutter up an example whose main purpose is just to demonstrate how to
+use flex.
+
+The latest release is 2.5.4, by the way, available from ftp.ee.lbl.gov.
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC106" HREF="flex_toc.html#TOC106">unnamed-faq-53</A></H2>
+
+<PRE>
+@verbatim
+To: tsv@cs.UManitoba.CA
+Subject: Re: Flex (reg)..
+In-reply-to: Your message of Thu, 06 Mar 1997 23:50:16 PST.
+Date: Thu, 06 Mar 1997 15:54:19 PST
+From: Vern Paxson &#60;vern&#62;
+
+&#62; [:alpha:] ([:alnum:] | \\_)*
+
+If your rule really has embedded blanks as shown above, then it won't
+work, as the first blank delimits the rule from the action.  (It wouldn't
+even compile ...)  You need instead:
+
+[:alpha:]([:alnum:]|\\_)*
+
+and that should work fine - there's no restriction on what can go inside
+of ()'s except for the trailing context operator, '/'.
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC107" HREF="flex_toc.html#TOC107">unnamed-faq-54</A></H2>
+
+<PRE>
+@verbatim
+To: "Mike Stolnicki" &#60;mstolnic@ford.com&#62;
+Subject: Re: FLEX help
+In-reply-to: Your message of Fri, 30 May 1997 13:33:27 PDT.
+Date: Fri, 30 May 1997 10:46:35 PDT
+From: Vern Paxson &#60;vern&#62;
+
+&#62; We'd like to add "if-then-else", "while", and "for" statements to our
+&#62; language ...
+&#62; We've investigated many possible solutions.  The one solution that seems
+&#62; the most reasonable involves knowing the position of a TOKEN in yyin.
+
+I strongly advise you to instead build a parse tree (abstract syntax tree)
+and loop over that instead.  You'll find this has major benefits in keeping
+your interpreter simple and extensible.
+
+That said, the functionality you mention for get_position and set_position
+have been on the to-do list for a while.  As flex is a purely spare-time
+project for me, no guarantees when this will be added (in particular, it
+for sure won't be for many months to come).
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC108" HREF="flex_toc.html#TOC108">unnamed-faq-55</A></H2>
+
+<PRE>
+@verbatim
+To: Colin Paul Adams &#60;colin@colina.demon.co.uk&#62;
+Subject: Re: Flex C++ classes and Bison
+In-reply-to: Your message of 09 Aug 1997 17:11:41 PDT.
+Date: Fri, 15 Aug 1997 10:48:19 PDT
+From: Vern Paxson &#60;vern&#62;
+
+&#62; #define YY_DECL   int yylex (YYSTYPE *lvalp, struct parser_control
+&#62; *parm)
+&#62;
+&#62; I have been trying  to get this to work as a C++ scanner, but it does
+&#62; not appear to be possible (warning that it matches no declarations in
+&#62; yyFlexLexer, or something like that).
+&#62;
+&#62; Is this supposed to be possible, or is it being worked on (I DID
+&#62; notice the comment that scanner classes are still experimental, so I'm
+&#62; not too hopeful)?
+
+What you need to do is derive a subclass from yyFlexLexer that provides
+the above yylex() method, squirrels away lvalp and parm into member
+variables, and then invokes yyFlexLexer::yylex() to do the regular scanning.
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC109" HREF="flex_toc.html#TOC109">unnamed-faq-56</A></H2>
+
+<PRE>
+@verbatim
+To: Mikael.Latvala@lmf.ericsson.se
+Subject: Re: Possible mistake in Flex v2.5 document
+In-reply-to: Your message of Fri, 05 Sep 1997 16:07:24 PDT.
+Date: Fri, 05 Sep 1997 10:01:54 PDT
+From: Vern Paxson &#60;vern&#62;
+
+&#62; In that example you show how to count comment lines when using
+&#62; C style /* ... */ comments. My question is, shouldn't you take into
+&#62; account a scenario where end of a comment marker occurs inside
+&#62; character or string literals?
+
+The scanner certainly needs to also scan character and string literals.
+However it does that (there's an example in the man page for strings), the
+lexer will recognize the beginning of the literal before it runs across the
+embedded "/*".  Consequently, it will finish scanning the literal before it
+even considers the possibility of matching "/*".
+
+Example:
+
+        '([^']*|{ESCAPE_SEQUENCE})'
+
+will match all the text between the ''s (inclusive).  So the lexer
+considers this as a token beginning at the first ', and doesn't even
+attempt to match other tokens inside it.
+
+I thinnk this subtlety is not worth putting in the manual, as I suspect
+it would confuse more people than it would enlighten.
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC110" HREF="flex_toc.html#TOC110">unnamed-faq-57</A></H2>
+
+<PRE>
+@verbatim
+To: "Marty Leisner" &#60;leisner@sdsp.mc.xerox.com&#62;
+Subject: Re: flex limitations
+In-reply-to: Your message of Sat, 06 Sep 1997 11:27:21 PDT.
+Date: Mon, 08 Sep 1997 11:38:08 PDT
+From: Vern Paxson &#60;vern&#62;
+
+&#62; %%
+&#62; [a-zA-Z]+       /* skip a line */
+&#62;                 {  printf("got %s\n", yytext); }
+&#62; %%
+
+What version of flex are you using?  If I feed this to 2.5.4, it complains:
+
+        "bug.l", line 5: EOF encountered inside an action
+        "bug.l", line 5: unrecognized rule
+        "bug.l", line 5: fatal parse error
+
+Not the world's greatest error message, but it manages to flag the problem.
+
+(With the introduction of start condition scopes, flex can't accommodate
+an action on a separate line, since it's ambiguous with an indented rule.)
+
+You can get 2.5.4 from ftp.ee.lbl.gov.
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC111" HREF="flex_toc.html#TOC111">unnamed-faq-58</A></H2>
+
+<PRE>
+@verbatim
+To: uocarroll@deagostini.co.uk (Ultan O'Carroll)
+Subject: Re: Flex repositries
+In-reply-to: Your message of Fri, 12 Sep 1997 15:02:28 PDT.
+Date: Fri, 12 Sep 1997 10:31:50 PDT
+From: Vern Paxson &#60;vern&#62;
+
+&#62;      before I start beavering away I wonder if you know of any
+&#62;      place/libraries for flex
+&#62;      desciption files that might already do this or give me a head start ?
+
+Unfortunately, no, I don't.  You might try asking on comp.compilers.
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC112" HREF="flex_toc.html#TOC112">unnamed-faq-59</A></H2>
+
+<PRE>
+@verbatim
+To: Adoram Rogel &#60;adoram@hybridge.com&#62;
+Subject: Re: Conditional compiling in the definitions section
+In-reply-to: Your message of Thu, 25 Sep 1997 11:22:42 PDT.
+Date: Thu, 25 Sep 1997 10:56:31 PDT
+From: Vern Paxson &#60;vern&#62;
+
+&#62; I'm trying to combine two large lex files that now differ only in
+&#62; about 10 lines in the definitions section.
+&#62; I would like to have something like this:
+&#62; #ifdef FFF
+&#62; it        \&#60;IT\&#62;
+&#62; #else
+&#62; it        \&#60;I\&#62;
+&#62; #endif
+&#62;
+&#62; Now, I can't add states for these, as I have already too many states
+&#62; and the program is very complicated, and I won't be able to handle
+&#62; 10 or 20 more states.
+&#62;
+&#62; Any trick to do this ?
+
+You might try using m4, or the C preprocessor plus a sed script to
+clean up the result (strip out the #line's).
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC113" HREF="flex_toc.html#TOC113">unnamed-faq-60</A></H2>
+
+<PRE>
+@verbatim
+To: Steve Antoch &#60;SteveAn@visio.com&#62;
+Subject: Re: lex and yacc grammars
+In-reply-to: Your message of Mon, 17 Nov 1997 15:31:25 PST.
+Date: Mon, 17 Nov 1997 15:27:01 PST
+From: Vern Paxson &#60;vern&#62;
+
+&#62; Would you happen to know where I can find grammars for lex and yacc?
+
+The flex sources have a grammar for (f)lex.  Dunno about yacc,
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC114" HREF="flex_toc.html#TOC114">unnamed-faq-61</A></H2>
+
+<PRE>
+@verbatim
+To: Bryan Housel &#60;bryan@drawcomp.com&#62;
+Subject: Re: Question about Flex v2.5
+In-reply-to: Your message of Tue, 11 Nov 1997 21:30:23 PST.
+Date: Mon, 17 Nov 1997 17:12:21 PST
+From: Vern Paxson &#60;vern&#62;
+
+&#62; It prints one of those "end of buffer.." messages for each character in the
+&#62; token...
+
+This will happen if your LexerInput() function returns only one character
+at a time, which can happen either if you're scanner is "interactive", or
+if the streams library on your platform always returns 1 for yyin-&#62;gcount().
+
+Solution: override LexerInput() with a version that returns whole buffers.
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC115" HREF="flex_toc.html#TOC115">unnamed-faq-62</A></H2>
+
+<PRE>
+@verbatim
+To: Georg.Rehm@CL-KI.Uni-Osnabrueck.DE
+Subject: Re: Flex maximums
+In-reply-to: Your message of Mon, 17 Nov 1997 17:16:06 PST.
+Date: Mon, 17 Nov 1997 17:16:15 PST
+From: Vern Paxson &#60;vern&#62;
+
+&#62; I took a quick look into the flex-sources and altered some #defines in
+&#62; flexdefs.h:
+&#62;
+&#62;   #define INITIAL_MNS 64000
+&#62;   #define MNS_INCREMENT 1024000
+&#62;   #define MAXIMUM_MNS 64000
+
+The things to fix are to add a couple of zeroes to:
+
+#define JAMSTATE -32766 /* marks a reference to the state that always jams */
+#define MAXIMUM_MNS 31999
+#define BAD_SUBSCRIPT -32767
+#define MAX_SHORT 32700
+
+and, if you get complaints about too many rules, make the following change too:
+
+        #define YY_TRAILING_MASK 0x200000
+        #define YY_TRAILING_HEAD_MASK 0x400000
+
+- Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC116" HREF="flex_toc.html#TOC116">unnamed-faq-63</A></H2>
+
+<PRE>
+@verbatim
+To: jimmey@lexis-nexis.com (Jimmey Todd)
+Subject: Re: FLEX question regarding istream vs ifstream
+In-reply-to: Your message of Mon, 08 Dec 1997 15:54:15 PST.
+Date: Mon, 15 Dec 1997 13:21:35 PST
+From: Vern Paxson &#60;vern&#62;
+
+&#62;         stdin_handle = YY_CURRENT_BUFFER;
+&#62;         ifstream fin( "aFile" );
+&#62;         yy_switch_to_buffer( yy_create_buffer( fin, YY_BUF_SIZE ) );
+&#62;
+&#62; What I'm wanting to do, is pass the contents of a file thru one set
+&#62; of rules and then pass stdin thru another set... It works great if, I
+&#62; don't use the C++ classes. But since everything else that I'm doing is
+&#62; in C++, I thought I'd be consistent.
+&#62;
+&#62; The problem is that 'yy_create_buffer' is expecting an istream* as it's
+&#62; first argument (as stated in the man page). However, fin is a ifstream
+&#62; object. Any ideas on what I might be doing wrong? Any help would be
+&#62; appreciated. Thanks!!
+
+You need to pass &#38;fin, to turn it into an ifstream* instead of an ifstream.
+Then its type will be compatible with the expected istream*, because ifstream
+is derived from istream.
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC117" HREF="flex_toc.html#TOC117">unnamed-faq-64</A></H2>
+
+<PRE>
+@verbatim
+To: Enda Fadian &#60;fadiane@piercom.ie&#62;
+Subject: Re: Question related to Flex man page?
+In-reply-to: Your message of Tue, 16 Dec 1997 15:17:34 PST.
+Date: Tue, 16 Dec 1997 14:17:09 PST
+From: Vern Paxson &#60;vern&#62;
+
+&#62; Can you explain to me what is ment by a long-jump in relation to flex?
+
+Using the longjmp() function while inside yylex() or a routine called by it.
+
+&#62; what is the flex activation frame.
+
+Just yylex()'s stack frame.
+
+&#62; As far as I can see yyrestart will bring me back to the sart of the input
+&#62; file and using flex++ isnot really an option!
+
+No, yyrestart() doesn't imply a rewind, even though its name might sound
+like it does.  It tells the scanner to flush its internal buffers and
+start reading from the given file at its present location.
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC118" HREF="flex_toc.html#TOC118">unnamed-faq-65</A></H2>
+
+<PRE>
+@verbatim
+To: hassan@larc.info.uqam.ca (Hassan Alaoui)
+Subject: Re: Need urgent Help
+In-reply-to: Your message of Sat, 20 Dec 1997 19:38:19 PST.
+Date: Sun, 21 Dec 1997 21:30:46 PST
+From: Vern Paxson &#60;vern&#62;
+
+&#62; /usr/lib/yaccpar: In function `int yyparse()':
+&#62; /usr/lib/yaccpar:184: warning: implicit declaration of function `int yylex(...)'
+&#62;
+&#62; ld: Undefined symbol
+&#62;    _yylex
+&#62;    _yyparse
+&#62;    _yyin
+
+This is a known problem with Solaris C++ (and/or Solaris yacc).  I believe
+the fix is to explicitly insert some 'extern "C"' statements for the
+corresponding routines/symbols.
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC119" HREF="flex_toc.html#TOC119">unnamed-faq-66</A></H2>
+
+<PRE>
+@verbatim
+To: mc0307@mclink.it
+Cc: gnu@prep.ai.mit.edu
+Subject: Re: [mc0307@mclink.it: Help request]
+In-reply-to: Your message of Fri, 12 Dec 1997 17:57:29 PST.
+Date: Sun, 21 Dec 1997 22:33:37 PST
+From: Vern Paxson &#60;vern&#62;
+
+&#62; This is my definition for float and integer types:
+&#62; . . .
+&#62; NZD          [1-9]
+&#62; ...
+&#62; I've tested my program on other lex version (on UNIX Sun Solaris an HP
+&#62; UNIX) and it work well, so I think that my definitions are correct.
+&#62; There are any differences between Lex and Flex?
+
+There are indeed differences, as discussed in the man page.  The one
+you are probably running into is that when flex expands a name definition,
+it puts parentheses around the expansion, while lex does not.  There's
+an example in the man page of how this can lead to different matching.
+Flex's behavior complies with the POSIX standard (or at least with the
+last POSIX draft I saw).
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC120" HREF="flex_toc.html#TOC120">unnamed-faq-67</A></H2>
+
+<PRE>
+@verbatim
+To: hassan@larc.info.uqam.ca (Hassan Alaoui)
+Subject: Re: Thanks
+In-reply-to: Your message of Mon, 22 Dec 1997 16:06:35 PST.
+Date: Mon, 22 Dec 1997 14:35:05 PST
+From: Vern Paxson &#60;vern&#62;
+
+&#62; Thank you very much for your help. I compile and link well with C++ while
+&#62; declaring 'yylex ...' extern, But a little problem remains. I get a
+&#62; segmentation default when executing ( I linked with lfl library) while it
+&#62; works well when using LEX instead of flex. Do you have some ideas about the
+&#62; reason for this ?
+
+The one possible reason for this that comes to mind is if you've defined
+yytext as "extern char yytext[]" (which is what lex uses) instead of
+"extern char *yytext" (which is what flex uses).  If it's not that, then
+I'm afraid I don't know what the problem might be.
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC121" HREF="flex_toc.html#TOC121">unnamed-faq-68</A></H2>
+
+<PRE>
+@verbatim
+To: "Bart Niswonger" &#60;NISWONGR@almaden.ibm.com&#62;
+Subject: Re: flex 2.5: c++ scanners &#38; start conditions
+In-reply-to: Your message of Tue, 06 Jan 1998 10:34:21 PST.
+Date: Tue, 06 Jan 1998 19:19:30 PST
+From: Vern Paxson &#60;vern&#62;
+
+&#62; The problem is that when I do this (using %option c++) start
+&#62; conditions seem to not apply.
+
+The BEGIN macro modifies the yy_start variable.  For C scanners, this
+is a static with scope visible through the whole file.  For C++ scanners,
+it's a member variable, so it only has visible scope within a member
+function.  Your lexbegin() routine is not a member function when you
+build a C++ scanner, so it's not modifying the correct yy_start.  The
+diagnostic that indicates this is that you found you needed to add
+a declaration of yy_start in order to get your scanner to compile when
+using C++; instead, the correct fix is to make lexbegin() a member
+function (by deriving from yyFlexLexer).
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC122" HREF="flex_toc.html#TOC122">unnamed-faq-69</A></H2>
+
+<PRE>
+@verbatim
+To: "Boris Zinin" &#60;boris@ippe.rssi.ru&#62;
+Subject: Re: current position in flex buffer
+In-reply-to: Your message of Mon, 12 Jan 1998 18:58:23 PST.
+Date: Mon, 12 Jan 1998 12:03:15 PST
+From: Vern Paxson &#60;vern&#62;
+
+&#62; The problem is how to determine the current position in flex active
+&#62; buffer when a rule is matched....
+
+You will need to keep track of this explicitly, such as by redefining
+YY_USER_ACTION to count the number of characters matched.
+
+The latest flex release, by the way, is 2.5.4, available from ftp.ee.lbl.gov.
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC123" HREF="flex_toc.html#TOC123">unnamed-faq-70</A></H2>
+
+<PRE>
+@verbatim
+To: Bik.Dhaliwal@bis.org
+Subject: Re: Flex question
+In-reply-to: Your message of Mon, 26 Jan 1998 13:05:35 PST.
+Date: Tue, 27 Jan 1998 22:41:52 PST
+From: Vern Paxson &#60;vern&#62;
+
+&#62; That requirement involves knowing
+&#62; the character position at which a particular token was matched
+&#62; in the lexer.
+
+The way you have to do this is by explicitly keeping track of where
+you are in the file, by counting the number of characters scanned
+for each token (available in yyleng).  It may prove convenient to
+do this by redefining YY_USER_ACTION, as described in the manual.
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC124" HREF="flex_toc.html#TOC124">unnamed-faq-71</A></H2>
+
+<PRE>
+@verbatim
+To: Vladimir Alexiev &#60;vladimir@cs.ualberta.ca&#62;
+Subject: Re: flex: how to control start condition from parser?
+In-reply-to: Your message of Mon, 26 Jan 1998 05:50:16 PST.
+Date: Tue, 27 Jan 1998 22:45:37 PST
+From: Vern Paxson &#60;vern&#62;
+
+&#62; It seems useful for the parser to be able to tell the lexer about such
+&#62; context dependencies, because then they don't have to be limited to
+&#62; local or sequential context.
+
+One way to do this is to have the parser call a stub routine that's
+included in the scanner's .l file, and consequently that has access ot
+BEGIN.  The only ugliness is that the parser can't pass in the state
+it wants, because those aren't visible - but if you don't have many
+such states, then using a different set of names doesn't seem like
+to much of a burden.
+
+While generating a .h file like you suggests is certainly cleaner,
+flex development has come to a virtual stand-still :-(, so a workaround
+like the above is much more pragmatic than waiting for a new feature.
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC125" HREF="flex_toc.html#TOC125">unnamed-faq-72</A></H2>
+
+<PRE>
+@verbatim
+To: Barbara Denny &#60;denny@3com.com&#62;
+Subject: Re: freebsd flex bug?
+In-reply-to: Your message of Fri, 30 Jan 1998 12:00:43 PST.
+Date: Fri, 30 Jan 1998 12:42:32 PST
+From: Vern Paxson &#60;vern&#62;
+
+&#62; lex.yy.c:1996: parse error before `='
+
+This is the key, identifying this error.  (It may help to pinpoint
+it by using flex -L, so it doesn't generate #line directives in its
+output.)  I will bet you heavy money that you have a start condition
+name that is also a variable name, or something like that; flex spits
+out #define's for each start condition name, mapping them to a number,
+so you can wind up with:
+
+        %x foo
+        %%
+                ...
+        %%
+        void bar()
+                {
+                int foo = 3;
+                }
+
+and the penultimate will turn into "int 1 = 3" after C preprocessing,
+since flex will put "#define foo 1" in the generated scanner.
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC126" HREF="flex_toc.html#TOC126">unnamed-faq-73</A></H2>
+
+<PRE>
+@verbatim
+To: Maurice Petrie &#60;mpetrie@infoscigroup.com&#62;
+Subject: Re: Lost flex .l file
+In-reply-to: Your message of Mon, 02 Feb 1998 14:10:01 PST.
+Date: Mon, 02 Feb 1998 11:15:12 PST
+From: Vern Paxson &#60;vern&#62;
+
+&#62; I am curious as to
+&#62; whether there is a simple way to backtrack from the generated source to
+&#62; reproduce the lost list of tokens we are searching on.
+
+In theory, it's straight-forward to go from the DFA representation
+back to a regular-expression representation - the two are isomorphic.
+In practice, a huge headache, because you have to unpack all the tables
+back into a single DFA representation, and then write a program to munch
+on that and translate it into an RE.
+
+Sorry for the less-than-happy news ...
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC127" HREF="flex_toc.html#TOC127">unnamed-faq-74</A></H2>
+
+<PRE>
+@verbatim
+To: jimmey@lexis-nexis.com (Jimmey Todd)
+Subject: Re: Flex performance question
+In-reply-to: Your message of Thu, 19 Feb 1998 11:01:17 PST.
+Date: Thu, 19 Feb 1998 08:48:51 PST
+From: Vern Paxson &#60;vern&#62;
+
+&#62; What I have found, is that the smaller the data chunk, the faster the
+&#62; program executes. This is the opposite of what I expected. Should this be
+&#62; happening this way?
+
+This is exactly what will happen if your input file has embedded NULs.
+From the man page:
+
+A final note: flex is slow when matching NUL's, particularly
+when  a  token  contains multiple NUL's.  It's best to write
+rules which match short amounts of text if it's  anticipated
+that the text will often include NUL's.
+
+So that's the first thing to look for.
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC128" HREF="flex_toc.html#TOC128">unnamed-faq-75</A></H2>
+
+<PRE>
+@verbatim
+To: jimmey@lexis-nexis.com (Jimmey Todd)
+Subject: Re: Flex performance question
+In-reply-to: Your message of Thu, 19 Feb 1998 11:01:17 PST.
+Date: Thu, 19 Feb 1998 15:42:25 PST
+From: Vern Paxson &#60;vern&#62;
+
+So there are several problems.
+
+First, to go fast, you want to match as much text as possible, which
+your scanners don't in the case that what they're scanning is *not*
+a &#60;RN&#62; tag.  So you want a rule like:
+
+        [^&#60;]+
+
+Second, C++ scanners are particularly slow if they're interactive,
+which they are by default.  Using -B speeds it up by a factor of 3-4
+on my workstation.
+
+Third, C++ scanners that use the istream interface are slow, because
+of how poorly implemented istream's are.  I built two versions of
+the following scanner:
+
+        %%
+        .*\n
+        .*
+        %%
+
+and the C version inhales a 2.5MB file on my workstation in 0.8 seconds.
+The C++ istream version, using -B, takes 3.8 seconds.
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC129" HREF="flex_toc.html#TOC129">unnamed-faq-76</A></H2>
+
+<PRE>
+@verbatim
+To: "Frescatore, David (CRD, TAD)" &#60;frescatore@exc01crdge.crd.ge.com&#62;
+Subject: Re: FLEX 2.5 &#38; THE YEAR 2000
+In-reply-to: Your message of Wed, 03 Jun 1998 11:26:22 PDT.
+Date: Wed, 03 Jun 1998 10:22:26 PDT
+From: Vern Paxson &#60;vern&#62;
+
+&#62; I am researching the Y2K problem with General Electric R&#38;D
+&#62; and need to know if there are any known issues concerning
+&#62; the above mentioned software and Y2K regardless of version.
+
+There shouldn't be, all it ever does with the date is ask the system
+for it and then print it out.
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC130" HREF="flex_toc.html#TOC130">unnamed-faq-77</A></H2>
+
+<PRE>
+@verbatim
+To: "Hans Dermot Doran" &#60;htd@ibhdoran.com&#62;
+Subject: Re: flex problem
+In-reply-to: Your message of Wed, 15 Jul 1998 21:30:13 PDT.
+Date: Tue, 21 Jul 1998 14:23:34 PDT
+From: Vern Paxson &#60;vern&#62;
+
+&#62; To overcome this, I gets() the stdin into a string and lex the string. The
+&#62; string is lexed OK except that the end of string isn't lexed properly
+&#62; (yy_scan_string()), that is the lexer dosn't recognise the end of string.
+
+Flex doesn't contain mechanisms for recognizing buffer endpoints.  But if
+you use fgets instead (which you should anyway, to protect against buffer
+overflows), then the final \n will be preserved in the string, and you can
+scan that in order to find the end of the string.
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC131" HREF="flex_toc.html#TOC131">unnamed-faq-78</A></H2>
+
+<PRE>
+@verbatim
+To: soumen@almaden.ibm.com
+Subject: Re: Flex++ 2.5.3 instance member vs. static member
+In-reply-to: Your message of Mon, 27 Jul 1998 02:10:04 PDT.
+Date: Tue, 28 Jul 1998 01:10:34 PDT
+From: Vern Paxson &#60;vern&#62;
+
+&#62; %{
+&#62; int mylineno = 0;
+&#62; %}
+&#62; ws      [ \t]+
+&#62; alpha   [A-Za-z]
+&#62; dig     [0-9]
+&#62; %%
+&#62;
+&#62; Now you'd expect mylineno to be a member of each instance of class
+&#62; yyFlexLexer, but is this the case?  A look at the lex.yy.cc file seems to
+&#62; indicate otherwise; unless I am missing something the declaration of
+&#62; mylineno seems to be outside any class scope.
+&#62;
+&#62; How will this work if I want to run a multi-threaded application with each
+&#62; thread creating a FlexLexer instance?
+
+Derive your own subclass and make mylineno a member variable of it.
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC132" HREF="flex_toc.html#TOC132">unnamed-faq-79</A></H2>
+
+<PRE>
+@verbatim
+To: Adoram Rogel &#60;adoram@hybridge.com&#62;
+Subject: Re: More than 32K states change hangs
+In-reply-to: Your message of Tue, 04 Aug 1998 16:55:39 PDT.
+Date: Tue, 04 Aug 1998 22:28:45 PDT
+From: Vern Paxson &#60;vern&#62;
+
+&#62; Vern Paxson,
+&#62;
+&#62; I followed your advice, posted on Usenet bu you, and emailed to me
+&#62; personally by you, on how to overcome the 32K states limit. I'm running
+&#62; on Linux machines.
+&#62; I took the full source of version 2.5.4 and did the following changes in
+&#62; flexdef.h:
+&#62; #define JAMSTATE -327660
+&#62; #define MAXIMUM_MNS 319990
+&#62; #define BAD_SUBSCRIPT -327670
+&#62; #define MAX_SHORT 327000
+&#62;
+&#62; and compiled.
+&#62; All looked fine, including check and bigcheck, so I installed.
+
+Hmmm, you shouldn't increase MAX_SHORT, though looking through my email
+archives I see that I did indeed recommend doing so.  Try setting it back
+to 32700; that should suffice that you no longer need -Ca.  If it still
+hangs, then the interesting question is - where?
+
+&#62; Compiling the same hanged program with a out-of-the-box (RedHat 4.2
+&#62; distribution of Linux)
+&#62; flex 2.5.4 binary works.
+
+Since Linux comes with source code, you should diff it against what
+you have to see what problems they missed.
+
+&#62; Should I always compile with the -Ca option now ? even short and simple
+&#62; filters ?
+
+No, definitely not.  It's meant to be for those situations where you
+absolutely must squeeze every last cycle out of your scanner.
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC133" HREF="flex_toc.html#TOC133">unnamed-faq-80</A></H2>
+
+<PRE>
+@verbatim
+To: "Schmackpfeffer, Craig" &#60;Craig.Schmackpfeffer@usa.xerox.com&#62;
+Subject: Re: flex output for static code portion
+In-reply-to: Your message of Tue, 11 Aug 1998 11:55:30 PDT.
+Date: Mon, 17 Aug 1998 23:57:42 PDT
+From: Vern Paxson &#60;vern&#62;
+
+&#62; I would like to use flex under the hood to generate a binary file
+&#62; containing the data structures that control the parse.
+
+This has been on the wish-list for a long time.  In principle it's
+straight-forward - you redirect mkdata() et al's I/O to another file,
+and modify the skeleton to have a start-up function that slurps these
+into dynamic arrays.  The concerns are (1) the scanner generation code
+is hairy and full of corner cases, so it's easy to get surprised when
+going down this path :-( ; and (2) being careful about buffering so
+that when the tables change you make sure the scanner starts in the
+correct state and reading at the right point in the input file.
+
+&#62; I was wondering if you know of anyone who has used flex in this way.
+
+I don't - but it seems like a reasonable project to undertake (unlike
+numerous other flex tweaks :-).
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC134" HREF="flex_toc.html#TOC134">unnamed-faq-81</A></H2>
+
+<PRE>
+@verbatim
+Received: from 131.173.17.11 (131.173.17.11 [131.173.17.11])
+        by ee.lbl.gov (8.9.1/8.9.1) with ESMTP id AAA03838
+        for &#60;vern@ee.lbl.gov&#62;; Thu, 20 Aug 1998 00:47:57 -0700 (PDT)
+Received: from hal.cl-ki.uni-osnabrueck.de (hal.cl-ki.Uni-Osnabrueck.DE [131.173.141.2])
+        by deimos.rz.uni-osnabrueck.de (8.8.7/8.8.8) with ESMTP id JAA34694
+        for &#60;vern@ee.lbl.gov&#62;; Thu, 20 Aug 1998 09:47:55 +0200
+Received: (from georg@localhost) by hal.cl-ki.uni-osnabrueck.de (8.6.12/8.6.12) id JAA34834 for vern@ee.lbl.gov; Thu, 20 Aug 1998 09:47:54 +0200
+From: Georg Rehm &#60;georg@hal.cl-ki.uni-osnabrueck.de&#62;
+Message-Id: &#60;199808200747.JAA34834@hal.cl-ki.uni-osnabrueck.de&#62;
+Subject: "flex scanner push-back overflow"
+To: vern@ee.lbl.gov
+Date: Thu, 20 Aug 1998 09:47:54 +0200 (MEST)
+Reply-To: Georg.Rehm@CL-KI.Uni-Osnabrueck.DE
+X-NoJunk: Do NOT send commercial mail, spam or ads to this address!
+X-URL: http://www.cl-ki.uni-osnabrueck.de/~georg/
+X-Mailer: ELM [version 2.4ME+ PL28 (25)]
+MIME-Version: 1.0
+Content-Type: text/plain; charset=US-ASCII
+Content-Transfer-Encoding: 7bit
+
+Hi Vern,
+
+Yesterday, I encountered a strange problem: I use the macro processor m4
+to include some lengthy lists into a .l file. Following is a flex macro
+definition that causes some serious pain in my neck:
+
+AUTHOR           ("A. Boucard / L. Boucard"|"A. Dastarac / M. Levent"|"A.Boucaud / L.Boucaud"|"Abderrahim Lamchichi"|"Achmat Dangor"|"Adeline Toullier"|"Adewale Maja-Pearce"|"Ahmed Ziri"|"Akram Ellyas"|"Alain Bihr"|"Alain Gresh"|"Alain Guillemoles"|"Alain Joxe"|"Alain Morice"|"Alain Renon"|"Alain Zecchini"|"Albert Memmi"|"Alberto Manguel"|"Alex De Waal"|"Alfonso Artico"| [...])
+
+The complete list contains about 10kB. When I try to "flex" this file
+(on a Solaris 2.6 machine, using a modified flex 2.5.4 (I only increased
+some of the predefined values in flexdefs.h) I get the error:
+
+myflex/flex -8  sentag.tmp.l
+flex scanner push-back overflow
+
+When I remove the slashes in the macro definition everything works fine.
+As I understand it, the double quotes escape the slash-character so it
+really means "/" and not "trailing context". Furthermore, I tried to
+escape the slashes with backslashes, but with no use, the same error message
+appeared when flexing the code.
+
+Do you have an idea what's going on here?
+
+Greetings from Germany,
+        Georg
+--
+Georg Rehm                                     georg@cl-ki.uni-osnabrueck.de
+Institute for Semantic Information Processing, University of Osnabrueck, FRG
+</PRE>
+
+
+
+<H2><A NAME="SEC135" HREF="flex_toc.html#TOC135">unnamed-faq-82</A></H2>
+
+<PRE>
+@verbatim
+To: Georg.Rehm@CL-KI.Uni-Osnabrueck.DE
+Subject: Re: "flex scanner push-back overflow"
+In-reply-to: Your message of Thu, 20 Aug 1998 09:47:54 PDT.
+Date: Thu, 20 Aug 1998 07:05:35 PDT
+From: Vern Paxson &#60;vern&#62;
+
+&#62; myflex/flex -8  sentag.tmp.l
+&#62; flex scanner push-back overflow
+
+Flex itself uses a flex scanner.  That scanner is running out of buffer
+space when it tries to unput() the humongous macro you've defined.  When
+you remove the '/'s, you make it small enough so that it fits in the buffer;
+removing spaces would do the same thing.
+
+The fix is to either rethink how come you're using such a big macro and
+perhaps there's another/better way to do it; or to rebuild flex's own
+scan.c with a larger value for
+
+        #define YY_BUF_SIZE 16384
+
+- Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC136" HREF="flex_toc.html#TOC136">unnamed-faq-83</A></H2>
+
+<PRE>
+@verbatim
+To: Jan Kort &#60;jan@research.techforce.nl&#62;
+Subject: Re: Flex
+In-reply-to: Your message of Fri, 04 Sep 1998 12:18:43 +0200.
+Date: Sat, 05 Sep 1998 00:59:49 PDT
+From: Vern Paxson &#60;vern&#62;
+
+&#62; %%
+&#62;
+&#62; "TEST1\n"       { fprintf(stderr, "TEST1\n"); yyless(5); }
+&#62; ^\n             { fprintf(stderr, "empty line\n"); }
+&#62; .               { }
+&#62; \n              { fprintf(stderr, "new line\n"); }
+&#62;
+&#62; %%
+&#62; -- input ---------------------------------------
+&#62; TEST1
+&#62; -- output --------------------------------------
+&#62; TEST1
+&#62; empty line
+&#62; ------------------------------------------------
+
+IMHO, it's not clear whether or not this is in fact a bug.  It depends
+on whether you view yyless() as backing up in the input stream, or as
+pushing new characters onto the beginning of the input stream.  Flex
+interprets it as the latter (for implementation convenience, I'll admit),
+and so considers the newline as in fact matching at the beginning of a
+line, as after all the last token scanned an entire line and so the
+scanner is now at the beginning of a new line.
+
+I agree that this is counter-intuitive for yyless(), given its
+functional description (it's less so for unput(), depending on whether
+you're unput()'ing new text or scanned text).  But I don't plan to
+change it any time soon, as it's a pain to do so.  Consequently,
+you do indeed need to use yy_set_bol() and YY_AT_BOL() to tweak
+your scanner into the behavior you desire.
+
+Sorry for the less-than-completely-satisfactory answer.
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC137" HREF="flex_toc.html#TOC137">unnamed-faq-84</A></H2>
+
+<PRE>
+@verbatim
+To: Patrick Krusenotto &#60;krusenot@mac-info-link.de&#62;
+Subject: Re: Problems with restarting flex-2.5.2-generated scanner
+In-reply-to: Your message of Thu, 24 Sep 1998 10:14:07 PDT.
+Date: Thu, 24 Sep 1998 23:28:43 PDT
+From: Vern Paxson &#60;vern&#62;
+
+&#62; I am using flex-2.5.2 and bison 1.25 for Solaris and I am desperately
+&#62; trying to make my scanner restart with a new file after my parser stops
+&#62; with a parse error. When my compiler restarts, the parser always
+&#62; receives the token after the token (in the old file!) that caused the
+&#62; parser error.
+
+I suspect the problem is that your parser has read ahead in order
+to attempt to resolve an ambiguity, and when it's restarted it picks
+up with that token rather than reading a fresh one.  If you're using
+yacc, then the special "error" production can sometimes be used to
+consume tokens in an attempt to get the parser into a consistent state.
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC138" HREF="flex_toc.html#TOC138">unnamed-faq-85</A></H2>
+
+<PRE>
+@verbatim
+To: Henric Jungheim &#60;junghelh@pe-nelson.com&#62;
+Subject: Re: flex 2.5.4a
+In-reply-to: Your message of Tue, 27 Oct 1998 16:41:42 PST.
+Date: Tue, 27 Oct 1998 16:50:14 PST
+From: Vern Paxson &#60;vern&#62;
+
+&#62; This brings up a feature request:  How about a command line
+&#62; option to specify the filename when reading from stdin?  That way one
+&#62; doesn't need to create a temporary file in order to get the "#line"
+&#62; directives to make sense.
+
+Use -o combined with -t (per the man page description of -o).
+
+&#62; P.S., Is there any simple way to use non-blocking IO to parse multiple
+&#62; streams?
+
+Simple, no.
+
+One approach might be to return a magic character on EWOULDBLOCK and
+have a rule
+
+        .*&#60;magic-character&#62;     // put back .*, eat magic character
+
+This is off the top of my head, not sure it'll work.
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC139" HREF="flex_toc.html#TOC139">unnamed-faq-86</A></H2>
+
+<PRE>
+@verbatim
+To: "Repko, Billy D" &#60;billy.d.repko@intel.com&#62;
+Subject: Re: Compiling scanners
+In-reply-to: Your message of Wed, 13 Jan 1999 10:52:47 PST.
+Date: Thu, 14 Jan 1999 00:25:30 PST
+From: Vern Paxson &#60;vern&#62;
+
+&#62; It appears that maybe it cannot find the lfl library.
+
+The Makefile in the distribution builds it, so you should have it.
+It's exceedingly trivial, just a main() that calls yylex() and
+a yyrap() that always returns 1.
+
+&#62; %%
+&#62;       \n      ++num_lines; ++num_chars;
+&#62;       .       ++num_chars;
+
+You can't indent your rules like this - that's where the errors are coming
+from.  Flex copies indented text to the output file, it's how you do things
+like
+
+        int num_lines_seen = 0;
+
+to declare local variables.
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC140" HREF="flex_toc.html#TOC140">unnamed-faq-87</A></H2>
+
+<PRE>
+@verbatim
+To: Erick Branderhorst &#60;Erick.Branderhorst@asml.nl&#62;
+Subject: Re: flex input buffer
+In-reply-to: Your message of Tue, 09 Feb 1999 13:53:46 PST.
+Date: Tue, 09 Feb 1999 21:03:37 PST
+From: Vern Paxson &#60;vern&#62;
+
+&#62; In the flex.skl file the size of the default input buffers is set.  Can you
+&#62; explain why this size is set and why it is such a high number.
+
+It's large to optimize performance when scanning large files.  You can
+safely make it a lot lower if needed.
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC141" HREF="flex_toc.html#TOC141">unnamed-faq-88</A></H2>
+
+<PRE>
+@verbatim
+To: "Guido Minnen" &#60;guidomi@cogs.susx.ac.uk&#62;
+Subject: Re: Flex error message
+In-reply-to: Your message of Wed, 24 Feb 1999 15:31:46 PST.
+Date: Thu, 25 Feb 1999 00:11:31 PST
+From: Vern Paxson &#60;vern&#62;
+
+&#62; I'm extending a larger scanner written in Flex and I keep running into
+&#62; problems. More specifically, I get the error message:
+&#62; "flex: input rules are too complicated (&#62;= 32000 NFA states)"
+
+Increase the definitions in flexdef.h for:
+
+#define JAMSTATE -32766 /* marks a reference to the state that always j
+ams */
+#define MAXIMUM_MNS 31999
+#define BAD_SUBSCRIPT -32767
+
+recompile everything, and it should all work.
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC142" HREF="flex_toc.html#TOC142">unnamed-faq-90</A></H2>
+
+<PRE>
+@verbatim
+To: "Dmitriy Goldobin" &#60;gold@ems.chel.su&#62;
+Subject: Re: FLEX trouble
+In-reply-to: Your message of Mon, 31 May 1999 18:44:49 PDT.
+Date: Tue, 01 Jun 1999 00:15:07 PDT
+From: Vern Paxson &#60;vern&#62;
+
+&#62;   I have a trouble with FLEX. Why rule "/*".*"*/" work properly,=20
+&#62; but rule "/*"(.|\n)*"*/" don't work ?
+
+The second of these will have to scan the entire input stream (because
+"(.|\n)*" matches an arbitrary amount of any text) in order to see if
+it ends with "*/", terminating the comment.  That potentially will overflow
+the input buffer.
+
+&#62;   More complex rule "/*"([^*]|(\*/[^/]))*"*/ give an error
+&#62; 'unrecognized rule'.
+
+You can't use the '/' operator inside parentheses.  It's not clear
+what "(a/b)*" actually means.
+
+&#62;   I now use workaround with state &#60;comment&#62;, but single-rule is
+&#62; better, i think.
+
+Single-rule is nice but will always have the problem of either setting
+restrictions on comments (like not allowing multi-line comments) and/or
+running the risk of consuming the entire input stream, as noted above.
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC143" HREF="flex_toc.html#TOC143">unnamed-faq-91</A></H2>
+
+<PRE>
+@verbatim
+Received: from mc-qout4.whowhere.com (mc-qout4.whowhere.com [209.185.123.18])
+        by ee.lbl.gov (8.9.3/8.9.3) with SMTP id IAA05100
+        for &#60;vern@ee.lbl.gov&#62;; Tue, 15 Jun 1999 08:56:06 -0700 (PDT)
+Received: from Unknown/Local ([?.?.?.?]) by my-deja.com; Tue Jun 15 08:55:43 1999
+To: vern@ee.lbl.gov
+Date: Tue, 15 Jun 1999 08:55:43 -0700
+From: "Aki Niimura" &#60;neko@my-deja.com&#62;
+Message-ID: &#60;KNONDOHDOBGAEAAA@my-deja.com&#62;
+Mime-Version: 1.0
+Cc:
+X-Sent-Mail: on
+Reply-To:
+X-Mailer: MailCity Service
+Subject: A question on flex C++ scanner
+X-Sender-Ip: 12.72.207.61
+Organization: My Deja Email  (http://www.my-deja.com:80)
+Content-Type: text/plain; charset=us-ascii
+Content-Transfer-Encoding: 7bit
+
+Dear Dr. Paxon,
+
+I have been using flex for years.
+It works very well on many projects.
+Most case, I used it to generate a scanner on C language.
+However, one project I needed to generate  a scanner
+on C++ lanuage. Thanks to your enhancement, flex did
+the job.
+
+Currently, I'm working on enhancing my previous project.
+I need to deal with multiple input streams (recursive
+inclusion) in this scanner (C++).
+I did similar thing for another scanner (C) as you
+explained in your documentation.
+
+The generated scanner (C++) has necessary methods:
+- switch_to_buffer(struct yy_buffer_state *b)
+- yy_create_buffer(istream *is, int sz)
+- yy_delete_buffer(struct yy_buffer_state *b)
+
+However, I couldn't figure out how to access current
+buffer (yy_current_buffer).
+
+yy_current_buffer is a protected member of yyFlexLexer.
+I can't access it directly.
+Then, I thought yy_create_buffer() with is = 0 might
+return current stream buffer. But it seems not as far
+as I checked the source. (flex 2.5.4)
+
+I went through the Web in addition to Flex documentation.
+However, it hasn't been successful, so far.
+
+It is not my intention to bother you, but, can you
+comment about how to obtain the current stream buffer?
+
+Your response would be highly appreciated.
+
+Best regards,
+Aki Niimura
+
+--== Sent via Deja.com http://www.deja.com/ ==--
+Share what you know. Learn what you don't.
+</PRE>
+
+
+
+<H2><A NAME="SEC144" HREF="flex_toc.html#TOC144">unnamed-faq-92</A></H2>
+
+<PRE>
+@verbatim
+To: neko@my-deja.com
+Subject: Re: A question on flex C++ scanner
+In-reply-to: Your message of Tue, 15 Jun 1999 08:55:43 PDT.
+Date: Tue, 15 Jun 1999 09:04:24 PDT
+From: Vern Paxson &#60;vern&#62;
+
+&#62; However, I couldn't figure out how to access current
+&#62; buffer (yy_current_buffer).
+
+Derive your own subclass from yyFlexLexer.
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC145" HREF="flex_toc.html#TOC145">unnamed-faq-93</A></H2>
+
+<PRE>
+@verbatim
+To: "Stones, Darren" &#60;Darren.Stones@nectech.co.uk&#62;
+Subject: Re: You're the man to see?
+In-reply-to: Your message of Wed, 23 Jun 1999 11:10:29 PDT.
+Date: Wed, 23 Jun 1999 09:01:40 PDT
+From: Vern Paxson &#60;vern&#62;
+
+&#62; I hope you can help me.  I am using Flex and Bison to produce an interpreted
+&#62; language.  However all goes well until I try to implement an IF statement or
+&#62; a WHILE.  I cannot get this to work as the parser parses all the conditions
+&#62; eg. the TRUE and FALSE conditons to check for a rule match.  So I cannot
+&#62; make a decision!!
+
+You need to use the parser to build a parse tree (= abstract syntax trwee),
+and when that's all done you recursively evaluate the tree, binding variables
+to values at that time.
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC146" HREF="flex_toc.html#TOC146">unnamed-faq-94</A></H2>
+
+<PRE>
+@verbatim
+To: Petr Danecek &#60;petr@ics.cas.cz&#62;
+Subject: Re: flex - question
+In-reply-to: Your message of Mon, 28 Jun 1999 19:21:41 PDT.
+Date: Fri, 02 Jul 1999 16:52:13 PDT
+From: Vern Paxson &#60;vern&#62;
+
+&#62; file, it takes an enormous amount of time. It is funny, because the
+&#62; source code has only 12 rules!!! I think it looks like an exponencial
+&#62; growth.
+
+Right, that's the problem - some patterns (those with a lot of
+ambiguity, where yours has because at any given time the scanner can
+be in the middle of all sorts of combinations of the different
+rules) blow up exponentially.
+
+For your rules, there is an easy fix.  Change the ".*" that comes fater
+the directory name to "[^ ]*".  With that in place, the rules are no
+longer nearly so ambiguous, because then once one of the directories
+has been matched, no other can be matched (since they all require a
+leading blank).
+
+If that's not an acceptable solution, then you can enter a start state
+to pick up the .*\n after each directory is matched.
+
+Also note that for speed, you'll want to add a ".*" rule at the end,
+otherwise rules that don't match any of the patterns will be matched
+very slowly, a character at a time.
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC147" HREF="flex_toc.html#TOC147">unnamed-faq-95</A></H2>
+
+<PRE>
+@verbatim
+To: Tielman Koekemoer &#60;tielman@spi.co.za&#62;
+Subject: Re: Please help.
+In-reply-to: Your message of Thu, 08 Jul 1999 13:20:37 PDT.
+Date: Thu, 08 Jul 1999 08:20:39 PDT
+From: Vern Paxson &#60;vern&#62;
+
+&#62; I was hoping you could help me with my problem.
+&#62;
+&#62; I tried compiling (gnu)flex on a Solaris 2.4 machine
+&#62; but when I ran make (after configure) I got an error.
+&#62;
+&#62; --------------------------------------------------------------
+&#62; gcc -c -I. -I. -g -O parse.c
+&#62; ./flex -t -p  ./scan.l &#62;scan.c
+&#62; sh: ./flex: not found
+&#62; *** Error code 1
+&#62; make: Fatal error: Command failed for target `scan.c'
+&#62; -------------------------------------------------------------
+&#62;
+&#62; What's strange to me is that I'm only
+&#62; trying to install flex now. I then edited the Makefile to
+&#62; and changed where it says "FLEX = flex" to "FLEX = lex"
+&#62; ( lex: the native Solaris one ) but then it complains about
+&#62; the "-p" option. Is there any way I can compile flex without
+&#62; using flex or lex?
+&#62;
+&#62; Thanks so much for your time.
+
+You managed to step on the bootstrap sequence, which first copies
+initscan.c to scan.c in order to build flex.  Try fetching a fresh
+distribution from ftp.ee.lbl.gov.  (Or you can first try removing
+".bootstrap" and doing a make again.)
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC148" HREF="flex_toc.html#TOC148">unnamed-faq-96</A></H2>
+
+<PRE>
+@verbatim
+To: Tielman Koekemoer &#60;tielman@spi.co.za&#62;
+Subject: Re: Please help.
+In-reply-to: Your message of Fri, 09 Jul 1999 09:16:14 PDT.
+Date: Fri, 09 Jul 1999 00:27:20 PDT
+From: Vern Paxson &#60;vern&#62;
+
+&#62; First I removed .bootstrap (and ran make) - no luck. I downloaded the
+&#62; software but I still have the same problem. Is there anything else I
+&#62; could try.
+
+Try:
+
+        cp initscan.c scan.c
+        touch scan.c
+        make scan.o
+
+If this last tries to first build scan.c from scan.l using ./flex, then
+your "make" is broken, in which case compile scan.c to scan.o by hand.
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC149" HREF="flex_toc.html#TOC149">unnamed-faq-97</A></H2>
+
+<PRE>
+@verbatim
+To: Sumanth Kamenani &#60;skamenan@crl.nmsu.edu&#62;
+Subject: Re: Error
+In-reply-to: Your message of Mon, 19 Jul 1999 23:08:41 PDT.
+Date: Tue, 20 Jul 1999 00:18:26 PDT
+From: Vern Paxson &#60;vern&#62;
+
+&#62; I am getting a compilation error. The error is given as "unknown symbol- yylex".
+
+The parser relies on calling yylex(), but you're instead using the C++ scanning
+class, so you need to supply a yylex() "glue" function that calls an instance
+scanner of the scanner (e.g., "scanner-&#62;yylex()").
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC150" HREF="flex_toc.html#TOC150">unnamed-faq-98</A></H2>
+
+<PRE>
+@verbatim
+To: daniel@synchrods.synchrods.COM (Daniel Senderowicz)
+Subject: Re: lex
+In-reply-to: Your message of Mon, 22 Nov 1999 11:19:04 PST.
+Date: Tue, 23 Nov 1999 15:54:30 PST
+From: Vern Paxson &#60;vern&#62;
+
+Well, your problem is the
+
+switch (yybgin-yysvec-1) {      /* witchcraft */
+
+at the beginning of lex rules.  "witchcraft" == "non-portable".  It's
+assuming knowledge of the AT&#38;T lex's internal variables.
+
+For flex, you can probably do the equivalent using a switch on YYSTATE.
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC151" HREF="flex_toc.html#TOC151">unnamed-faq-99</A></H2>
+
+<PRE>
+@verbatim
+To: archow@hss.hns.com
+Subject: Re: Regarding distribution of flex and yacc based grammars
+In-reply-to: Your message of Sun, 19 Dec 1999 17:50:24 +0530.
+Date: Wed, 22 Dec 1999 01:56:24 PST
+From: Vern Paxson &#60;vern&#62;
+
+&#62; When we provide the customer with an object code distribution, is it
+&#62; necessary for us to provide source
+&#62; for the generated C files from flex and bison since they are generated by
+&#62; flex and bison ?
+
+For flex, no.  I don't know what the current state of this is for bison.
+
+&#62; Also, is there any requrirement for us to neccessarily  provide source for
+&#62; the grammar files which are fed into flex and bison ?
+
+Again, for flex, no.
+
+See the file "COPYING" in the flex distribution for the legalese.
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC152" HREF="flex_toc.html#TOC152">unnamed-faq-100</A></H2>
+
+<PRE>
+@verbatim
+To: Martin Gallwey &#60;gallweym@hyperion.moe.ul.ie&#62;
+Subject: Re: Flex, and self referencing rules
+In-reply-to: Your message of Sun, 20 Feb 2000 01:01:21 PST.
+Date: Sat, 19 Feb 2000 18:33:16 PST
+From: Vern Paxson &#60;vern&#62;
+
+&#62; However, I do not use unput anywhere. I do use self-referencing
+&#62; rules like this:
+&#62;
+&#62; UnaryExpr               ({UnionExpr})|("-"{UnaryExpr})
+
+You can't do this - flex is *not* a parser like yacc (which does indeed
+allow recursion), it is a scanner that's confined to regular expressions.
+
+                Vern
+</PRE>
+
+
+
+<H2><A NAME="SEC153" HREF="flex_toc.html#TOC153">unnamed-faq-101</A></H2>
+
+<PRE>
+@verbatim
+To: slg3@lehigh.edu (SAMUEL L. GULDEN)
+Subject: Re: Flex problem
+In-reply-to: Your message of Thu, 02 Mar 2000 12:29:04 PST.
+Date: Thu, 02 Mar 2000 23:00:46 PST
+From: Vern Paxson &#60;vern&#62;
+
+If this is exactly your program:
+
+&#62; digit [0-9]
+&#62; digits {digit}+
+&#62; whitespace [ \t\n]+
+&#62;
+&#62; %%
+&#62; "[" { printf("open_brac\n");}
+&#62; "]" { printf("close_brac\n");}
+&#62; "+" { printf("addop\n");}
+&#62; "*" { printf("multop\n");}
+&#62; {digits} { printf("NUMBER = %s\n", yytext);}
+&#62; whitespace ;
+
+then the problem is that the last rule needs to be "{whitespace}" !
+
+                Vern
+</PRE>
+
+
+
+<H1><A NAME="SEC154" HREF="flex_toc.html#TOC154">Appendices</A></H1>
+
+
+
+<H2><A NAME="SEC155" HREF="flex_toc.html#TOC155">Makefiles and Flex</A></H2>
+
+<P>
+<A NAME="IDX463"></A>
 
 
 <P>
@@ -6037,7 +8731,7 @@
 <P>
 Modern @command{make} programs understand that <TT>`foo.l'</TT> is intended to
 generate <TT>`lex.yy.c'</TT> or <TT>`foo.c'</TT>, and will behave
-accordingly<A NAME="DOCF2" HREF="flex_foot.html#FOOT2">(2)</A> and GNU @command{automake} are two such
+accordingly<A NAME="DOCF3" HREF="flex_foot.html#FOOT3">(3)</A> and GNU @command{automake} are two such
 programs that provide implicit rules for flex-generated scanners.}.  The
 following Makefile does not explicitly instruct @command{make} how to build
 <TT>`foo.c'</TT> from <TT>`foo.l'</TT>. Instead, it relies on the implicit rules of the
@@ -6045,7 +8739,7 @@
 
 
 <P>
-<A NAME="IDX298"></A>
+<A NAME="IDX464"></A>
 
 <PRE>
 @verbatim
@@ -6065,7 +8759,7 @@
 
 
 <P>
-<A NAME="IDX299"></A>
+<A NAME="IDX465"></A>
 
 <PRE>
 @verbatim
@@ -6097,7 +8791,7 @@
 
 <P>
 Finally, we provide a realistic example of a <CODE>flex</CODE> scanner used with a
-<CODE>bison</CODE> parser<A NAME="DOCF3" HREF="flex_foot.html#FOOT3">(3)</A>.
+<CODE>bison</CODE> parser<A NAME="DOCF4" HREF="flex_foot.html#FOOT4">(4)</A>.
 There is a tricky problem we have to deal with. Since a <CODE>flex</CODE> scanner
 will typically include a header file (e.g., <TT>`y.tab.h'</TT>) generated by the
 parser, we need to be sure that the header file is generated BEFORE the scanner
@@ -6145,28 +8839,155 @@
 
 
 
-<H1><A NAME="SEC81" HREF="flex_toc.html#TOC81">Indices</A></H1>
+<H2><A NAME="SEC156" HREF="flex_toc.html#TOC156">C Scanners with Bison Parsers</A></H2>
 
+<P>
+<A NAME="IDX466"></A>
+<A NAME="IDX467"></A>
+<A NAME="IDX468"></A>
+<A NAME="IDX469"></A>
+<A NAME="IDX470"></A>
 
 
-<H2><A NAME="SEC82" HREF="flex_toc.html#TOC82">Concept Index</A></H2>
 <P>
-<A NAME="IDX300"></A>
-<A NAME="IDX301"></A>
-<A NAME="IDX302"></A>
-<A NAME="IDX303"></A>
-<A NAME="IDX304"></A>
-<A NAME="IDX305"></A>
-<A NAME="IDX306"></A>
-<A NAME="IDX307"></A>
-<A NAME="IDX308"></A>
-<A NAME="IDX309"></A>
-<A NAME="IDX310"></A>
+This section describes the <CODE>flex</CODE> features useful when integrating
+<CODE>flex</CODE> with <CODE>GNU bison</CODE><A NAME="DOCF5" HREF="flex_foot.html#FOOT5">(5)</A>.
+Skip this section if you are not using
+<CODE>bison</CODE> with your scanner.  Here we discuss only the <CODE>flex</CODE>
+half of the <CODE>flex</CODE> and <CODE>bison</CODE> pair.  We do not discuss
+<CODE>bison</CODE> in any detail.  For more information about generating
+<CODE>bison</CODE> parsers, see section `Top' in <CITE>the GNU Bison Manual</CITE>.
+
+
+<P>
+A compatible <CODE>bison</CODE> scanner is generated by declaring <SAMP>`%option
+bison-bridge'</SAMP> or by supplying <SAMP>`--bison-bridge'</SAMP> when invoking <CODE>flex</CODE>
+from the command line.  This instructs <CODE>flex</CODE> that the macros
+<CODE>yylval</CODE> and <CODE>yylloc</CODE> may be used. The data types for
+<CODE>yylval</CODE> and <CODE>yylloc</CODE>, (<CODE>YYSTYPE</CODE> and <CODE>YYLTYPE</CODE>,
+are typically defined in a header file, included in section 1 of the
+<CODE>flex</CODE> input file.  If <CODE>%option bison-bridge</CODE> is
+specified, <CODE>flex</CODE> provides support for the functions
+<CODE>yyget_lval</CODE>, <CODE>yyset_lval</CODE>, <CODE>yyget_lloc</CODE>, and
+<CODE>yyset_lloc</CODE>, defined below, and the corresponding macros
+<CODE>yylval</CODE> and <CODE>yylloc</CODE>, for use within actions.
+
+
+<P>
+<DL>
+<DT><U>Function:</U> YYSTYPE* <B>yyget_lval</B> <I>( yyscan_t scanner )</I>
+<DD><A NAME="IDX471"></A>
+</DL>
+<DL>
+<DT><U>Function:</U> YYLTYPE* <B>yyget_lloc</B> <I>( yyscan_t scanner )</I>
+<DD><A NAME="IDX472"></A>
+</DL>
+
+
+<P>
+<DL>
+<DT><U>Function:</U> void <B>yyset_lval</B> <I>( YYSTYPE* lvalp, yyscan_t scanner )</I>
+<DD><A NAME="IDX473"></A>
+</DL>
+<DL>
+<DT><U>Function:</U> void <B>yyset_lloc</B> <I>( YYLTYPE* llocp, yyscan_t scanner )</I>
+<DD><A NAME="IDX474"></A>
+</DL>
+
+
+<P>
+Where yyscan_t is defined in the reentrant scanner <A NAME="DOCF6" HREF="flex_foot.html#FOOT6">(6)</A>.  Accordingly, the declaration of
+yylex becomes one of the following:
+
+
+<P>
+<A NAME="IDX475"></A>
+
+<PRE>
+@verbatim
+      int yylex ( YYSTYPE * lvalp, yyscan_t scanner );
+      int yylex ( YYSTYPE * lvalp, YYLTYPE * llocp, yyscan_t scanner );
+</PRE>
+
+<P>
+Note that the macros <CODE>yylval</CODE> and <CODE>yylloc</CODE> evaluate to
+pointers.  Support for <CODE>yylloc</CODE> is optional in <CODE>bison</CODE>, so it
+is optional in <CODE>flex</CODE> as well. This support is automatically
+handled by <CODE>flex</CODE>.  Specifically, support for <CODE>yyloc</CODE> is only
+present in a <CODE>flex</CODE> scanner if the preprocessor symbol
+<CODE>YYLTYPE</CODE> is defined.  The following is an example of a <CODE>flex</CODE>
+scanner that is compatible with <CODE>bison</CODE>.
+
+
+<P>
+<A NAME="IDX476"></A>
+
+<PRE>
+@verbatim
+    /* Scanner for "C" assignment statements... sort of. */
+    %{
+    #include "y.tab.h"  /* Generated by bison. */
+    %}
+
+    %option reentrant-bison
+    %
+
+    [[:digit:]]+  { yylval-&#62;num = atoi(yytext);   return NUMBER;}
+    [[:alnum:]]+  { yylval-&#62;str = strdup(yytext); return STRING;}
+    "="|";"       { return yytext[0];}
+    .  {}
+    %
+</PRE>
+
+<P>
+As you can see, there really is no magic here. We just use
+<CODE>yylval</CODE> as we would any other variable. The data type of
+<CODE>yylval</CODE> is generated by <CODE>bison</CODE>, and included in the file
+<TT>`y.tab.h'</TT>. Here is the corresponding <CODE>bison</CODE> parser:
+
+
+<P>
+<A NAME="IDX477"></A>
+
+<PRE>
+@verbatim
+    /* Parser to convert "C" assignments to lisp. */
+    %{
+    /* Pass the argument to yyparse through to yylex. */
+    #define YYPARSE_PARAM scanner
+    #define YYLEX_PARAM   scanner
+    %}
+    %pure_parser
+    %union {
+        int num;
+        char* str;
+    }
+    %token &#60;str&#62; STRING
+    %token &#60;num&#62; NUMBER
+    %%
+    assignment:
+        STRING '=' NUMBER ';' {
+            printf( "(setf %s %d)", $1, $3 );
+       }
+    ;
+</PRE>
+
+
+
+<H1><A NAME="SEC157" HREF="flex_toc.html#TOC157">Indices</A></H1>
+
+
+
+<H2><A NAME="SEC158" HREF="flex_toc.html#TOC158">Concept Index</A></H2>
+
+<P>
 Jump to:
 <A HREF="#cindex_$">$</A>
 -
 <A HREF="#cindex_%">%</A>
 -
+<A HREF="#cindex_<">&#60;</A>
+-
 <A HREF="#cindex_[">[</A>
 -
 <A HREF="#cindex_^">^</A>
@@ -6183,6 +9004,8 @@
 -
 <A HREF="#cindex_f">f</A>
 -
+<A HREF="#cindex_g">g</A>
+-
 <A HREF="#cindex_h">h</A>
 -
 <A HREF="#cindex_i">i</A>
@@ -6215,260 +9038,366 @@
 <P>
 <H2><A NAME="cindex_$">$</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX303">$ -- see EOL</A>
+<LI><A HREF="flex.html#IDX74">$ as normal character in patterns</A>
 </DIR>
 <H2><A NAME="cindex_%">%</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX65">%array, use of</A>
-<LI><A HREF="flex.html#IDX68">%array, with C++</A>
-<LI><A HREF="flex.html#IDX98">%pointer, caveat with unput()</A>
-<LI><A HREF="flex.html#IDX66">%pointer, use of</A>
-<LI><A HREF="flex.html#IDX15">%{ and %}, in Definitions Section</A>
-<LI><A HREF="flex.html#IDX73">%{ and %}, in Rules Section</A>
+<LI><A HREF="flex.html#IDX93">%array, advantages of</A>
+<LI><A HREF="flex.html#IDX90">%array, use of</A>
+<LI><A HREF="flex.html#IDX94">%array, with C++</A>
+<LI><A HREF="flex.html#IDX124">%pointer, caveat with unput()</A>
+<LI><A HREF="flex.html#IDX91">%pointer, use of</A>
+<LI><A HREF="flex.html#IDX24">%{ and %}, in Definitions Section</A>
+<LI><A HREF="flex.html#IDX99">%{ and %}, in Rules Section</A>
+</DIR>
+<H2><A NAME="cindex_<">&#60;</A></H2>
+<DIR>
+<LI><A HREF="flex.html#IDX199">&#60;&#60;EOF&#62;&#62;, use of</A>
 </DIR>
 <H2><A NAME="cindex_[">[</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX33">[] in patterns</A>
+<LI><A HREF="flex.html#IDX39">[] in patterns</A>
 </DIR>
 <H2><A NAME="cindex_^">^</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX301">^ -- see BOL</A>
+<LI><A HREF="flex.html#IDX73">^ as non-special character in patterns</A>
 </DIR>
 <H2><A NAME="cindex_a">a</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX75">actions, embedded C strings</A>
-<LI><A HREF="flex.html#IDX69">actions, explanation</A>
-<LI><A HREF="flex.html#IDX183">actions, redefining YY_BREAK</A>
-<LI><A HREF="flex.html#IDX74">actions, use of { and }</A>
-<LI><A HREF="flex.html#IDX308">allocating memory see memory</A>
-<LI><A HREF="flex.html#IDX201">arguments, command-line</A>
-<LI><A HREF="flex.html#IDX187">array, default size for yytext</A>
+<LI><A HREF="flex.html#IDX402">accessor functions, use of</A>
+<LI><A HREF="flex.html#IDX101">actions, embedded C strings</A>
+<LI><A HREF="flex.html#IDX95">actions, explanation</A>
+<LI><A HREF="flex.html#IDX209">actions, redefining YY_BREAK</A>
+<LI><A HREF="flex.html#IDX100">actions, use of { and }</A>
+<LI><A HREF="flex.html#IDX18">aliases, how to define</A>
+<LI><A HREF="flex.html#IDX227">arguments, command-line</A>
+<LI><A HREF="flex.html#IDX213">array, default size for yytext</A>
 </DIR>
 <H2><A NAME="cindex_b">b</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX208">backing up, example of eliminating</A>
-<LI><A HREF="flex.html#IDX83">BEGIN</A>
-<LI><A HREF="flex.html#IDX130">BEGIN, explanation</A>
-<LI><A HREF="flex.html#IDX300">beginning of line -- see BOL</A>
-<LI><A HREF="flex.html#IDX310">bison, see also yacc</A>
-<LI><A HREF="flex.html#IDX261">bison, with reentrant</A>
-<LI><A HREF="flex.html#IDX56">BOL, ^ as normal character</A>
-<LI><A HREF="flex.html#IDX181">BOL, checking the BOL flag</A>
-<LI><A HREF="flex.html#IDX179">BOL, setting it</A>
-<LI><A HREF="flex.html#IDX42">BOL, syntax of</A>
-<LI><A HREF="flex.html#IDX296">bugs, reporting</A>
+<LI><A HREF="flex.html#IDX356">backing up, eliminating</A>
+<LI><A HREF="flex.html#IDX358">backing up, eliminating by adding error rules</A>
+<LI><A HREF="flex.html#IDX359">backing up, eliminating with catch-all rule</A>
+<LI><A HREF="flex.html#IDX355">backing up, example of eliminating</A>
+<LI><A HREF="flex.html#IDX109">BEGIN</A>
+<LI><A HREF="flex.html#IDX156">BEGIN, explanation</A>
+<LI><A HREF="flex.html#IDX54">beginning of line, in patterns</A>
+<LI><A HREF="flex.html#IDX466">bison, bridging with flex</A>
+<LI><A HREF="flex.html#IDX477">bison, parser</A>
+<LI><A HREF="flex.html#IDX476">bison, scanner to be called from bison</A>
+<LI><A HREF="flex.html#IDX207">BOL, checking the BOL flag</A>
+<LI><A HREF="flex.html#IDX55">BOL, in patterns</A>
+<LI><A HREF="flex.html#IDX205">BOL, setting it</A>
+<LI><A HREF="flex.html#IDX45">braces in patterns</A>
+<LI><A HREF="flex.html#IDX3">bugs, reporting</A>
 </DIR>
 <H2><A NAME="cindex_c">c</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX218">C++</A>
-<LI><A HREF="flex.html#IDX189">C++ and %array</A>
-<LI><A HREF="flex.html#IDX236">C++, multiple different scanners</A>
-<LI><A HREF="flex.html#IDX53">case-insensitive, effect on character classes</A>
-<LI><A HREF="flex.html#IDX49">character classes in patterns</A>
-<LI><A HREF="flex.html#IDX30">character classes in patterns, syntax of</A>
-<LI><A HREF="flex.html#IDX51">character classes, equivalence of</A>
-<LI><A HREF="flex.html#IDX158">clearing an input buffer</A>
-<LI><A HREF="flex.html#IDX199">command-line options</A>
-<LI><A HREF="flex.html#IDX103">comments, example of discarding</A>
-<LI><A HREF="flex.html#IDX135">comments, example of scanning C comments</A>
-<LI><A HREF="flex.html#IDX24">comments, syntax</A>
-<LI><A HREF="flex.html#IDX25">comments, valid uses of</A>
-<LI><A HREF="flex.html#IDX77">commments, in actions</A>
-<LI><A HREF="flex.html#IDX294">copyright of flex</A>
+<LI><A HREF="flex.html#IDX26">C code in flex input</A>
+<LI><A HREF="flex.html#IDX367">C++</A>
+<LI><A HREF="flex.html#IDX215">C++ and %array</A>
+<LI><A HREF="flex.html#IDX462">C++ I/O, customizing</A>
+<LI><A HREF="flex.html#IDX388">C++ scanners, including multiple scanners</A>
+<LI><A HREF="flex.html#IDX384">C++ scanners, use of</A>
+<LI><A HREF="flex.html#IDX365">c++, experimental form of scanner class</A>
+<LI><A HREF="flex.html#IDX385">C++, multiple different scanners</A>
+<LI><A HREF="flex.html#IDX69">case-insensitive, effect on character classes</A>
+<LI><A HREF="flex.html#IDX65">character classes in patterns</A>
+<LI><A HREF="flex.html#IDX40">character classes in patterns, syntax of</A>
+<LI><A HREF="flex.html#IDX67">character classes, equivalence of</A>
+<LI><A HREF="flex.html#IDX184">clearing an input buffer</A>
+<LI><A HREF="flex.html#IDX225">command-line options</A>
+<LI><A HREF="flex.html#IDX23">comments in flex input</A>
+<LI><A HREF="flex.html#IDX34">comments in the input</A>
+<LI><A HREF="flex.html#IDX129">comments, example of discarding</A>
+<LI><A HREF="flex.html#IDX161">comments, example of scanning C comments</A>
+<LI><A HREF="flex.html#IDX32">comments, in rules section</A>
+<LI><A HREF="flex.html#IDX31">comments, syntax of</A>
+<LI><A HREF="flex.html#IDX33">comments, valid uses of</A>
+<LI><A HREF="flex.html#IDX103">commments, in actions</A>
+<LI><A HREF="flex.html#IDX98">compressing whitespace</A>
+<LI><A HREF="flex.html#IDX52">concatenation, in patterns</A>
+<LI><A HREF="flex.html#IDX1">copyright of flex</A>
+<LI><A HREF="flex.html#IDX9">counting characters and lines</A>
+<LI><A HREF="flex.html#IDX461">customizing I/O in C++ scanners</A>
 </DIR>
 <H2><A NAME="cindex_d">d</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX2">default rule</A>
-<LI><A HREF="flex.html#IDX62">default rule, explanation</A>
-<LI><A HREF="flex.html#IDX11">Definitions Sections</A>
-<LI><A HREF="flex.html#IDX295">distributing flex</A>
+<LI><A HREF="flex.html#IDX7">default rule</A>, <A HREF="flex.html#IDX87">default rule</A>
+<LI><A HREF="flex.html#IDX21">defining pattern aliases</A>
+<LI><A HREF="flex.html#IDX17">Definitions, in flex input</A>
+<LI><A HREF="flex.html#IDX96">deleting lines from input</A>
+<LI><A HREF="flex.html#IDX130">discarding C comments</A>
+<LI><A HREF="flex.html#IDX2">distributing flex</A>
 </DIR>
 <H2><A NAME="cindex_e">e</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX82">ECHO, explanation</A>
-<LI><A HREF="flex.html#IDX16">embedding C code with %{ and %}</A>
-<LI><A HREF="flex.html#IDX304">end of file -- see EOF</A>
-<LI><A HREF="flex.html#IDX302">end of line -- see EOL</A>
-<LI><A HREF="flex.html#IDX116">EOF and yyrestart()</A>
-<LI><A HREF="flex.html#IDX45">EOF in patterns, syntax of</A>
-<LI><A HREF="flex.html#IDX163">EOF, example using multiple input buffers</A>
-<LI><A HREF="flex.html#IDX171">EOF, explanation</A>
-<LI><A HREF="flex.html#IDX101">EOF, pushing back</A>
-<LI><A HREF="flex.html#IDX43">EOL in patterns, syntax of</A>
-<LI><A HREF="flex.html#IDX57">EOL, $ as normal character</A>
-<LI><A HREF="flex.html#IDX54">EOL, in negated character classes</A>
-<LI><A HREF="flex.html#IDX289">error reporting, diagnostic messages</A>
-<LI><A HREF="flex.html#IDX233">error reporting, in C++</A>
-<LI><A HREF="flex.html#IDX210">error rules, to eliminate backing up</A>
-<LI><A HREF="flex.html#IDX39">escape sequences in patterns, syntax of</A>
-<LI><A HREF="flex.html#IDX109">exiting with yyterminate()</A>
+<LI><A HREF="flex.html#IDX108">ECHO, explanation</A>
+<LI><A HREF="flex.html#IDX25">embedding C code in flex input</A>
+<LI><A HREF="flex.html#IDX60">end of file, in patterns</A>
+<LI><A HREF="flex.html#IDX70">end of line, in negated character classes</A>
+<LI><A HREF="flex.html#IDX56">end of line, in patterns</A>
+<LI><A HREF="flex.html#IDX142">EOF and yyrestart()</A>
+<LI><A HREF="flex.html#IDX61">EOF in patterns, syntax of</A>
+<LI><A HREF="flex.html#IDX189">EOF, example using multiple input buffers</A>
+<LI><A HREF="flex.html#IDX197">EOF, explanation</A>
+<LI><A HREF="flex.html#IDX127">EOF, pushing back</A>
+<LI><A HREF="flex.html#IDX71">EOL, in negated character classes</A>
+<LI><A HREF="flex.html#IDX57">EOL, in patterns</A>
+<LI><A HREF="flex.html#IDX425">error messages, end of buffer missed</A>
+<LI><A HREF="flex.html#IDX452">error reporting, diagnostic messages</A>
+<LI><A HREF="flex.html#IDX382">error reporting, in C++</A>
+<LI><A HREF="flex.html#IDX357">error rules, to eliminate backing up</A>
+<LI><A HREF="flex.html#IDX49">escape sequences in patterns, syntax of</A>
+<LI><A HREF="flex.html#IDX135">exiting with yyterminate()</A>
+<LI><A HREF="flex.html#IDX366">experimental form of c++ scanner class</A>
+<LI><A HREF="flex.html#IDX170">extended scope of start conditions</A>
 </DIR>
 <H2><A NAME="cindex_f">f</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX6">file format</A>
-<LI><A HREF="flex.html#IDX1">flex, introduction</A>
-<LI><A HREF="flex.html#IDX159">flushing an input buffer</A>
-<LI><A HREF="flex.html#IDX106">flushing the internal buffer</A>
-<LI><A HREF="flex.html#IDX5">format of the input</A>
-<LI><A HREF="flex.html#IDX9">format, Definitions Section</A>
-<LI><A HREF="flex.html#IDX18">format, Rules Section</A>
-<LI><A HREF="flex.html#IDX21">format, User Code Section</A>
-<LI><A HREF="flex.html#IDX307">freeing memory -- see memory</A>
+<LI><A HREF="flex.html#IDX13">file format</A>
+<LI><A HREF="flex.html#IDX451">file format, serialized tables</A>
+<LI><A HREF="flex.html#IDX185">flushing an input buffer</A>
+<LI><A HREF="flex.html#IDX132">flushing the internal buffer</A>
+<LI><A HREF="flex.html#IDX11">format of flex input</A>
+<LI><A HREF="flex.html#IDX15">format of input file</A>
+<LI><A HREF="flex.html#IDX446">freeing tables</A>
+</DIR>
+<H2><A NAME="cindex_g">g</A></H2>
+<DIR>
+<LI><A HREF="flex.html#IDX166">getting current start state with YY_START</A>
 </DIR>
 <H2><A NAME="cindex_h">h</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX110">halting with yyterminate()</A>
-<LI><A HREF="flex.html#IDX238">header files, with C++</A>
+<LI><A HREF="flex.html#IDX136">halting with yyterminate()</A>
+<LI><A HREF="flex.html#IDX190">handling include files with multiple input buffers</A>
+<LI><A HREF="flex.html#IDX387">header files, with C++</A>
 </DIR>
 <H2><A NAME="cindex_i">i</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX237">include files, with C++</A>
-<LI><A HREF="flex.html#IDX17">including C code with %{ and %}</A>
-<LI><A HREF="flex.html#IDX105">input(), and C++</A>
-<LI><A HREF="flex.html#IDX102">input(), explanation</A>
+<LI><A HREF="flex.html#IDX386">include files, with C++</A>
+<LI><A HREF="flex.html#IDX16">input file, Definitions section</A>
+<LI><A HREF="flex.html#IDX27">input file, Rules Section</A>
+<LI><A HREF="flex.html#IDX29">input file, user code Section</A>
+<LI><A HREF="flex.html#IDX131">input(), and C++</A>
+<LI><A HREF="flex.html#IDX128">input(), explanation</A>
+<LI><A HREF="flex.html#IDX12">input, format of</A>
+<LI><A HREF="flex.html#IDX79">input, matching</A>
 </DIR>
 <H2><A NAME="cindex_k">k</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX215">keywords, for performance</A>
+<LI><A HREF="flex.html#IDX362">keywords, for performance</A>
 </DIR>
 <H2><A NAME="cindex_l">l</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX283">lex (traditional) and POSIX</A>
-<LI><A HREF="flex.html#IDX292">limitations of flex</A>
-<LI><A HREF="flex.html#IDX37">literal text in patterns, syntax of</A>
+<LI><A HREF="flex.html#IDX424">lex (traditional) and POSIX</A>
+<LI><A HREF="flex.html#IDX458">LexerInput, overriding</A>
+<LI><A HREF="flex.html#IDX457">LexerOutput, overriding</A>
+<LI><A HREF="flex.html#IDX455">limitations of flex</A>
+<LI><A HREF="flex.html#IDX47">literal text in patterns, syntax of</A>
+<LI><A HREF="flex.html#IDX444">loading tables at runtime</A>
 </DIR>
 <H2><A NAME="cindex_m">m</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX306">macros, see preprocessor macros</A>
-<LI><A HREF="flex.html#IDX297">Makefile, syntax</A>
-<LI><A HREF="flex.html#IDX309">malloc -- see memory</A>
-<LI><A HREF="flex.html#IDX219">member functions in C++</A>
-<LI><A HREF="flex.html#IDX152">memory, allocating input buffers</A>
-<LI><A HREF="flex.html#IDX248">memory, considerations for reentrant scanners</A>
-<LI><A HREF="flex.html#IDX156">memory, deleting input buffers</A>
-<LI><A HREF="flex.html#IDX150">memory, for start condition stacks</A>
-<LI><A HREF="flex.html#IDX220">methods</A>
-<LI><A HREF="flex.html#IDX151">multiple input streams</A>
+<LI><A HREF="flex.html#IDX464">Makefile, example of implicit rules</A>
+<LI><A HREF="flex.html#IDX465">Makefile, explicit example</A>
+<LI><A HREF="flex.html#IDX463">Makefile, syntax</A>
+<LI><A HREF="flex.html#IDX168">matching C-style double-quoted strings</A>
+<LI><A HREF="flex.html#IDX81">matching, and trailing context</A>
+<LI><A HREF="flex.html#IDX82">matching, length of</A>
+<LI><A HREF="flex.html#IDX83">matching, multiple matches</A>
+<LI><A HREF="flex.html#IDX368">member functions, C++</A>
+<LI><A HREF="flex.html#IDX431">memory management</A>
+<LI><A HREF="flex.html#IDX178">memory, allocating input buffers</A>
+<LI><A HREF="flex.html#IDX397">memory, considerations for reentrant scanners</A>
+<LI><A HREF="flex.html#IDX182">memory, deleting input buffers</A>
+<LI><A HREF="flex.html#IDX176">memory, for start condition stacks</A>
+<LI><A HREF="flex.html#IDX439">memory, serialized tables</A>, <A HREF="flex.html#IDX447">memory, serialized tables</A>
+<LI><A HREF="flex.html#IDX369">methods, c++</A>
+<LI><A HREF="flex.html#IDX88">minimal scanner</A>
+<LI><A HREF="flex.html#IDX177">multiple input streams</A>
 </DIR>
 <H2><A NAME="cindex_n">n</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX35">negating ranges in patterns</A>
-<LI><A HREF="flex.html#IDX40">NULL character in patterns, syntax of</A>
+<LI><A HREF="flex.html#IDX427">name definitions, not POSIX</A>
+<LI><A HREF="flex.html#IDX44">negating ranges in patterns</A>
+<LI><A HREF="flex.html#IDX58">newline, matching in patterns</A>
+<LI><A HREF="flex.html#IDX430">non-POSIX features of flex</A>
+<LI><A HREF="flex.html#IDX50">NULL character in patterns, syntax of</A>
 </DIR>
 <H2><A NAME="cindex_o">o</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX200">options, command-line</A>
+<LI><A HREF="flex.html#IDX51">octal characters in patterns</A>
+<LI><A HREF="flex.html#IDX226">options, command-line</A>
+<LI><A HREF="flex.html#IDX460">overriding LexerInput</A>
+<LI><A HREF="flex.html#IDX459">overriding LexerOutput</A>
+<LI><A HREF="flex.html#IDX436">overriding the memory routines</A>
 </DIR>
 <H2><A NAME="cindex_p">p</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX36">pattern aliases, expansion of</A>
-<LI><A HREF="flex.html#IDX27">Patterns</A>
-<LI><A HREF="flex.html#IDX12">patterns aliases, how to define</A>
-<LI><A HREF="flex.html#IDX61">patterns, how the input is matched</A>
-<LI><A HREF="flex.html#IDX46">patterns, precedence of operators</A>
-<LI><A HREF="flex.html#IDX28">patterns, syntax</A>
-<LI><A HREF="flex.html#IDX206">patterns, tuning for performance</A>
-<LI><A HREF="flex.html#IDX207">performance, backing up</A>
-<LI><A HREF="flex.html#IDX202">performance, considerations</A>
-<LI><A HREF="flex.html#IDX216">performance, using keywords</A>
-<LI><A HREF="flex.html#IDX282">POSIX and lex</A>
-<LI><A HREF="flex.html#IDX31">POSIX, character classes in patterns, syntax of</A>
-<LI><A HREF="flex.html#IDX288">POSIX, non-POSIX features of flex</A>
-<LI><A HREF="flex.html#IDX81">preprocessor macros, for use in actions</A>
-<LI><A HREF="flex.html#IDX96">pushing back characters with unput</A>
-<LI><A HREF="flex.html#IDX93">pushing back characters with yyless</A>
-<LI><A HREF="flex.html#IDX100">pushing back EOF</A>
+<LI><A HREF="flex.html#IDX10">Pascal-like language</A>
+<LI><A HREF="flex.html#IDX20">pattern aliases, defining</A>
+<LI><A HREF="flex.html#IDX46">pattern aliases, expansion of</A>
+<LI><A HREF="flex.html#IDX19">pattern aliases, how to define</A>
+<LI><A HREF="flex.html#IDX22">pattern aliases, use of</A>
+<LI><A HREF="flex.html#IDX428">patterns and actions on different lines</A>
+<LI><A HREF="flex.html#IDX68">patterns, character class equivalence</A>
+<LI><A HREF="flex.html#IDX77">patterns, end of line</A>
+<LI><A HREF="flex.html#IDX63">patterns, grouping and precedence</A>
+<LI><A HREF="flex.html#IDX35">patterns, in rules section</A>
+<LI><A HREF="flex.html#IDX75">patterns, invalid trailing context</A>
+<LI><A HREF="flex.html#IDX78">patterns, matching</A>
+<LI><A HREF="flex.html#IDX62">patterns, precedence of operators</A>
+<LI><A HREF="flex.html#IDX64">patterns, repetitions with grouping</A>
+<LI><A HREF="flex.html#IDX76">patterns, special characters treated as non-special</A>
+<LI><A HREF="flex.html#IDX37">patterns, syntax</A>, <A HREF="flex.html#IDX38">patterns, syntax</A>
+<LI><A HREF="flex.html#IDX353">patterns, tuning for performance</A>
+<LI><A HREF="flex.html#IDX66">patterns, valid character classes</A>
+<LI><A HREF="flex.html#IDX361">performance optimization, matching longer tokens</A>
+<LI><A HREF="flex.html#IDX364">performance optimization, recognizing keywords</A>
+<LI><A HREF="flex.html#IDX354">performance, backing up</A>
+<LI><A HREF="flex.html#IDX349">performance, considerations</A>
+<LI><A HREF="flex.html#IDX363">performance, using keywords</A>
+<LI><A HREF="flex.html#IDX423">POSIX and lex</A>
+<LI><A HREF="flex.html#IDX429">POSIX comp;compliance</A>
+<LI><A HREF="flex.html#IDX41">POSIX, character classes in patterns, syntax of</A>
+<LI><A HREF="flex.html#IDX107">preprocessor macros, for use in actions</A>
+<LI><A HREF="flex.html#IDX122">pushing back characters with unput</A>
+<LI><A HREF="flex.html#IDX119">pushing back characters with yyless</A>
+<LI><A HREF="flex.html#IDX126">pushing back EOF</A>
 </DIR>
 <H2><A NAME="cindex_r">r</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX32">ranges in patterns</A>
-<LI><A HREF="flex.html#IDX34">ranges in patterns, negating</A>
-<LI><A HREF="flex.html#IDX247">reentrant, accessing flex variables</A>
-<LI><A HREF="flex.html#IDX252">reentrant, accessor functions</A>
-<LI><A HREF="flex.html#IDX243">reentrant, API explanation</A>
-<LI><A HREF="flex.html#IDX245">reentrant, calling functions</A>
-<LI><A HREF="flex.html#IDX244">reentrant, example of</A>
-<LI><A HREF="flex.html#IDX240">reentrant, explanation</A>
-<LI><A HREF="flex.html#IDX254">reentrant, extra data</A>
-<LI><A HREF="flex.html#IDX249">reentrant, initialization</A>
-<LI><A HREF="flex.html#IDX305">regular expressions -- see Patterns</A>
-<LI><A HREF="flex.html#IDX85">REJECT, example</A>
-<LI><A HREF="flex.html#IDX84">REJECT, explanation</A>
-<LI><A HREF="flex.html#IDX203">REJECT, performance costs</A>
-<LI><A HREF="flex.html#IDX117">returning from within an action</A>
-<LI><A HREF="flex.html#IDX20">Rules Section</A>
+<LI><A HREF="flex.html#IDX42">ranges in patterns</A>
+<LI><A HREF="flex.html#IDX43">ranges in patterns, negating</A>
+<LI><A HREF="flex.html#IDX162">recognizing C comments</A>
+<LI><A HREF="flex.html#IDX390">reentrant scanners, multiple interleaved scanners</A>
+<LI><A HREF="flex.html#IDX391">reentrant scanners, recursive invocation</A>
+<LI><A HREF="flex.html#IDX396">reentrant, accessing flex variables</A>
+<LI><A HREF="flex.html#IDX401">reentrant, accessor functions</A>
+<LI><A HREF="flex.html#IDX392">reentrant, API explanation</A>
+<LI><A HREF="flex.html#IDX394">reentrant, calling functions</A>
+<LI><A HREF="flex.html#IDX393">reentrant, example of</A>
+<LI><A HREF="flex.html#IDX389">reentrant, explanation</A>
+<LI><A HREF="flex.html#IDX403">reentrant, extra data</A>
+<LI><A HREF="flex.html#IDX398">reentrant, initialization</A>
+<LI><A HREF="flex.html#IDX36">regular expressions, in patterns</A>
+<LI><A HREF="flex.html#IDX112">REJECT</A>
+<LI><A HREF="flex.html#IDX113">REJECT, calling multiple times</A>
+<LI><A HREF="flex.html#IDX111">REJECT, example</A>
+<LI><A HREF="flex.html#IDX110">REJECT, explanation</A>
+<LI><A HREF="flex.html#IDX350">REJECT, performance costs</A>
+<LI><A HREF="flex.html#IDX4">reporting bugs</A>
+<LI><A HREF="flex.html#IDX426">restarting the scanner</A>
+<LI><A HREF="flex.html#IDX143">returning from within an action</A>
+<LI><A HREF="flex.html#IDX8">rules, default</A>
+<LI><A HREF="flex.html#IDX28">rules, in flex input</A>
 </DIR>
 <H2><A NAME="cindex_s">s</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX7">sections of the input</A>
-<LI><A HREF="flex.html#IDX10">sections, Definitions Section</A>
-<LI><A HREF="flex.html#IDX19">sections, format of Rules Section</A>
-<LI><A HREF="flex.html#IDX22">sections, User Code Section</A>
-<LI><A HREF="flex.html#IDX145">stacks, routines for manipulating</A>
-<LI><A HREF="flex.html#IDX143">start condition, applying to multiple patterns</A>
-<LI><A HREF="flex.html#IDX44">start conditions in patterns, syntax of</A>
-<LI><A HREF="flex.html#IDX121">start conditions, explanation</A>
-<LI><A HREF="flex.html#IDX124">start conditions, inclusive v.s. exclusive</A>
-<LI><A HREF="flex.html#IDX137">start conditions, integer values</A>
-<LI><A HREF="flex.html#IDX127">start conditions, special wildcard condition</A>
-<LI><A HREF="flex.html#IDX146">start conditions, use of a stack</A>
-<LI><A HREF="flex.html#IDX115">stdin, default for yyin</A>
-<LI><A HREF="flex.html#IDX76">strings, in actions</A>
-<LI><A HREF="flex.html#IDX165">strings, scanning strings instead of files</A>
+<LI><A HREF="flex.html#IDX5">scanner, definition of</A>
+<LI><A HREF="flex.html#IDX14">sections of flex input</A>
+<LI><A HREF="flex.html#IDX438">serialization</A>
+<LI><A HREF="flex.html#IDX441">serialization of tables</A>
+<LI><A HREF="flex.html#IDX442">serialized tables, multiple scanners</A>
+<LI><A HREF="flex.html#IDX171">stacks, routines for manipulating</A>
+<LI><A HREF="flex.html#IDX169">start condition, applying to multiple patterns</A>
+<LI><A HREF="flex.html#IDX148">start conditions, basic</A>
+<LI><A HREF="flex.html#IDX155">start conditions, behavior of default rule</A>
+<LI><A HREF="flex.html#IDX152">start conditions, exclusive</A>
+<LI><A HREF="flex.html#IDX147">start conditions, explanation</A>
+<LI><A HREF="flex.html#IDX160">start conditions, for different interpretations of same input</A>
+<LI><A HREF="flex.html#IDX59">start conditions, in patterns</A>
+<LI><A HREF="flex.html#IDX151">start conditions, inclusive</A>
+<LI><A HREF="flex.html#IDX150">start conditions, inclusive v.s. exclusive</A>
+<LI><A HREF="flex.html#IDX163">start conditions, integer values</A>
+<LI><A HREF="flex.html#IDX149">start conditions, multiple</A>
+<LI><A HREF="flex.html#IDX153">start conditions, special wildcard condition</A>
+<LI><A HREF="flex.html#IDX172">start conditions, use of a stack</A>
+<LI><A HREF="flex.html#IDX154">start conditions, use of wildcard condition (&#60;*&#62;)</A>
+<LI><A HREF="flex.html#IDX159">start conditions, using BEGIN</A>
+<LI><A HREF="flex.html#IDX141">stdin, default for yyin</A>
+<LI><A HREF="flex.html#IDX102">strings, in actions</A>
+<LI><A HREF="flex.html#IDX191">strings, scanning strings instead of files</A>
 </DIR>
 <H2><A NAME="cindex_t">t</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX108">terminating with yyterminate()</A>
-<LI><A HREF="flex.html#IDX41">trailing context in patterns, syntax of</A>
-<LI><A HREF="flex.html#IDX55">trailing context, limits of</A>
-<LI><A HREF="flex.html#IDX205">trailing context, performance costs</A>
+<LI><A HREF="flex.html#IDX440">tables, creating serialized</A>
+<LI><A HREF="flex.html#IDX450">tables, file format</A>
+<LI><A HREF="flex.html#IDX445">tables, freeing</A>
+<LI><A HREF="flex.html#IDX443">tables, loading and unloading</A>
+<LI><A HREF="flex.html#IDX134">terminating with yyterminate()</A>
+<LI><A HREF="flex.html#IDX84">token</A>
+<LI><A HREF="flex.html#IDX53">trailing context, in patterns</A>
+<LI><A HREF="flex.html#IDX72">trailing context, limits of</A>
+<LI><A HREF="flex.html#IDX80">trailing context, matching</A>
+<LI><A HREF="flex.html#IDX352">trailing context, performance costs</A>
+<LI><A HREF="flex.html#IDX360">trailing context, variable length</A>
 </DIR>
 <H2><A NAME="cindex_u">u</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX99">unput(), caveat with %pointer</A>
-<LI><A HREF="flex.html#IDX95">unput(), explanation</A>
-<LI><A HREF="flex.html#IDX23">User Code Section</A>
+<LI><A HREF="flex.html#IDX123">unput() to push back characters</A>
+<LI><A HREF="flex.html#IDX125">unput(), caveat with %pointer</A>
+<LI><A HREF="flex.html#IDX121">unput(), explanation</A>
+<LI><A HREF="flex.html#IDX30">user code, in flex input</A>
+<LI><A HREF="flex.html#IDX6">username expansion</A>
+<LI><A HREF="flex.html#IDX164">using integer values of start condition names</A>
 </DIR>
 <H2><A NAME="cindex_v">v</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX38">verbatim text in patterns, syntax of</A>
+<LI><A HREF="flex.html#IDX48">verbatim text in patterns, syntax of</A>
 </DIR>
 <H2><A NAME="cindex_w">w</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX290">warnings, diagnostic messages</A>
-<LI><A HREF="flex.html#IDX71">whitespace, compressing, example</A>
+<LI><A HREF="flex.html#IDX456">warning, dangerous trailing context</A>
+<LI><A HREF="flex.html#IDX454">warning, rule cannot be matched</A>
+<LI><A HREF="flex.html#IDX453">warnings, diagnostic messages</A>
+<LI><A HREF="flex.html#IDX97">whitespace, compressing, example</A>
 </DIR>
 <H2><A NAME="cindex_y">y</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX196">yacc, interface</A>
-<LI><A HREF="flex.html#IDX162">YY_CURRENT_BUFFER, and multiple buffers</A>
-<LI><A HREF="flex.html#IDX118">YY_INPUT, overriding</A>
-<LI><A HREF="flex.html#IDX139">YY_START, example</A>
-<LI><A HREF="flex.html#IDX79">yyleng, modification of</A>
-<LI><A HREF="flex.html#IDX92">yyless(), example</A>
-<LI><A HREF="flex.html#IDX91">yyless(), explanation</A>
-<LI><A HREF="flex.html#IDX112">yylex(), in generated scanner</A>
-<LI><A HREF="flex.html#IDX113">yylex(), overriding</A>
-<LI><A HREF="flex.html#IDX281">yylineno, in a reentrant scanner</A>
-<LI><A HREF="flex.html#IDX204">yylineno, performance costs</A>
-<LI><A HREF="flex.html#IDX89">yymore(), example</A>
-<LI><A HREF="flex.html#IDX88">yymore(), explanation</A>
-<LI><A HREF="flex.html#IDX80">yymore, caveat</A>
-<LI><A HREF="flex.html#IDX107">yyterminate(), explanation</A>
-<LI><A HREF="flex.html#IDX186">yytext, default array size</A>
-<LI><A HREF="flex.html#IDX64">yytext, definition of</A>
-<LI><A HREF="flex.html#IDX78">yytext, modification of</A>
-<LI><A HREF="flex.html#IDX120">yywrap(), explanation</A>
+<LI><A HREF="flex.html#IDX224">yacc interface</A>
+<LI><A HREF="flex.html#IDX222">yacc, interface</A>
+<LI><A HREF="flex.html#IDX188">YY_CURRENT_BUFFER, and multiple buffers</A>
+<LI><A HREF="flex.html#IDX408">YY_EXTRA_TYPE, defining your own type</A>
+<LI><A HREF="flex.html#IDX144">YY_INPUT, overriding</A>
+<LI><A HREF="flex.html#IDX145">YY_INPUT, overriding the input mechanism</A>
+<LI><A HREF="flex.html#IDX165">YY_START, example</A>
+<LI><A HREF="flex.html#IDX201">YY_USER_ACTION to track each time a rule is matched</A>
+<LI><A HREF="flex.html#IDX432">yyalloc, overriding</A>
+<LI><A HREF="flex.html#IDX434">yyfree, overriding</A>
+<LI><A HREF="flex.html#IDX86">yyleng</A>
+<LI><A HREF="flex.html#IDX105">yyleng, modification of</A>
+<LI><A HREF="flex.html#IDX120">yyless() to push back characters</A>
+<LI><A HREF="flex.html#IDX118">yyless(), example</A>
+<LI><A HREF="flex.html#IDX117">yyless(), explanation</A>
+<LI><A HREF="flex.html#IDX138">yylex(), in generated scanner</A>
+<LI><A HREF="flex.html#IDX139">yylex(), overriding</A>
+<LI><A HREF="flex.html#IDX140">yylex, overriding the prototype</A>
+<LI><A HREF="flex.html#IDX422">yylineno, in a reentrant scanner</A>
+<LI><A HREF="flex.html#IDX351">yylineno, performance costs</A>
+<LI><A HREF="flex.html#IDX116">yymore() to append token to previous token</A>
+<LI><A HREF="flex.html#IDX115">yymore(), example</A>
+<LI><A HREF="flex.html#IDX114">yymore(), explanation</A>
+<LI><A HREF="flex.html#IDX106">yymore, caveat</A>
+<LI><A HREF="flex.html#IDX433">yyrealloc, overriding</A>
+<LI><A HREF="flex.html#IDX133">yyterminate(), explanation</A>
+<LI><A HREF="flex.html#IDX85">yytext</A>
+<LI><A HREF="flex.html#IDX212">yytext, default array size</A>
+<LI><A HREF="flex.html#IDX437">yytext, memory considerations</A>
+<LI><A HREF="flex.html#IDX104">yytext, modification of</A>
+<LI><A HREF="flex.html#IDX89">yytext, two types of</A>
+<LI><A HREF="flex.html#IDX146">yywrap(), explanation</A>
 </DIR>
 
 
 
 
-<H2><A NAME="SEC83" HREF="flex_toc.html#TOC83">Index of Functions and Macros</A></H2>
+<H2><A NAME="SEC159" HREF="flex_toc.html#TOC159">Index of Functions and Macros</A></H2>
 
 <P>
 This is an index of functions and preprocessor macros that look like functions.
-For macros that expand to variables or constants, see section <A HREF="flex.html#SEC84">Index of Variables</A>.
+For macros that expand to variables or constants, see section <A HREF="flex.html#SEC160">Index of Variables</A>.
 
 
 <P>
@@ -6485,70 +9414,74 @@
 <P>
 <H2><A NAME="findex_b">b</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX131">BEGIN</A>
+<LI><A HREF="flex.html#IDX157">BEGIN</A>
 </DIR>
 <H2><A NAME="findex_d">d</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX225">debug (C++ only)</A>
+<LI><A HREF="flex.html#IDX374">debug (C++ only)</A>
 </DIR>
 <H2><A NAME="findex_l">l</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX234">LexerError (C++ only)</A>
-<LI><A HREF="flex.html#IDX231">LexerInput (C++ only)</A>
-<LI><A HREF="flex.html#IDX232">LexerOutput (C++ only)</A>
-<LI><A HREF="flex.html#IDX223">lineno (C++ only)</A>
+<LI><A HREF="flex.html#IDX383">LexerError (C++ only)</A>
+<LI><A HREF="flex.html#IDX380">LexerInput (C++ only)</A>
+<LI><A HREF="flex.html#IDX381">LexerOutput (C++ only)</A>
+<LI><A HREF="flex.html#IDX372">lineno (C++ only)</A>
 </DIR>
 <H2><A NAME="findex_s">s</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX224">set_debug (C++ only)</A>
-<LI><A HREF="flex.html#IDX230">switch_streams (C++ only)</A>
+<LI><A HREF="flex.html#IDX373">set_debug (C++ only)</A>
+<LI><A HREF="flex.html#IDX379">switch_streams (C++ only)</A>
 </DIR>
 <H2><A NAME="findex_y">y</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX182">YY_AT_BOL</A>
-<LI><A HREF="flex.html#IDX153">yy_create_buffer</A>
-<LI><A HREF="flex.html#IDX157">yy_delete_buffer</A>
-<LI><A HREF="flex.html#IDX160">yy_flush_buffer</A>
-<LI><A HREF="flex.html#IDX161">yy_new_buffer</A>
-<LI><A HREF="flex.html#IDX172">YY_NEW_FILE  (now obsolete)</A>
-<LI><A HREF="flex.html#IDX148">yy_pop_state</A>
-<LI><A HREF="flex.html#IDX147">yy_push_state</A>
-<LI><A HREF="flex.html#IDX169">yy_scan_buffer</A>
-<LI><A HREF="flex.html#IDX167">yy_scan_bytes</A>
-<LI><A HREF="flex.html#IDX166">yy_scan_string</A>
-<LI><A HREF="flex.html#IDX180">yy_set_bol</A>
-<LI><A HREF="flex.html#IDX178">yy_set_interactive</A>
-<LI><A HREF="flex.html#IDX155">yy_switch_to_buffer</A>
-<LI><A HREF="flex.html#IDX149">yy_top_state</A>
-<LI><A HREF="flex.html#IDX228">yyFlexLexer constructor (C++ only)</A>
-<LI><A HREF="flex.html#IDX257">yyget_extra</A>
-<LI><A HREF="flex.html#IDX275">yyget_in</A>
-<LI><A HREF="flex.html#IDX274">yyget_leng</A>
-<LI><A HREF="flex.html#IDX277">yyget_lineno</A>
-<LI><A HREF="flex.html#IDX267">yyget_lloc</A>
-<LI><A HREF="flex.html#IDX266">yyget_lval</A>
-<LI><A HREF="flex.html#IDX276">yyget_out</A>
-<LI><A HREF="flex.html#IDX273">yyget_text</A>
-<LI><A HREF="flex.html#IDX222">YYLeng (C++ only)</A>
-<LI><A HREF="flex.html#IDX229">yylex (C++ version)</A>
-<LI><A HREF="flex.html#IDX270">yylex (reentrant version)</A>
-<LI><A HREF="flex.html#IDX251">yylex_destroy</A>
-<LI><A HREF="flex.html#IDX250">yylex_init</A>
-<LI><A HREF="flex.html#IDX192">yyrestart</A>
-<LI><A HREF="flex.html#IDX258">yyset_extra</A>
-<LI><A HREF="flex.html#IDX278">yyset_in</A>
-<LI><A HREF="flex.html#IDX280">yyset_lineno</A>
-<LI><A HREF="flex.html#IDX269">yyset_lloc</A>
-<LI><A HREF="flex.html#IDX268">yyset_lval</A>
-<LI><A HREF="flex.html#IDX279">yyset_out</A>
-<LI><A HREF="flex.html#IDX111">yyterminate</A>
-<LI><A HREF="flex.html#IDX221">YYText (C++ only)</A>
+<LI><A HREF="flex.html#IDX208">YY_AT_BOL</A>
+<LI><A HREF="flex.html#IDX179">yy_create_buffer</A>
+<LI><A HREF="flex.html#IDX183">yy_delete_buffer</A>
+<LI><A HREF="flex.html#IDX186">yy_flush_buffer</A>
+<LI><A HREF="flex.html#IDX187">yy_new_buffer</A>
+<LI><A HREF="flex.html#IDX198">YY_NEW_FILE  (now obsolete)</A>
+<LI><A HREF="flex.html#IDX174">yy_pop_state</A>
+<LI><A HREF="flex.html#IDX173">yy_push_state</A>
+<LI><A HREF="flex.html#IDX195">yy_scan_buffer</A>
+<LI><A HREF="flex.html#IDX193">yy_scan_bytes</A>
+<LI><A HREF="flex.html#IDX192">yy_scan_string</A>
+<LI><A HREF="flex.html#IDX206">yy_set_bol</A>
+<LI><A HREF="flex.html#IDX204">yy_set_interactive</A>
+<LI><A HREF="flex.html#IDX181">yy_switch_to_buffer</A>
+<LI><A HREF="flex.html#IDX175">yy_top_state</A>
+<LI><A HREF="flex.html#IDX377">yyFlexLexer constructor (C++ only)</A>
+<LI><A HREF="flex.html#IDX418">yyget_debug</A>
+<LI><A HREF="flex.html#IDX406">yyget_extra</A>, <A HREF="flex.html#IDX420">yyget_extra</A>
+<LI><A HREF="flex.html#IDX412">yyget_in</A>
+<LI><A HREF="flex.html#IDX411">yyget_leng</A>
+<LI><A HREF="flex.html#IDX414">yyget_lineno</A>
+<LI><A HREF="flex.html#IDX472">yyget_lloc</A>
+<LI><A HREF="flex.html#IDX471">yyget_lval</A>
+<LI><A HREF="flex.html#IDX413">yyget_out</A>
+<LI><A HREF="flex.html#IDX410">yyget_text</A>
+<LI><A HREF="flex.html#IDX371">YYLeng (C++ only)</A>
+<LI><A HREF="flex.html#IDX378">yylex (C++ version)</A>
+<LI><A HREF="flex.html#IDX475">yylex (reentrant version)</A>
+<LI><A HREF="flex.html#IDX400">yylex_destroy</A>
+<LI><A HREF="flex.html#IDX399">yylex_init</A>
+<LI><A HREF="flex.html#IDX218">yyrestart</A>
+<LI><A HREF="flex.html#IDX419">yyset_debug</A>
+<LI><A HREF="flex.html#IDX407">yyset_extra</A>, <A HREF="flex.html#IDX421">yyset_extra</A>
+<LI><A HREF="flex.html#IDX415">yyset_in</A>
+<LI><A HREF="flex.html#IDX417">yyset_lineno</A>
+<LI><A HREF="flex.html#IDX474">yyset_lloc</A>
+<LI><A HREF="flex.html#IDX473">yyset_lval</A>
+<LI><A HREF="flex.html#IDX416">yyset_out</A>
+<LI><A HREF="flex.html#IDX449">yytables_destroy</A>
+<LI><A HREF="flex.html#IDX448">yytables_fload</A>
+<LI><A HREF="flex.html#IDX137">yyterminate</A>
+<LI><A HREF="flex.html#IDX370">YYText (C++ only)</A>
 </DIR>
 
 
 
 
-<H2><A NAME="SEC84" HREF="flex_toc.html#TOC84">Index of Variables</A></H2>
+<H2><A NAME="SEC160" HREF="flex_toc.html#TOC160">Index of Variables</A></H2>
 
 <P>
 This is an index of variables, constants, and preprocessor macros
@@ -6563,30 +9496,30 @@
 <P>
 <H2><A NAME="vindex_i">i</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX132">INITIAL</A>
+<LI><A HREF="flex.html#IDX158">INITIAL</A>
 </DIR>
 <H2><A NAME="vindex_y">y</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX194">YY_CURRENT_BUFFER</A>
-<LI><A HREF="flex.html#IDX168">YY_END_OF_BUFFER_CHAR</A>
-<LI><A HREF="flex.html#IDX246">yy_globals (reentrant only)</A>
-<LI><A HREF="flex.html#IDX176">YY_NUM_RULES</A>
-<LI><A HREF="flex.html#IDX141">YY_START</A>, <A HREF="flex.html#IDX195">YY_START</A>
-<LI><A HREF="flex.html#IDX255">yyextra</A>
-<LI><A HREF="flex.html#IDX191">yyin</A>
-<LI><A HREF="flex.html#IDX190">yyleng</A>
-<LI><A HREF="flex.html#IDX263">yylloc</A>
-<LI><A HREF="flex.html#IDX188">YYLMAX</A>
-<LI><A HREF="flex.html#IDX262">yylval</A>
-<LI><A HREF="flex.html#IDX197">yylval, with yacc</A>
-<LI><A HREF="flex.html#IDX193">yyout</A>
-<LI><A HREF="flex.html#IDX67">yytext</A>, <A HREF="flex.html#IDX185">yytext</A>
+<LI><A HREF="flex.html#IDX220">YY_CURRENT_BUFFER</A>
+<LI><A HREF="flex.html#IDX194">YY_END_OF_BUFFER_CHAR</A>
+<LI><A HREF="flex.html#IDX202">YY_NUM_RULES</A>
+<LI><A HREF="flex.html#IDX167">YY_START</A>, <A HREF="flex.html#IDX221">YY_START</A>
+<LI><A HREF="flex.html#IDX404">yyextra</A>
+<LI><A HREF="flex.html#IDX217">yyin</A>
+<LI><A HREF="flex.html#IDX216">yyleng</A>
+<LI><A HREF="flex.html#IDX468">yylloc</A>
+<LI><A HREF="flex.html#IDX214">YYLMAX</A>
+<LI><A HREF="flex.html#IDX467">yylval</A>
+<LI><A HREF="flex.html#IDX223">yylval, with yacc</A>
+<LI><A HREF="flex.html#IDX219">yyout</A>
+<LI><A HREF="flex.html#IDX395">yyscanner (reentrant only)</A>
+<LI><A HREF="flex.html#IDX92">yytext</A>, <A HREF="flex.html#IDX211">yytext</A>
 </DIR>
 
 
 
 
-<H2><A NAME="SEC85" HREF="flex_toc.html#TOC85">Index of Data Types</A></H2>
+<H2><A NAME="SEC161" HREF="flex_toc.html#TOC161">Index of Data Types</A></H2>
 <P>
 Jump to:
 <A HREF="#tindex_f">f</A>
@@ -6595,23 +9528,23 @@
 <P>
 <H2><A NAME="tindex_f">f</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX227">FlexLexer (C++ only)</A>
+<LI><A HREF="flex.html#IDX376">FlexLexer (C++ only)</A>
 </DIR>
 <H2><A NAME="tindex_y">y</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX154">YY_BUFFER_STATE</A>
-<LI><A HREF="flex.html#IDX256">YY_EXTRA_TYPE (reentrant only)</A>
-<LI><A HREF="flex.html#IDX170">yy_size_t</A>
-<LI><A HREF="flex.html#IDX226">yyFlexLexer (C++ only)</A>
-<LI><A HREF="flex.html#IDX264">YYLTYPE</A>
-<LI><A HREF="flex.html#IDX260">yyscan_t (reentrant only)</A>
-<LI><A HREF="flex.html#IDX265">YYSTYPE</A>
+<LI><A HREF="flex.html#IDX180">YY_BUFFER_STATE</A>
+<LI><A HREF="flex.html#IDX405">YY_EXTRA_TYPE (reentrant only)</A>
+<LI><A HREF="flex.html#IDX196">yy_size_t</A>
+<LI><A HREF="flex.html#IDX375">yyFlexLexer (C++ only)</A>
+<LI><A HREF="flex.html#IDX469">YYLTYPE</A>
+<LI><A HREF="flex.html#IDX409">yyscan_t (reentrant only)</A>
+<LI><A HREF="flex.html#IDX470">YYSTYPE</A>
 </DIR>
 
 
 
 
-<H2><A NAME="SEC86" HREF="flex_toc.html#TOC86">Index of Hooks</A></H2>
+<H2><A NAME="SEC162" HREF="flex_toc.html#TOC162">Index of Hooks</A></H2>
 
 <P>
 This is an index of "hooks" that the user may define. These hooks typically  correspond
@@ -6624,175 +9557,254 @@
 <P>
 <H2><A NAME="hkindex_y">y</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX184">YY_BREAK</A>
-<LI><A HREF="flex.html#IDX174">YY_USER_ACTION</A>
-<LI><A HREF="flex.html#IDX177">YY_USER_INIT</A>
+<LI><A HREF="flex.html#IDX210">YY_BREAK</A>
+<LI><A HREF="flex.html#IDX200">YY_USER_ACTION</A>
+<LI><A HREF="flex.html#IDX203">YY_USER_INIT</A>
 </DIR>
 
 
 
 
-<H2><A NAME="SEC87" HREF="flex_toc.html#TOC87">Index of Examples</A></H2>
+<H2><A NAME="SEC163" HREF="flex_toc.html#TOC163">Index of Scanner Options</A></H2>
+
 <P>
 Jump to:
-<A HREF="#exindex_<">&#60;</A>
+<A HREF="#opindex_-">-</A>
+-
+<A HREF="#opindex_7">7</A>
 -
-<A HREF="#exindex_a">a</A>
+<A HREF="#opindex_8">8</A>
 -
-<A HREF="#exindex_b">b</A>
+<A HREF="#opindex_a">a</A>
 -
-<A HREF="#exindex_c">c</A>
+<A HREF="#opindex_b">b</A>
 -
-<A HREF="#exindex_d">d</A>
+<A HREF="#opindex_c">c</A>
 -
-<A HREF="#exindex_e">e</A>
+<A HREF="#opindex_d">d</A>
 -
-<A HREF="#exindex_f">f</A>
+<A HREF="#opindex_e">e</A>
 -
-<A HREF="#exindex_g">g</A>
+<A HREF="#opindex_f">f</A>
 -
-<A HREF="#exindex_h">h</A>
+<A HREF="#opindex_h">h</A>
 -
-<A HREF="#exindex_m">m</A>
+<A HREF="#opindex_i">i</A>
 -
-<A HREF="#exindex_n">n</A>
+<A HREF="#opindex_l">l</A>
 -
-<A HREF="#exindex_p">p</A>
+<A HREF="#opindex_m">m</A>
 -
-<A HREF="#exindex_r">r</A>
+<A HREF="#opindex_n">n</A>
 -
-<A HREF="#exindex_s">s</A>
+<A HREF="#opindex_o">o</A>
 -
-<A HREF="#exindex_t">t</A>
+<A HREF="#opindex_p">p</A>
 -
-<A HREF="#exindex_u">u</A>
+<A HREF="#opindex_r">r</A>
 -
-<A HREF="#exindex_w">w</A>
+<A HREF="#opindex_s">s</A>
 -
-<A HREF="#exindex_y">y</A>
+<A HREF="#opindex_t">t</A>
+-
+<A HREF="#opindex_v">v</A>
+-
+<A HREF="#opindex_w">w</A>
+-
+<A HREF="#opindex_y">y</A>
 <P>
-<H2><A NAME="exindex_<">&#60;</A></H2>
+<H2><A NAME="opindex_-">-</A></H2>
+<DIR>
+<LI><A HREF="flex.html#IDX283">-+</A>
+<LI><A HREF="flex.html#IDX254">--7bit</A>
+<LI><A HREF="flex.html#IDX257">--8bit</A>
+<LI><A HREF="flex.html#IDX301">--align</A>
+<LI><A HREF="flex.html#IDX261">--always-interactive</A>
+<LI><A HREF="flex.html#IDX286">--array</A>
+<LI><A HREF="flex.html#IDX321">--backup</A>
+<LI><A HREF="flex.html#IDX248">--batch</A>
+<LI><A HREF="flex.html#IDX275">--bison-bridge</A>
+<LI><A HREF="flex.html#IDX284">--c++</A>
+<LI><A HREF="flex.html#IDX242">--case-insensitive</A>
+<LI><A HREF="flex.html#IDX324">--debug</A>
+<LI><A HREF="flex.html#IDX259">--default</A>
+<LI><A HREF="flex.html#IDX304">--ecs</A>
+<LI><A HREF="flex.html#IDX318">--fast</A>
+<LI><A HREF="flex.html#IDX315">--full</A>
+<LI><A HREF="flex.html#IDX228">--header-file</A>
+<LI><A HREF="flex.html#IDX345">--help</A>
+<LI><A HREF="flex.html#IDX251">--interactive</A>
+<LI><A HREF="flex.html#IDX245">--lex-compat</A>
+<LI><A HREF="flex.html#IDX293">--main</A>
+<LI><A HREF="flex.html#IDX309">--meta-ecs</A>
+<LI><A HREF="flex.html#IDX263">--never-interactive</A>
+<LI><A HREF="flex.html#IDX330">--nodefault</A>
+<LI><A HREF="flex.html#IDX278">--noline</A>
+<LI><A HREF="flex.html#IDX295">--nounistd</A>
+<LI><A HREF="flex.html#IDX336">--nowarn</A>
+<LI><A HREF="flex.html#IDX231">--outfile</A>
+<LI><A HREF="flex.html#IDX327">--perf-report</A>
+<LI><A HREF="flex.html#IDX288">--pointer</A>
+<LI><A HREF="flex.html#IDX265">--posix</A>
+<LI><A HREF="flex.html#IDX291">--prefix</A>
+<LI><A HREF="flex.html#IDX312">--read</A>
+<LI><A HREF="flex.html#IDX281">--reentrant</A>
+<LI><A HREF="flex.html#IDX236">--skel</A>
+<LI><A HREF="flex.html#IDX267">--stack</A>
+<LI><A HREF="flex.html#IDX269">--stdinit</A>
+<LI><A HREF="flex.html#IDX234">--stdout</A>
+<LI><A HREF="flex.html#IDX237">--tables-file</A>
+<LI><A HREF="flex.html#IDX239">--tables-verify</A>
+<LI><A HREF="flex.html#IDX333">--trace</A>
+<LI><A HREF="flex.html#IDX339">--verbose</A>
+<LI><A HREF="flex.html#IDX348">--version</A>
+<LI><A HREF="flex.html#IDX341">--warn</A>
+<LI><A HREF="flex.html#IDX297">--yyclass</A>
+<LI><A HREF="flex.html#IDX271">--yylineno</A>
+<LI><A HREF="flex.html#IDX273">--yywrap</A>
+<LI><A HREF="flex.html#IDX253">-7</A>
+<LI><A HREF="flex.html#IDX256">-8</A>
+<LI><A HREF="flex.html#IDX247">-B</A>
+<LI><A HREF="flex.html#IDX320">-b</A>
+<LI><A HREF="flex.html#IDX343">-c</A>
+<LI><A HREF="flex.html#IDX299">-C</A>
+<LI><A HREF="flex.html#IDX300">-Ca</A>
+<LI><A HREF="flex.html#IDX303">-Ce</A>
+<LI><A HREF="flex.html#IDX307">-CF</A>
+<LI><A HREF="flex.html#IDX306">-Cf</A>
+<LI><A HREF="flex.html#IDX308">-Cm</A>
+<LI><A HREF="flex.html#IDX311">-Cr</A>
+<LI><A HREF="flex.html#IDX323">-d</A>
+<LI><A HREF="flex.html#IDX314">-f</A>
+<LI><A HREF="flex.html#IDX317">-F</A>
+<LI><A HREF="flex.html#IDX344">-h</A>
+<LI><A HREF="flex.html#IDX250">-I</A>
+<LI><A HREF="flex.html#IDX241">-i</A>
+<LI><A HREF="flex.html#IDX277">-L</A>
+<LI><A HREF="flex.html#IDX244">-l</A>
+<LI><A HREF="flex.html#IDX346">-n</A>
+<LI><A HREF="flex.html#IDX230">-o</A>
+<LI><A HREF="flex.html#IDX326">-p</A>
+<LI><A HREF="flex.html#IDX290">-P</A>
+<LI><A HREF="flex.html#IDX280">-R</A>
+<LI><A HREF="flex.html#IDX329">-s</A>
+<LI><A HREF="flex.html#IDX233">-t</A>
+<LI><A HREF="flex.html#IDX332">-T</A>
+<LI><A HREF="flex.html#IDX347">-V</A>
+<LI><A HREF="flex.html#IDX338">-v</A>
+<LI><A HREF="flex.html#IDX335">-w</A>
+<LI><A HREF="flex.html#IDX264">-X</A>
+</DIR>
+<H2><A NAME="opindex_7">7</A></H2>
+<DIR>
+<LI><A HREF="flex.html#IDX255">7bit</A>
+</DIR>
+<H2><A NAME="opindex_8">8</A></H2>
+<DIR>
+<LI><A HREF="flex.html#IDX258">8bit</A>
+</DIR>
+<H2><A NAME="opindex_a">a</A></H2>
+<DIR>
+<LI><A HREF="flex.html#IDX302">align</A>
+<LI><A HREF="flex.html#IDX262">always-interactive</A>
+<LI><A HREF="flex.html#IDX287">array</A>
+</DIR>
+<H2><A NAME="opindex_b">b</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX173">&#60;&#60;EOF&#62;&#62;, use of</A>
+<LI><A HREF="flex.html#IDX322">backup</A>
+<LI><A HREF="flex.html#IDX249">batch</A>
+<LI><A HREF="flex.html#IDX276">bison-bridge</A>
 </DIR>
-<H2><A NAME="exindex_a">a</A></H2>
+<H2><A NAME="opindex_c">c</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX253">accessor functions, use of</A>
+<LI><A HREF="flex.html#IDX285">c++</A>
+<LI><A HREF="flex.html#IDX243">case-insensitive</A>
 </DIR>
-<H2><A NAME="exindex_b">b</A></H2>
+<H2><A NAME="opindex_d">d</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX209">backing up, eliminating</A>
-<LI><A HREF="flex.html#IDX211">backing up, eliminating by adding error rules</A>
-<LI><A HREF="flex.html#IDX212">backing up, eliminating with catch-all rule</A>
-<LI><A HREF="flex.html#IDX272">bison, parser</A>
-<LI><A HREF="flex.html#IDX271">bison, scanner to be called from bison</A>
+<LI><A HREF="flex.html#IDX325">debug</A>
+<LI><A HREF="flex.html#IDX260">default</A>
 </DIR>
-<H2><A NAME="exindex_c">c</A></H2>
+<H2><A NAME="opindex_e">e</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX239">C++ scanners, including multiple scanners</A>
-<LI><A HREF="flex.html#IDX235">C++ scanners, use of</A>
-<LI><A HREF="flex.html#IDX26">comments in the input</A>
-<LI><A HREF="flex.html#IDX72">compressing whitespace</A>
-<LI><A HREF="flex.html#IDX3">counting characters and lines</A>
+<LI><A HREF="flex.html#IDX305">ecs</A>
 </DIR>
-<H2><A NAME="exindex_d">d</A></H2>
+<H2><A NAME="opindex_f">f</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX70">deleting lines from input</A>
-<LI><A HREF="flex.html#IDX104">discarding C comments</A>
+<LI><A HREF="flex.html#IDX319">fast</A>
+<LI><A HREF="flex.html#IDX316">full</A>
 </DIR>
-<H2><A NAME="exindex_e">e</A></H2>
+<H2><A NAME="opindex_h">h</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX284">error messages, end of buffer missed</A>
-<LI><A HREF="flex.html#IDX144">extended scope of start conditions</A>
+<LI><A HREF="flex.html#IDX229">header-file</A>
 </DIR>
-<H2><A NAME="exindex_f">f</A></H2>
+<H2><A NAME="opindex_i">i</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX8">format of input file</A>
+<LI><A HREF="flex.html#IDX252">interactive</A>
 </DIR>
-<H2><A NAME="exindex_g">g</A></H2>
+<H2><A NAME="opindex_l">l</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX140">getting current start state with YY_START</A>
+<LI><A HREF="flex.html#IDX246">lex-compat</A>
 </DIR>
-<H2><A NAME="exindex_h">h</A></H2>
+<H2><A NAME="opindex_m">m</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX164">handling include files with multiple input buffers</A>
+<LI><A HREF="flex.html#IDX294">main</A>
+<LI><A HREF="flex.html#IDX310">meta-ecs</A>
 </DIR>
-<H2><A NAME="exindex_m">m</A></H2>
+<H2><A NAME="opindex_n">n</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX298">Makefile, example of implicit rules</A>
-<LI><A HREF="flex.html#IDX299">Makefile, explicit example</A>
-<LI><A HREF="flex.html#IDX142">matching C-style double-quoted strings</A>
-<LI><A HREF="flex.html#IDX63">minimal scanner</A>
+<LI><A HREF="flex.html#IDX331">nodefault</A>
+<LI><A HREF="flex.html#IDX279">noline</A>
+<LI><A HREF="flex.html#IDX296">nounistd</A>
+<LI><A HREF="flex.html#IDX337">nowarn</A>
+<LI><A HREF="flex.html#IDX435">noyyalloc</A>
 </DIR>
-<H2><A NAME="exindex_n">n</A></H2>
+<H2><A NAME="opindex_o">o</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX286">name definitions, not POSIX</A>
+<LI><A HREF="flex.html#IDX232">outfile</A>
 </DIR>
-<H2><A NAME="exindex_p">p</A></H2>
+<H2><A NAME="opindex_p">p</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX4">Pascal-like language</A>
-<LI><A HREF="flex.html#IDX13">pattern aliases, defining</A>
-<LI><A HREF="flex.html#IDX14">pattern aliases, use of</A>
-<LI><A HREF="flex.html#IDX287">patterns and actions on different lines</A>
-<LI><A HREF="flex.html#IDX52">patterns, character class equivalence</A>
-<LI><A HREF="flex.html#IDX60">patterns, end of line</A>
-<LI><A HREF="flex.html#IDX47">patterns, grouping and precedence</A>
-<LI><A HREF="flex.html#IDX58">patterns, invalid trailing context</A>
-<LI><A HREF="flex.html#IDX48">patterns, repetitions with grouping</A>
-<LI><A HREF="flex.html#IDX59">patterns, special characters treated as normal</A>
-<LI><A HREF="flex.html#IDX29">patterns, syntax</A>
-<LI><A HREF="flex.html#IDX50">patterns, valid character classes</A>
-<LI><A HREF="flex.html#IDX214">performance optimization, matching longer tokens</A>
-<LI><A HREF="flex.html#IDX217">performance optimization, recognizing keywords</A>
+<LI><A HREF="flex.html#IDX328">perf-report</A>
+<LI><A HREF="flex.html#IDX289">pointer</A>
+<LI><A HREF="flex.html#IDX266">posix</A>
+<LI><A HREF="flex.html#IDX292">prefix</A>
 </DIR>
-<H2><A NAME="exindex_r">r</A></H2>
+<H2><A NAME="opindex_r">r</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX136">recognizing C comments</A>
-<LI><A HREF="flex.html#IDX241">reentrant scanners, multiple interleaved scanners</A>
-<LI><A HREF="flex.html#IDX242">reentrant scanners, recursive invocation</A>
-<LI><A HREF="flex.html#IDX86">REJECT</A>
-<LI><A HREF="flex.html#IDX87">REJECT, calling multiple times</A>
-<LI><A HREF="flex.html#IDX285">restarting the scanner</A>
+<LI><A HREF="flex.html#IDX313">read</A>
+<LI><A HREF="flex.html#IDX282">reentrant</A>
 </DIR>
-<H2><A NAME="exindex_s">s</A></H2>
+<H2><A NAME="opindex_s">s</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX122">start conditions, basic</A>
-<LI><A HREF="flex.html#IDX129">start conditions, behavior of default rule</A>
-<LI><A HREF="flex.html#IDX126">start conditions, exclusive</A>
-<LI><A HREF="flex.html#IDX134">start conditions, for different interpretations of same input</A>
-<LI><A HREF="flex.html#IDX125">start conditions, inclusive</A>
-<LI><A HREF="flex.html#IDX123">start conditions, multiple</A>
-<LI><A HREF="flex.html#IDX128">start conditions, use of wildcard condition (&#60;*&#62;)</A>
-<LI><A HREF="flex.html#IDX133">start conditions, using BEGIN</A>
+<LI><A HREF="flex.html#IDX268">stack</A>
+<LI><A HREF="flex.html#IDX270">stdinit</A>
+<LI><A HREF="flex.html#IDX235">stdout</A>
 </DIR>
-<H2><A NAME="exindex_t">t</A></H2>
+<H2><A NAME="opindex_t">t</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX213">trailing context, variable length</A>
+<LI><A HREF="flex.html#IDX238">tables-file</A>
+<LI><A HREF="flex.html#IDX240">tables-verify</A>
+<LI><A HREF="flex.html#IDX334">trace</A>
 </DIR>
-<H2><A NAME="exindex_u">u</A></H2>
+<H2><A NAME="opindex_v">v</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX97">unput() to push back characters</A>
-<LI><A HREF="flex.html#IDX138">using integer values of start condition names</A>
+<LI><A HREF="flex.html#IDX340">verbose</A>
 </DIR>
-<H2><A NAME="exindex_w">w</A></H2>
+<H2><A NAME="opindex_w">w</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX293">warning, dangerous trailing context</A>
-<LI><A HREF="flex.html#IDX291">warning, rule cannot be matched</A>
+<LI><A HREF="flex.html#IDX342">warn</A>
 </DIR>
-<H2><A NAME="exindex_y">y</A></H2>
+<H2><A NAME="opindex_y">y</A></H2>
 <DIR>
-<LI><A HREF="flex.html#IDX198">yacc interface</A>
-<LI><A HREF="flex.html#IDX259">YY_EXTRA_TYPE, defining your own type</A>
-<LI><A HREF="flex.html#IDX119">YY_INPUT, overriding the input mechanism</A>
-<LI><A HREF="flex.html#IDX175">YY_USER_ACTION to track each time a rule is matched</A>
-<LI><A HREF="flex.html#IDX94">yyless() to push back characters</A>
-<LI><A HREF="flex.html#IDX114">yylex, overriding the prototype</A>
-<LI><A HREF="flex.html#IDX90">yymore() to append token to previous token</A>
+<LI><A HREF="flex.html#IDX298">yyclass</A>
+<LI><A HREF="flex.html#IDX272">yylineno</A>
+<LI><A HREF="flex.html#IDX274">yywrap</A>
 </DIR>
 
 
 <P><HR><P>
-This document was generated on 2 July 2002 using
+This document was generated on 9 November 2002 using
 <A HREF="http://wwwinfo.cern.ch/dis/texi2html/">texi2html</A>&nbsp;1.56k.
 </BODY>
 </HTML>


ossp-adm/autotools/flex_toc.html -> 1.1

*** /dev/null    Sat Nov 23 06:11:26 2024
--- -    Sat Nov 23 06:11:29 2024
***************
*** 0 ****
--- 1,203 ----
+ <HTML>
+ <HEAD>
+ <!-- Created by texi2html 1.56k from flex.texi on 9 November 2002 -->
+ 
+ <TITLE>flex: a fast lexical analyzer generator - Table of Contents</TITLE>
+ </HEAD>
+ <BODY>
+ <H1>Flex, version 2.5.23</H1>
+ <H2>A fast scanner generator</H2>
+ <H2>Edition 2.5.23, 21 October 2002</H2>
+ <ADDRESS>Vern Paxson</ADDRESS>
+ <ADDRESS>W. L. Estes</ADDRESS>
+ <ADDRESS>John Millaway</ADDRESS>
+ <P>
+ <P><HR><P>
+ <UL>
+ <LI><A NAME="TOC1" HREF="flex.html#SEC1">Copyright</A>
+ <LI><A NAME="TOC2" HREF="flex.html#SEC2">Reporting Bugs</A>
+ <LI><A NAME="TOC3" HREF="flex.html#SEC3">Introduction</A>
+ <LI><A NAME="TOC4" HREF="flex.html#SEC4">Some Simple Examples</A>
+ <LI><A NAME="TOC5" HREF="flex.html#SEC5">Format of the Input File</A>
+ <UL>
+ <LI><A NAME="TOC6" HREF="flex.html#SEC6">Format of the Definitions Section</A>
+ <LI><A NAME="TOC7" HREF="flex.html#SEC7">Format of the Rules Section</A>
+ <LI><A NAME="TOC8" HREF="flex.html#SEC8">Format of the User Code Section</A>
+ <LI><A NAME="TOC9" HREF="flex.html#SEC9">Comments in the Input</A>
+ </UL>
+ <LI><A NAME="TOC10" HREF="flex.html#SEC10">Patterns</A>
+ <LI><A NAME="TOC11" HREF="flex.html#SEC11">How the Input Is Matched</A>
+ <LI><A NAME="TOC12" HREF="flex.html#SEC12">Actions</A>
+ <LI><A NAME="TOC13" HREF="flex.html#SEC13">The Generated Scanner</A>
+ <LI><A NAME="TOC14" HREF="flex.html#SEC14">Start Conditions</A>
+ <LI><A NAME="TOC15" HREF="flex.html#SEC15">Multiple Input Buffers</A>
+ <LI><A NAME="TOC16" HREF="flex.html#SEC16">End-of-File Rules</A>
+ <LI><A NAME="TOC17" HREF="flex.html#SEC17">Miscellaneous Macros</A>
+ <LI><A NAME="TOC18" HREF="flex.html#SEC18">Values Available To the User</A>
+ <LI><A NAME="TOC19" HREF="flex.html#SEC19">Interfacing with Yacc</A>
+ <LI><A NAME="TOC20" HREF="flex.html#SEC20">Scanner Options</A>
+ <UL>
+ <LI><A NAME="TOC21" HREF="flex.html#SEC21">Options for Specifing Filenames</A>
+ <LI><A NAME="TOC22" HREF="flex.html#SEC22">Options Affecting Scanner Behavior</A>
+ <LI><A NAME="TOC23" HREF="flex.html#SEC23">Code-Level And API Options</A>
+ <LI><A NAME="TOC24" HREF="flex.html#SEC24">Options for Scanner Speed and Size</A>
+ <LI><A NAME="TOC25" HREF="flex.html#SEC25">Debugging Options</A>
+ <LI><A NAME="TOC26" HREF="flex.html#SEC26">Miscellaneous Options</A>
+ </UL>
+ <LI><A NAME="TOC27" HREF="flex.html#SEC27">Performance Considerations</A>
+ <LI><A NAME="TOC28" HREF="flex.html#SEC28">Generating C++ Scanners</A>
+ <LI><A NAME="TOC29" HREF="flex.html#SEC29">Reentrant C Scanners</A>
+ <UL>
+ <LI><A NAME="TOC30" HREF="flex.html#SEC30">Uses for Reentrant Scanners</A>
+ <LI><A NAME="TOC31" HREF="flex.html#SEC31">An Overview of the Reentrant API</A>
+ <LI><A NAME="TOC32" HREF="flex.html#SEC32">Reentrant Example</A>
+ <LI><A NAME="TOC33" HREF="flex.html#SEC33">The Reentrant API in Detail</A>
+ <UL>
+ <LI><A NAME="TOC34" HREF="flex.html#SEC34">Declaring a Scanner As Reentrant</A>
+ <LI><A NAME="TOC35" HREF="flex.html#SEC35">The Extra Argument</A>
+ <LI><A NAME="TOC36" HREF="flex.html#SEC36">Global Variables Replaced By Macros</A>
+ <LI><A NAME="TOC37" HREF="flex.html#SEC37">Init and Destroy Functions</A>
+ <LI><A NAME="TOC38" HREF="flex.html#SEC38">Accessing Variables with Reentrant Scanners</A>
+ <LI><A NAME="TOC39" HREF="flex.html#SEC39">Extra Data</A>
+ <LI><A NAME="TOC40" HREF="flex.html#SEC40">About yyscan_t</A>
+ </UL>
+ <LI><A NAME="TOC41" HREF="flex.html#SEC41">Functions and Macros Available in Reentrant C Scanners</A>
+ </UL>
+ <LI><A NAME="TOC42" HREF="flex.html#SEC42">Incompatibilities with Lex and Posix</A>
+ <LI><A NAME="TOC43" HREF="flex.html#SEC43">Memory Management</A>
+ <UL>
+ <LI><A NAME="TOC44" HREF="flex.html#SEC44">The Default Memory Management</A>
+ <LI><A NAME="TOC45" HREF="flex.html#SEC45">Overriding The Default Memory Management</A>
+ <LI><A NAME="TOC46" HREF="flex.html#SEC46">A Note About yytext And Memory</A>
+ </UL>
+ <LI><A NAME="TOC47" HREF="flex.html#SEC47">Serialized Tables</A>
+ <UL>
+ <LI><A NAME="TOC48" HREF="flex.html#SEC48">Creating Serialized Tables</A>
+ <LI><A NAME="TOC49" HREF="flex.html#SEC49">Loading and Unloading Serialized Tables</A>
+ <LI><A NAME="TOC50" HREF="flex.html#SEC50">Tables File Format</A>
+ </UL>
+ <LI><A NAME="TOC51" HREF="flex.html#SEC51">Diagnostics</A>
+ <LI><A NAME="TOC52" HREF="flex.html#SEC52">Limitations</A>
+ <LI><A NAME="TOC53" HREF="flex.html#SEC53">Additional Reading</A>
+ <LI><A NAME="TOC54" HREF="flex.html#SEC54">FAQ</A>
+ <UL>
+ <LI><A NAME="TOC55" HREF="flex.html#SEC55">When was flex born?</A>
+ <LI><A NAME="TOC56" HREF="flex.html#SEC56">How do I expand \ escape sequences in C-style quoted strings?</A>
+ <LI><A NAME="TOC57" HREF="flex.html#SEC57">Why do flex scanners call fileno if it is not ANSI compatible?</A>
+ <LI><A NAME="TOC58" HREF="flex.html#SEC58">Does flex support recursive pattern definitions?</A>
+ <LI><A NAME="TOC59" HREF="flex.html#SEC59">How do I skip huge chunks of input (tens of megabytes) while using flex?</A>
+ <LI><A NAME="TOC60" HREF="flex.html#SEC60">Flex is not matching my patterns in the same order that I defined them.</A>
+ <LI><A NAME="TOC61" HREF="flex.html#SEC61">My actions are executing out of order or sometimes not at all.</A>
+ <LI><A NAME="TOC62" HREF="flex.html#SEC62">How can I have multiple input sources feed into the same scanner at the same time?</A>
+ <LI><A NAME="TOC63" HREF="flex.html#SEC63">Can I build nested parsers that work with the same input file?</A>
+ <LI><A NAME="TOC64" HREF="flex.html#SEC64">How can I match text only at the end of a file?</A>
+ <LI><A NAME="TOC65" HREF="flex.html#SEC65">How can I make REJECT cascade across start condition boundaries?</A>
+ <LI><A NAME="TOC66" HREF="flex.html#SEC66">Why can't I use fast or full tables with interactive mode?</A>
+ <LI><A NAME="TOC67" HREF="flex.html#SEC67">How much faster is -F or -f than -C?</A>
+ <LI><A NAME="TOC68" HREF="flex.html#SEC68">If I have a simple grammar can't I just parse it with flex?</A>
+ <LI><A NAME="TOC69" HREF="flex.html#SEC69">Why doesn't yyrestart() set the start state back to INITIAL?</A>
+ <LI><A NAME="TOC70" HREF="flex.html#SEC70">How can I match C-style comments?</A>
+ <LI><A NAME="TOC71" HREF="flex.html#SEC71">The '.' isn't working the way I expected.</A>
+ <LI><A NAME="TOC72" HREF="flex.html#SEC72">Can I get the flex manual in another format?</A>
+ <LI><A NAME="TOC73" HREF="flex.html#SEC73">Does there exist a "faster" NDFA-&#62;DFA algorithm?</A>
+ <LI><A NAME="TOC74" HREF="flex.html#SEC74">How does flex compile the DFA so quickly?</A>
+ <LI><A NAME="TOC75" HREF="flex.html#SEC75">How can I use more than 8192 rules?</A>
+ <LI><A NAME="TOC76" HREF="flex.html#SEC76">How do I abandon a file in the middle of a scan and switch to a new file?</A>
+ <LI><A NAME="TOC77" HREF="flex.html#SEC77">How do I execute code only during initialization (only before the first scan)?</A>
+ <LI><A NAME="TOC78" HREF="flex.html#SEC78">How do I execute code at termination?</A>
+ <LI><A NAME="TOC79" HREF="flex.html#SEC79">Where else can I find help?</A>
+ <LI><A NAME="TOC80" HREF="flex.html#SEC80">Can I include comments in the "rules" section of the file?</A>
+ <LI><A NAME="TOC81" HREF="flex.html#SEC81">I get an error about undefined yywrap().</A>
+ <LI><A NAME="TOC82" HREF="flex.html#SEC82">How can I change the matching pattern at run time?</A>
+ <LI><A NAME="TOC83" HREF="flex.html#SEC83">How can I expand macros in the input?</A>
+ <LI><A NAME="TOC84" HREF="flex.html#SEC84">How can I build a two-pass scanner?</A>
+ <LI><A NAME="TOC85" HREF="flex.html#SEC85">How do I match any string not matched in the preceding rules?</A>
+ <LI><A NAME="TOC86" HREF="flex.html#SEC86">I am trying to port code from AT&#38;T lex that uses yysptr and yysbuf.</A>
+ <LI><A NAME="TOC87" HREF="flex.html#SEC87">Is there a way to make flex treat NULL like a regular character?</A>
+ <LI><A NAME="TOC88" HREF="flex.html#SEC88">Whenever flex can not match the input it says "flex scanner jammed".</A>
+ <LI><A NAME="TOC89" HREF="flex.html#SEC89">Why doesn't flex have non-greedy operators like perl does?</A>
+ <LI><A NAME="TOC90" HREF="flex.html#SEC90">Memory leak - 16386 bytes allocated by malloc.</A>
+ <LI><A NAME="TOC91" HREF="flex.html#SEC91">How do I track the byte offset for lseek()?</A>
+ <LI><A NAME="TOC92" HREF="flex.html#SEC92">How do I use my own I/O classes in a C++ scanner?</A>
+ <LI><A NAME="TOC93" HREF="flex.html#SEC93">How do I skip as many chars as possible?</A>
+ <LI><A NAME="TOC94" HREF="flex.html#SEC94">unnamed-faq-33</A>
+ <LI><A NAME="TOC95" HREF="flex.html#SEC95">unnamed-faq-42</A>
+ <LI><A NAME="TOC96" HREF="flex.html#SEC96">unnamed-faq-43</A>
+ <LI><A NAME="TOC97" HREF="flex.html#SEC97">unnamed-faq-44</A>
+ <LI><A NAME="TOC98" HREF="flex.html#SEC98">unnamed-faq-45</A>
+ <LI><A NAME="TOC99" HREF="flex.html#SEC99">unnamed-faq-46</A>
+ <LI><A NAME="TOC100" HREF="flex.html#SEC100">unnamed-faq-47</A>
+ <LI><A NAME="TOC101" HREF="flex.html#SEC101">unnamed-faq-48</A>
+ <LI><A NAME="TOC102" HREF="flex.html#SEC102">unnamed-faq-49</A>
+ <LI><A NAME="TOC103" HREF="flex.html#SEC103">unnamed-faq-50</A>
+ <LI><A NAME="TOC104" HREF="flex.html#SEC104">unnamed-faq-51</A>
+ <LI><A NAME="TOC105" HREF="flex.html#SEC105">unnamed-faq-52</A>
+ <LI><A NAME="TOC106" HREF="flex.html#SEC106">unnamed-faq-53</A>
+ <LI><A NAME="TOC107" HREF="flex.html#SEC107">unnamed-faq-54</A>
+ <LI><A NAME="TOC108" HREF="flex.html#SEC108">unnamed-faq-55</A>
+ <LI><A NAME="TOC109" HREF="flex.html#SEC109">unnamed-faq-56</A>
+ <LI><A NAME="TOC110" HREF="flex.html#SEC110">unnamed-faq-57</A>
+ <LI><A NAME="TOC111" HREF="flex.html#SEC111">unnamed-faq-58</A>
+ <LI><A NAME="TOC112" HREF="flex.html#SEC112">unnamed-faq-59</A>
+ <LI><A NAME="TOC113" HREF="flex.html#SEC113">unnamed-faq-60</A>
+ <LI><A NAME="TOC114" HREF="flex.html#SEC114">unnamed-faq-61</A>
+ <LI><A NAME="TOC115" HREF="flex.html#SEC115">unnamed-faq-62</A>
+ <LI><A NAME="TOC116" HREF="flex.html#SEC116">unnamed-faq-63</A>
+ <LI><A NAME="TOC117" HREF="flex.html#SEC117">unnamed-faq-64</A>
+ <LI><A NAME="TOC118" HREF="flex.html#SEC118">unnamed-faq-65</A>
+ <LI><A NAME="TOC119" HREF="flex.html#SEC119">unnamed-faq-66</A>
+ <LI><A NAME="TOC120" HREF="flex.html#SEC120">unnamed-faq-67</A>
+ <LI><A NAME="TOC121" HREF="flex.html#SEC121">unnamed-faq-68</A>
+ <LI><A NAME="TOC122" HREF="flex.html#SEC122">unnamed-faq-69</A>
+ <LI><A NAME="TOC123" HREF="flex.html#SEC123">unnamed-faq-70</A>
+ <LI><A NAME="TOC124" HREF="flex.html#SEC124">unnamed-faq-71</A>
+ <LI><A NAME="TOC125" HREF="flex.html#SEC125">unnamed-faq-72</A>
+ <LI><A NAME="TOC126" HREF="flex.html#SEC126">unnamed-faq-73</A>
+ <LI><A NAME="TOC127" HREF="flex.html#SEC127">unnamed-faq-74</A>
+ <LI><A NAME="TOC128" HREF="flex.html#SEC128">unnamed-faq-75</A>
+ <LI><A NAME="TOC129" HREF="flex.html#SEC129">unnamed-faq-76</A>
+ <LI><A NAME="TOC130" HREF="flex.html#SEC130">unnamed-faq-77</A>
+ <LI><A NAME="TOC131" HREF="flex.html#SEC131">unnamed-faq-78</A>
+ <LI><A NAME="TOC132" HREF="flex.html#SEC132">unnamed-faq-79</A>
+ <LI><A NAME="TOC133" HREF="flex.html#SEC133">unnamed-faq-80</A>
+ <LI><A NAME="TOC134" HREF="flex.html#SEC134">unnamed-faq-81</A>
+ <LI><A NAME="TOC135" HREF="flex.html#SEC135">unnamed-faq-82</A>
+ <LI><A NAME="TOC136" HREF="flex.html#SEC136">unnamed-faq-83</A>
+ <LI><A NAME="TOC137" HREF="flex.html#SEC137">unnamed-faq-84</A>
+ <LI><A NAME="TOC138" HREF="flex.html#SEC138">unnamed-faq-85</A>
+ <LI><A NAME="TOC139" HREF="flex.html#SEC139">unnamed-faq-86</A>
+ <LI><A NAME="TOC140" HREF="flex.html#SEC140">unnamed-faq-87</A>
+ <LI><A NAME="TOC141" HREF="flex.html#SEC141">unnamed-faq-88</A>
+ <LI><A NAME="TOC142" HREF="flex.html#SEC142">unnamed-faq-90</A>
+ <LI><A NAME="TOC143" HREF="flex.html#SEC143">unnamed-faq-91</A>
+ <LI><A NAME="TOC144" HREF="flex.html#SEC144">unnamed-faq-92</A>
+ <LI><A NAME="TOC145" HREF="flex.html#SEC145">unnamed-faq-93</A>
+ <LI><A NAME="TOC146" HREF="flex.html#SEC146">unnamed-faq-94</A>
+ <LI><A NAME="TOC147" HREF="flex.html#SEC147">unnamed-faq-95</A>
+ <LI><A NAME="TOC148" HREF="flex.html#SEC148">unnamed-faq-96</A>
+ <LI><A NAME="TOC149" HREF="flex.html#SEC149">unnamed-faq-97</A>
+ <LI><A NAME="TOC150" HREF="flex.html#SEC150">unnamed-faq-98</A>
+ <LI><A NAME="TOC151" HREF="flex.html#SEC151">unnamed-faq-99</A>
+ <LI><A NAME="TOC152" HREF="flex.html#SEC152">unnamed-faq-100</A>
+ <LI><A NAME="TOC153" HREF="flex.html#SEC153">unnamed-faq-101</A>
+ </UL>
+ <LI><A NAME="TOC154" HREF="flex.html#SEC154">Appendices</A>
+ <UL>
+ <LI><A NAME="TOC155" HREF="flex.html#SEC155">Makefiles and Flex</A>
+ <LI><A NAME="TOC156" HREF="flex.html#SEC156">C Scanners with Bison Parsers</A>
+ </UL>
+ <LI><A NAME="TOC157" HREF="flex.html#SEC157">Indices</A>
+ <UL>
+ <LI><A NAME="TOC158" HREF="flex.html#SEC158">Concept Index</A>
+ <LI><A NAME="TOC159" HREF="flex.html#SEC159">Index of Functions and Macros</A>
+ <LI><A NAME="TOC160" HREF="flex.html#SEC160">Index of Variables</A>
+ <LI><A NAME="TOC161" HREF="flex.html#SEC161">Index of Data Types</A>
+ <LI><A NAME="TOC162" HREF="flex.html#SEC162">Index of Hooks</A>
+ <LI><A NAME="TOC163" HREF="flex.html#SEC163">Index of Scanner Options</A>
+ </UL>
+ </UL>
+ <P><HR><P>
+ This document was generated on 9 November 2002 using
+ <A HREF="http://wwwinfo.cern.ch/dis/texi2html/">texi2html</A>&nbsp;1.56k.
+ </BODY>
+ </HTML>

CVSTrac 2.0.1