1 This version of Berkeley Yacc has been extensively reorganized and 2contains many new features. It is an amalgam of three earlier versions 3of Berkeley Yacc. It is largely untested, so expect it to contain bugs. 4When bugs are found report them to corbett@berkeley.edu. Please 5include small examples if possible. 6 7 Despite my pleas not to be told of undocumented features of AT&T Yacc, 8I have received unsolicited descriptions of such features. Telling me of 9such features places the public-domain status of Berkeley Yacc at risk. 10Please do not send me descriptions of undocumented features. On the 11other hand, I would be very interested in learning of documented 12features I have not implemented. 13 14 The -l and -t options have been implemented. The -l option tells 15Yacc not to include #line directives in the code it produces. The -t 16option causes debugging code to be included in the compiled parser. 17 18 The code for error recovery has been changed to implement the same 19algorithm as AT&T Yacc. There will still be differences in the way 20error recovery works because AT&T Yacc uses more default reductions 21than Berekeley Yacc. 22 23 The environment variable TMPDIR determines the directory where 24temporary files will be created. If TMPDIR is defined, temporary files 25will be created in the directory whose pathname is the value of TMPDIR. 26By default, temporary files are created in /tmp. 27 28 The keywords are now case-insensitive. For example, %nonassoc, 29%NONASSOC, %NonAssoc, and %nOnAsSoC are all equivalent. 30 31 Commas and semicolons that are not part of C code are treated as 32commentary. 33 34 Line-end comments, as in BCPL, are permitted. Line-end comments 35begin with // and end at the next end-of-line. Line-end comments are 36permitted in C code; they are converted to C comments on output. 37 38 The form of y.output files has been changed to look more like 39those produced by AT&T Yacc. 40 41 A new kind of declaration has been added. The form of the declaration 42is 43 44 %ident string 45 46where string is a sequence of characters begining with a double quote 47and ending with either a double quote or the next end-of-line, whichever 48comes first. The declaration will cause a #ident directive to be written 49near the start of the output file. 50 51 If a parser has been compiled with debugging code, that code can be 52enabled by setting an environment variable. If the environment variable 53YYDEBUG is set to 0, debugging output is suppressed. If it is set to 1, 54debugging output is written to standard output. 55