Annotation of cci/usr/src/man/man1/yacc.1, revision 1.1.1.1

1.1       root        1: .TH YACC 1  "18 January 1983"
                      2: .SH NAME
                      3: yacc \- yet another compiler-compiler
                      4: .SH SYNOPSIS
                      5: .B yacc
                      6: [
                      7: .B \-vd
                      8: ]
                      9: grammar
                     10: .SH DESCRIPTION
                     11: .I Yacc
                     12: converts a context-free grammar into a set of
                     13: tables for a simple automaton which executes an LR(1) parsing
                     14: algorithm.
                     15: The grammar may be ambiguous;
                     16: specified precedence rules are used to break ambiguities.
                     17: .PP
                     18: The output file,
                     19: .IR y.tab.c ,
                     20: must be compiled by the C compiler
                     21: to produce a program
                     22: .IR yyparse .
                     23: This program must be loaded with the lexical analyzer program,
                     24: .IR yylex ,
                     25: as well as
                     26: .I main
                     27: and
                     28: .IR yyerror ,
                     29: an error handling routine.
                     30: These routines must be supplied by the user;
                     31: .IR Lex (1)
                     32: is useful for creating lexical analyzers usable by
                     33: .IR yacc .
                     34: .PP
                     35: If the
                     36: .B \-v
                     37: flag is given, the file
                     38: .I y.output
                     39: is prepared, which contains a description of the parsing tables
                     40: and a report on
                     41: conflicts generated by ambiguities in the grammar.
                     42: .PP
                     43: If the \-\fBd\fR flag is used, the file
                     44: .I y.tab.h
                     45: is generated with the
                     46: .I define
                     47: statements that associate the
                     48: .I yacc\c
                     49: -assigned `token codes' with the user-declared `token names'.
                     50: This allows source files other than
                     51: .I y.tab.c
                     52: to access the token codes.
                     53: .SH FILES
                     54: .ta \w'yacc.tmp, yacc.acts 'u
                     55: y.output
                     56: .br
                     57: y.tab.c
                     58: .br
                     59: y.tab.h        defines for token names
                     60: .br
                     61: yacc.tmp, yacc.acts    temporary files
                     62: .br
                     63: /usr/lib/yaccpar       parser prototype for C programs
                     64: .SH "SEE ALSO"
                     65: .IR lex (1)
                     66: .br
                     67: .I "LR Parsing"
                     68: by A. V. Aho and S. C. Johnson,
                     69: Computing Surveys, June, 1974.
                     70: .br
                     71: .I "YACC \- Yet Another Compiler Compiler"
                     72: by S. C. Johnson.
                     73: .SH DIAGNOSTICS
                     74: The number of reduce-reduce and shift-reduce conflicts
                     75: is reported on the standard output;
                     76: a more detailed report is
                     77: found in the
                     78: .I y.output
                     79: file.
                     80: Similarly, if some rules are not reachable from the
                     81: start symbol, this is also reported.
                     82: .SH BUGS
                     83: Because file names are fixed, at most one
                     84: .I yacc
                     85: process can be active in a given directory at
                     86: a time.

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.