home *** CD-ROM | disk | FTP | other *** search
/ Power-Programmierung / CD2.mdf / c / compcomp / flex237 / flex.man < prev    next >
Encoding:
Text File  |  1991-11-06  |  23.5 KB  |  727 lines

  1.  
  2.  
  3.  
  4. FLEX(1)            November 6, 1991          FLEX(1)
  5.  
  6.  
  7.  
  8. NAME
  9.      flex - fast lexical analyzer generator
  10.  
  11. SYNOPSIS
  12.      flex [-bcdfinpstvFILT8 -C[efmF] -Sskeleton] [_f_i_l_e_n_a_m_e ...]
  13.  
  14. DESCRIPTION
  15.      _f_l_e_x is a tool for    generating _s_c_a_n_n_e_r_s: programs which
  16.      recognized    lexical    patterns in text.  _f_l_e_x    reads the given
  17.      input files, or its standard input    if no file names are
  18.      given, for    a description of a scanner to generate.     The
  19.      description is in the form    of pairs of regular expressions
  20.      and C code, called    _r_u_l_e_s. _f_l_e_x generates as output    a C
  21.      source file, lex.yy.c, which defines a routine yylex(). This
  22.      file is compiled and linked with the -lfl library to produce
  23.      an    executable.  When the executable is run, it analyzes its
  24.      input for occurrences of the regular expressions.    Whenever
  25.      it    finds one, it executes the corresponding C code.
  26.  
  27.      For full documentation, see flexdoc(1). This manual entry is
  28.      intended for use as a quick reference.
  29.  
  30. OPTIONS
  31.      _f_l_e_x has the following options:
  32.  
  33.      -b      Generate backtracking    information to _l_e_x._b_a_c_k_t_r_a_c_k.
  34.       This is a list of scanner states which require
  35.       backtracking and the input characters    on which they do
  36.       so.  By adding rules one can remove backtracking
  37.       states.  If all backtracking states are eliminated and
  38.       -f or    -F is used, the    generated scanner will run
  39.       faster.
  40.  
  41.      -c      is a do-nothing, deprecated option included for POSIX
  42.       compliance.
  43.  
  44.       NOTE:    in previous releases of    _f_l_e_x -c    specified table-
  45.       compression options.    This functionality is now given
  46.       by the -C flag.  To ease the the impact of this change,
  47.       when _f_l_e_x encounters -c, it currently    issues a warning
  48.       message and assumes that -C was desired instead.  In
  49.       the future this "promotion" of -c to -C will go away in
  50.       the name of full POSIX compliance (unless the    POSIX
  51.       meaning is removed first).
  52.  
  53.      -d      makes    the generated scanner run in _d_e_b_u_g mode.
  54.       Whenever a pattern is    recognized and the global
  55.       yy_flex_debug    is non-zero (which is the default), the
  56.       scanner will write to    _s_t_d_e_r_r a line of the form:
  57.  
  58.           --accepting rule at line 53 ("the    matched    text")
  59.  
  60.  
  61.  
  62.  
  63. Page 1                     Pyramid OSx Operating System
  64.  
  65.  
  66.  
  67.  
  68.  
  69.  
  70. FLEX(1)            November 6, 1991          FLEX(1)
  71.  
  72.  
  73.  
  74.       The line number refers to the    location of the    rule in
  75.       the file defining the    scanner    (i.e., the file    that was
  76.       fed to flex).     Messages are also generated when the
  77.       scanner backtracks, accepts the default rule,    reaches
  78.       the end of its input buffer (or encounters a NUL; the
  79.       two look the same as far as the scanner's concerned),
  80.       or reaches an    end-of-file.
  81.  
  82.      -f      specifies (take your pick) _f_u_l_l _t_a_b_l_e    or _f_a_s_t    _s_c_a_n_n_e_r.
  83.       No table compression is done.     The result is large but
  84.       fast.     This option is    equivalent to -Cf (see below).
  85.  
  86.      -i      instructs _f_l_e_x to generate a _c_a_s_e-_i_n_s_e_n_s_i_t_i_v_e    scanner.
  87.       The case of letters given in the _f_l_e_x    input patterns
  88.       will be ignored, and tokens in the input will    be
  89.       matched regardless of    case.  The matched text    given in
  90.       _y_y_t_e_x_t will have the preserved case (i.e., it    will not
  91.       be folded).
  92.  
  93.      -n      is another do-nothing, deprecated option included only
  94.       for POSIX compliance.
  95.  
  96.      -p      generates a performance report to stderr.  The report
  97.       consists of comments regarding features of the _f_l_e_x
  98.       input    file which will    cause a    loss of    performance in
  99.       the resulting    scanner.
  100.  
  101.      -s      causes the _d_e_f_a_u_l_t _r_u_l_e (that    unmatched scanner input
  102.       is echoed to _s_t_d_o_u_t) to be suppressed.  If the scanner
  103.       encounters input that    does not match any of its rules,
  104.       it aborts with an error.
  105.  
  106.      -t      instructs _f_l_e_x to write the scanner it generates to
  107.       standard output instead of lex.yy.c.
  108.  
  109.      -v      specifies that _f_l_e_x should write to _s_t_d_e_r_r a summary of
  110.       statistics regarding the scanner it generates.
  111.  
  112.      -F      specifies that the _f_a_s_t scanner table    representation
  113.       should be used.  This    representation is about    as fast
  114.       as the full table representation (-_f), and for some
  115.       sets of patterns will    be considerably    smaller    (and for
  116.       others, larger).  See    flexdoc(1) for details.
  117.  
  118.       This option is equivalent to -CF (see    below).
  119.  
  120.      -I      instructs _f_l_e_x to generate an    _i_n_t_e_r_a_c_t_i_v_e scanner, that
  121.       is, a    scanner    which stops immediately    rather than
  122.       looking ahead    if it knows that the currently scanned
  123.       text cannot be part of a longer rule's match.     Again,
  124.       see flexdoc(1) for details.
  125.  
  126.  
  127.  
  128.  
  129. Page 2                     Pyramid OSx Operating System
  130.  
  131.  
  132.  
  133.  
  134.  
  135.  
  136. FLEX(1)            November 6, 1991          FLEX(1)
  137.  
  138.  
  139.  
  140.       Note,    -I cannot be used in conjunction with _f_u_l_l or
  141.       _f_a_s_t _t_a_b_l_e_s, i.e., the -f, -F, -Cf, or -CF flags.
  142.  
  143.      -L      instructs _f_l_e_x not to    generate #line directives in
  144.       lex.yy.c. The    default    is to generate such directives so
  145.       error    messages in the    actions    will be    correctly located
  146.       with respect to the original _f_l_e_x input file,    and not
  147.       to the fairly    meaningless line numbers of lex.yy.c.
  148.  
  149.      -T      makes    _f_l_e_x run in _t_r_a_c_e mode.     It will generate a lot
  150.       of messages to _s_t_d_o_u_t    concerning the form of the input
  151.       and the resultant non-deterministic and deterministic
  152.       finite automata.  This option    is mostly for use in
  153.       maintaining _f_l_e_x.
  154.  
  155.      -8      instructs _f_l_e_x to generate an    8-bit scanner.    On some
  156.       sites, this is the default.  On others, the default is
  157.       7-bit    characters.  To    see which is the case, check the
  158.       verbose (-v) output for "equivalence classes created".
  159.       If the denominator of    the number shown is 128, then by
  160.       default _f_l_e_x is generating 7-bit characters.    If it is
  161.       256, then the    default    is 8-bit characters.
  162.  
  163.      -C[efmF]
  164.       controls the degree of table compression.
  165.  
  166.       -Ce directs _f_l_e_x to construct    _e_q_u_i_v_a_l_e_n_c_e _c_l_a_s_s_e_s,
  167.       i.e.,    sets of    characters which have identical    lexical
  168.       properties.  Equivalence classes usually give    dramatic
  169.       reductions in    the final table/object file sizes
  170.       (typically a factor of 2-5) and are pretty cheap
  171.       performance-wise (one    array look-up per character
  172.       scanned).
  173.  
  174.       -Cf specifies    that the _f_u_l_l scanner tables should be
  175.       generated - _f_l_e_x should not compress the tables by
  176.       taking advantages of similar transition functions for
  177.       different states.
  178.  
  179.       -CF specifies    that the alternate fast    scanner
  180.       representation (described in flexdoc(1)) should be
  181.       used.
  182.  
  183.       -Cm directs _f_l_e_x to construct    _m_e_t_a-_e_q_u_i_v_a_l_e_n_c_e _c_l_a_s_s_e_s,
  184.       which    are sets of equivalence    classes    (or characters,
  185.       if equivalence classes are not being used) that are
  186.       commonly used    together.  Meta-equivalence classes are
  187.       often    a big win when using compressed    tables,    but they
  188.       have a moderate performance impact (one or two "if"
  189.       tests    and one    array look-up per character scanned).
  190.  
  191.       A lone -C specifies that the scanner tables should be
  192.  
  193.  
  194.  
  195. Page 3                     Pyramid OSx Operating System
  196.  
  197.  
  198.  
  199.  
  200.  
  201.  
  202. FLEX(1)            November 6, 1991          FLEX(1)
  203.  
  204.  
  205.  
  206.       compressed but neither equivalence classes nor meta-
  207.       equivalence classes should be    used.
  208.  
  209.       The options -Cf or -CF and -Cm do not    make sense
  210.       together - there is no opportunity for meta-equivalence
  211.       classes if the table is not being compressed.
  212.       Otherwise the    options    may be freely mixed.
  213.  
  214.       The default setting is -Cem, which specifies that _f_l_e_x
  215.       should generate equivalence classes and meta-
  216.       equivalence classes.    This setting provides the highest
  217.       degree of table compression.    You can    trade off
  218.       faster-executing scanners at the cost    of larger tables
  219.       with the following generally being true:
  220.  
  221.           slowest &    smallest
  222.             -Cem
  223.             -Cm
  224.             -Ce
  225.             -C
  226.             -C{f,F}e
  227.             -C{f,F}
  228.           fastest &    largest
  229.  
  230.  
  231.       -C options are not cumulative; whenever the flag is
  232.       encountered, the previous -C settings    are forgotten.
  233.  
  234.      -Sskeleton_file
  235.       overrides the    default    skeleton file from which _f_l_e_x
  236.       constructs its scanners.  You'll never need this option
  237.       unless you are doing _f_l_e_x maintenance    or development.
  238.  
  239. SUMMARY    OF FLEX    REGULAR    EXPRESSIONS
  240.      The patterns in the input are written using an extended set
  241.      of    regular    expressions.  These are:
  242.  
  243.      x        match the character    'x'
  244.      .        any    character except newline
  245.      [xyz]        a "character class"; in this case, the pattern
  246.               matches either an    'x', a 'y', or a 'z'
  247.      [abj-oZ]   a "character class"    with a range in    it; matches
  248.               an 'a', a    'b', any letter    from 'j' through 'o',
  249.               or a 'Z'
  250.      [^A-Z]        a "negated character class", i.e., any character
  251.               but those    in the class.  In this case, any
  252.               character    EXCEPT an uppercase letter.
  253.      [^A-Z\n]   any    character EXCEPT an uppercase letter or
  254.               a    newline
  255.      r*        zero or more r's, where r is any regular expression
  256.      r+        one    or more    r's
  257.      r?        zero or one    r's (that is, "an optional r")
  258.  
  259.  
  260.  
  261. Page 4                     Pyramid OSx Operating System
  262.  
  263.  
  264.  
  265.  
  266.  
  267.  
  268. FLEX(1)            November 6, 1991          FLEX(1)
  269.  
  270.  
  271.  
  272.      r{2,5}        anywhere from two to five r's
  273.      r{2,}        two    or more    r's
  274.      r{4}        exactly 4 r's
  275.      {name}        the    expansion of the "name"    definition
  276.             (see above)
  277.      "[xyz]\"foo"
  278.             the    literal    string:    [xyz]"foo
  279.      \X        if X is an 'a', 'b', 'f', 'n', 'r',    't', or    'v',
  280.               then the ANSI-C interpretation of    \x.
  281.               Otherwise, a literal 'X' (used to    escape
  282.               operators    such as    '*')
  283.      \123        the    character with octal value 123
  284.      \x2a        the    character with hexadecimal value 2a
  285.      (r)        match an r;    parentheses are    used to    override
  286.               precedence (see below)
  287.  
  288.  
  289.      rs        the    regular    expression r followed by the
  290.               regular expression s; called "concatenation"
  291.  
  292.  
  293.      r|s        either an r    or an s
  294.  
  295.  
  296.      r/s        an r but only if it    is followed by an s.  The
  297.               s    is not part of the matched text.  This type
  298.               of pattern is called as "trailing    context".
  299.      ^r        an r, but only at the beginning of a line
  300.      r$        an r, but only at the end of a line.  Equivalent
  301.               to "r/\n".
  302.  
  303.  
  304.      <s>r        an r, but only in start condition s    (see
  305.             below for discussion of start conditions)
  306.      <s1,s2,s3>r
  307.             same, but in any of    start conditions s1,
  308.             s2,    or s3
  309.  
  310.  
  311.      <<EOF>>    an end-of-file
  312.      <s1,s2><<EOF>>
  313.             an end-of-file when    in start condition s1 or s2
  314.  
  315.      The regular expressions listed above are grouped according
  316.      to    precedence, from highest precedence at the top to lowest
  317.      at    the bottom.  Those grouped together have equal
  318.      precedence.
  319.  
  320.      Some notes    on patterns:
  321.  
  322.      -      Negated character classes _m_a_t_c_h _n_e_w_l_i_n_e_s unless "\n"
  323.       (or an equivalent escape sequence) is    one of the
  324.  
  325.  
  326.  
  327. Page 5                     Pyramid OSx Operating System
  328.  
  329.  
  330.  
  331.  
  332.  
  333.  
  334. FLEX(1)            November 6, 1991          FLEX(1)
  335.  
  336.  
  337.  
  338.       characters explicitly    present    in the negated character
  339.       class    (e.g., "[^A-Z\n]").
  340.  
  341.      -      A rule can have at most one instance of trailing
  342.       context (the '/' operator or the '$' operator).  The
  343.       start    condition, '^',    and "<<EOF>>" patterns can only
  344.       occur    at the beginning of a pattern, and, as well as
  345.       with '/' and '$', cannot be grouped inside parentheses.
  346.       The following    are all    illegal:
  347.  
  348.           foo/bar$
  349.           foo|(bar$)
  350.           foo|^bar
  351.           <sc1>foo<sc2>bar
  352.  
  353.  
  354. SUMMARY    OF SPECIAL ACTIONS
  355.      In    addition to arbitrary C    code, the following can    appear in
  356.      actions:
  357.  
  358.      -      ECHO copies yytext to    the scanner's output.
  359.  
  360.      -      BEGIN    followed by the    name of    a start    condition places
  361.       the scanner in the corresponding start condition.
  362.  
  363.      -      REJECT directs the scanner to    proceed    on to the "second
  364.       best"    rule which matched the input (or a prefix of the
  365.       input).  yytext and yyleng are set up    appropriately.
  366.       Note that REJECT is a    particularly expensive feature in
  367.       terms    scanner    performance; if    it is used in _a_n_y of the
  368.       scanner's actions it will slow down _a_l_l of the
  369.       scanner's matching.  Furthermore, REJECT cannot be used
  370.       with the -_f or -_F options.
  371.  
  372.       Note also that unlike    the other special actions, REJECT
  373.       is a _b_r_a_n_c_h; code immediately    following it in    the
  374.       action will _n_o_t be executed.
  375.  
  376.      -      yymore() tells the scanner that the next time    it
  377.       matches a rule, the corresponding token should be
  378.       _a_p_p_e_n_d_e_d onto    the current value of yytext rather than
  379.       replacing it.
  380.  
  381.      -      yyless(n) returns all    but the    first _n    characters of the
  382.       current token    back to    the input stream, where    they will
  383.       be rescanned when the    scanner    looks for the next match.
  384.       yytext and yyleng are    adjusted appropriately (e.g.,
  385.       yyleng will now be equal to _n    ).
  386.  
  387.      -      unput(c) puts    the character _c    back onto the input
  388.       stream.  It will be the next character scanned.
  389.  
  390.  
  391.  
  392.  
  393. Page 6                     Pyramid OSx Operating System
  394.  
  395.  
  396.  
  397.  
  398.  
  399.  
  400. FLEX(1)            November 6, 1991          FLEX(1)
  401.  
  402.  
  403.  
  404.      -      input() reads    the next character from    the input stream
  405.       (this    routine    is called yyinput() if the scanner is
  406.       compiled using C++).
  407.  
  408.      -      yyterminate()    can be used in lieu of a return    statement
  409.       in an    action.     It terminates the scanner and returns a
  410.       0 to the scanner's caller, indicating    "all done".
  411.  
  412.       By default, yyterminate() is also called when    an end-
  413.       of-file is encountered.  It is a macro and may be
  414.       redefined.
  415.  
  416.      -      YY_NEW_FILE is an action available only in <<EOF>>
  417.       rules.  It means "Okay, I've set up a    new input file,
  418.       continue scanning".
  419.  
  420.      -      yy_create_buffer( file, size ) takes a _F_I_L_E pointer and
  421.       an integer _s_i_z_e. It returns a    YY_BUFFER_STATE    handle to
  422.       a new    input buffer large enough to accomodate    _s_i_z_e
  423.       characters and associated with the given file.  When in
  424.       doubt, use YY_BUF_SIZE for the size.
  425.  
  426.      -      yy_switch_to_buffer( new_buffer ) switches the
  427.       scanner's processing to scan for tokens from the given
  428.       buffer, which    must be    a YY_BUFFER_STATE.
  429.  
  430.      -      yy_delete_buffer( buffer ) deletes the given buffer.
  431.  
  432. VALUES AVAILABLE TO THE    USER
  433.      -      char *yytext holds the text of the current token.  It
  434.       may not be modified.
  435.  
  436.      -      int yyleng holds the length of the current token.  It
  437.       may not be modified.
  438.  
  439.      -      FILE *yyin is    the file which by default _f_l_e_x reads
  440.       from.     It may    be redefined but doing so only makes
  441.       sense    before scanning    begins.     Changing it in    the
  442.       middle of scanning will have unexpected results since
  443.       _f_l_e_x buffers its input.  Once    scanning terminates
  444.       because an end-of-file has been seen,    void yyrestart(
  445.       FILE *new_file ) may be called to point _y_y_i_n at the new
  446.       input    file.
  447.  
  448.      -      FILE *yyout is the file to which ECHO    actions    are done.
  449.       It can be reassigned by the user.
  450.  
  451.      -      YY_CURRENT_BUFFER returns a YY_BUFFER_STATE handle to
  452.       the current buffer.
  453.  
  454. MACROS THE USER    CAN REDEFINE
  455.      -      YY_DECL controls how the scanning routine is declared.
  456.  
  457.  
  458.  
  459. Page 7                     Pyramid OSx Operating System
  460.  
  461.  
  462.  
  463.  
  464.  
  465.  
  466. FLEX(1)            November 6, 1991          FLEX(1)
  467.  
  468.  
  469.  
  470.       By default, it is "int yylex()", or, if prototypes are
  471.       being    used, "int yylex(void)".  This definition may be
  472.       changed by redefining    the "YY_DECL" macro.  Note that
  473.       if you give arguments    to the scanning    routine    using a
  474.       K&R-style/non-prototyped function declaration, you must
  475.       terminate the    definition with    a semi-colon (;).
  476.  
  477.      -      The nature of    how the    scanner    gets its input can be
  478.       controlled by    redefining the YY_INPUT    macro.
  479.       YY_INPUT's calling sequence is
  480.       "YY_INPUT(buf,result,max_size)".  Its    action is to
  481.       place    up to _m_a_x__s_i_z_e characters in the character array
  482.       _b_u_f and return in the    integer    variable _r_e_s_u_l_t    either
  483.       the number of    characters read    or the constant    YY_NULL
  484.       (0 on    Unix systems) to indicate EOF.    The default
  485.       YY_INPUT reads from the global file-pointer "yyin".  A
  486.       sample redefinition of YY_INPUT (in the definitions
  487.       section of the input file):
  488.  
  489.           %{
  490.           #undef YY_INPUT
  491.           #define YY_INPUT(buf,result,max_size) \
  492.           { \
  493.           int c    = getchar(); \
  494.           result = (c == EOF) ?    YY_NULL    : (buf[0] = c, 1); \
  495.           }
  496.           %}
  497.  
  498.  
  499.      -      When the scanner receives an end-of-file indication
  500.       from YY_INPUT, it then checks    the yywrap() function.
  501.       If yywrap() returns false (zero), then it is assumed
  502.       that the function has    gone ahead and set up _y_y_i_n to
  503.       point    to another input file, and scanning continues.
  504.       If it    returns    true (non-zero), then the scanner
  505.       terminates, returning    0 to its caller.
  506.  
  507.       The default yywrap() always returns 1.  Presently, to
  508.       redefine it you must first "#undef yywrap", as it is
  509.       currently implemented    as a macro.  It    is likely that
  510.       yywrap() will    soon be    defined    to be a    function rather
  511.       than a macro.
  512.  
  513.      -      YY_USER_ACTION can be    redefined to provide an    action
  514.       which    is always executed prior to the    matched    rule's
  515.       action.
  516.  
  517.      -      The macro YY_USER_INIT may be    redefined to provide an
  518.       action which is always executed before the first scan.
  519.  
  520.      -      In the generated scanner, the    actions    are all    gathered
  521.       in one large switch statement    and separated using
  522.  
  523.  
  524.  
  525. Page 8                     Pyramid OSx Operating System
  526.  
  527.  
  528.  
  529.  
  530.  
  531.  
  532. FLEX(1)            November 6, 1991          FLEX(1)
  533.  
  534.  
  535.  
  536.       YY_BREAK, which may be redefined.  By    default, it is
  537.       simply a "break", to separate    each rule's action from
  538.       the following    rule's.
  539.  
  540. FILES
  541.      _f_l_e_x._s_k_l
  542.       skeleton scanner.
  543.  
  544.      _l_e_x._y_y._c
  545.       generated scanner (called _l_e_x_y_y._c on some systems).
  546.  
  547.      _l_e_x._b_a_c_k_t_r_a_c_k
  548.       backtracking information for -b flag (called _l_e_x._b_c_k on
  549.       some systems).
  550.  
  551.      -lfl library with which to    link the scanners.
  552.  
  553. SEE ALSO
  554.      flexdoc(1), lex(1), yacc(1), sed(1), awk(1).
  555.  
  556.      M.    E. Lesk    and E. Schmidt,    _L_E_X - _L_e_x_i_c_a_l _A_n_a_l_y_z_e_r _G_e_n_e_r_a_t_o_r
  557.  
  558. DIAGNOSTICS
  559.      _r_e_j_e_c_t__u_s_e_d__b_u_t__n_o_t__d_e_t_e_c_t_e_d _u_n_d_e_f_i_n_e_d or
  560.  
  561.      _y_y_m_o_r_e__u_s_e_d__b_u_t__n_o_t__d_e_t_e_c_t_e_d _u_n_d_e_f_i_n_e_d - These errors can
  562.      occur at compile time.  They indicate that    the scanner uses
  563.      REJECT or yymore()    but that _f_l_e_x failed to    notice the fact,
  564.      meaning that _f_l_e_x scanned the first two sections looking for
  565.      occurrences of these actions and failed to    find any, but
  566.      somehow you snuck some in (via a #include file, for
  567.      example).    Make an    explicit reference to the action in your
  568.      _f_l_e_x input    file.  (Note that previously _f_l_e_x supported a
  569.      %used/%unused mechanism for dealing with this problem; this
  570.      feature is    still supported    but now    deprecated, and    will go
  571.      away soon unless the author hears from people who can argue
  572.      compellingly that they need it.)
  573.  
  574.      _f_l_e_x _s_c_a_n_n_e_r _j_a_m_m_e_d - a scanner compiled with -s has
  575.      encountered an input string which wasn't matched by any of
  576.      its rules.
  577.  
  578.      _f_l_e_x _i_n_p_u_t    _b_u_f_f_e_r _o_v_e_r_f_l_o_w_e_d - a scanner rule matched a
  579.      string long enough    to overflow the    scanner's internal input
  580.      buffer (16K bytes - controlled by YY_BUF_MAX in "flex.skl").
  581.  
  582.      _s_c_a_n_n_e_r _r_e_q_u_i_r_e_s -_8 _f_l_a_g -    Your scanner specification
  583.      includes recognizing 8-bit    characters and you did not
  584.      specify the -8 flag (and your site    has not    installed flex
  585.      with -8 as    the default).
  586.  
  587.  
  588.  
  589.  
  590.  
  591. Page 9                     Pyramid OSx Operating System
  592.  
  593.  
  594.  
  595.  
  596.  
  597.  
  598. FLEX(1)            November 6, 1991          FLEX(1)
  599.  
  600.  
  601.  
  602.      _f_a_t_a_l _f_l_e_x    _s_c_a_n_n_e_r    _i_n_t_e_r_n_a_l _e_r_r_o_r--_e_n_d _o_f _b_u_f_f_e_r _m_i_s_s_e_d -
  603.      This can occur in an scanner which    is reentered after a
  604.      long-jump has jumped out (or over)    the scanner's activation
  605.      frame.  Before reentering the scanner, use:
  606.  
  607.      yyrestart( yyin );
  608.  
  609.  
  610.      _t_o_o _m_a_n_y %_t _c_l_a_s_s_e_s! - You    managed    to put every single
  611.      character into its    own %t class.  _f_l_e_x requires that at
  612.      least one of the classes share characters.
  613.  
  614. AUTHOR
  615.      Vern Paxson, with the help    of many    ideas and much
  616.      inspiration from Van Jacobson.  Original version by Jef
  617.      Poskanzer.
  618.  
  619.      See flexdoc(1) for    additional credits and the address to
  620.      send comments to.
  621.  
  622. DEFICIENCIES / BUGS
  623.      Some trailing context patterns cannot be properly matched
  624.      and generate warning messages ("Dangerous trailing
  625.      context").     These are patterns where the ending of    the first
  626.      part of the rule matches the beginning of the second part,
  627.      such as "zx*/xy*",    where the 'x*' matches the 'x' at the
  628.      beginning of the trailing context.     (Note that the    POSIX
  629.      draft states that the text    matched    by such    patterns is
  630.      undefined.)
  631.  
  632.      For some trailing context rules, parts which are actually
  633.      fixed-length are not recognized as    such, leading to the
  634.      abovementioned performance    loss.  In particular, parts using
  635.      '|' or {n}    (such as "foo{3}") are always considered
  636.      variable-length.
  637.  
  638.      Combining trailing    context    with the special '|' action can
  639.      result in _f_i_x_e_d trailing context being turned into    the more
  640.      expensive _v_a_r_i_a_b_l_e    trailing context.  For example,    this
  641.      happens in    the following example:
  642.  
  643.      %%
  644.      abc      |
  645.      xyz/def
  646.  
  647.  
  648.      Use of unput() invalidates    yytext and yyleng.
  649.  
  650.      Use of unput() to push back more text than    was matched can
  651.      result in the pushed-back text matching a beginning-of-line
  652.      ('^') rule    even though it didn't come at the beginning of
  653.      the line (though this is rare!).
  654.  
  655.  
  656.  
  657. Page 10                     Pyramid OSx Operating System
  658.  
  659.  
  660.  
  661.  
  662.  
  663.  
  664. FLEX(1)            November 6, 1991          FLEX(1)
  665.  
  666.  
  667.  
  668.      Pattern-matching of NUL's is substantially    slower than
  669.      matching other characters.
  670.  
  671.      _f_l_e_x does not generate correct #line directives for code
  672.      internal to the scanner; thus, bugs in _f_l_e_x._s_k_l yield bogus
  673.      line numbers.
  674.  
  675.      Due to both buffering of input and    read-ahead, you    cannot
  676.      intermix calls to <stdio.h> routines, such    as, for    example,
  677.      getchar(),    with _f_l_e_x rules    and expect it to work.    Call
  678.      input() instead.
  679.  
  680.      The total table entries listed by the -v flag excludes the
  681.      number of table entries needed to determine what rule has
  682.      been matched.  The    number of entries is equal to the number
  683.      of    DFA states if the scanner does not use REJECT, and
  684.      somewhat greater than the number of states    if it does.
  685.  
  686.      REJECT cannot be used with    the -_f or -_F options.
  687.  
  688.      Some of the macros, such as yywrap(), may in the future
  689.      become functions which live in the    -lfl library.  This will
  690.      doubtless break a lot of code, but    may be required    for
  691.      POSIX-compliance.
  692.  
  693.      The _f_l_e_x internal algorithms need documentation.
  694.  
  695.  
  696.  
  697.  
  698.  
  699.  
  700.  
  701.  
  702.  
  703.  
  704.  
  705.  
  706.  
  707.  
  708.  
  709.  
  710.  
  711.  
  712.  
  713.  
  714.  
  715.  
  716.  
  717.  
  718.  
  719.  
  720.  
  721.  
  722.  
  723. Page 11                     Pyramid OSx Operating System
  724.  
  725.  
  726.  
  727.