Updated
This commit is contained in:
parent
c2607fdf0f
commit
13fea7102b
4 changed files with 40 additions and 2 deletions
util/LLgen
|
@ -4,7 +4,7 @@
|
||||||
.SH NAME
|
.SH NAME
|
||||||
LLgen, an extended LL(1) parser generator
|
LLgen, an extended LL(1) parser generator
|
||||||
.SH SYNOPSIS
|
.SH SYNOPSIS
|
||||||
LLgen [ \-vxwa ] [ \-j[\fInum\fP] ] [ \-l\fInum\fP ] [ \-h\fInum\fP ] file ...
|
LLgen [ \-vxwans ] [ \-j[\fInum\fP] ] [ \-l\fInum\fP ] [ \-h\fInum\fP ] file ...
|
||||||
.SH DESCRIPTION
|
.SH DESCRIPTION
|
||||||
\fILLgen\fP
|
\fILLgen\fP
|
||||||
converts a context-free grammar into a set of
|
converts a context-free grammar into a set of
|
||||||
|
@ -36,7 +36,14 @@ to access the token-codes by
|
||||||
using the token-names.
|
using the token-names.
|
||||||
\fILpars.c\fP
|
\fILpars.c\fP
|
||||||
contains the error recovery routines and tables. It must also
|
contains the error recovery routines and tables. It must also
|
||||||
be compiled by the C-compiler.
|
be compiled by the C-compiler. When the generated parser uses non-correcting
|
||||||
|
error recovery (
|
||||||
|
\fB\-n\fP
|
||||||
|
option)
|
||||||
|
\fILLgen\fP
|
||||||
|
also generates a file
|
||||||
|
\fILncor.c\fP
|
||||||
|
that contains the non-correcting recovery mechanism.
|
||||||
.PP
|
.PP
|
||||||
\fILLgen\fP
|
\fILLgen\fP
|
||||||
will only update those output files that differ from their previous
|
will only update those output files that differ from their previous
|
||||||
|
@ -78,6 +85,12 @@ file.
|
||||||
no warnings are given.
|
no warnings are given.
|
||||||
.IP \fB\-a\fP
|
.IP \fB\-a\fP
|
||||||
Produce ANSI C function headers and prototypes.
|
Produce ANSI C function headers and prototypes.
|
||||||
|
.IP \fB\-n\fP
|
||||||
|
Produce a parser with non-correcting error recovery.
|
||||||
|
.IP \fB\-s\fP
|
||||||
|
Simulate the calling of all defined subparsers in all semantic actions. When
|
||||||
|
using non-correcting error recovery, subparsers that are called in semantic
|
||||||
|
actions may cause problems; this flag provides a `brute-force' solution.
|
||||||
.IP \fB\-j\fP[\fInum\fP]
|
.IP \fB\-j\fP[\fInum\fP]
|
||||||
when this flag is given, \fILLgen\fP will generate dense switches,
|
when this flag is given, \fILLgen\fP will generate dense switches,
|
||||||
so that the compiler can generate a jump table for it. This will only be
|
so that the compiler can generate a jump table for it. This will only be
|
||||||
|
@ -109,6 +122,9 @@ Lpars.h defines for token names
|
||||||
.br
|
.br
|
||||||
\fILLgen, an Extended LL(1) Parser Generator\fP
|
\fILLgen, an Extended LL(1) Parser Generator\fP
|
||||||
by C.J.H. Jacobs.
|
by C.J.H. Jacobs.
|
||||||
|
.br
|
||||||
|
\fITop-down Non-Correcting Error Recovery in LLgen\fP
|
||||||
|
by A.W van Deudekom and P.J. Kooiman
|
||||||
.SH DIAGNOSTICS
|
.SH DIAGNOSTICS
|
||||||
Are intended to be self-explanatory. They are reported
|
Are intended to be self-explanatory. They are reported
|
||||||
on standard error. A more detailed report is found in the
|
on standard error. A more detailed report is found in the
|
||||||
|
@ -116,3 +132,6 @@ on standard error. A more detailed report is found in the
|
||||||
file.
|
file.
|
||||||
.SH AUTHOR
|
.SH AUTHOR
|
||||||
Ceriel J. H. Jacobs
|
Ceriel J. H. Jacobs
|
||||||
|
.br
|
||||||
|
The non-correcting error recovery mechanism is written by
|
||||||
|
A.W van Deudekom and P.J. Kooiman.
|
||||||
|
|
|
@ -15,6 +15,8 @@ install:
|
||||||
cp src/LLgen $(INSTALLDIR)/LLgen
|
cp src/LLgen $(INSTALLDIR)/LLgen
|
||||||
cp lib/rec $(LIBDIR)/rec
|
cp lib/rec $(LIBDIR)/rec
|
||||||
cp lib/incl $(LIBDIR)/incl
|
cp lib/incl $(LIBDIR)/incl
|
||||||
|
cp lib/nc_rec $(LIBDIR)/nc_rec
|
||||||
|
cp lib/nc_incl $(LIBDIR)/nc_incl
|
||||||
cp LLgen.1 $(MANDIR)/LLgen.1
|
cp LLgen.1 $(MANDIR)/LLgen.1
|
||||||
|
|
||||||
firstinstall:
|
firstinstall:
|
||||||
|
@ -24,6 +26,8 @@ firstinstall:
|
||||||
-mkdir $(LIBDIR)
|
-mkdir $(LIBDIR)
|
||||||
cp lib/rec $(LIBDIR)/rec
|
cp lib/rec $(LIBDIR)/rec
|
||||||
cp lib/incl $(LIBDIR)/incl
|
cp lib/incl $(LIBDIR)/incl
|
||||||
|
cp lib/nc_rec $(LIBDIR)/nc_rec
|
||||||
|
cp lib/nc_incl $(LIBDIR)/nc_incl
|
||||||
cp LLgen.1 $(MANDIR)/LLgen.1
|
cp LLgen.1 $(MANDIR)/LLgen.1
|
||||||
|
|
||||||
cmp:
|
cmp:
|
||||||
|
@ -31,6 +35,8 @@ cmp:
|
||||||
-cmp src/LLgen $(INSTALLDIR)/LLgen
|
-cmp src/LLgen $(INSTALLDIR)/LLgen
|
||||||
-cmp lib/rec $(LIBDIR)/rec
|
-cmp lib/rec $(LIBDIR)/rec
|
||||||
-cmp lib/incl $(LIBDIR)/incl
|
-cmp lib/incl $(LIBDIR)/incl
|
||||||
|
-cmp lib/nc_rec $(LIBDIR)/nc_rec
|
||||||
|
-cmp lib/nc_incl $(LIBDIR)/nc_incl
|
||||||
-cmp LLgen.1 $(MANDIR)/LLgen.1
|
-cmp LLgen.1 $(MANDIR)/LLgen.1
|
||||||
|
|
||||||
distr:
|
distr:
|
||||||
|
|
|
@ -17,6 +17,8 @@ install:
|
||||||
if [ $(DO_MACHINE_INDEP) = y ] ; \
|
if [ $(DO_MACHINE_INDEP) = y ] ; \
|
||||||
then cp $(SRC_HOME)/util/LLgen/lib/rec $(LIBDIR)/rec ; \
|
then cp $(SRC_HOME)/util/LLgen/lib/rec $(LIBDIR)/rec ; \
|
||||||
cp $(SRC_HOME)/util/LLgen/lib/incl $(LIBDIR)/incl ; \
|
cp $(SRC_HOME)/util/LLgen/lib/incl $(LIBDIR)/incl ; \
|
||||||
|
cp $(SRC_HOME)/util/LLgen/lib/nc_incl $(LIBDIR)/nc_incl ; \
|
||||||
|
cp $(SRC_HOME)/util/LLgen/lib/nc_rec $(LIBDIR)/nc_rec ; \
|
||||||
mk_manpage $(SRC_HOME)/util/LLgen/LLgen.1 $(TARGET_HOME) ; \
|
mk_manpage $(SRC_HOME)/util/LLgen/LLgen.1 $(TARGET_HOME) ; \
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
@ -27,6 +29,8 @@ firstinstall:
|
||||||
then if [ -d $(LIBDIR) ] ; then : ; else mkdir $(LIBDIR) ; fi ; \
|
then if [ -d $(LIBDIR) ] ; then : ; else mkdir $(LIBDIR) ; fi ; \
|
||||||
cp $(SRC_HOME)/util/LLgen/lib/rec $(LIBDIR)/rec ; \
|
cp $(SRC_HOME)/util/LLgen/lib/rec $(LIBDIR)/rec ; \
|
||||||
cp $(SRC_HOME)/util/LLgen/lib/incl $(LIBDIR)/incl ; \
|
cp $(SRC_HOME)/util/LLgen/lib/incl $(LIBDIR)/incl ; \
|
||||||
|
cp $(SRC_HOME)/util/LLgen/lib/nc_incl $(LIBDIR)/nc_incl ; \
|
||||||
|
cp $(SRC_HOME)/util/LLgen/lib/nc_rec $(LIBDIR)/nc_rec ; \
|
||||||
mk_manpage $(SRC_HOME)/util/LLgen/LLgen.1 $(TARGET_HOME) ; \
|
mk_manpage $(SRC_HOME)/util/LLgen/LLgen.1 $(TARGET_HOME) ; \
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
@ -35,6 +39,8 @@ cmp:
|
||||||
-cmp src/LLgen $(INSTALLDIR)/LLgen
|
-cmp src/LLgen $(INSTALLDIR)/LLgen
|
||||||
-cmp $(SRC_HOME)/util/LLgen/lib/rec $(LIBDIR)/rec
|
-cmp $(SRC_HOME)/util/LLgen/lib/rec $(LIBDIR)/rec
|
||||||
-cmp $(SRC_HOME)/util/LLgen/lib/incl $(LIBDIR)/incl
|
-cmp $(SRC_HOME)/util/LLgen/lib/incl $(LIBDIR)/incl
|
||||||
|
-cmp $(SRC_HOME)/util/LLgen/lib/nc_rec $(LIBDIR)/nc_rec
|
||||||
|
-cmp $(SRC_HOME)/util/LLgen/lib/nc_incl $(LIBDIR)/nc_incl
|
||||||
|
|
||||||
distr:
|
distr:
|
||||||
cd src; make distr
|
cd src; make distr
|
||||||
|
|
|
@ -148,3 +148,10 @@ tokens.$(SUF): $(SRC_DIR)/cclass.h
|
||||||
tokens.$(SUF): $(SRC_DIR)/extern.h
|
tokens.$(SUF): $(SRC_DIR)/extern.h
|
||||||
tokens.$(SUF): $(SRC_DIR)/io.h
|
tokens.$(SUF): $(SRC_DIR)/io.h
|
||||||
tokens.$(SUF): $(SRC_DIR)/types.h
|
tokens.$(SUF): $(SRC_DIR)/types.h
|
||||||
|
|
||||||
|
savegram.$(SUF): $(SRC_DIR)/savegram.c
|
||||||
|
$(CC) -c $(CFLAGS) $(SRC_DIR)/savegram.c
|
||||||
|
savegram.$(SUF): $(SRC_DIR)/types.h
|
||||||
|
savegram.$(SUF): $(SRC_DIR)/extern.h
|
||||||
|
savegram.$(SUF): $(SRC_DIR)/io.h
|
||||||
|
savegram.$(SUF): $(SRC_DIR)/sets.h
|
||||||
|
|
Loading…
Reference in a new issue