xref: /csrg-svn/usr.bin/yacc/NEW_FEATURES (revision 46059)
1*46059Scorbett     The -r option has been implemented.  The -r option tells Yacc to
2*46059Scorbettput the read-only tables in y.tab.c and the code and variables in
3*46059Scorbetty.code.c.  Keith Bostic asked for this option so that :yyfix could be
4*46059Scorbetteliminated.
539771Sbostic
639771Sbostic     The -l and -t options have been implemented.  The -l option tells
739771SbosticYacc not to include #line directives in the code it produces.  The -t
839771Sbosticoption causes debugging code to be included in the compiled parser.
939771Sbostic
1039771Sbostic     The code for error recovery has been changed to implement the same
1139771Sbosticalgorithm as AT&T Yacc.  There will still be differences in the way
1239771Sbosticerror recovery works because AT&T Yacc uses more default reductions
13*46059Scorbettthan Berkeley Yacc.
1439771Sbostic
1539771Sbostic     The environment variable TMPDIR determines the directory where
1639771Sbostictemporary files will be created.  If TMPDIR is defined, temporary files
1739771Sbosticwill be created in the directory whose pathname is the value of TMPDIR.
1839771SbosticBy default, temporary files are created in /tmp.
1939771Sbostic
2039771Sbostic     The keywords are now case-insensitive.  For example, %nonassoc,
2139771Sbostic%NONASSOC, %NonAssoc, and %nOnAsSoC are all equivalent.
2239771Sbostic
2339771Sbostic     Commas and semicolons that are not part of C code are treated as
2439771Sbosticcommentary.
2539771Sbostic
2639771Sbostic     Line-end comments, as in BCPL, are permitted.  Line-end comments
2739771Sbosticbegin with // and end at the next end-of-line.  Line-end comments are
2839771Sbosticpermitted in C code; they are converted to C comments on output.
2939771Sbostic
3039771Sbostic     The form of y.output files has been changed to look more like
3139771Sbosticthose produced by AT&T Yacc.
3239771Sbostic
3339771Sbostic     A new kind of declaration has been added.  The form of the declaration
3439771Sbosticis
3539771Sbostic
3639771Sbostic	  %ident string
3739771Sbostic
3839771Sbosticwhere string is a sequence of characters begining with a double quote
3939771Sbosticand ending with either a double quote or the next end-of-line, whichever
4039771Sbosticcomes first.  The declaration will cause a #ident directive to be written
4139771Sbosticnear the start of the output file.
4239771Sbostic
4339771Sbostic     If a parser has been compiled with debugging code, that code can be
4439771Sbosticenabled by setting an environment variable.  If the environment variable
4539771SbosticYYDEBUG is set to 0, debugging output is suppressed.  If it is set to 1,
4639771Sbosticdebugging output is written to standard output.
47