summaryrefslogtreecommitdiff
path: root/lang/nawk
diff options
context:
space:
mode:
authorryoon <ryoon@pkgsrc.org>2014-03-12 14:20:43 +0000
committerryoon <ryoon@pkgsrc.org>2014-03-12 14:20:43 +0000
commit7403723b584db77fa7663b15e947a02d24a884a8 (patch)
tree72203650b711cb96c4d55a4dff4ade25b7ab0981 /lang/nawk
parent415a375975585be83c02fb2566bf6f0bab81606d (diff)
downloadpkgsrc-7403723b584db77fa7663b15e947a02d24a884a8.tar.gz
Update to 20121220
* Works fine under Debian GNU/Linux 7.4, NetBSD/amd64 6.99.36 * Merge pkgsrc specific changes Changelog: Dec 20, 2012: fiddled makefile to get correct yacc and bison flags. pick yacc (linux) or bison (mac) as necessary. added __attribute__((__noreturn__)) to a couple of lines in proto.h, to silence someone's enthusiastic checker. fixed obscure call by value bug in split(a[1],a) reported on 9fans. the management of temporary values is just a mess; i took a shortcut by making an extra string copy. thanks to paul patience and arnold robbins for passing it on and for proposed patches. tiny fiddle in setfval to eliminate -0 results in T.expr, which has irritated me for 20+ years. Aug 10, 2011: another fix to avoid core dump with delete(ARGV); again, many thanks to ruslan ermilov. Aug 7, 2011: split(s, a, //) now behaves the same as split(s, a, "") Jun 12, 2011: /pat/, \n /pat/ {...} is now legal, though bad style to use. added checks to new -v code that permits -vnospace; thanks to ruslan ermilov for spotting this and providing the patch. removed fixed limit on number of open files; thanks to aleksey cheusov and christos zoulos. fixed day 1 bug that resurrected deleted elements of ARGV when used as filenames (in lib.c). minor type fiddles to make gcc -Wall -pedantic happier (but not totally so); turned on -fno-strict-aliasing in makefile. May 6, 2011: added #ifdef for isblank. now allows -ffoo as well as -f foo arguments. (thanks, ruslan) May 1, 2011: after advice from todd miller, kevin lo, ruslan ermilov, and arnold robbins, changed srand() to return the previous seed (which is 1 on the first call of srand). the seed is an Awkfloat internally though converted to unsigned int to pass to the library srand(). thanks, everyone. fixed a subtle (and i hope low-probability) overflow error in fldbld, by adding space for one extra \0. thanks to robert bassett for spotting this one and providing a fix. removed the files related to compilation on windows. i no longer have anything like a current windows environment, so i can't test any of it. May 23, 2010: fixed long-standing overflow bug in run.c; many thanks to nelson beebe for spotting it and providing the fix. fixed bug that didn't parse -vd=1 properly; thanks to santiago vila for spotting it. Feb 8, 2010: i give up. replaced isblank with isspace in b.c; there are no consistent header files. Nov 26, 2009: fixed a long-standing issue with when FS takes effect. a change to FS is now noticed immediately for subsequent splits. changed the name getline() to awkgetline() to avoid yet another name conflict somewhere. Feb 11, 2009: temporarily for now defined HAS_ISBLANK, since that seems to be the best way through the thicket. isblank arrived in C99, but seems to be arriving at different systems at different times. Oct 8, 2008: fixed typo in b.c that set tmpvec wrongly. no one had ever run into the problem, apparently. thanks to alistair crooks. Oct 23, 2007: minor fix in lib.c: increase inputFS to 100, change malloc for fields to n+1. fixed memory fault caused by out of order test in setsval. thanks to david o'brien, freebsd, for both fixes. May 1, 2007: fiddle in makefile to fix for BSD make; thanks to igor sobrado. Mar 31, 2007: fixed some null pointer refs calling adjbuf. Feb 21, 2007: fixed a bug in matching the null RE in sub and gsub. thanks to al aho who actually did the fix (in b.c), and to wolfgang seeberg for finding it and providing a very compact test case. fixed quotation in b.c; thanks to Hal Pratt and the Princeton Dante Project. removed some no-effect asserts in run.c. fiddled maketab.c to not complain about bison-generated values. removed the obsolete -V argument; fixed --version to print the version and exit. fixed wording and an outright error in the usage message; thanks to igor sobrado and jason mcintyre. fixed a bug in -d that caused core dump if no program followed. Jan 1, 2007: dropped mac.code from makefile; there are few non-MacOSX mac's these days. Jan 17, 2006: system() not flagged as unsafe in the unadvertised -safe option. found it while enhancing tests before shipping the ;login: article. practice what you preach. removed the 9-years-obsolete -mr and -mf flags. added -version and --version options. core dump on linux with BEGIN {nextfile}, now fixed. removed some #ifdef's in run.c and lex.c that appear to no longer be necessary.
Diffstat (limited to 'lang/nawk')
-rw-r--r--lang/nawk/Makefile7
-rw-r--r--lang/nawk/files/FIXES140
-rw-r--r--lang/nawk/files/README4
-rw-r--r--lang/nawk/files/README.pkgsrc10
-rw-r--r--lang/nawk/files/awk.h4
-rw-r--r--lang/nawk/files/awkgram.y8
-rw-r--r--lang/nawk/files/b.c64
-rw-r--r--lang/nawk/files/lex.c26
-rw-r--r--lang/nawk/files/lib.c28
-rw-r--r--lang/nawk/files/main.c65
-rw-r--r--lang/nawk/files/maketab.c6
-rw-r--r--lang/nawk/files/missing95.c14
-rw-r--r--lang/nawk/files/proctab.c202
-rw-r--r--lang/nawk/files/proto.h12
-rw-r--r--lang/nawk/files/run.c123
-rw-r--r--lang/nawk/files/tran.c24
-rw-r--r--lang/nawk/files/ytab.c4828
-rw-r--r--lang/nawk/files/ytab.h332
18 files changed, 2140 insertions, 3757 deletions
diff --git a/lang/nawk/Makefile b/lang/nawk/Makefile
index 7237410aaf2..dd19caa1532 100644
--- a/lang/nawk/Makefile
+++ b/lang/nawk/Makefile
@@ -1,13 +1,12 @@
-# $NetBSD: Makefile,v 1.39 2012/10/02 20:11:46 asau Exp $
+# $NetBSD: Makefile,v 1.40 2014/03/12 14:20:43 ryoon Exp $
-DISTNAME= nawk-20050424
-PKGREVISION= 3
+DISTNAME= nawk-20121220
CATEGORIES= lang
MASTER_SITES= # empty
DISTFILES= # empty
MAINTAINER= pkgsrc-users@NetBSD.org
-HOMEPAGE= http://cm.bell-labs.com/who/bwk/
+HOMEPAGE= http://www.cs.princeton.edu/~bwk/btl.mirror/
COMMENT= Brian Kernighan's pattern-directed scanning and processing language
PKG_INSTALLATION_TYPES= overwrite pkgviews
diff --git a/lang/nawk/files/FIXES b/lang/nawk/files/FIXES
index 5b3a66950a4..039f9cc0b2c 100644
--- a/lang/nawk/files/FIXES
+++ b/lang/nawk/files/FIXES
@@ -1,4 +1,4 @@
-$NetBSD: FIXES,v 1.1 2006/07/14 14:23:06 jlam Exp $
+$NetBSD: FIXES,v 1.2 2014/03/12 14:20:43 ryoon Exp $
/****************************************************************
Copyright (C) Lucent Technologies 1997
@@ -27,6 +27,144 @@ THIS SOFTWARE.
This file lists all bug fixes, changes, etc., made since the AWK book
was sent to the printers in August, 1987.
+Dec 20, 2012:
+ fiddled makefile to get correct yacc and bison flags. pick yacc
+ (linux) or bison (mac) as necessary.
+
+ added __attribute__((__noreturn__)) to a couple of lines in
+ proto.h, to silence someone's enthusiastic checker.
+
+ fixed obscure call by value bug in split(a[1],a) reported on
+ 9fans. the management of temporary values is just a mess; i
+ took a shortcut by making an extra string copy. thanks
+ to paul patience and arnold robbins for passing it on and for
+ proposed patches.
+
+ tiny fiddle in setfval to eliminate -0 results in T.expr, which
+ has irritated me for 20+ years.
+
+Aug 10, 2011:
+ another fix to avoid core dump with delete(ARGV); again, many thanks
+ to ruslan ermilov.
+
+Aug 7, 2011:
+ split(s, a, //) now behaves the same as split(s, a, "")
+
+Jun 12, 2011:
+ /pat/, \n /pat/ {...} is now legal, though bad style to use.
+
+ added checks to new -v code that permits -vnospace; thanks to
+ ruslan ermilov for spotting this and providing the patch.
+
+ removed fixed limit on number of open files; thanks to aleksey
+ cheusov and christos zoulos.
+
+ fixed day 1 bug that resurrected deleted elements of ARGV when
+ used as filenames (in lib.c).
+
+ minor type fiddles to make gcc -Wall -pedantic happier (but not
+ totally so); turned on -fno-strict-aliasing in makefile.
+
+May 6, 2011:
+ added #ifdef for isblank.
+ now allows -ffoo as well as -f foo arguments.
+ (thanks, ruslan)
+
+May 1, 2011:
+ after advice from todd miller, kevin lo, ruslan ermilov,
+ and arnold robbins, changed srand() to return the previous
+ seed (which is 1 on the first call of srand). the seed is
+ an Awkfloat internally though converted to unsigned int to
+ pass to the library srand(). thanks, everyone.
+
+ fixed a subtle (and i hope low-probability) overflow error
+ in fldbld, by adding space for one extra \0. thanks to
+ robert bassett for spotting this one and providing a fix.
+
+ removed the files related to compilation on windows. i no
+ longer have anything like a current windows environment, so
+ i can't test any of it.
+
+May 23, 2010:
+ fixed long-standing overflow bug in run.c; many thanks to
+ nelson beebe for spotting it and providing the fix.
+
+ fixed bug that didn't parse -vd=1 properly; thanks to santiago
+ vila for spotting it.
+
+Feb 8, 2010:
+ i give up. replaced isblank with isspace in b.c; there are
+ no consistent header files.
+
+Nov 26, 2009:
+ fixed a long-standing issue with when FS takes effect. a
+ change to FS is now noticed immediately for subsequent splits.
+
+ changed the name getline() to awkgetline() to avoid yet another
+ name conflict somewhere.
+
+Feb 11, 2009:
+ temporarily for now defined HAS_ISBLANK, since that seems to
+ be the best way through the thicket. isblank arrived in C99,
+ but seems to be arriving at different systems at different
+ times.
+
+Oct 8, 2008:
+ fixed typo in b.c that set tmpvec wrongly. no one had ever
+ run into the problem, apparently. thanks to alistair crooks.
+
+Oct 23, 2007:
+ minor fix in lib.c: increase inputFS to 100, change malloc
+ for fields to n+1.
+
+ fixed memory fault caused by out of order test in setsval.
+
+ thanks to david o'brien, freebsd, for both fixes.
+
+May 1, 2007:
+ fiddle in makefile to fix for BSD make; thanks to igor sobrado.
+
+Mar 31, 2007:
+ fixed some null pointer refs calling adjbuf.
+
+Feb 21, 2007:
+ fixed a bug in matching the null RE in sub and gsub. thanks to al aho
+ who actually did the fix (in b.c), and to wolfgang seeberg for finding
+ it and providing a very compact test case.
+
+ fixed quotation in b.c; thanks to Hal Pratt and the Princeton Dante
+ Project.
+
+ removed some no-effect asserts in run.c.
+
+ fiddled maketab.c to not complain about bison-generated values.
+
+ removed the obsolete -V argument; fixed --version to print the
+ version and exit.
+
+ fixed wording and an outright error in the usage message; thanks to igor
+ sobrado and jason mcintyre.
+
+ fixed a bug in -d that caused core dump if no program followed.
+
+Jan 1, 2007:
+ dropped mac.code from makefile; there are few non-MacOSX
+ mac's these days.
+
+Jan 17, 2006:
+ system() not flagged as unsafe in the unadvertised -safe option.
+ found it while enhancing tests before shipping the ;login: article.
+ practice what you preach.
+
+ removed the 9-years-obsolete -mr and -mf flags.
+
+ added -version and --version options.
+
+ core dump on linux with BEGIN {nextfile}, now fixed.
+
+ removed some #ifdef's in run.c and lex.c that appear to no
+ longer be necessary.
+
Apr 24, 2005:
modified lib.c so that values of $0 et al are preserved in the END
block, apparently as required by posix. thanks to havard eidnes
diff --git a/lang/nawk/files/README b/lang/nawk/files/README
index ba7ac2eae3d..93d00c3b1db 100644
--- a/lang/nawk/files/README
+++ b/lang/nawk/files/README
@@ -1,4 +1,4 @@
-$NetBSD: README,v 1.1 2006/07/14 14:23:06 jlam Exp $
+$NetBSD: README,v 1.2 2014/03/12 14:20:43 ryoon Exp $
/****************************************************************
Copyright (C) Lucent Technologies 1997
@@ -31,7 +31,7 @@ by Al Aho, Brian Kernighan, and Peter Weinberger
Changes, mostly bug fixes and occasional enhancements, are listed
in FIXES. If you distribute this code further, please please please
distribute FIXES with it. If you find errors, please report them
-to bwk@bell-labs.com. Thanks.
+to bwk@cs.princeton.edu. Thanks.
The program itself is created by
make
diff --git a/lang/nawk/files/README.pkgsrc b/lang/nawk/files/README.pkgsrc
index 88bad6df02d..5fedd3da6e2 100644
--- a/lang/nawk/files/README.pkgsrc
+++ b/lang/nawk/files/README.pkgsrc
@@ -1,4 +1,4 @@
-$NetBSD: README.pkgsrc,v 1.2 2009/10/29 20:21:53 tnn Exp $
+$NetBSD: README.pkgsrc,v 1.3 2014/03/12 14:20:43 ryoon Exp $
The following changes were made to the standard distribution:
@@ -15,12 +15,4 @@ The following changes were made to the standard distribution:
* The *.bat files were removed. These files are only used on
MS Windows.
- * The makefile.win file was removed. This file is only used on
- MS Windows.
-
- * The mac.code files was removed. This file is only used on
- Mac OS with MPW.
-
* A "NetBSD" CVS Id tag was added to each file.
-
- * getline was renamed to get_line to avoid conflict with getline(3)
diff --git a/lang/nawk/files/awk.h b/lang/nawk/files/awk.h
index a15f74623bf..459729a63c2 100644
--- a/lang/nawk/files/awk.h
+++ b/lang/nawk/files/awk.h
@@ -1,4 +1,4 @@
-/* $NetBSD: awk.h,v 1.2 2008/08/26 14:46:21 joerg Exp $ */
+/* $NetBSD: awk.h,v 1.3 2014/03/12 14:20:43 ryoon Exp $ */
/****************************************************************
Copyright (C) Lucent Technologies 1997
@@ -32,7 +32,7 @@ typedef double Awkfloat;
typedef unsigned char uschar;
-#define xfree(a) { if ((a) != NULL) { free((char *) a); a = NULL; } }
+#define xfree(a) { if ((a) != NULL) { free((void *) (a)); (a) = NULL; } }
#define NN(p) ((p) ? (p) : "(null)") /* guaranteed non-null for dprintf
*/
diff --git a/lang/nawk/files/awkgram.y b/lang/nawk/files/awkgram.y
index 9b4e4db7645..74a40c75a44 100644
--- a/lang/nawk/files/awkgram.y
+++ b/lang/nawk/files/awkgram.y
@@ -1,4 +1,4 @@
-/* $NetBSD: awkgram.y,v 1.1 2006/07/14 14:23:06 jlam Exp $ */
+/* $NetBSD: awkgram.y,v 1.2 2014/03/12 14:20:43 ryoon Exp $ */
/****************************************************************
Copyright (C) Lucent Technologies 1997
@@ -52,7 +52,7 @@ Node *arglist = 0; /* list of args for current function */
%token <i> NL ',' '{' '(' '|' ';' '/' ')' '}' '[' ']'
%token <i> ARRAY
%token <i> MATCH NOTMATCH MATCHOP
-%token <i> FINAL DOT ALL CCL NCCL CHAR OR STAR QUEST PLUS
+%token <i> FINAL DOT ALL CCL NCCL CHAR OR STAR QUEST PLUS EMPTYRE
%token <i> AND BOR APPEND EQ GE GT LE LT NE IN
%token <i> ARG BLTIN BREAK CLOSE CONTINUE DELETE DO EXIT FOR FUNC
%token <i> SUB GSUB IF INDEX LSUBSTR MATCHFCN NEXT NEXTFILE
@@ -176,8 +176,8 @@ pa_pat:
pa_stat:
pa_pat { $$ = stat2(PASTAT, $1, stat2(PRINT, rectonode(), NIL)); }
| pa_pat lbrace stmtlist '}' { $$ = stat2(PASTAT, $1, $3); }
- | pa_pat ',' pa_pat { $$ = pa2stat($1, $3, stat2(PRINT, rectonode(), NIL)); }
- | pa_pat ',' pa_pat lbrace stmtlist '}' { $$ = pa2stat($1, $3, $5); }
+ | pa_pat ',' opt_nl pa_pat { $$ = pa2stat($1, $4, stat2(PRINT, rectonode(), NIL)); }
+ | pa_pat ',' opt_nl pa_pat lbrace stmtlist '}' { $$ = pa2stat($1, $4, $6); }
| lbrace stmtlist '}' { $$ = stat2(PASTAT, NIL, $2); }
| XBEGIN lbrace stmtlist '}'
{ beginloc = linkum(beginloc, $3); $$ = 0; }
diff --git a/lang/nawk/files/b.c b/lang/nawk/files/b.c
index 1c65b16a497..d4a149a8787 100644
--- a/lang/nawk/files/b.c
+++ b/lang/nawk/files/b.c
@@ -1,4 +1,4 @@
-/* $NetBSD: b.c,v 1.2 2013/06/14 14:46:37 tron Exp $ */
+/* $NetBSD: b.c,v 1.3 2014/03/12 14:20:43 ryoon Exp $ */
/****************************************************************
Copyright (C) Lucent Technologies 1997
@@ -24,7 +24,7 @@ ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF
THIS SOFTWARE.
****************************************************************/
-/* lasciate ogne speranza, voi ch'entrate. */
+/* lasciate ogne speranza, voi ch'intrate. */
#define DEBUG
@@ -46,10 +46,11 @@ THIS SOFTWARE.
#define parent(v) (v)->nnext
#define LEAF case CCL: case NCCL: case CHAR: case DOT: case FINAL: case ALL:
+#define ELEAF case EMPTYRE: /* empty string in regexp */
#define UNARY case STAR: case PLUS: case QUEST:
/* encoding in tree Nodes:
- leaf (CCL, NCCL, CHAR, DOT, FINAL, ALL):
+ leaf (CCL, NCCL, CHAR, DOT, FINAL, ALL, EMPTYRE):
left is index, right contains value or pointer to value
unary (STAR, PLUS, QUEST): left is child, right is null
binary (CAT, OR): left and right are children
@@ -184,6 +185,7 @@ int makeinit(fa *f, int anchor)
void penter(Node *p) /* set up parent pointers and leaf indices */
{
switch (type(p)) {
+ ELEAF
LEAF
info(p) = poscnt;
poscnt++;
@@ -208,6 +210,7 @@ void penter(Node *p) /* set up parent pointers and leaf indices */
void freetr(Node *p) /* free parse tree */
{
switch (type(p)) {
+ ELEAF
LEAF
xfree(p);
break;
@@ -230,7 +233,7 @@ void freetr(Node *p) /* free parse tree */
/* in the parsing of regular expressions, metacharacters like . have */
/* to be seen literally; \056 is not a metacharacter. */
-int hexstr(char **pp) /* find and eval hex string at pp, return new p */
+int hexstr(uschar **pp) /* find and eval hex string at pp, return new p */
{ /* only pick up one 8-bit byte (2 chars) */
uschar *p;
int n = 0;
@@ -244,16 +247,16 @@ int hexstr(char **pp) /* find and eval hex string at pp, return new p */
else if (*p >= 'A' && *p <= 'F')
n = 16 * n + *p - 'A' + 10;
}
- *pp = (char *) p;
+ *pp = (uschar *) p;
return n;
}
#define isoctdigit(c) ((c) >= '0' && (c) <= '7') /* multiple use of arg */
-int quoted(char **pp) /* pick up next thing after a \\ */
+int quoted(uschar **pp) /* pick up next thing after a \\ */
/* and increment *pp */
{
- char *p = *pp;
+ uschar *p = *pp;
int c;
if ((c = *p++) == 't')
@@ -298,20 +301,20 @@ char *cclenter(const char *argp) /* add a character class */
bp = buf;
for (i = 0; (c = *p++) != 0; ) {
if (c == '\\') {
- c = quoted((char **) &p);
+ c = quoted(&p);
} else if (c == '-' && i > 0 && bp[-1] != 0) {
if (*p != 0) {
c = bp[-1];
c2 = *p++;
if (c2 == '\\')
- c2 = quoted((char **) &p);
+ c2 = quoted(&p);
if (c > c2) { /* empty; ignore */
bp--;
i--;
continue;
}
while (c < c2) {
- if (!adjbuf((char **) &buf, &bufsz, bp-buf+2, 100, (char **) &bp, 0))
+ if (!adjbuf((char **) &buf, &bufsz, bp-buf+2, 100, (char **) &bp, "cclenter1"))
FATAL("out of space for character class [%.10s...] 2", p);
*bp++ = ++c;
i++;
@@ -319,7 +322,7 @@ char *cclenter(const char *argp) /* add a character class */
continue;
}
}
- if (!adjbuf((char **) &buf, &bufsz, bp-buf+2, 100, (char **) &bp, 0))
+ if (!adjbuf((char **) &buf, &bufsz, bp-buf+2, 100, (char **) &bp, "cclenter2"))
FATAL("out of space for character class [%.10s...] 3", p);
*bp++ = c;
i++;
@@ -341,6 +344,7 @@ void cfoll(fa *f, Node *v) /* enter follow set of each leaf of vertex v into lfo
int *p;
switch (type(v)) {
+ ELEAF
LEAF
f->re[info(v)].ltype = type(v);
f->re[info(v)].lval.np = right(v);
@@ -377,11 +381,12 @@ void cfoll(fa *f, Node *v) /* enter follow set of each leaf of vertex v into lfo
}
int first(Node *p) /* collects initially active leaves of p into setvec */
- /* returns 1 if p matches empty string */
+ /* returns 0 if p matches empty string */
{
int b, lp;
switch (type(p)) {
+ ELEAF
LEAF
lp = info(p); /* look for high-water mark of subscripts */
while (setcnt >= maxsetvec || lp >= maxsetvec) { /* guessing here! */
@@ -391,6 +396,10 @@ int first(Node *p) /* collects initially active leaves of p into setvec */
if (setvec == 0 || tmpset == 0)
overflo("out of space in first()");
}
+ if (type(p) == EMPTYRE) {
+ setvec[lp] = 0;
+ return(0);
+ }
if (setvec[lp] != 1) {
setvec[lp] = 1;
setcnt++;
@@ -467,7 +476,7 @@ int match(fa *f, const char *p0) /* shortest match ? */
if (f->out[s])
return(1);
do {
- assert(*p < NCHARS);
+ /* assert(*p < NCHARS); */
if ((ns = f->gototab[s][*p]) != 0)
s = ns;
else
@@ -498,7 +507,7 @@ int pmatch(fa *f, const char *p0) /* longest match, for sub */
do {
if (f->out[s]) /* final state */
patlen = q-p;
- assert(*q < NCHARS);
+ /* assert(*q < NCHARS); */
if ((ns = f->gototab[s][*q]) != 0)
s = ns;
else
@@ -556,7 +565,7 @@ int nematch(fa *f, const char *p0) /* non-empty match, for sub */
do {
if (f->out[s]) /* final state */
patlen = q-p;
- assert(*q < NCHARS);
+ /* assert(*q < NCHARS); */
if ((ns = f->gototab[s][*q]) != 0)
s = ns;
else
@@ -603,9 +612,10 @@ Node *reparse(const char *p) /* parses regular expression pointed to by p */
lastre = prestr = (uschar *) p; /* prestr points to string to be parsed */
rtok = relex();
/* GNU compatibility: an empty regexp matches anything */
- if (rtok == '\0')
+ if (rtok == '\0') {
/* FATAL("empty regular expression"); previous */
- return(op2(ALL, NIL, NIL));
+ return(op2(EMPTYRE, NIL, NIL));
+ }
np = regexp();
if (rtok != '\0')
FATAL("syntax error in regular expression %s at %s", lastre, prestr);
@@ -629,6 +639,9 @@ Node *primary(void)
case ALL:
rtok = relex();
return (unary(op2(ALL, NIL, NIL)));
+ case EMPTYRE:
+ rtok = relex();
+ return (unary(op2(ALL, NIL, NIL)));
case DOT:
rtok = relex();
return (unary(op2(DOT, NIL, NIL)));
@@ -668,7 +681,7 @@ Node *primary(void)
Node *concat(Node *np)
{
switch (rtok) {
- case CHAR: case DOT: case ALL: case CCL: case NCCL: case '$': case '(':
+ case CHAR: case DOT: case ALL: case EMPTYRE: case CCL: case NCCL: case '$': case '(':
return (concat(op2(CAT, np, primary())));
}
return (np);
@@ -722,7 +735,7 @@ Node *unary(Node *np)
#if !defined(HAS_ISBLANK) && !defined(__APPLE__)
-int (isblank)(int c)
+int (xisblank)(int c)
{
return c==' ' || c=='\t';
}
@@ -736,7 +749,11 @@ struct charclass {
} charclasses[] = {
{ "alnum", 5, isalnum },
{ "alpha", 5, isalpha },
+#ifndef HAS_ISBLANK
+ { "blank", 5, isspace }, /* was isblank */
+#else
{ "blank", 5, isblank },
+#endif
{ "cntrl", 5, iscntrl },
{ "digit", 5, isdigit },
{ "graph", 5, isgraph },
@@ -773,7 +790,7 @@ int relex(void) /* lexical analyzer for reparse */
case ')':
return c;
case '\\':
- rlxval = quoted((char **) &prestr);
+ rlxval = quoted(&prestr);
return CHAR;
default:
rlxval = c;
@@ -789,7 +806,7 @@ int relex(void) /* lexical analyzer for reparse */
else
cflag = 0;
n = 2 * strlen((const char *) prestr)+1;
- if (!adjbuf((char **) &buf, &bufsz, n, n, (char **) &bp, 0))
+ if (!adjbuf((char **) &buf, &bufsz, n, n, (char **) &bp, "relex1"))
FATAL("out of space for reg expr %.10s...", lastre);
for (; ; ) {
if ((c = *prestr++) == '\\') {
@@ -808,7 +825,7 @@ int relex(void) /* lexical analyzer for reparse */
prestr[2 + cc->cc_namelen] == ']') {
prestr += cc->cc_namelen + 3;
for (i = 0; i < NCHARS; i++) {
- if (!adjbuf((char **) &buf, &bufsz, bp-buf+1, 100, (char **) &bp, 0))
+ if (!adjbuf((char **) &buf, &bufsz, bp-buf+1, 100, (char **) &bp, "relex2"))
FATAL("out of space for reg expr %.10s...", lastre);
if (cc->cc_func(i)) {
*bp++ = i;
@@ -857,6 +874,7 @@ int cgoto(fa *f, int s, int c)
if ((k == CHAR && c == ptoi(f->re[p[i]].lval.np))
|| (k == DOT && c != 0 && c != HAT)
|| (k == ALL && c != 0)
+ || (k == EMPTYRE && c != 0)
|| (k == CCL && member(c, (char *) f->re[p[i]].lval.up))
|| (k == NCCL && !member(c, (char *) f->re[p[i]].lval.up) && c != 0 && c != HAT)) {
q = f->re[p[i]].lfollow;
@@ -864,7 +882,7 @@ int cgoto(fa *f, int s, int c)
if (q[j] >= maxsetvec) {
maxsetvec *= 4;
setvec = (int *) realloc(setvec, maxsetvec * sizeof(int));
- tmpset = (int *) realloc(setvec, maxsetvec * sizeof(int));
+ tmpset = (int *) realloc(tmpset, maxsetvec * sizeof(int));
if (setvec == 0 || tmpset == 0)
overflo("cgoto overflow");
}
diff --git a/lang/nawk/files/lex.c b/lang/nawk/files/lex.c
index f94bfec4530..94b197ae9ce 100644
--- a/lang/nawk/files/lex.c
+++ b/lang/nawk/files/lex.c
@@ -1,4 +1,4 @@
-/* $NetBSD: lex.c,v 1.1 2006/07/14 14:23:06 jlam Exp $ */
+/* $NetBSD: lex.c,v 1.2 2014/03/12 14:20:43 ryoon Exp $ */
/****************************************************************
Copyright (C) Lucent Technologies 1997
@@ -91,12 +91,7 @@ Keyword keywords[] ={ /* keep sorted: binary searched */
{ "while", WHILE, WHILE },
};
-#define DEBUG
-#ifdef DEBUG
#define RET(x) { if(dbg)printf("lex %s\n", tokname(x)); return(x); }
-#else
-#define RET(x) return(x)
-#endif
int peek(void)
{
@@ -124,7 +119,7 @@ int gettok(char **pbuf, int *psz) /* get next input token */
if (isalpha(c) || c == '_') { /* it's a varname */
for ( ; (c = input()) != 0; ) {
if (bp-buf >= sz)
- if (!adjbuf(&buf, &sz, bp-buf+2, 100, &bp, 0))
+ if (!adjbuf(&buf, &sz, bp-buf+2, 100, &bp, "gettok"))
FATAL( "out of space for name %.10s...", buf );
if (isalnum(c) || c == '_')
*bp++ = c;
@@ -141,7 +136,7 @@ int gettok(char **pbuf, int *psz) /* get next input token */
/* read input until can't be a number */
for ( ; (c = input()) != 0; ) {
if (bp-buf >= sz)
- if (!adjbuf(&buf, &sz, bp-buf+2, 100, &bp, 0))
+ if (!adjbuf(&buf, &sz, bp-buf+2, 100, &bp, "gettok"))
FATAL( "out of space for number %.10s...", buf );
if (isdigit(c) || c == 'e' || c == 'E'
|| c == '.' || c == '+' || c == '-')
@@ -178,7 +173,7 @@ int yylex(void)
{
int c;
static char *buf = 0;
- static int bufsize = 500;
+ static int bufsize = 5; /* BUG: setting this small causes core dump! */
if (buf == 0 && (buf = (char *) malloc(bufsize)) == NULL)
FATAL( "out of space in yylex" );
@@ -190,10 +185,8 @@ int yylex(void)
reg = 0;
return regexpr();
}
-/* printf("top\n"); */
for (;;) {
c = gettok(&buf, &bufsize);
-/* printf("gettok [%s]\n", buf); */
if (c == 0)
return 0;
if (isalpha(c) || c == '_')
@@ -373,7 +366,7 @@ int string(void)
if (buf == 0 && (buf = (char *) malloc(bufsz)) == NULL)
FATAL("out of space for strings");
for (bp = buf; (c = input()) != '"'; ) {
- if (!adjbuf(&buf, &bufsz, bp-buf+2, 500, &bp, 0))
+ if (!adjbuf(&buf, &bufsz, bp-buf+2, 500, &bp, "string"))
FATAL("out of space for string %.10s...", buf);
switch (c) {
case '\n':
@@ -420,7 +413,7 @@ int string(void)
}
*px = 0;
unput(c);
- sscanf(xbuf, "%x", &n);
+ sscanf(xbuf, "%x", (unsigned int *) &n);
*bp++ = n;
break;
}
@@ -467,12 +460,13 @@ int word(char *w)
int c, n;
n = binsearch(w, keywords, sizeof(keywords)/sizeof(keywords[0]));
+/* BUG: this ought to be inside the if; in theory could fault (daniel barrett) */
kp = keywords + n;
if (n != -1) { /* found in table */
yylval.i = kp->sub;
switch (kp->type) { /* special handling */
- case FSYSTEM:
- if (safe)
+ case BLTIN:
+ if (kp->sub == FSYSTEM && safe)
SYNTAX( "system is unsafe" );
RET(kp->type);
case FUNC:
@@ -520,7 +514,7 @@ int regexpr(void)
FATAL("out of space for rex expr");
bp = buf;
for ( ; (c = input()) != '/' && c != 0; ) {
- if (!adjbuf(&buf, &bufsz, bp-buf+3, 500, &bp, 0))
+ if (!adjbuf(&buf, &bufsz, bp-buf+3, 500, &bp, "regexpr"))
FATAL("out of space for reg expr %.10s...", buf);
if (c == '\n') {
SYNTAX( "newline in regular expression %.10s...", buf );
diff --git a/lang/nawk/files/lib.c b/lang/nawk/files/lib.c
index ece88c1ac02..4ca60e0ea5b 100644
--- a/lang/nawk/files/lib.c
+++ b/lang/nawk/files/lib.c
@@ -1,4 +1,4 @@
-/* $NetBSD: lib.c,v 1.3 2008/08/26 20:26:25 joerg Exp $ */
+/* $NetBSD: lib.c,v 1.4 2014/03/12 14:20:43 ryoon Exp $ */
/****************************************************************
Copyright (C) Lucent Technologies 1997
@@ -46,7 +46,7 @@ char static_inputFS[16] = " ";
size_t len_inputFS = sizeof(static_inputFS) - 1;
char *inputFS = static_inputFS;
-#define MAXFLD 200
+#define MAXFLD 2
int nfields = MAXFLD; /* last allocated slot for $i */
int donefld; /* 1 = implies rec broken into fields */
@@ -62,7 +62,7 @@ static Cell dollar1 = { OCELL, CFLD, NULL, "", 0.0, FLD|STR|DONTFREE };
void recinit(unsigned int n)
{
if ( (record = (char *) malloc(n)) == NULL
- || (fields = (char *) malloc(n)) == NULL
+ || (fields = (char *) malloc(n+1)) == NULL
|| (fldtab = (Cell **) malloc((nfields+1) * sizeof(Cell *))) == NULL
|| (fldtab[0] = (Cell *) malloc(sizeof(Cell))) == NULL )
FATAL("out of space for $0 and fields");
@@ -93,8 +93,13 @@ void initgetrec(void)
char *p;
for (i = 1; i < *ARGC; i++) {
- if (!isclvar(p = getargv(i))) { /* find 1st real filename */
- setsval(lookup("FILENAME", symtab), getargv(i));
+ p = getargv(i); /* find 1st real filename */
+ if (p == NULL || *p == '\0') { /* deleted or zapped */
+ argno++;
+ continue;
+ }
+ if (!isclvar(p)) {
+ setsval(lookup("FILENAME", symtab), p);
return;
}
setclvar(p); /* a commandline assignment before filename */
@@ -128,7 +133,7 @@ int getrec(char **pbuf, int *pbufsize, int isrecord) /* get next input record */
dprintf( ("argno=%d, file=|%s|\n", argno, file) );
if (infile == NULL) { /* have to open a new file */
file = getargv(argno);
- if (*file == '\0') { /* it's been zapped */
+ if (file == NULL || *file == '\0') { /* deleted or zapped */
argno++;
continue;
}
@@ -177,7 +182,7 @@ int getrec(char **pbuf, int *pbufsize, int isrecord) /* get next input record */
void nextfile(void)
{
- if (infile != stdin)
+ if (infile != NULL && infile != stdin)
fclose(infile);
infile = NULL;
argno++;
@@ -240,6 +245,8 @@ char *getargv(int n) /* get ARGV[n] */
extern Array *ARGVtab;
sprintf(temp, "%d", n);
+ if (lookup(temp, ARGVtab) == NULL)
+ return NULL;
x = setsymtab(temp, "", 0.0, STR, ARGVtab);
s = getsval(x);
dprintf( ("getargv(%d) returns |%s|\n", n, s) );
@@ -269,6 +276,7 @@ void fldbld(void) /* create fields from current record */
{
/* this relies on having fields[] the same length as $0 */
/* the fields are all stored in this one array with \0's */
+ /* possibly with a final trailing \0 not associated with any field */
char *r, *fr, sep;
Cell *p;
int i, j, n;
@@ -281,7 +289,7 @@ void fldbld(void) /* create fields from current record */
n = strlen(r);
if (n > fieldssize) {
xfree(fields);
- if ((fields = (char *) malloc(n+1)) == NULL)
+ if ((fields = (char *) malloc(n+2)) == NULL) /* possibly 2 final \0s */
FATAL("out of space for fields in fldbld %d", n);
fieldssize = n;
}
@@ -488,14 +496,14 @@ void recbld(void) /* create $0 from $1..$NF if necessary */
if (!adjbuf(&record, &recsize, 2+r-record, recsize, &r, "recbld 3"))
FATAL("built giant record `%.30s...'", record);
*r = '\0';
- dprintf( ("in recbld inputFS=%s, fldtab[0]=%p\n", inputFS, fldtab[0]) );
+ dprintf( ("in recbld inputFS=%s, fldtab[0]=%p\n", inputFS, (void*)fldtab[0]) );
if (freeable(fldtab[0]))
xfree(fldtab[0]->sval);
fldtab[0]->tval = REC | STR | DONTFREE;
fldtab[0]->sval = record;
- dprintf( ("in recbld inputFS=%s, fldtab[0]=%p\n", inputFS, fldtab[0]) );
+ dprintf( ("in recbld inputFS=%s, fldtab[0]=%p\n", inputFS, (void*)fldtab[0]) );
dprintf( ("recbld = |%s|\n", record) );
donerec = 1;
}
diff --git a/lang/nawk/files/main.c b/lang/nawk/files/main.c
index 4ce783f6a47..67b7ffecd71 100644
--- a/lang/nawk/files/main.c
+++ b/lang/nawk/files/main.c
@@ -1,4 +1,4 @@
-/* $NetBSD: main.c,v 1.1 2006/07/14 14:23:06 jlam Exp $ */
+/* $NetBSD: main.c,v 1.2 2014/03/12 14:20:43 ryoon Exp $ */
/****************************************************************
Copyright (C) Lucent Technologies 1997
@@ -24,7 +24,7 @@ ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF
THIS SOFTWARE.
****************************************************************/
-const char *version = "version 20050424";
+const char *version = "version 20121220";
#define DEBUG
#include <stdio.h>
@@ -40,6 +40,7 @@ extern char **environ;
extern int nfields;
int dbg = 0;
+Awkfloat srand_seed = 1;
char *cmdname; /* gets argv[0] for error messages */
extern FILE *yyin; /* lex input file */
char *lexprog; /* points to program argument if it exists */
@@ -63,14 +64,25 @@ int main(int argc, char *argv[])
setlocale(LC_NUMERIC, "C"); /* for parsing cmdline & prog */
cmdname = argv[0];
if (argc == 1) {
- fprintf(stderr, "Usage: %s [-f programfile | 'program'] [-Ffieldsep] [-v var=value] [files]\n", cmdname);
+ fprintf(stderr,
+ "usage: %s [-F fs] [-v var=value] [-f progfile | 'prog'] [file ...]\n",
+ cmdname);
exit(1);
}
signal(SIGFPE, fpecatch);
+
+ srand_seed = 1;
+ srand(srand_seed);
+
yyin = NULL;
- symtab = makesymtab(NSYMTAB);
+ symtab = makesymtab(NSYMTAB/NSYMTAB);
while (argc > 1 && argv[1][0] == '-' && argv[1][1] != '\0') {
- if (strcmp(argv[1], "--") == 0) { /* explicit end of args */
+ if (strcmp(argv[1],"-version") == 0 || strcmp(argv[1],"--version") == 0) {
+ printf("awk %s\n", version);
+ exit(0);
+ break;
+ }
+ if (strncmp(argv[1], "--", 2) == 0) { /* explicit end of args */
argc--;
argv++;
break;
@@ -81,13 +93,18 @@ int main(int argc, char *argv[])
safe = 1;
break;
case 'f': /* next argument is program filename */
- argc--;
- argv++;
- if (argc <= 1)
- FATAL("no program filename");
- if (npfile >= MAX_PFILE - 1)
- FATAL("too many -f options");
- pfile[npfile++] = argv[1];
+ if (argv[1][2] != 0) { /* arg is -fsomething */
+ if (npfile >= MAX_PFILE - 1)
+ FATAL("too many -f options");
+ pfile[npfile++] = &argv[1][2];
+ } else { /* arg is -f something */
+ argc--; argv++;
+ if (argc <= 1)
+ FATAL("no program filename");
+ if (npfile >= MAX_PFILE - 1)
+ FATAL("too many -f options");
+ pfile[npfile++] = argv[1];
+ }
break;
case 'F': /* set field separator */
if (argv[1][2] != 0) { /* arg is -Fsomething */
@@ -106,12 +123,20 @@ int main(int argc, char *argv[])
WARNING("field separator FS is empty");
break;
case 'v': /* -v a=1 to be done NOW. one -v for each */
- if (argv[1][2] == '\0' && --argc > 1 && isclvar((++argv)[1]))
- setclvar(argv[1]);
- break;
- case 'm': /* more memory: -mr=record, -mf=fields */
- /* no longer supported */
- WARNING("obsolete option %s ignored", argv[1]);
+ if (argv[1][2] != 0) { /* arg is -vsomething */
+ if (isclvar(&argv[1][2]))
+ setclvar(&argv[1][2]);
+ else
+ FATAL("invalid -v option argument: %s", &argv[1][2]);
+ } else { /* arg is -v something */
+ argc--; argv++;
+ if (argc <= 1)
+ FATAL("no variable name");
+ if (isclvar(argv[1]))
+ setclvar(argv[1]);
+ else
+ FATAL("invalid -v option argument: %s", argv[1]);
+ }
break;
case 'd':
dbg = atoi(&argv[1][2]);
@@ -119,10 +144,6 @@ int main(int argc, char *argv[])
dbg = 1;
printf("awk %s\n", version);
break;
- case 'V': /* added for exptools "standard" */
- printf("awk %s\n", version);
- exit(0);
- break;
default:
WARNING("unknown option %s ignored", argv[1]);
break;
diff --git a/lang/nawk/files/maketab.c b/lang/nawk/files/maketab.c
index 7fce34fd85e..f70329e4776 100644
--- a/lang/nawk/files/maketab.c
+++ b/lang/nawk/files/maketab.c
@@ -1,4 +1,4 @@
-/* $NetBSD: maketab.c,v 1.1 2006/07/14 14:23:06 jlam Exp $ */
+/* $NetBSD: maketab.c,v 1.2 2014/03/12 14:20:43 ryoon Exp $ */
/****************************************************************
Copyright (C) Lucent Technologies 1997
@@ -104,7 +104,7 @@ struct xx
{ CALL, "call", "call" },
{ ARG, "arg", "arg" },
{ VARNF, "getnf", "NF" },
- { GETLINE, "getline", "getline" },
+ { GETLINE, "awkgetline", "getline" },
{ 0, "", "" },
};
@@ -137,7 +137,7 @@ int main(int argc, char *argv[])
if (c != '#' || (n != 4 && strcmp(def,"define") != 0)) /* not a valid #define */
continue;
if (tok < FIRSTTOKEN || tok > LASTTOKEN) {
- fprintf(stderr, "maketab funny token %d %s ignored\n", tok, buf);
+ /* fprintf(stderr, "maketab funny token %d %s ignored\n", tok, buf); */
continue;
}
names[tok-FIRSTTOKEN] = (char *) malloc(strlen(name)+1);
diff --git a/lang/nawk/files/missing95.c b/lang/nawk/files/missing95.c
deleted file mode 100644
index 93fe85c5e1e..00000000000
--- a/lang/nawk/files/missing95.c
+++ /dev/null
@@ -1,14 +0,0 @@
-/* $NetBSD: missing95.c,v 1.1 2006/07/14 14:23:06 jlam Exp $ */
-
-/* popen and pclose are not part of win 95 and nt,
- but it appears that _popen and _pclose "work".
- if this won't load, use the return NULL statements. */
-
-#include <stdio.h>
-FILE *popen(char *s, char *m) {
- return _popen(s, m); /* return NULL; */
-}
-
-int pclose(FILE *f) {
- return _pclose(f); /* return NULL; */
-}
diff --git a/lang/nawk/files/proctab.c b/lang/nawk/files/proctab.c
index 664f3a4c117..88a8bb5f989 100644
--- a/lang/nawk/files/proctab.c
+++ b/lang/nawk/files/proctab.c
@@ -1,106 +1,107 @@
-/* $NetBSD: proctab.c,v 1.2 2009/10/29 20:21:53 tnn Exp $ */
+/* $NetBSD: proctab.c,v 1.3 2014/03/12 14:20:43 ryoon Exp $ */
#include <stdio.h>
#include "awk.h"
#include "ytab.h"
-static char *printname[92] = {
- (char *) "FIRSTTOKEN", /* 258 */
- (char *) "PROGRAM", /* 259 */
- (char *) "PASTAT", /* 260 */
- (char *) "PASTAT2", /* 261 */
- (char *) "XBEGIN", /* 262 */
- (char *) "XEND", /* 263 */
- (char *) "NL", /* 264 */
- (char *) "ARRAY", /* 265 */
- (char *) "MATCH", /* 266 */
- (char *) "NOTMATCH", /* 267 */
- (char *) "MATCHOP", /* 268 */
- (char *) "FINAL", /* 269 */
- (char *) "DOT", /* 270 */
- (char *) "ALL", /* 271 */
- (char *) "CCL", /* 272 */
- (char *) "NCCL", /* 273 */
- (char *) "CHAR", /* 274 */
- (char *) "OR", /* 275 */
- (char *) "STAR", /* 276 */
- (char *) "QUEST", /* 277 */
- (char *) "PLUS", /* 278 */
- (char *) "AND", /* 279 */
- (char *) "BOR", /* 280 */
- (char *) "APPEND", /* 281 */
- (char *) "EQ", /* 282 */
- (char *) "GE", /* 283 */
- (char *) "GT", /* 284 */
- (char *) "LE", /* 285 */
- (char *) "LT", /* 286 */
- (char *) "NE", /* 287 */
- (char *) "IN", /* 288 */
- (char *) "ARG", /* 289 */
- (char *) "BLTIN", /* 290 */
- (char *) "BREAK", /* 291 */
- (char *) "CLOSE", /* 292 */
- (char *) "CONTINUE", /* 293 */
- (char *) "DELETE", /* 294 */
- (char *) "DO", /* 295 */
- (char *) "EXIT", /* 296 */
- (char *) "FOR", /* 297 */
- (char *) "FUNC", /* 298 */
- (char *) "SUB", /* 299 */
- (char *) "GSUB", /* 300 */
- (char *) "IF", /* 301 */
- (char *) "INDEX", /* 302 */
- (char *) "LSUBSTR", /* 303 */
- (char *) "MATCHFCN", /* 304 */
- (char *) "NEXT", /* 305 */
- (char *) "NEXTFILE", /* 306 */
- (char *) "ADD", /* 307 */
- (char *) "MINUS", /* 308 */
- (char *) "MULT", /* 309 */
- (char *) "DIVIDE", /* 310 */
- (char *) "MOD", /* 311 */
- (char *) "ASSIGN", /* 312 */
- (char *) "ASGNOP", /* 313 */
- (char *) "ADDEQ", /* 314 */
- (char *) "SUBEQ", /* 315 */
- (char *) "MULTEQ", /* 316 */
- (char *) "DIVEQ", /* 317 */
- (char *) "MODEQ", /* 318 */
- (char *) "POWEQ", /* 319 */
- (char *) "PRINT", /* 320 */
- (char *) "PRINTF", /* 321 */
- (char *) "SPRINTF", /* 322 */
- (char *) "ELSE", /* 323 */
- (char *) "INTEST", /* 324 */
- (char *) "CONDEXPR", /* 325 */
- (char *) "POSTINCR", /* 326 */
- (char *) "PREINCR", /* 327 */
- (char *) "POSTDECR", /* 328 */
- (char *) "PREDECR", /* 329 */
- (char *) "VAR", /* 330 */
- (char *) "IVAR", /* 331 */
- (char *) "VARNF", /* 332 */
- (char *) "CALL", /* 333 */
- (char *) "NUMBER", /* 334 */
- (char *) "STRING", /* 335 */
- (char *) "REGEXPR", /* 336 */
- (char *) "GETLINE", /* 337 */
- (char *) "SUBSTR", /* 338 */
- (char *) "SPLIT", /* 339 */
- (char *) "RETURN", /* 340 */
- (char *) "WHILE", /* 341 */
- (char *) "CAT", /* 342 */
- (char *) "UMINUS", /* 343 */
- (char *) "NOT", /* 344 */
- (char *) "POWER", /* 345 */
- (char *) "INCR", /* 346 */
- (char *) "DECR", /* 347 */
- (char *) "INDIRECT", /* 348 */
- (char *) "LASTTOKEN", /* 349 */
+static char *printname[93] = {
+ (char *) "FIRSTTOKEN", /* 57346 */
+ (char *) "PROGRAM", /* 57347 */
+ (char *) "PASTAT", /* 57348 */
+ (char *) "PASTAT2", /* 57349 */
+ (char *) "XBEGIN", /* 57350 */
+ (char *) "XEND", /* 57351 */
+ (char *) "NL", /* 57352 */
+ (char *) "ARRAY", /* 57353 */
+ (char *) "MATCH", /* 57354 */
+ (char *) "NOTMATCH", /* 57355 */
+ (char *) "MATCHOP", /* 57356 */
+ (char *) "FINAL", /* 57357 */
+ (char *) "DOT", /* 57358 */
+ (char *) "ALL", /* 57359 */
+ (char *) "CCL", /* 57360 */
+ (char *) "NCCL", /* 57361 */
+ (char *) "CHAR", /* 57362 */
+ (char *) "OR", /* 57363 */
+ (char *) "STAR", /* 57364 */
+ (char *) "QUEST", /* 57365 */
+ (char *) "PLUS", /* 57366 */
+ (char *) "EMPTYRE", /* 57367 */
+ (char *) "AND", /* 57368 */
+ (char *) "BOR", /* 57369 */
+ (char *) "APPEND", /* 57370 */
+ (char *) "EQ", /* 57371 */
+ (char *) "GE", /* 57372 */
+ (char *) "GT", /* 57373 */
+ (char *) "LE", /* 57374 */
+ (char *) "LT", /* 57375 */
+ (char *) "NE", /* 57376 */
+ (char *) "IN", /* 57377 */
+ (char *) "ARG", /* 57378 */
+ (char *) "BLTIN", /* 57379 */
+ (char *) "BREAK", /* 57380 */
+ (char *) "CLOSE", /* 57381 */
+ (char *) "CONTINUE", /* 57382 */
+ (char *) "DELETE", /* 57383 */
+ (char *) "DO", /* 57384 */
+ (char *) "EXIT", /* 57385 */
+ (char *) "FOR", /* 57386 */
+ (char *) "FUNC", /* 57387 */
+ (char *) "SUB", /* 57388 */
+ (char *) "GSUB", /* 57389 */
+ (char *) "IF", /* 57390 */
+ (char *) "INDEX", /* 57391 */
+ (char *) "LSUBSTR", /* 57392 */
+ (char *) "MATCHFCN", /* 57393 */
+ (char *) "NEXT", /* 57394 */
+ (char *) "NEXTFILE", /* 57395 */
+ (char *) "ADD", /* 57396 */
+ (char *) "MINUS", /* 57397 */
+ (char *) "MULT", /* 57398 */
+ (char *) "DIVIDE", /* 57399 */
+ (char *) "MOD", /* 57400 */
+ (char *) "ASSIGN", /* 57401 */
+ (char *) "ASGNOP", /* 57402 */
+ (char *) "ADDEQ", /* 57403 */
+ (char *) "SUBEQ", /* 57404 */
+ (char *) "MULTEQ", /* 57405 */
+ (char *) "DIVEQ", /* 57406 */
+ (char *) "MODEQ", /* 57407 */
+ (char *) "POWEQ", /* 57408 */
+ (char *) "PRINT", /* 57409 */
+ (char *) "PRINTF", /* 57410 */
+ (char *) "SPRINTF", /* 57411 */
+ (char *) "ELSE", /* 57412 */
+ (char *) "INTEST", /* 57413 */
+ (char *) "CONDEXPR", /* 57414 */
+ (char *) "POSTINCR", /* 57415 */
+ (char *) "PREINCR", /* 57416 */
+ (char *) "POSTDECR", /* 57417 */
+ (char *) "PREDECR", /* 57418 */
+ (char *) "VAR", /* 57419 */
+ (char *) "IVAR", /* 57420 */
+ (char *) "VARNF", /* 57421 */
+ (char *) "CALL", /* 57422 */
+ (char *) "NUMBER", /* 57423 */
+ (char *) "STRING", /* 57424 */
+ (char *) "REGEXPR", /* 57425 */
+ (char *) "GETLINE", /* 57426 */
+ (char *) "RETURN", /* 57427 */
+ (char *) "SPLIT", /* 57428 */
+ (char *) "SUBSTR", /* 57429 */
+ (char *) "WHILE", /* 57430 */
+ (char *) "CAT", /* 57431 */
+ (char *) "NOT", /* 57432 */
+ (char *) "UMINUS", /* 57433 */
+ (char *) "POWER", /* 57434 */
+ (char *) "DECR", /* 57435 */
+ (char *) "INCR", /* 57436 */
+ (char *) "INDIRECT", /* 57437 */
+ (char *) "LASTTOKEN", /* 57438 */
};
-Cell *(*proctab[92])(Node **, int) = {
+Cell *(*proctab[93])(Node **, int) = {
nullproc, /* FIRSTTOKEN */
program, /* PROGRAM */
pastat, /* PASTAT */
@@ -122,6 +123,7 @@ Cell *(*proctab[92])(Node **, int) = {
nullproc, /* STAR */
nullproc, /* QUEST */
nullproc, /* PLUS */
+ nullproc, /* EMPTYRE */
boolop, /* AND */
boolop, /* BOR */
nullproc, /* APPEND */
@@ -180,17 +182,17 @@ Cell *(*proctab[92])(Node **, int) = {
nullproc, /* NUMBER */
nullproc, /* STRING */
nullproc, /* REGEXPR */
- get_line, /* GETLINE */
- substr, /* SUBSTR */
- split, /* SPLIT */
+ awkgetline, /* GETLINE */
jump, /* RETURN */
+ split, /* SPLIT */
+ substr, /* SUBSTR */
whilestat, /* WHILE */
cat, /* CAT */
- arith, /* UMINUS */
boolop, /* NOT */
+ arith, /* UMINUS */
arith, /* POWER */
- nullproc, /* INCR */
nullproc, /* DECR */
+ nullproc, /* INCR */
indirect, /* INDIRECT */
nullproc, /* LASTTOKEN */
};
diff --git a/lang/nawk/files/proto.h b/lang/nawk/files/proto.h
index a808eba4569..de81b4af0a0 100644
--- a/lang/nawk/files/proto.h
+++ b/lang/nawk/files/proto.h
@@ -1,4 +1,4 @@
-/* $NetBSD: proto.h,v 1.2 2009/10/29 20:21:53 tnn Exp $ */
+/* $NetBSD: proto.h,v 1.3 2014/03/12 14:20:43 ryoon Exp $ */
/****************************************************************
Copyright (C) Lucent Technologies 1997
@@ -45,10 +45,10 @@ extern fa *mkdfa(const char *, int);
extern int makeinit(fa *, int);
extern void penter(Node *);
extern void freetr(Node *);
-extern int hexstr(char **);
-extern int quoted(char **);
+extern int hexstr(uschar **);
+extern int quoted(uschar **);
extern char *cclenter(const char *);
-extern void overflo(const char *);
+extern void overflo(const char *) __attribute__((__noreturn__));
extern void cfoll(fa *, Node *);
extern int first(Node *);
extern void follow(Node *);
@@ -134,7 +134,7 @@ extern void fpecatch(int);
extern void bracecheck(void);
extern void bcheck2(int, int, int);
extern void SYNTAX(const char *, ...);
-extern void FATAL(const char *, ...);
+extern void FATAL(const char *, ...) __attribute__((__noreturn__));
extern void WARNING(const char *, ...);
extern void error(void);
extern void eprint(void);
@@ -151,7 +151,7 @@ extern Cell *call(Node **, int);
extern Cell *copycell(Cell *);
extern Cell *arg(Node **, int);
extern Cell *jump(Node **, int);
-extern Cell *get_line(Node **, int);
+extern Cell *awkgetline(Node **, int);
extern Cell *getnf(Node **, int);
extern Cell *array(Node **, int);
extern Cell *awkdelete(Node **, int);
diff --git a/lang/nawk/files/run.c b/lang/nawk/files/run.c
index 506e98cd481..e984ad76ce6 100644
--- a/lang/nawk/files/run.c
+++ b/lang/nawk/files/run.c
@@ -1,4 +1,4 @@
-/* $NetBSD: run.c,v 1.2 2009/10/29 20:21:53 tnn Exp $ */
+/* $NetBSD: run.c,v 1.3 2014/03/12 14:20:43 ryoon Exp $ */
/****************************************************************
Copyright (C) Lucent Technologies 1997
@@ -51,22 +51,24 @@ void tempfree(Cell *p) {
}
*/
-#ifdef _NFILE
-#ifndef FOPEN_MAX
-#define FOPEN_MAX _NFILE
-#endif
-#endif
-
-#ifndef FOPEN_MAX
-#define FOPEN_MAX 40 /* max number of open files */
-#endif
-
-#ifndef RAND_MAX
-#define RAND_MAX 32767 /* all that ansi guarantees */
-#endif
+/* do we really need these? */
+/* #ifdef _NFILE */
+/* #ifndef FOPEN_MAX */
+/* #define FOPEN_MAX _NFILE */
+/* #endif */
+/* #endif */
+/* */
+/* #ifndef FOPEN_MAX */
+/* #define FOPEN_MAX 40 */ /* max number of open files */
+/* #endif */
+/* */
+/* #ifndef RAND_MAX */
+/* #define RAND_MAX 32767 */ /* all that ansi guarantees */
+/* #endif */
jmp_buf env;
extern int pairstack[];
+extern Awkfloat srand_seed;
Node *winner = NULL; /* root of parse tree */
Cell *tmps; /* free temporary cells for execution */
@@ -112,6 +114,7 @@ int adjbuf(char **pbuf, int *psiz, int minlen, int quantum, char **pbptr,
if (rminlen)
minlen += quantum - rminlen;
tbuf = (char *) realloc(*pbuf, minlen);
+ dprintf( ("adjbuf %s: %d %d (pbuf=%p, tbuf=%p)\n", whatrtn, *psiz, minlen, *pbuf, tbuf) );
if (tbuf == NULL) {
if (whatrtn)
FATAL("out of memory in %s", whatrtn);
@@ -388,7 +391,7 @@ Cell *jump(Node **a, int n) /* break, continue, next, nextfile, return */
return 0; /* not reached */
}
-Cell *get_line(Node **a, int n) /* get next line from specific input */
+Cell *awkgetline(Node **a, int n) /* get next line from specific input */
{ /* a[0] is variable, a[1] is operator, a[2] is filename */
Cell *r, *x;
extern Cell **fldtab;
@@ -465,7 +468,7 @@ Cell *array(Node **a, int n) /* a[0] is symtab, a[1] is list of subscripts */
for (np = a[1]; np; np = np->nnext) {
y = execute(np); /* subscript */
s = getsval(y);
- if (!adjbuf(&buf, &bufsz, strlen(buf)+strlen(s)+nsub+1, recsize, 0, 0))
+ if (!adjbuf(&buf, &bufsz, strlen(buf)+strlen(s)+nsub+1, recsize, 0, "array"))
FATAL("out of memory for %s[%s...]", x->nval, buf);
strcat(buf, s);
if (np->nnext)
@@ -512,7 +515,7 @@ Cell *awkdelete(Node **a, int n) /* a[0] is symtab, a[1] is list of subscripts *
for (np = a[1]; np; np = np->nnext) {
y = execute(np); /* subscript */
s = getsval(y);
- if (!adjbuf(&buf, &bufsz, strlen(buf)+strlen(s)+nsub+1, recsize, 0, 0))
+ if (!adjbuf(&buf, &bufsz, strlen(buf)+strlen(s)+nsub+1, recsize, 0, "awkdelete"))
FATAL("out of memory deleting %s[%s...]", x->nval, buf);
strcat(buf, s);
if (np->nnext)
@@ -551,7 +554,7 @@ Cell *intest(Node **a, int n) /* a[0] is index (list), a[1] is symtab */
for (p = a[0]; p; p = p->nnext) {
x = execute(p); /* expr */
s = getsval(x);
- if (!adjbuf(&buf, &bufsz, strlen(buf)+strlen(s)+nsub+1, recsize, 0, 0))
+ if (!adjbuf(&buf, &bufsz, strlen(buf)+strlen(s)+nsub+1, recsize, 0, "intest"))
FATAL("out of memory deleting %s[%s...]", x->nval, buf);
strcat(buf, s);
tempfree(x);
@@ -821,7 +824,7 @@ int format(char **pbuf, int *pbufsize, const char *s, Node *a) /* printf-like co
if ((fmt = (char *) malloc(fmtsz)) == NULL)
FATAL("out of memory in format()");
while (*s) {
- adjbuf(&buf, &bufsize, MAXNUMSIZE+1+p-buf, recsize, &p, "format");
+ adjbuf(&buf, &bufsize, MAXNUMSIZE+1+p-buf, recsize, &p, "format1");
if (*s != '%') {
*p++ = *s++;
continue;
@@ -835,9 +838,9 @@ int format(char **pbuf, int *pbufsize, const char *s, Node *a) /* printf-like co
fmtwd = atoi(s+1);
if (fmtwd < 0)
fmtwd = -fmtwd;
- adjbuf(&buf, &bufsize, fmtwd+1+p-buf, recsize, &p, "format");
+ adjbuf(&buf, &bufsize, fmtwd+1+p-buf, recsize, &p, "format2");
for (t = fmt; (*t++ = *s) != '\0'; s++) {
- if (!adjbuf(&fmt, &fmtsz, MAXNUMSIZE+1+t-fmt, recsize, &t, 0))
+ if (!adjbuf(&fmt, &fmtsz, MAXNUMSIZE+1+t-fmt, recsize, &t, "format3"))
FATAL("format item %.30s... ran format() out of memory", os);
if (isalpha((uschar)*s) && *s != 'l' && *s != 'h' && *s != 'L')
break; /* the ansi panoply */
@@ -855,7 +858,7 @@ int format(char **pbuf, int *pbufsize, const char *s, Node *a) /* printf-like co
*t = '\0';
if (fmtwd < 0)
fmtwd = -fmtwd;
- adjbuf(&buf, &bufsize, fmtwd+1+p-buf, recsize, &p, "format");
+ adjbuf(&buf, &bufsize, fmtwd+1+p-buf, recsize, &p, "format4");
switch (*s) {
case 'f': case 'e': case 'g': case 'E': case 'G':
@@ -889,14 +892,14 @@ int format(char **pbuf, int *pbufsize, const char *s, Node *a) /* printf-like co
n = MAXNUMSIZE;
if (fmtwd > n)
n = fmtwd;
- adjbuf(&buf, &bufsize, 1+n+p-buf, recsize, &p, "format");
+ adjbuf(&buf, &bufsize, 1+n+p-buf, recsize, &p, "format5");
switch (flag) {
case '?': sprintf(p, "%s", fmt); /* unknown, so dump it too */
t = getsval(x);
n = strlen(t);
if (fmtwd > n)
n = fmtwd;
- adjbuf(&buf, &bufsize, 1+strlen(p)+n+p-buf, recsize, &p, "format");
+ adjbuf(&buf, &bufsize, 1+strlen(p)+n+p-buf, recsize, &p, "format6");
p += strlen(p);
sprintf(p, "%s", t);
break;
@@ -908,7 +911,7 @@ int format(char **pbuf, int *pbufsize, const char *s, Node *a) /* printf-like co
n = strlen(t);
if (fmtwd > n)
n = fmtwd;
- if (!adjbuf(&buf, &bufsize, 1+n+p-buf, recsize, &p, 0))
+ if (!adjbuf(&buf, &bufsize, 1+n+p-buf, recsize, &p, "format7"))
FATAL("huge string/format (%d chars) in printf %.30s... ran format() out of memory", n, t);
sprintf(p, fmt, t);
break;
@@ -1159,11 +1162,11 @@ Cell *cat(Node **a, int q) /* a[0] cat a[1] */
x->sval, y->sval);
strcpy(s, x->sval);
strcpy(s+n1, y->sval);
+ tempfree(x);
tempfree(y);
z = gettemp();
z->sval = s;
z->tval = STR;
- tempfree(x);
return(z);
}
@@ -1209,13 +1212,13 @@ Cell *dopa2(Node **a, int n) /* a[0], a[1] { a[2] } */
Cell *split(Node **a, int nnn) /* split(a[0], a[1], a[2]); a[3] is type */
{
Cell *x = 0, *y, *ap;
- char *s;
+ char *s, *origs;
int sep;
char *t, temp, num[50], *fs = 0;
int n, tempstat, arg3type;
y = execute(a[0]); /* source string */
- s = getsval(y);
+ origs = s = strdup(getsval(y));
arg3type = ptoi(a[3]);
if (a[2] == 0) /* fs string */
fs = *FS;
@@ -1235,6 +1238,12 @@ Cell *split(Node **a, int nnn) /* split(a[0], a[1], a[2]); a[3] is type */
ap->sval = (char *) makesymtab(NSYMTAB);
n = 0;
+ if (arg3type == REGEXPR && strlen((char*)((fa*)a[2])->restr) == 0) {
+ /* split(s, a, //); have to arrange that it looks like empty sep */
+ arg3type = 0;
+ fs = "";
+ sep = 0;
+ }
if (*s != '\0' && (strlen(fs) > 1 || arg3type == REGEXPR)) { /* reg expr */
fa *pfa;
if (arg3type == REGEXPR) { /* it's ready already */
@@ -1329,6 +1338,7 @@ Cell *split(Node **a, int nnn) /* split(a[0], a[1], a[2]); a[3] is type */
}
tempfree(ap);
tempfree(y);
+ free(origs);
if (a[2] != 0 && arg3type == STRING) {
tempfree(x);
}
@@ -1466,6 +1476,7 @@ Cell *bltin(Node **a, int n) /* builtin functions. a[0] is type, a[1] is arg lis
Cell *x, *y;
Awkfloat u;
int t;
+ Awkfloat tmp;
char *p, *buf;
Node *nextarg;
FILE *fp;
@@ -1517,7 +1528,10 @@ Cell *bltin(Node **a, int n) /* builtin functions. a[0] is type, a[1] is arg lis
u = time((time_t *)0);
else
u = getfval(x);
+ tmp = u;
srand((unsigned int) u);
+ u = srand_seed;
+ srand_seed = tmp;
break;
case FTOUPPER:
case FTOLOWER:
@@ -1613,17 +1627,25 @@ struct files {
FILE *fp;
const char *fname;
int mode; /* '|', 'a', 'w' => LE/LT, GT */
-} files[FOPEN_MAX] ={
- { NULL, "/dev/stdin", LT }, /* watch out: don't free this! */
- { NULL, "/dev/stdout", GT },
- { NULL, "/dev/stderr", GT }
-};
+} *files;
+
+int nfiles;
void stdinit(void) /* in case stdin, etc., are not constants */
{
- files[0].fp = stdin;
- files[1].fp = stdout;
- files[2].fp = stderr;
+ nfiles = FOPEN_MAX;
+ files = calloc(nfiles, sizeof(*files));
+ if (files == NULL)
+ FATAL("can't allocate file memory for %u files", nfiles);
+ files[0].fp = stdin;
+ files[0].fname = "/dev/stdin";
+ files[0].mode = LT;
+ files[1].fp = stdout;
+ files[1].fname = "/dev/stdout";
+ files[1].mode = GT;
+ files[2].fp = stderr;
+ files[2].fname = "/dev/stderr";
+ files[2].mode = GT;
}
FILE *openfile(int a, const char *us)
@@ -1634,7 +1656,7 @@ FILE *openfile(int a, const char *us)
if (*s == '\0')
FATAL("null file name in print or getline");
- for (i=0; i < FOPEN_MAX; i++)
+ for (i=0; i < nfiles; i++)
if (files[i].fname && strcmp(s, files[i].fname) == 0) {
if (a == files[i].mode || (a==APPEND && files[i].mode==GT))
return files[i].fp;
@@ -1644,11 +1666,19 @@ FILE *openfile(int a, const char *us)
if (a == FFLUSH) /* didn't find it, so don't create it! */
return NULL;
- for (i=0; i < FOPEN_MAX; i++)
+ for (i=0; i < nfiles; i++)
if (files[i].fp == 0)
break;
- if (i >= FOPEN_MAX)
- FATAL("%s makes too many open files", s);
+ if (i >= nfiles) {
+ struct files *nf;
+ int nnf = nfiles + FOPEN_MAX;
+ nf = realloc(files, nnf * sizeof(*nf));
+ if (nf == NULL)
+ FATAL("cannot grow files for %s and %d files", s, nnf);
+ memset(&nf[nfiles], 0, FOPEN_MAX * sizeof(*nf));
+ nfiles = nnf;
+ files = nf;
+ }
fflush(stdout); /* force a semblance of order */
m = a;
if (a == GT) {
@@ -1676,7 +1706,7 @@ const char *filename(FILE *fp)
{
int i;
- for (i = 0; i < FOPEN_MAX; i++)
+ for (i = 0; i < nfiles; i++)
if (fp == files[i].fp)
return files[i].fname;
return "???";
@@ -1691,7 +1721,7 @@ Cell *closefile(Node **a, int n)
x = execute(a[0]);
getsval(x);
stat = -1;
- for (i = 0; i < FOPEN_MAX; i++) {
+ for (i = 0; i < nfiles; i++) {
if (files[i].fname && strcmp(x->sval, files[i].fname) == 0) {
if (ferror(files[i].fp))
WARNING( "i/o error occurred on %s", files[i].fname );
@@ -1735,7 +1765,7 @@ void flush_all(void)
{
int i;
- for (i = 0; i < FOPEN_MAX; i++)
+ for (i = 0; i < nfiles; i++)
if (files[i].fp)
fflush(files[i].fp);
}
@@ -1887,9 +1917,10 @@ Cell *gsub(Node **a, int nnn) /* global substitute */
adjbuf(&buf, &bufsz, 1+strlen(sptr)+pb-buf, 0, &pb, "gsub");
while ((*pb++ = *sptr++) != 0)
;
- done: if (pb > buf + bufsz)
- FATAL("gsub result2 %.30s too big; can't happen", buf);
- *pb = '\0';
+ done: if (pb < buf + bufsz)
+ *pb = '\0';
+ else if (*(pb-1) != '\0')
+ FATAL("gsub result2 %.30s truncated; can't happen", buf);
setsval(x, buf); /* BUG: should be able to avoid copy + free */
pfa->initstat = tempstat;
}
diff --git a/lang/nawk/files/tran.c b/lang/nawk/files/tran.c
index c98eaaf9faa..fa7575f4ecf 100644
--- a/lang/nawk/files/tran.c
+++ b/lang/nawk/files/tran.c
@@ -1,4 +1,4 @@
-/* $NetBSD: tran.c,v 1.3 2008/09/08 13:47:55 joerg Exp $ */
+/* $NetBSD: tran.c,v 1.4 2014/03/12 14:20:43 ryoon Exp $ */
/****************************************************************
Copyright (C) Lucent Technologies 1997
@@ -214,7 +214,7 @@ Cell *setsymtab(const char *n, const char *s, Awkfloat f, unsigned t, Array *tp)
if (n != NULL && (p = lookup(n, tp)) != NULL) {
dprintf( ("setsymtab found %p: n=%s s=\"%s\" f=%g t=%o\n",
- p, NN(p->nval), NN(p->sval), p->fval, p->tval) );
+ (void*)p, NN(p->nval), NN(p->sval), p->fval, p->tval) );
return(p);
}
p = (Cell *) malloc(sizeof(Cell));
@@ -233,7 +233,7 @@ Cell *setsymtab(const char *n, const char *s, Awkfloat f, unsigned t, Array *tp)
p->cnext = tp->tab[h];
tp->tab[h] = p;
dprintf( ("setsymtab set %p: n=%s s=\"%s\" f=%g t=%o\n",
- p, p->nval, p->sval, p->fval, p->tval) );
+ (void*)p, p->nval, p->sval, p->fval, p->tval) );
return(p);
}
@@ -300,7 +300,9 @@ Awkfloat setfval(Cell *vp, Awkfloat f) /* set float val of a Cell */
xfree(vp->sval); /* free any previous string */
vp->tval &= ~STR; /* mark string invalid */
vp->tval |= NUM; /* mark number ok */
- dprintf( ("setfval %p: %s = %g, t=%o\n", vp, NN(vp->nval), f, vp->tval) );
+ if (f == -0) /* who would have thought this possible? */
+ f = 0;
+ dprintf( ("setfval %p: %s = %g, t=%o\n", (void*)vp, NN(vp->nval), f, vp->tval) );
return vp->fval = f;
}
@@ -320,7 +322,7 @@ char *setsval(Cell *vp, const char *s) /* set string val of a Cell */
int fldno;
dprintf( ("starting setsval %p: %s = \"%s\", t=%o, r,f=%d,%d\n",
- vp, NN(vp->nval), s, vp->tval, donerec, donefld) );
+ (void*)vp, NN(vp->nval), s, vp->tval, donerec, donefld) );
if ((vp->tval & (NUM | STR)) == 0)
funnyvar(vp, "assign to");
if (isfld(vp)) {
@@ -334,13 +336,13 @@ char *setsval(Cell *vp, const char *s) /* set string val of a Cell */
donerec = 1;
}
t = tostring(s); /* in case it's self-assign */
- vp->tval &= ~NUM;
- vp->tval |= STR;
if (freeable(vp))
xfree(vp->sval);
+ vp->tval &= ~NUM;
+ vp->tval |= STR;
vp->tval &= ~DONTFREE;
dprintf( ("setsval %p: %s = \"%s (%p) \", t=%o r,f=%d,%d\n",
- vp, NN(vp->nval), t,t, vp->tval, donerec, donefld) );
+ (void*)vp, NN(vp->nval), t,t, vp->tval, donerec, donefld) );
return(vp->sval = t);
}
@@ -357,7 +359,8 @@ Awkfloat getfval(Cell *vp) /* get float val of a Cell */
if (is_number(vp->sval) && !(vp->tval&CON))
vp->tval |= NUM; /* make NUM only sparingly */
}
- dprintf( ("getfval %p: %s = %g, t=%o\n", vp, NN(vp->nval), vp->fval, vp->tval) );
+ dprintf( ("getfval %p: %s = %g, t=%o\n",
+ (void*)vp, NN(vp->nval), vp->fval, vp->tval) );
return(vp->fval);
}
@@ -383,7 +386,8 @@ static char *get_str_val(Cell *vp, char **fmt) /* get string val of a Cel
vp->tval &= ~DONTFREE;
vp->tval |= STR;
}
- dprintf( ("getsval %p: %s = \"%s (%p)\", t=%o\n", vp, NN(vp->nval), vp->sval, vp->sval, vp->tval) );
+ dprintf( ("getsval %p: %s = \"%s (%p)\", t=%o\n",
+ (void*)vp, NN(vp->nval), vp->sval, vp->sval, vp->tval) );
return(vp->sval);
}
diff --git a/lang/nawk/files/ytab.c b/lang/nawk/files/ytab.c
index 35b9346b8b1..8720de57c7f 100644
--- a/lang/nawk/files/ytab.c
+++ b/lang/nawk/files/ytab.c
@@ -1,251 +1,5 @@
-/* A Bison parser, made by GNU Bison 1.875. */
-
-/* Skeleton parser for Yacc-like parsing with Bison,
- Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002 Free Software Foundation, Inc.
-
- This program is free software; you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation; either version 2, or (at your option)
- any later version.
-
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program; if not, write to the Free Software
- Foundation, Inc., 59 Temple Place - Suite 330,
- Boston, MA 02111-1307, USA. */
-
-/* As a special exception, when this file is copied by Bison into a
- Bison output file, you may use that output file without restriction.
- This special exception was added by the Free Software Foundation
- in version 1.24 of Bison. */
-
-/* Written by Richard Stallman by simplifying the original so called
- ``semantic'' parser. */
-
-/* All symbols defined below should begin with yy or YY, to avoid
- infringing on user name space. This should be done even for local
- variables, as they might otherwise be expanded by user macros.
- There are some unavoidable exceptions within include files to
- define necessary library symbols; they are noted "INFRINGES ON
- USER NAME SPACE" below. */
-
-/* Identify Bison output. */
-#define YYBISON 1
-
-/* Skeleton name. */
-#define YYSKELETON_NAME "yacc.c"
-
-/* Pure parsers. */
-#define YYPURE 0
-
-/* Using locations. */
-#define YYLSP_NEEDED 0
-
-
-
-/* Tokens. */
-#ifndef YYTOKENTYPE
-# define YYTOKENTYPE
- /* Put the tokens into the symbol table, so that GDB and other debuggers
- know about them. */
- enum yytokentype {
- FIRSTTOKEN = 258,
- PROGRAM = 259,
- PASTAT = 260,
- PASTAT2 = 261,
- XBEGIN = 262,
- XEND = 263,
- NL = 264,
- ARRAY = 265,
- MATCH = 266,
- NOTMATCH = 267,
- MATCHOP = 268,
- FINAL = 269,
- DOT = 270,
- ALL = 271,
- CCL = 272,
- NCCL = 273,
- CHAR = 274,
- OR = 275,
- STAR = 276,
- QUEST = 277,
- PLUS = 278,
- AND = 279,
- BOR = 280,
- APPEND = 281,
- EQ = 282,
- GE = 283,
- GT = 284,
- LE = 285,
- LT = 286,
- NE = 287,
- IN = 288,
- ARG = 289,
- BLTIN = 290,
- BREAK = 291,
- CLOSE = 292,
- CONTINUE = 293,
- DELETE = 294,
- DO = 295,
- EXIT = 296,
- FOR = 297,
- FUNC = 298,
- SUB = 299,
- GSUB = 300,
- IF = 301,
- INDEX = 302,
- LSUBSTR = 303,
- MATCHFCN = 304,
- NEXT = 305,
- NEXTFILE = 306,
- ADD = 307,
- MINUS = 308,
- MULT = 309,
- DIVIDE = 310,
- MOD = 311,
- ASSIGN = 312,
- ASGNOP = 313,
- ADDEQ = 314,
- SUBEQ = 315,
- MULTEQ = 316,
- DIVEQ = 317,
- MODEQ = 318,
- POWEQ = 319,
- PRINT = 320,
- PRINTF = 321,
- SPRINTF = 322,
- ELSE = 323,
- INTEST = 324,
- CONDEXPR = 325,
- POSTINCR = 326,
- PREINCR = 327,
- POSTDECR = 328,
- PREDECR = 329,
- VAR = 330,
- IVAR = 331,
- VARNF = 332,
- CALL = 333,
- NUMBER = 334,
- STRING = 335,
- REGEXPR = 336,
- GETLINE = 337,
- SUBSTR = 338,
- SPLIT = 339,
- RETURN = 340,
- WHILE = 341,
- CAT = 342,
- UMINUS = 343,
- NOT = 344,
- POWER = 345,
- INCR = 346,
- DECR = 347,
- INDIRECT = 348,
- LASTTOKEN = 349
- };
-#endif
-#define FIRSTTOKEN 258
-#define PROGRAM 259
-#define PASTAT 260
-#define PASTAT2 261
-#define XBEGIN 262
-#define XEND 263
-#define NL 264
-#define ARRAY 265
-#define MATCH 266
-#define NOTMATCH 267
-#define MATCHOP 268
-#define FINAL 269
-#define DOT 270
-#define ALL 271
-#define CCL 272
-#define NCCL 273
-#define CHAR 274
-#define OR 275
-#define STAR 276
-#define QUEST 277
-#define PLUS 278
-#define AND 279
-#define BOR 280
-#define APPEND 281
-#define EQ 282
-#define GE 283
-#define GT 284
-#define LE 285
-#define LT 286
-#define NE 287
-#define IN 288
-#define ARG 289
-#define BLTIN 290
-#define BREAK 291
-#define CLOSE 292
-#define CONTINUE 293
-#define DELETE 294
-#define DO 295
-#define EXIT 296
-#define FOR 297
-#define FUNC 298
-#define SUB 299
-#define GSUB 300
-#define IF 301
-#define INDEX 302
-#define LSUBSTR 303
-#define MATCHFCN 304
-#define NEXT 305
-#define NEXTFILE 306
-#define ADD 307
-#define MINUS 308
-#define MULT 309
-#define DIVIDE 310
-#define MOD 311
-#define ASSIGN 312
-#define ASGNOP 313
-#define ADDEQ 314
-#define SUBEQ 315
-#define MULTEQ 316
-#define DIVEQ 317
-#define MODEQ 318
-#define POWEQ 319
-#define PRINT 320
-#define PRINTF 321
-#define SPRINTF 322
-#define ELSE 323
-#define INTEST 324
-#define CONDEXPR 325
-#define POSTINCR 326
-#define PREINCR 327
-#define POSTDECR 328
-#define PREDECR 329
-#define VAR 330
-#define IVAR 331
-#define VARNF 332
-#define CALL 333
-#define NUMBER 334
-#define STRING 335
-#define REGEXPR 336
-#define GETLINE 337
-#define SUBSTR 338
-#define SPLIT 339
-#define RETURN 340
-#define WHILE 341
-#define CAT 342
-#define UMINUS 343
-#define NOT 344
-#define POWER 345
-#define INCR 346
-#define DECR 347
-#define INDIRECT 348
-#define LASTTOKEN 349
-
-
-
-
-/* Copy the first part of user declarations. */
-#line 25 "awkgram.y"
+#line 26 "/n/fs/fac/bwk/awk/awkgram.y"
#include <stdio.h>
#include <string.h>
#include "awk.h"
@@ -260,3092 +14,1666 @@ int inloop = 0; /* = 1 if in while, for, do */
char *curfname = 0; /* current function name */
Node *arglist = 0; /* list of args for current function */
-
-/* Enabling traces. */
-#ifndef YYDEBUG
-# define YYDEBUG 0
-#endif
-
-/* Enabling verbose error messages. */
-#ifdef YYERROR_VERBOSE
-# undef YYERROR_VERBOSE
-# define YYERROR_VERBOSE 1
-#else
-# define YYERROR_VERBOSE 0
-#endif
-
-#if ! defined (YYSTYPE) && ! defined (YYSTYPE_IS_DECLARED)
-#line 41 "awkgram.y"
-typedef union YYSTYPE {
+#line 41 "/n/fs/fac/bwk/awk/awkgram.y"
+typedef union {
Node *p;
Cell *cp;
int i;
char *s;
} YYSTYPE;
-/* Line 191 of yacc.c. */
-#line 286 "y.tab.c"
-# define yystype YYSTYPE /* obsolescent; will be withdrawn */
-# define YYSTYPE_IS_DECLARED 1
-# define YYSTYPE_IS_TRIVIAL 1
-#endif
-
-
-
-/* Copy the second part of user declarations. */
-
-
-/* Line 214 of yacc.c. */
-#line 298 "y.tab.c"
-
-#if ! defined (yyoverflow) || YYERROR_VERBOSE
-
-/* The parser invokes alloca or malloc; define the necessary symbols. */
-
-# if YYSTACK_USE_ALLOCA
-# define YYSTACK_ALLOC alloca
-# else
-# ifndef YYSTACK_USE_ALLOCA
-# if defined (alloca) || defined (_ALLOCA_H)
-# define YYSTACK_ALLOC alloca
-# else
-# ifdef __GNUC__
-# define YYSTACK_ALLOC __builtin_alloca
-# endif
-# endif
-# endif
-# endif
-
-# ifdef YYSTACK_ALLOC
- /* Pacify GCC's `empty if-body' warning. */
-# define YYSTACK_FREE(Ptr) do { /* empty */; } while (0)
-# else
-# if defined (__STDC__) || defined (__cplusplus)
-# include <stdlib.h> /* INFRINGES ON USER NAME SPACE */
-# define YYSIZE_T size_t
-# endif
-# define YYSTACK_ALLOC malloc
-# define YYSTACK_FREE free
-# endif
-#endif /* ! defined (yyoverflow) || YYERROR_VERBOSE */
-
-
-#if (! defined (yyoverflow) \
- && (! defined (__cplusplus) \
- || (YYSTYPE_IS_TRIVIAL)))
-
-/* A type that is properly aligned for any stack member. */
-union yyalloc
-{
- short yyss;
- YYSTYPE yyvs;
- };
-
-/* The size of the maximum gap between one aligned stack and the next. */
-# define YYSTACK_GAP_MAXIMUM (sizeof (union yyalloc) - 1)
-
-/* The size of an array large to enough to hold all stacks, each with
- N elements. */
-# define YYSTACK_BYTES(N) \
- ((N) * (sizeof (short) + sizeof (YYSTYPE)) \
- + YYSTACK_GAP_MAXIMUM)
-
-/* Copy COUNT objects from FROM to TO. The source and destination do
- not overlap. */
-# ifndef YYCOPY
-# if 1 < __GNUC__
-# define YYCOPY(To, From, Count) \
- __builtin_memcpy (To, From, (Count) * sizeof (*(From)))
-# else
-# define YYCOPY(To, From, Count) \
- do \
- { \
- register YYSIZE_T yyi; \
- for (yyi = 0; yyi < (Count); yyi++) \
- (To)[yyi] = (From)[yyi]; \
- } \
- while (0)
-# endif
-# endif
-
-/* Relocate STACK from its old location to the new one. The
- local variables YYSIZE and YYSTACKSIZE give the old and new number of
- elements in the stack, and YYPTR gives the new location of the
- stack. Advance YYPTR to a properly aligned location for the next
- stack. */
-# define YYSTACK_RELOCATE(Stack) \
- do \
- { \
- YYSIZE_T yynewbytes; \
- YYCOPY (&yyptr->Stack, Stack, yysize); \
- Stack = &yyptr->Stack; \
- yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \
- yyptr += yynewbytes / sizeof (*yyptr); \
- } \
- while (0)
-
-#endif
-
-#if defined (__STDC__) || defined (__cplusplus)
- typedef signed char yysigned_char;
-#else
- typedef short yysigned_char;
+extern int yyerrflag;
+#ifndef YYMAXDEPTH
+#define YYMAXDEPTH 150
#endif
+YYSTYPE yylval;
+YYSTYPE yyval;
+#define FIRSTTOKEN 57346
+#define PROGRAM 57347
+#define PASTAT 57348
+#define PASTAT2 57349
+#define XBEGIN 57350
+#define XEND 57351
+#define NL 57352
+#define ARRAY 57353
+#define MATCH 57354
+#define NOTMATCH 57355
+#define MATCHOP 57356
+#define FINAL 57357
+#define DOT 57358
+#define ALL 57359
+#define CCL 57360
+#define NCCL 57361
+#define CHAR 57362
+#define OR 57363
+#define STAR 57364
+#define QUEST 57365
+#define PLUS 57366
+#define EMPTYRE 57367
+#define AND 57368
+#define BOR 57369
+#define APPEND 57370
+#define EQ 57371
+#define GE 57372
+#define GT 57373
+#define LE 57374
+#define LT 57375
+#define NE 57376
+#define IN 57377
+#define ARG 57378
+#define BLTIN 57379
+#define BREAK 57380
+#define CLOSE 57381
+#define CONTINUE 57382
+#define DELETE 57383
+#define DO 57384
+#define EXIT 57385
+#define FOR 57386
+#define FUNC 57387
+#define SUB 57388
+#define GSUB 57389
+#define IF 57390
+#define INDEX 57391
+#define LSUBSTR 57392
+#define MATCHFCN 57393
+#define NEXT 57394
+#define NEXTFILE 57395
+#define ADD 57396
+#define MINUS 57397
+#define MULT 57398
+#define DIVIDE 57399
+#define MOD 57400
+#define ASSIGN 57401
+#define ASGNOP 57402
+#define ADDEQ 57403
+#define SUBEQ 57404
+#define MULTEQ 57405
+#define DIVEQ 57406
+#define MODEQ 57407
+#define POWEQ 57408
+#define PRINT 57409
+#define PRINTF 57410
+#define SPRINTF 57411
+#define ELSE 57412
+#define INTEST 57413
+#define CONDEXPR 57414
+#define POSTINCR 57415
+#define PREINCR 57416
+#define POSTDECR 57417
+#define PREDECR 57418
+#define VAR 57419
+#define IVAR 57420
+#define VARNF 57421
+#define CALL 57422
+#define NUMBER 57423
+#define STRING 57424
+#define REGEXPR 57425
+#define GETLINE 57426
+#define RETURN 57427
+#define SPLIT 57428
+#define SUBSTR 57429
+#define WHILE 57430
+#define CAT 57431
+#define NOT 57432
+#define UMINUS 57433
+#define POWER 57434
+#define DECR 57435
+#define INCR 57436
+#define INDIRECT 57437
+#define LASTTOKEN 57438
+#define YYEOFCODE 1
+#define YYERRCODE 2
+
+#line 445 "/n/fs/fac/bwk/awk/awkgram.y"
-/* YYFINAL -- State number of the termination state. */
-#define YYFINAL 8
-/* YYLAST -- Last index in YYTABLE. */
-#define YYLAST 4569
-
-/* YYNTOKENS -- Number of terminals. */
-#define YYNTOKENS 111
-/* YYNNTS -- Number of nonterminals. */
-#define YYNNTS 49
-/* YYNRULES -- Number of rules. */
-#define YYNRULES 185
-/* YYNRULES -- Number of states. */
-#define YYNSTATES 367
-
-/* YYTRANSLATE(YYLEX) -- Bison symbol number corresponding to YYLEX. */
-#define YYUNDEFTOK 2
-#define YYMAXUTOK 349
-#define YYTRANSLATE(YYX) \
- ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK)
-
-/* YYTRANSLATE[YYLEX] -- Bison symbol number corresponding to YYLEX. */
-static const unsigned char yytranslate[] =
+void setfname(Cell *p)
{
- 0, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 103, 2, 2,
- 12, 16, 102, 100, 9, 101, 2, 15, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 93, 14,
- 2, 2, 2, 92, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 18, 2, 19, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 11, 13, 17, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 1, 2, 3, 4,
- 5, 6, 7, 8, 10, 20, 21, 22, 23, 24,
- 25, 26, 27, 28, 29, 30, 31, 32, 33, 34,
- 35, 36, 37, 38, 39, 40, 41, 42, 43, 44,
- 45, 46, 47, 48, 49, 50, 51, 52, 53, 54,
- 55, 56, 57, 58, 59, 60, 61, 62, 63, 64,
- 65, 66, 67, 68, 69, 70, 71, 72, 73, 74,
- 75, 76, 77, 78, 79, 80, 81, 82, 83, 84,
- 85, 86, 87, 88, 89, 90, 91, 94, 95, 96,
- 97, 98, 99, 104, 105, 106, 107, 108, 109, 110
-};
+ if (isarr(p))
+ SYNTAX("%s is an array, not a function", p->nval);
+ else if (isfcn(p))
+ SYNTAX("you can't define function %s more than once", p->nval);
+ curfname = p->nval;
+}
-#if YYDEBUG
-/* YYPRHS[YYN] -- Index of the first RHS symbol of rule number YYN in
- YYRHS. */
-static const unsigned short yyprhs[] =
+int constnode(Node *p)
{
- 0, 0, 3, 5, 7, 9, 12, 14, 17, 19,
- 22, 24, 27, 29, 32, 33, 46, 47, 58, 59,
- 68, 70, 72, 77, 79, 82, 84, 87, 88, 90,
- 91, 93, 94, 96, 98, 102, 104, 106, 111, 115,
- 122, 126, 131, 136, 137, 147, 149, 153, 155, 159,
- 163, 169, 173, 177, 181, 185, 189, 195, 198, 200,
- 202, 206, 212, 216, 220, 224, 228, 232, 236, 240,
- 244, 248, 252, 256, 262, 267, 271, 274, 276, 278,
- 282, 286, 288, 292, 293, 295, 299, 301, 303, 305,
- 307, 310, 313, 315, 318, 320, 323, 324, 329, 331,
- 334, 339, 344, 349, 352, 358, 361, 363, 365, 367,
- 370, 373, 376, 377, 378, 388, 392, 395, 397, 402,
- 405, 409, 412, 415, 419, 422, 425, 426, 430, 433,
- 435, 438, 440, 442, 447, 451, 455, 459, 463, 467,
- 471, 474, 477, 480, 484, 489, 491, 495, 500, 503,
- 506, 509, 512, 515, 520, 524, 527, 529, 536, 543,
- 547, 554, 561, 563, 572, 581, 588, 593, 595, 602,
- 609, 618, 627, 636, 643, 645, 647, 652, 654, 657,
- 658, 660, 664, 666, 668, 670
-};
+ return isvalue(p) && ((Cell *) (p->narg[0]))->csub == CCON;
+}
-/* YYRHS -- A `-1'-separated list of the rules' RHS. */
-static const short yyrhs[] =
+char *strnode(Node *p)
{
- 112, 0, -1, 129, -1, 1, -1, 34, -1, 113,
- 10, -1, 35, -1, 114, 10, -1, 9, -1, 115,
- 10, -1, 50, -1, 116, 10, -1, 78, -1, 117,
- 10, -1, -1, 52, 12, 128, 14, 126, 136, 14,
- 126, 128, 146, 119, 149, -1, -1, 52, 12, 128,
- 14, 14, 126, 128, 146, 120, 149, -1, -1, 52,
- 12, 158, 43, 158, 146, 121, 149, -1, 85, -1,
- 88, -1, 56, 12, 136, 146, -1, 11, -1, 124,
- 10, -1, 10, -1, 125, 10, -1, -1, 125, -1,
- -1, 141, -1, -1, 147, -1, 127, -1, 127, 133,
- 127, -1, 136, -1, 130, -1, 130, 124, 153, 17,
- -1, 130, 9, 130, -1, 130, 9, 130, 124, 153,
- 17, -1, 124, 153, 17, -1, 7, 124, 153, 17,
- -1, 8, 124, 153, 17, -1, -1, 53, 122, 12,
- 157, 146, 132, 124, 153, 17, -1, 131, -1, 133,
- 127, 131, -1, 136, -1, 134, 115, 136, -1, 156,
- 68, 135, -1, 135, 92, 135, 93, 135, -1, 135,
- 114, 135, -1, 135, 113, 135, -1, 135, 23, 144,
- -1, 135, 23, 135, -1, 135, 43, 158, -1, 12,
- 137, 16, 43, 158, -1, 135, 155, -1, 143, -1,
- 155, -1, 156, 68, 136, -1, 136, 92, 136, 93,
- 136, -1, 136, 114, 136, -1, 136, 113, 136, -1,
- 136, 37, 136, -1, 136, 38, 136, -1, 136, 39,
- 136, -1, 136, 40, 136, -1, 136, 41, 136, -1,
- 136, 42, 136, -1, 136, 23, 144, -1, 136, 23,
- 136, -1, 136, 43, 158, -1, 12, 137, 16, 43,
- 158, -1, 136, 13, 94, 156, -1, 136, 13, 94,
- -1, 136, 155, -1, 143, -1, 155, -1, 136, 115,
- 136, -1, 137, 115, 136, -1, 135, -1, 138, 115,
- 135, -1, -1, 138, -1, 12, 137, 16, -1, 75,
- -1, 76, -1, 10, -1, 14, -1, 141, 10, -1,
- 141, 14, -1, 17, -1, 142, 10, -1, 144, -1,
- 105, 143, -1, -1, 15, 145, 91, 15, -1, 16,
- -1, 146, 10, -1, 140, 139, 13, 155, -1, 140,
- 139, 36, 155, -1, 140, 139, 39, 155, -1, 140,
- 139, -1, 49, 158, 18, 134, 19, -1, 49, 158,
- -1, 136, -1, 1, -1, 125, -1, 14, 126, -1,
- 46, 148, -1, 48, 148, -1, -1, -1, 116, 150,
- 149, 151, 98, 12, 136, 16, 148, -1, 51, 136,
- 148, -1, 51, 148, -1, 118, -1, 123, 149, 117,
- 149, -1, 123, 149, -1, 124, 153, 142, -1, 60,
- 148, -1, 61, 148, -1, 97, 136, 148, -1, 97,
- 148, -1, 147, 148, -1, -1, 159, 152, 149, -1,
- 14, 126, -1, 149, -1, 153, 149, -1, 54, -1,
- 55, -1, 155, 15, 68, 155, -1, 155, 100, 155,
- -1, 155, 101, 155, -1, 155, 102, 155, -1, 155,
- 15, 155, -1, 155, 103, 155, -1, 155, 106, 155,
- -1, 101, 155, -1, 100, 155, -1, 105, 155, -1,
- 45, 12, 16, -1, 45, 12, 134, 16, -1, 45,
- -1, 88, 12, 16, -1, 88, 12, 134, 16, -1,
- 47, 155, -1, 108, 156, -1, 107, 156, -1, 156,
- 108, -1, 156, 107, -1, 94, 156, 41, 155, -1,
- 94, 41, 155, -1, 94, 156, -1, 94, -1, 57,
- 12, 136, 115, 136, 16, -1, 57, 12, 136, 115,
- 144, 16, -1, 12, 136, 16, -1, 59, 12, 136,
- 115, 144, 16, -1, 59, 12, 136, 115, 136, 16,
- -1, 89, -1, 96, 12, 136, 115, 158, 115, 136,
- 16, -1, 96, 12, 136, 115, 158, 115, 144, 16,
- -1, 96, 12, 136, 115, 158, 16, -1, 77, 12,
- 134, 16, -1, 90, -1, 154, 12, 144, 115, 136,
- 16, -1, 154, 12, 136, 115, 136, 16, -1, 154,
- 12, 144, 115, 136, 115, 156, 16, -1, 154, 12,
- 136, 115, 136, 115, 156, 16, -1, 95, 12, 136,
- 115, 136, 115, 136, 16, -1, 95, 12, 136, 115,
- 136, 16, -1, 156, -1, 158, -1, 158, 18, 134,
- 19, -1, 86, -1, 109, 155, -1, -1, 85, -1,
- 157, 115, 85, -1, 85, -1, 44, -1, 87, -1,
- 98, 12, 136, 146, -1
-};
+ return ((Cell *)(p->narg[0]))->sval;
+}
-/* YYRLINE[YYN] -- source line where rule number YYN was defined. */
-static const unsigned short yyrline[] =
+Node *notnull(Node *n)
{
- 0, 98, 98, 100, 104, 104, 108, 108, 112, 112,
- 116, 116, 120, 120, 124, 124, 126, 126, 128, 128,
- 133, 134, 138, 142, 142, 146, 146, 150, 151, 155,
- 156, 161, 162, 166, 167, 171, 175, 176, 177, 178,
- 179, 180, 182, 184, 184, 189, 190, 194, 195, 199,
- 200, 202, 204, 206, 207, 212, 213, 214, 215, 216,
- 220, 221, 223, 225, 227, 228, 229, 230, 231, 232,
- 233, 234, 239, 240, 241, 244, 247, 248, 249, 253,
- 254, 258, 259, 263, 264, 265, 269, 269, 273, 273,
- 273, 273, 277, 277, 281, 283, 287, 287, 291, 291,
- 295, 298, 301, 304, 305, 306, 307, 308, 312, 313,
- 317, 319, 321, 321, 321, 323, 324, 325, 326, 327,
- 328, 329, 332, 335, 336, 337, 338, 338, 339, 343,
- 344, 348, 348, 352, 353, 354, 355, 356, 357, 358,
- 359, 360, 361, 362, 363, 364, 365, 366, 367, 368,
- 369, 370, 371, 372, 373, 374, 375, 376, 378, 381,
- 382, 384, 389, 390, 392, 394, 396, 397, 398, 400,
- 405, 407, 412, 414, 416, 420, 421, 422, 423, 427,
- 428, 429, 435, 436, 437, 442
-};
-#endif
+ switch (n->nobj) {
+ case LE: case LT: case EQ: case NE: case GT: case GE:
+ case BOR: case AND: case NOT:
+ return n;
+ default:
+ return op2(NE, n, nullnode);
+ }
+}
-#if YYDEBUG || YYERROR_VERBOSE
-/* YYTNME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM.
- First, the terminals, then, starting at YYNTOKENS, nonterminals. */
-static const char *const yytname[] =
+void checkdup(Node *vl, Cell *cp) /* check if name already in list */
{
- "$end", "error", "$undefined", "FIRSTTOKEN", "PROGRAM", "PASTAT",
- "PASTAT2", "XBEGIN", "XEND", "','", "NL", "'{'", "'('", "'|'", "';'",
- "'/'", "')'", "'}'", "'['", "']'", "ARRAY", "MATCH", "NOTMATCH",
- "MATCHOP", "FINAL", "DOT", "ALL", "CCL", "NCCL", "CHAR", "OR", "STAR",
- "QUEST", "PLUS", "AND", "BOR", "APPEND", "EQ", "GE", "GT", "LE", "LT",
- "NE", "IN", "ARG", "BLTIN", "BREAK", "CLOSE", "CONTINUE", "DELETE",
- "DO", "EXIT", "FOR", "FUNC", "SUB", "GSUB", "IF", "INDEX", "LSUBSTR",
- "MATCHFCN", "NEXT", "NEXTFILE", "ADD", "MINUS", "MULT", "DIVIDE", "MOD",
- "ASSIGN", "ASGNOP", "ADDEQ", "SUBEQ", "MULTEQ", "DIVEQ", "MODEQ",
- "POWEQ", "PRINT", "PRINTF", "SPRINTF", "ELSE", "INTEST", "CONDEXPR",
- "POSTINCR", "PREINCR", "POSTDECR", "PREDECR", "VAR", "IVAR", "VARNF",
- "CALL", "NUMBER", "STRING", "REGEXPR", "'?'", "':'", "GETLINE",
- "SUBSTR", "SPLIT", "RETURN", "WHILE", "CAT", "'+'", "'-'", "'*'", "'%'",
- "UMINUS", "NOT", "POWER", "INCR", "DECR", "INDIRECT", "LASTTOKEN",
- "$accept", "program", "and", "bor", "comma", "do", "else", "for", "@1",
- "@2", "@3", "funcname", "if", "lbrace", "nl", "opt_nl", "opt_pst",
- "opt_simple_stmt", "pas", "pa_pat", "pa_stat", "@4", "pa_stats",
- "patlist", "ppattern", "pattern", "plist", "pplist", "prarg", "print",
- "pst", "rbrace", "re", "reg_expr", "@5", "rparen", "simple_stmt", "st",
- "stmt", "@6", "@7", "@8", "stmtlist", "subop", "term", "var", "varlist",
- "varname", "while", 0
+ char *s = cp->nval;
+ for ( ; vl; vl = vl->nnext) {
+ if (strcmp(s, ((Cell *)(vl->narg[0]))->nval) == 0) {
+ SYNTAX("duplicate argument %s", s);
+ break;
+ }
+ }
+}
+static const short yyexca[] =
+{-1, 0,
+ 1, 28,
+ 8, 28,
+ 9, 28,
+ 12, 28,
+ 13, 28,
+ 16, 28,
+ 46, 28,
+ 47, 28,
+ 49, 28,
+ 55, 28,
+ 56, 28,
+ 57, 28,
+ 59, 28,
+ 61, 28,
+ 79, 28,
+ 87, 28,
+ 88, 28,
+ 89, 28,
+ 90, 28,
+ 91, 28,
+ 92, 28,
+ 96, 28,
+ 98, 28,
+ 99, 28,
+ 102, 28,
+ 103, 28,
+ 106, 28,
+ 109, 28,
+ 110, 28,
+ 111, 28,
+ -2, 0,
+-1, 1,
+ 1, -1,
+ -2, 0,
+-1, 157,
+ 15, 30,
+ -2, 0,
+-1, 176,
+ 14, 0,
+ 24, 0,
+ 39, 0,
+ 40, 0,
+ 41, 0,
+ 42, 0,
+ 43, 0,
+ 44, 0,
+ 45, 0,
+ -2, 63,
+-1, 177,
+ 14, 0,
+ 24, 0,
+ 39, 0,
+ 40, 0,
+ 41, 0,
+ 42, 0,
+ 43, 0,
+ 44, 0,
+ 45, 0,
+ -2, 64,
+-1, 178,
+ 14, 0,
+ 24, 0,
+ 39, 0,
+ 40, 0,
+ 41, 0,
+ 42, 0,
+ 43, 0,
+ 44, 0,
+ 45, 0,
+ -2, 65,
+-1, 179,
+ 14, 0,
+ 24, 0,
+ 39, 0,
+ 40, 0,
+ 41, 0,
+ 42, 0,
+ 43, 0,
+ 44, 0,
+ 45, 0,
+ -2, 66,
+-1, 180,
+ 14, 0,
+ 24, 0,
+ 39, 0,
+ 40, 0,
+ 41, 0,
+ 42, 0,
+ 43, 0,
+ 44, 0,
+ 45, 0,
+ -2, 67,
+-1, 181,
+ 14, 0,
+ 24, 0,
+ 39, 0,
+ 40, 0,
+ 41, 0,
+ 42, 0,
+ 43, 0,
+ 44, 0,
+ 45, 0,
+ -2, 68,
+-1, 183,
+ 14, 0,
+ 24, 0,
+ 39, 0,
+ 40, 0,
+ 41, 0,
+ 42, 0,
+ 43, 0,
+ 44, 0,
+ 45, 0,
+ -2, 70,
+-1, 289,
+ 24, 0,
+ 45, 0,
+ -2, 53,
+-1, 334,
+ 17, 30,
+ -2, 0,
+-1, 356,
+ 17, 30,
+ -2, 0,
};
-#endif
-
-# ifdef YYPRINT
-/* YYTOKNUM[YYLEX-NUM] -- Internal token number corresponding to
- token YYLEX-NUM. */
-static const unsigned short yytoknum[] =
+#define YYNPROD 185
+#define YYPRIVATE 57344
+#define YYLAST 4442
+static const short yyact[] =
{
- 0, 256, 257, 258, 259, 260, 261, 262, 263, 44,
- 264, 123, 40, 124, 59, 47, 41, 125, 91, 93,
- 265, 266, 267, 268, 269, 270, 271, 272, 273, 274,
- 275, 276, 277, 278, 279, 280, 281, 282, 283, 284,
- 285, 286, 287, 288, 289, 290, 291, 292, 293, 294,
- 295, 296, 297, 298, 299, 300, 301, 302, 303, 304,
- 305, 306, 307, 308, 309, 310, 311, 312, 313, 314,
- 315, 316, 317, 318, 319, 320, 321, 322, 323, 324,
- 325, 326, 327, 328, 329, 330, 331, 332, 333, 334,
- 335, 336, 63, 58, 337, 338, 339, 340, 341, 342,
- 43, 45, 42, 37, 343, 344, 345, 346, 347, 348,
- 349
+ 17, 140, 66, 228, 200, 105, 43, 62, 277, 10,
+ 125, 24, 11, 43, 253, 135, 100, 112, 51, 141,
+ 79, 80, 308, 243, 100, 185, 100, 100, 100, 103,
+ 104, 100, 122, 123, 124, 215, 82, 249, 54, 83,
+ 102, 107, 43, 107, 253, 223, 9, 42, 22, 44,
+ 43, 113, 314, 252, 42, 22, 44, 206, 11, 143,
+ 253, 147, 103, 104, 244, 150, 151, 153, 154, 278,
+ 113, 23, 136, 163, 353, 100, 190, 276, 23, 103,
+ 104, 190, 336, 42, 156, 44, 190, 324, 136, 352,
+ 134, 42, 22, 44, 190, 316, 43, 133, 85, 351,
+ 100, 149, 321, 258, 320, 182, 269, 100, 100, 100,
+ 100, 100, 100, 100, 232, 23, 86, 190, 168, 169,
+ 275, 318, 332, 278, 203, 205, 100, 108, 109, 110,
+ 111, 110, 111, 112, 211, 112, 170, 42, 233, 44,
+ 190, 234, 212, 190, 190, 217, 284, 100, 221, 265,
+ 260, 190, 167, 100, 226, 190, 3, 259, 219, 158,
+ 230, 188, 136, 100, 6, 137, 137, 236, 6, 7,
+ 142, 310, 100, 7, 100, 157, 100, 100, 100, 100,
+ 100, 100, 100, 131, 100, 21, 251, 100, 100, 130,
+ 48, 129, 128, 16, 100, 49, 127, 126, 120, 119,
+ 52, 16, 100, 190, 312, 137, 274, 100, 218, 100,
+ 100, 100, 144, 4, 100, 100, 155, 271, 145, 132,
+ 317, 348, 50, 55, 362, 270, 365, 162, 1, 72,
+ 40, 224, 100, 100, 100, 100, 163, 5, 163, 163,
+ 163, 163, 20, 58, 163, 67, 100, 222, 61, 292,
+ 60, 19, 288, 248, 293, 100, 100, 294, 96, 166,
+ 81, 238, 8, 159, 160, 2, 114, 0, 116, 117,
+ 118, 0, 0, 121, 300, 301, 0, 115, 139, 239,
+ 184, 0, 0, 100, 0, 148, 100, 100, 100, 313,
+ 100, 309, 100, 0, 0, 136, 0, 100, 0, 100,
+ 100, 0, 0, 100, 0, 100, 100, 100, 0, 307,
+ 0, 0, 0, 0, 0, 165, 163, 96, 0, 0,
+ 335, 0, 0, 0, 164, 339, 334, 342, 0, 343,
+ 136, 0, 0, 0, 100, 341, 0, 230, 347, 100,
+ 0, 100, 116, 229, 0, 100, 100, 0, 0, 96,
+ 194, 195, 196, 197, 198, 199, 357, 360, 139, 230,
+ 361, 0, 356, 0, 0, 0, 136, 0, 207, 220,
+ 363, 0, 0, 139, 0, 0, 0, 0, 349, 227,
+ 0, 238, 0, 0, 238, 238, 238, 0, 238, 96,
+ 238, 0, 139, 139, 0, 96, 0, 0, 0, 239,
+ 0, 257, 239, 239, 239, 242, 239, 0, 239, 0,
+ 0, 0, 0, 0, 96, 0, 96, 0, 96, 96,
+ 96, 96, 96, 96, 96, 0, 96, 290, 0, 96,
+ 96, 0, 0, 0, 0, 0, 256, 238, 297, 0,
+ 0, 0, 0, 0, 96, 0, 273, 0, 0, 261,
+ 303, 96, 96, 96, 0, 239, 96, 96, 0, 0,
+ 0, 0, 311, 282, 0, 285, 286, 287, 289, 0,
+ 0, 291, 0, 0, 96, 279, 280, 281, 165, 0,
+ 165, 165, 165, 165, 0, 0, 165, 164, 96, 164,
+ 164, 164, 164, 0, 0, 164, 0, 96, 96, 0,
+ 337, 0, 0, 0, 0, 74, 0, 189, 191, 0,
+ 15, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 106, 242, 0, 0, 242, 242,
+ 242, 139, 242, 0, 242, 0, 0, 0, 0, 96,
+ 0, 96, 96, 338, 0, 96, 0, 96, 96, 96,
+ 0, 0, 0, 0, 0, 0, 15, 0, 165, 0,
+ 0, 0, 235, 0, 0, 146, 0, 164, 0, 0,
+ 0, 152, 358, 139, 0, 0, 96, 0, 0, 0,
+ 0, 242, 0, 96, 0, 0, 364, 96, 96, 366,
+ 171, 173, 175, 176, 177, 178, 179, 180, 181, 183,
+ 0, 0, 0, 0, 0, 0, 0, 186, 187, 0,
+ 262, 263, 264, 0, 266, 267, 268, 0, 0, 201,
+ 0, 0, 0, 0, 0, 201, 201, 0, 0, 0,
+ 0, 0, 208, 209, 210, 201, 213, 214, 189, 0,
+ 0, 15, 0, 0, 0, 0, 190, 0, 101, 95,
+ 295, 0, 330, 0, 0, 0, 0, 0, 0, 93,
+ 0, 0, 0, 0, 231, 0, 0, 106, 0, 0,
+ 0, 98, 97, 245, 87, 88, 89, 90, 91, 92,
+ 94, 43, 28, 0, 30, 0, 0, 0, 0, 0,
+ 0, 46, 47, 0, 34, 254, 35, 255, 0, 0,
+ 0, 0, 0, 0, 0, 323, 326, 328, 329, 0,
+ 0, 0, 0, 0, 38, 189, 0, 0, 0, 0,
+ 0, 0, 42, 22, 44, 29, 36, 39, 0, 84,
+ 0, 33, 0, 37, 41, 0, 0, 27, 26, 0,
+ 0, 99, 0, 0, 31, 32, 23, 0, 0, 0,
+ 201, 0, 0, 0, 0, 0, 296, 0, 0, 0,
+ 0, 0, 0, 298, 0, 0, 0, 0, 299, 302,
+ 0, 0, 304, 305, 306, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 106,
+ 0, 0, 0, 0, 0, 75, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 16, 18, 0, 68, 45,
+ 0, 359, 0, 0, 0, 333, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 340,
+ 0, 0, 0, 0, 0, 344, 0, 0, 345, 43,
+ 28, 56, 30, 57, 73, 69, 59, 70, 0, 46,
+ 47, 71, 34, 0, 35, 63, 64, 0, 0, 0,
+ 0, 0, 0, 0, 0, 75, 0, 0, 0, 0,
+ 77, 78, 38, 53, 0, 16, 18, 0, 68, 45,
+ 42, 22, 44, 29, 36, 39, 0, 0, 0, 33,
+ 65, 37, 41, 76, 0, 27, 26, 0, 0, 25,
+ 0, 0, 31, 32, 23, 0, 0, 0, 0, 43,
+ 28, 56, 30, 57, 73, 69, 59, 70, 0, 46,
+ 47, 71, 34, 0, 35, 63, 64, 0, 0, 0,
+ 0, 0, 0, 75, 0, 0, 0, 0, 0, 0,
+ 77, 78, 38, 16, 18, 0, 68, 45, 0, 331,
+ 42, 22, 44, 29, 36, 39, 0, 0, 0, 33,
+ 65, 37, 41, 76, 0, 27, 26, 0, 0, 25,
+ 0, 0, 31, 32, 23, 0, 0, 43, 28, 56,
+ 30, 57, 73, 69, 59, 70, 0, 46, 47, 71,
+ 34, 0, 35, 63, 64, 0, 0, 0, 0, 0,
+ 0, 0, 0, 75, 0, 0, 0, 0, 77, 78,
+ 38, 272, 0, 16, 18, 0, 68, 45, 42, 22,
+ 44, 29, 36, 39, 0, 0, 0, 33, 65, 37,
+ 41, 76, 0, 27, 26, 0, 0, 25, 0, 0,
+ 31, 32, 23, 0, 0, 0, 0, 43, 28, 56,
+ 30, 57, 73, 69, 59, 70, 0, 46, 47, 71,
+ 34, 0, 35, 63, 64, 0, 0, 0, 0, 0,
+ 0, 75, 0, 0, 0, 0, 0, 0, 77, 78,
+ 38, 16, 18, 0, 68, 45, 0, 247, 42, 22,
+ 44, 29, 36, 39, 0, 0, 0, 33, 65, 37,
+ 41, 76, 0, 27, 26, 0, 0, 25, 0, 0,
+ 31, 32, 23, 0, 0, 43, 28, 56, 30, 57,
+ 73, 69, 59, 70, 0, 46, 47, 71, 34, 0,
+ 35, 63, 64, 0, 0, 0, 0, 0, 0, 75,
+ 0, 0, 0, 0, 0, 0, 77, 78, 38, 16,
+ 18, 0, 68, 45, 0, 246, 42, 22, 44, 29,
+ 36, 39, 0, 0, 0, 33, 65, 37, 41, 76,
+ 0, 27, 26, 0, 0, 25, 0, 0, 31, 32,
+ 23, 0, 0, 43, 28, 56, 30, 57, 73, 69,
+ 59, 70, 0, 46, 47, 71, 34, 0, 35, 63,
+ 64, 0, 0, 0, 0, 0, 0, 75, 0, 0,
+ 0, 0, 0, 0, 77, 78, 38, 16, 18, 0,
+ 68, 45, 0, 225, 42, 22, 44, 29, 36, 39,
+ 0, 0, 0, 33, 65, 37, 41, 76, 0, 27,
+ 26, 0, 0, 25, 0, 0, 31, 32, 23, 0,
+ 0, 43, 28, 56, 30, 57, 73, 69, 59, 70,
+ 0, 46, 47, 71, 34, 0, 35, 63, 64, 0,
+ 0, 0, 0, 0, 0, 75, 0, 0, 0, 0,
+ 0, 0, 77, 78, 38, 16, 18, 0, 68, 45,
+ 0, 216, 42, 22, 44, 29, 36, 39, 0, 0,
+ 0, 33, 65, 37, 41, 76, 0, 27, 26, 0,
+ 0, 25, 0, 0, 31, 32, 23, 0, 0, 43,
+ 28, 56, 30, 57, 73, 69, 59, 70, 0, 46,
+ 47, 71, 34, 0, 35, 63, 64, 0, 0, 0,
+ 0, 0, 0, 75, 0, 0, 0, 0, 0, 0,
+ 77, 78, 38, 16, 18, 0, 68, 45, 0, 138,
+ 42, 22, 44, 29, 36, 39, 0, 0, 0, 33,
+ 65, 37, 41, 76, 0, 27, 26, 0, 0, 25,
+ 0, 0, 31, 32, 23, 0, 0, 43, 28, 56,
+ 30, 57, 73, 69, 59, 70, 0, 46, 47, 71,
+ 34, 0, 35, 63, 64, 0, 0, 0, 0, 0,
+ 0, 75, 0, 0, 0, 0, 0, 0, 77, 78,
+ 38, 16, 18, 0, 68, 45, 0, 0, 42, 22,
+ 44, 29, 36, 39, 0, 0, 0, 33, 65, 37,
+ 41, 76, 0, 27, 26, 0, 0, 25, 0, 0,
+ 31, 32, 23, 0, 0, 43, 28, 56, 30, 57,
+ 73, 69, 59, 70, 0, 46, 47, 71, 34, 0,
+ 35, 63, 64, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 77, 78, 38, 0,
+ 0, 0, 0, 0, 0, 0, 42, 22, 44, 29,
+ 36, 39, 0, 0, 0, 33, 65, 37, 41, 76,
+ 0, 27, 26, 0, 0, 25, 0, 0, 31, 32,
+ 23, 190, 0, 101, 95, 0, 0, 327, 0, 0,
+ 0, 0, 0, 0, 93, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 98, 97, 0, 87,
+ 88, 89, 90, 91, 92, 94, 43, 28, 0, 30,
+ 0, 0, 0, 0, 0, 0, 46, 47, 0, 34,
+ 0, 35, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 38,
+ 0, 0, 0, 0, 0, 0, 0, 42, 22, 44,
+ 29, 36, 39, 0, 84, 0, 33, 0, 37, 41,
+ 0, 0, 27, 26, 0, 0, 99, 0, 0, 31,
+ 32, 23, 190, 0, 101, 95, 0, 0, 325, 0,
+ 0, 0, 0, 0, 0, 93, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 98, 97, 0,
+ 87, 88, 89, 90, 91, 92, 94, 43, 28, 0,
+ 30, 0, 0, 0, 0, 0, 0, 46, 47, 0,
+ 34, 0, 35, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 38, 0, 0, 0, 0, 0, 0, 0, 42, 22,
+ 44, 29, 36, 39, 0, 84, 0, 33, 0, 37,
+ 41, 0, 0, 27, 26, 0, 0, 99, 0, 0,
+ 31, 32, 23, 137, 0, 0, 101, 95, 142, 0,
+ 0, 0, 0, 0, 0, 0, 0, 93, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 98,
+ 97, 0, 87, 88, 89, 90, 91, 92, 94, 43,
+ 28, 0, 30, 0, 0, 0, 0, 0, 0, 46,
+ 47, 0, 34, 0, 35, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 38, 0, 0, 0, 0, 0, 0, 0,
+ 42, 22, 44, 29, 36, 39, 0, 84, 0, 33,
+ 0, 37, 41, 0, 0, 27, 26, 0, 0, 99,
+ 0, 0, 31, 32, 23, 190, 0, 101, 95, 0,
+ 0, 192, 0, 0, 0, 0, 0, 0, 93, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 98, 97, 0, 87, 88, 89, 90, 91, 92, 94,
+ 43, 28, 0, 30, 0, 0, 0, 0, 0, 0,
+ 46, 47, 0, 34, 0, 35, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 38, 0, 0, 0, 0, 0, 0,
+ 0, 42, 22, 44, 29, 36, 39, 0, 84, 0,
+ 33, 0, 37, 41, 0, 0, 27, 26, 101, 95,
+ 99, 0, 355, 31, 32, 23, 0, 0, 0, 93,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 98, 97, 0, 87, 88, 89, 90, 91, 92,
+ 94, 43, 28, 0, 30, 0, 0, 0, 0, 0,
+ 0, 46, 47, 0, 34, 0, 35, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 38, 0, 0, 0, 0, 0,
+ 0, 0, 42, 22, 44, 29, 36, 39, 0, 84,
+ 0, 33, 0, 37, 41, 0, 0, 27, 26, 101,
+ 95, 99, 0, 354, 31, 32, 23, 0, 0, 0,
+ 93, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 98, 97, 0, 87, 88, 89, 90, 91,
+ 92, 94, 43, 28, 0, 30, 0, 0, 0, 0,
+ 0, 0, 46, 47, 0, 34, 0, 35, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 38, 0, 0, 0, 0,
+ 0, 0, 0, 42, 22, 44, 29, 36, 39, 0,
+ 84, 0, 33, 0, 37, 41, 0, 0, 27, 26,
+ 101, 95, 99, 0, 350, 31, 32, 23, 0, 0,
+ 0, 93, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 98, 97, 0, 87, 88, 89, 90,
+ 91, 92, 94, 43, 28, 0, 30, 0, 0, 0,
+ 0, 0, 0, 46, 47, 0, 34, 0, 35, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 38, 0, 0, 0,
+ 0, 0, 0, 0, 42, 22, 44, 29, 36, 39,
+ 0, 84, 0, 33, 0, 37, 41, 0, 0, 27,
+ 26, 0, 0, 99, 0, 0, 31, 32, 23, 101,
+ 95, 346, 0, 0, 0, 0, 0, 0, 0, 0,
+ 93, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 98, 97, 0, 87, 88, 89, 90, 91,
+ 92, 94, 43, 28, 0, 30, 0, 0, 0, 0,
+ 0, 0, 46, 47, 0, 34, 0, 35, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 38, 0, 0, 0, 0,
+ 0, 0, 0, 42, 22, 44, 29, 36, 39, 0,
+ 84, 0, 33, 0, 37, 41, 0, 0, 27, 26,
+ 101, 95, 99, 0, 322, 31, 32, 23, 0, 0,
+ 0, 93, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 98, 97, 0, 87, 88, 89, 90,
+ 91, 92, 94, 43, 28, 0, 30, 0, 0, 0,
+ 0, 0, 0, 46, 47, 0, 34, 0, 35, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 38, 0, 0, 0,
+ 0, 0, 0, 0, 42, 22, 44, 29, 36, 39,
+ 0, 84, 0, 33, 0, 37, 41, 0, 0, 27,
+ 26, 101, 95, 99, 0, 319, 31, 32, 23, 0,
+ 0, 0, 93, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 98, 97, 0, 87, 88, 89,
+ 90, 91, 92, 94, 43, 28, 0, 30, 0, 0,
+ 0, 0, 0, 0, 46, 47, 0, 34, 0, 35,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 38, 0, 0,
+ 0, 0, 0, 0, 0, 42, 22, 44, 29, 36,
+ 39, 0, 84, 0, 33, 0, 37, 41, 0, 0,
+ 27, 26, 101, 95, 99, 0, 278, 31, 32, 23,
+ 0, 0, 0, 93, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 98, 97, 0, 87, 88,
+ 89, 90, 91, 92, 94, 43, 28, 0, 30, 0,
+ 0, 0, 0, 0, 0, 46, 47, 0, 34, 0,
+ 35, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 38, 0,
+ 0, 0, 0, 0, 0, 0, 42, 22, 44, 29,
+ 36, 39, 0, 84, 0, 33, 0, 37, 41, 0,
+ 0, 27, 26, 0, 190, 99, 101, 95, 31, 32,
+ 23, 0, 0, 0, 0, 0, 0, 93, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 98,
+ 97, 0, 87, 88, 89, 90, 91, 92, 94, 43,
+ 28, 0, 30, 0, 0, 0, 0, 0, 0, 46,
+ 47, 0, 34, 0, 35, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 38, 0, 0, 0, 0, 0, 0, 0,
+ 42, 22, 44, 29, 36, 39, 0, 84, 0, 33,
+ 0, 37, 41, 0, 0, 27, 26, 101, 95, 99,
+ 0, 192, 31, 32, 23, 0, 0, 0, 93, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 98, 97, 0, 87, 88, 89, 90, 91, 92, 94,
+ 43, 28, 0, 30, 0, 0, 0, 0, 0, 0,
+ 46, 47, 0, 34, 0, 35, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 38, 0, 0, 0, 0, 0, 0,
+ 0, 42, 22, 44, 29, 36, 39, 0, 84, 0,
+ 33, 0, 37, 41, 0, 0, 27, 26, 101, 95,
+ 99, 0, 0, 31, 32, 23, 0, 0, 0, 93,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 98, 97, 0, 87, 88, 89, 90, 91, 92,
+ 94, 43, 28, 0, 30, 0, 0, 0, 0, 0,
+ 0, 46, 47, 0, 34, 0, 35, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 38, 0, 0, 0, 0, 0,
+ 0, 0, 42, 22, 44, 29, 36, 39, 0, 84,
+ 250, 33, 0, 37, 41, 0, 0, 27, 26, 101,
+ 95, 99, 0, 0, 31, 32, 23, 0, 0, 0,
+ 93, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 98, 97, 0, 87, 88, 89, 90, 91,
+ 92, 94, 43, 28, 0, 30, 0, 0, 0, 0,
+ 0, 0, 46, 47, 0, 34, 0, 35, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 38, 0, 0, 0, 0,
+ 0, 0, 0, 42, 22, 44, 29, 36, 39, 0,
+ 84, 0, 33, 0, 37, 41, 0, 0, 27, 26,
+ 101, 95, 99, 0, 0, 31, 32, 23, 0, 0,
+ 0, 93, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 98, 0, 0, 87, 88, 89, 90,
+ 91, 92, 94, 43, 28, 0, 30, 0, 0, 0,
+ 0, 0, 0, 46, 47, 0, 34, 0, 35, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 38, 0, 0, 0,
+ 0, 0, 0, 0, 42, 22, 44, 29, 36, 39,
+ 101, 95, 0, 33, 0, 37, 41, 0, 0, 27,
+ 26, 93, 0, 99, 0, 0, 31, 32, 23, 0,
+ 0, 0, 0, 0, 0, 0, 87, 88, 89, 90,
+ 91, 92, 94, 43, 28, 0, 30, 0, 0, 0,
+ 0, 0, 0, 46, 47, 0, 34, 0, 35, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 38, 0, 0, 0,
+ 0, 101, 0, 0, 42, 22, 44, 29, 36, 39,
+ 0, 0, 240, 33, 0, 37, 41, 0, 0, 27,
+ 26, 0, 0, 99, 98, 97, 31, 32, 23, 0,
+ 0, 0, 0, 241, 43, 28, 0, 30, 0, 0,
+ 0, 0, 0, 0, 46, 47, 0, 34, 0, 35,
+ 0, 0, 0, 0, 0, 0, 0, 75, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 38, 18, 0,
+ 0, 45, 0, 0, 0, 42, 22, 44, 29, 36,
+ 39, 0, 237, 315, 33, 0, 37, 41, 0, 0,
+ 27, 26, 0, 0, 99, 0, 0, 31, 32, 23,
+ 0, 43, 28, 0, 30, 0, 73, 0, 0, 0,
+ 0, 46, 47, 0, 34, 0, 35, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 77, 78, 38, 0, 0, 0, 0, 101,
+ 0, 0, 42, 22, 44, 29, 36, 39, 0, 0,
+ 240, 33, 0, 37, 41, 0, 0, 27, 26, 0,
+ 0, 25, 98, 97, 31, 32, 23, 0, 0, 0,
+ 0, 241, 43, 28, 0, 30, 0, 0, 0, 0,
+ 0, 0, 46, 47, 0, 34, 0, 35, 0, 0,
+ 0, 0, 12, 13, 0, 0, 16, 18, 0, 0,
+ 45, 0, 0, 0, 0, 38, 0, 0, 0, 0,
+ 0, 0, 0, 42, 22, 44, 29, 36, 39, 0,
+ 237, 0, 33, 0, 37, 41, 0, 0, 27, 26,
+ 43, 28, 99, 30, 0, 31, 32, 23, 0, 14,
+ 46, 47, 0, 34, 0, 35, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 38, 0, 0, 101, 0, 0, 0,
+ 0, 42, 22, 44, 29, 36, 39, 240, 0, 0,
+ 33, 0, 37, 41, 0, 0, 27, 26, 0, 98,
+ 25, 0, 0, 31, 32, 23, 0, 0, 241, 43,
+ 28, 0, 30, 0, 0, 0, 0, 0, 0, 46,
+ 47, 0, 34, 0, 35, 0, 0, 0, 0, 0,
+ 0, 137, 0, 0, 18, 0, 142, 45, 0, 0,
+ 0, 0, 38, 0, 0, 0, 0, 0, 0, 0,
+ 42, 22, 44, 29, 36, 39, 0, 0, 0, 33,
+ 0, 37, 41, 0, 0, 27, 26, 43, 28, 99,
+ 30, 0, 31, 32, 23, 0, 0, 46, 47, 0,
+ 34, 0, 35, 0, 0, 0, 0, 0, 0, 253,
+ 0, 0, 18, 0, 0, 45, 0, 0, 0, 0,
+ 38, 0, 0, 0, 0, 0, 0, 0, 42, 22,
+ 44, 29, 36, 39, 0, 0, 0, 33, 0, 37,
+ 41, 0, 0, 27, 26, 43, 28, 25, 30, 0,
+ 31, 32, 23, 0, 0, 46, 47, 0, 34, 0,
+ 35, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 38, 0,
+ 0, 101, 0, 0, 0, 0, 42, 22, 44, 29,
+ 36, 39, 240, 0, 0, 33, 0, 37, 41, 0,
+ 0, 27, 26, 0, 0, 25, 0, 0, 31, 32,
+ 23, 0, 0, 241, 43, 28, 0, 30, 0, 0,
+ 0, 0, 0, 0, 46, 47, 0, 34, 0, 35,
+ 0, 0, 0, 0, 0, 0, 174, 0, 0, 283,
+ 0, 0, 45, 0, 0, 0, 0, 38, 0, 0,
+ 0, 0, 0, 0, 0, 42, 22, 44, 29, 36,
+ 39, 0, 0, 0, 33, 0, 37, 41, 0, 0,
+ 27, 26, 43, 28, 99, 30, 0, 31, 32, 23,
+ 0, 0, 46, 47, 0, 34, 0, 35, 0, 0,
+ 0, 0, 0, 0, 172, 0, 0, 283, 0, 0,
+ 45, 0, 0, 0, 0, 38, 0, 0, 0, 0,
+ 0, 0, 0, 42, 22, 44, 29, 36, 39, 0,
+ 0, 0, 33, 0, 37, 41, 0, 0, 27, 26,
+ 43, 28, 25, 30, 0, 31, 32, 23, 0, 0,
+ 46, 47, 0, 34, 0, 35, 0, 0, 0, 0,
+ 0, 0, 253, 0, 0, 283, 0, 0, 45, 0,
+ 0, 0, 0, 38, 0, 0, 0, 0, 0, 0,
+ 0, 42, 22, 44, 29, 36, 39, 0, 0, 0,
+ 33, 0, 37, 41, 0, 0, 27, 26, 43, 28,
+ 25, 30, 0, 31, 32, 23, 0, 0, 46, 47,
+ 0, 34, 0, 35, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 18, 0, 0, 45, 204, 0, 0,
+ 0, 38, 0, 0, 0, 0, 0, 0, 0, 42,
+ 22, 44, 29, 36, 39, 0, 0, 0, 33, 0,
+ 37, 41, 0, 0, 27, 26, 43, 28, 25, 30,
+ 0, 31, 32, 23, 0, 0, 46, 47, 0, 34,
+ 0, 35, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 18, 0, 0, 45, 202, 0, 0, 0, 38,
+ 0, 0, 0, 0, 0, 0, 0, 42, 22, 44,
+ 29, 36, 39, 0, 0, 0, 33, 0, 37, 41,
+ 0, 0, 27, 26, 43, 28, 25, 30, 0, 31,
+ 32, 23, 0, 0, 46, 47, 0, 34, 0, 35,
+ 0, 0, 0, 0, 0, 0, 174, 0, 0, 18,
+ 0, 0, 45, 0, 0, 0, 0, 38, 0, 0,
+ 0, 0, 0, 0, 0, 42, 22, 44, 29, 36,
+ 39, 0, 0, 0, 33, 0, 37, 41, 0, 0,
+ 27, 26, 43, 28, 25, 30, 0, 31, 32, 23,
+ 0, 0, 46, 47, 0, 34, 0, 35, 0, 0,
+ 0, 0, 0, 0, 172, 0, 0, 18, 0, 0,
+ 45, 0, 0, 0, 0, 38, 0, 0, 0, 0,
+ 0, 0, 0, 42, 22, 44, 29, 36, 39, 0,
+ 0, 0, 33, 0, 37, 41, 0, 0, 27, 26,
+ 43, 28, 25, 30, 0, 31, 32, 23, 0, 0,
+ 46, 47, 0, 34, 0, 35, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 18, 0, 0, 45, 0,
+ 0, 0, 0, 38, 0, 0, 0, 0, 0, 0,
+ 0, 42, 22, 44, 29, 36, 39, 0, 0, 0,
+ 33, 0, 37, 41, 0, 0, 27, 26, 43, 28,
+ 25, 30, 0, 31, 32, 23, 0, 0, 46, 47,
+ 0, 34, 0, 35, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 283, 0, 0, 45, 0, 0, 0,
+ 0, 38, 0, 0, 0, 0, 0, 0, 0, 42,
+ 22, 44, 29, 36, 39, 0, 0, 0, 33, 0,
+ 37, 41, 0, 0, 27, 26, 43, 28, 25, 30,
+ 0, 31, 32, 23, 0, 0, 46, 47, 0, 34,
+ 0, 35, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 101, 0, 0, 0, 0, 0, 0, 0, 38,
+ 0, 0, 0, 0, 0, 0, 0, 42, 22, 44,
+ 29, 36, 39, 0, 0, 0, 33, 0, 37, 41,
+ 0, 0, 27, 26, 43, 28, 25, 30, 0, 31,
+ 32, 23, 0, 0, 46, 47, 0, 34, 0, 35,
+ 0, 0, 0, 0, 0, 0, 0, 0, 193, 161,
+ 0, 0, 45, 0, 0, 0, 0, 38, 0, 0,
+ 0, 0, 0, 0, 0, 42, 22, 44, 29, 36,
+ 39, 0, 0, 0, 33, 0, 37, 41, 0, 0,
+ 27, 26, 43, 28, 99, 30, 0, 31, 32, 23,
+ 0, 0, 46, 47, 0, 34, 0, 35, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 101, 0, 0,
+ 45, 0, 0, 0, 0, 38, 0, 0, 0, 0,
+ 0, 0, 0, 42, 22, 44, 29, 36, 39, 0,
+ 0, 0, 33, 0, 37, 41, 0, 0, 27, 26,
+ 43, 28, 25, 30, 0, 31, 32, 23, 0, 0,
+ 46, 47, 0, 34, 0, 35, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 101, 0, 0, 0, 0,
+ 0, 0, 0, 38, 0, 0, 0, 0, 0, 0,
+ 0, 42, 22, 44, 29, 36, 39, 0, 0, 0,
+ 33, 0, 37, 41, 0, 0, 27, 26, 43, 28,
+ 25, 30, 0, 31, 32, 23, 0, 0, 46, 47,
+ 0, 34, 0, 35, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 101, 0, 0, 0, 0, 0, 0,
+ 0, 38, 0, 0, 0, 0, 0, 0, 0, 42,
+ 22, 44, 29, 36, 39, 0, 0, 0, 33, 0,
+ 37, 41, 0, 0, 27, 26, 43, 28, 99, 30,
+ 0, 31, 32, 23, 0, 0, 46, 47, 0, 34,
+ 0, 35, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 38,
+ 0, 0, 0, 0, 0, 0, 0, 42, 22, 44,
+ 29, 36, 39, 0, 0, 0, 0, 0, 37, 41,
+ 0, 0, 27, 26, 0, 0, 99, 0, 0, 31,
+ 32, 23
};
-# endif
-
-/* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */
-static const unsigned char yyr1[] =
+static const short yypact[] =
{
- 0, 111, 112, 112, 113, 113, 114, 114, 115, 115,
- 116, 116, 117, 117, 119, 118, 120, 118, 121, 118,
- 122, 122, 123, 124, 124, 125, 125, 126, 126, 127,
- 127, 128, 128, 129, 129, 130, 131, 131, 131, 131,
- 131, 131, 131, 132, 131, 133, 133, 134, 134, 135,
- 135, 135, 135, 135, 135, 135, 135, 135, 135, 135,
- 136, 136, 136, 136, 136, 136, 136, 136, 136, 136,
- 136, 136, 136, 136, 136, 136, 136, 136, 136, 137,
- 137, 138, 138, 139, 139, 139, 140, 140, 141, 141,
- 141, 141, 142, 142, 143, 143, 145, 144, 146, 146,
- 147, 147, 147, 147, 147, 147, 147, 147, 148, 148,
- 149, 149, 150, 151, 149, 149, 149, 149, 149, 149,
- 149, 149, 149, 149, 149, 149, 152, 149, 149, 153,
- 153, 154, 154, 155, 155, 155, 155, 155, 155, 155,
- 155, 155, 155, 155, 155, 155, 155, 155, 155, 155,
- 155, 155, 155, 155, 155, 155, 155, 155, 155, 155,
- 155, 155, 155, 155, 155, 155, 155, 155, 155, 155,
- 155, 155, 155, 155, 155, 156, 156, 156, 156, 157,
- 157, 157, 158, 158, 158, 159
+ 154,-1000,-1000,-1000,3264, 180,-1000,-1000, 158,-1000,
+ 189, 863, 181, 181, -51,2826,-1000, -30,3982,-1000,
+ 25, 51,-1000,4272,-1000,4214,4272,4272, 186, 185,
+4272, -40, -40, -33, 184, 183,-1000, 179, 178,-1000,
+ 176, 170,-1000,-1000,-1000,-1000,-1000,-1000,-1000,-1000,
+3264, 863, 195,-1000,1341,-1000, 155, 155, 202,3391,
+-1000,1409, 863, 155, 155,3391, 155,-1000, 195,-1000,
+ 162, 146,4156, -4,2826,-1000, 139,-1000,-1000, 863,
+ 863, 123,-1000,-1000,3982,3924,3866,3982,3982,3982,
+3982,3982,3982,3982, -4, -71, 25,-1000,-1000,4272,
+ -80,3982,3982,-1000,-1000, 144,1814,4098,4272,4272,
+4272,4272,4272,3982,-1000,-1000, -91, -91, -91,3808,
+3750, 25,-1000,-1000, 14,4272,3982,3982,3982,3982,
+3982,3982, -58,-1000,1273,3982, 198,-1000,-1000,-1000,
+-1000, 198, 195,-1000,-1000,1409,1713,-1000, -35,1205,
+-1000,-1000,1713,-1000,-1000,1409,-1000,3135,3982, 100,
+ 192,3982,3206, -47,-1000, 25, 45,3982,1137,1069,
+ -50,2735,-1000,2917,-1000,2997,4330,4330,4330,4330,
+4330,4330,-1000,4330,-1000, -40,2644,2826, 8,3449,
+-1000,3449,-1000,4272, -91, 27, 27, -91, -91, -91,
+ 83,2826,-1000, 140,-1000, 133,4272, 25,2553,2553,
+2553, 132, 192,2553,2553, 90,-1000, 181,-1000,-1000,
+-1000,-1000,1001,-1000, 196,-1000,-1000,-1000, 105, 32,
+-1000,2459,4272,4272,4272,3692, 129,4040,3634,3576,
+4040, -4, 25,4040,3982,2459,-1000,-1000, 106,-1000,
+3982,-1000, -4,-1000,2826,2826, 25,3449,-1000,-1000,
+-1000, 25,3449,3449, 50,-1000,3449,3449,3449,-1000,
+ 863, -78,-1000,-1000,-1000, 156, -4, 194,-1000, 25,
+ 25, 25,3206,3982, 7,3068,3333,3518,-1000,4330,
+-1000,3206, 75, 194, 194, 34,2826,-1000,2826,2368,
+ 87, 85,2277, 70,1611,1510, 635, 931, 109,3982,
+ 195, 52,-1000, 65, -4,4040,-1000, 181,-1000,-1000,
+-1000,-1000,-1000,3449,-1000,-1000, 4,-1000, 4,3449,
+-1000,-1000,3982,2186,3135, 194, 7,-1000,3206, 863,
+2087, 82, 72, 57,1996,1905, 195, 52,1409, 793,
+-1000,-1000,-1000,-1000,-1000, 155,3135, 194,-1000,-1000,
+-1000, 52,1409, 194,-1000,1409,-1000
};
-
-/* YYR2[YYN] -- Number of symbols composing right hand side of rule YYN. */
-static const unsigned char yyr2[] =
+static const short yypgo[] =
{
- 0, 2, 1, 1, 1, 2, 1, 2, 1, 2,
- 1, 2, 1, 2, 0, 12, 0, 10, 0, 8,
- 1, 1, 4, 1, 2, 1, 2, 0, 1, 0,
- 1, 0, 1, 1, 3, 1, 1, 4, 3, 6,
- 3, 4, 4, 0, 9, 1, 3, 1, 3, 3,
- 5, 3, 3, 3, 3, 3, 5, 2, 1, 1,
- 3, 5, 3, 3, 3, 3, 3, 3, 3, 3,
- 3, 3, 3, 5, 4, 3, 2, 1, 1, 3,
- 3, 1, 3, 0, 1, 3, 1, 1, 1, 1,
- 2, 2, 1, 2, 1, 2, 0, 4, 1, 2,
- 4, 4, 4, 2, 5, 2, 1, 1, 1, 2,
- 2, 2, 0, 0, 9, 3, 2, 1, 4, 2,
- 3, 2, 2, 3, 2, 2, 0, 3, 2, 1,
- 2, 1, 1, 4, 3, 3, 3, 3, 3, 3,
- 2, 2, 2, 3, 4, 1, 3, 4, 2, 2,
- 2, 2, 2, 4, 3, 2, 1, 6, 6, 3,
- 6, 6, 1, 8, 8, 6, 4, 1, 6, 6,
- 8, 8, 8, 6, 1, 1, 4, 1, 2, 0,
- 1, 3, 1, 1, 1, 4
+ 0, 265, 505, 227, 5, 264, 4, 263, 242, 251,
+ 9, 46, 262, 11, 2, 3, 223, 38, 0, 185,
+ 260, 253, 250, 248, 247, 245, 243, 1, 237, 213,
+ 7, 231, 8, 401, 19, 15, 116, 98, 230, 229,
+ 228, 226, 224, 221, 220, 219, 218, 217, 216
};
-
-/* YYDEFACT[STATE-NAME] -- Default rule to reduce with in state
- STATE-NUM when YYTABLE doesn't specify something else to do. Zero
- means the default is an error. */
-static const unsigned char yydefact[] =
+static const short yyr1[] =
{
- 0, 3, 88, 89, 0, 33, 2, 30, 1, 0,
- 0, 23, 0, 96, 183, 145, 0, 0, 131, 132,
- 0, 0, 0, 182, 177, 184, 0, 162, 167, 156,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 36,
- 45, 29, 35, 77, 94, 0, 78, 174, 175, 90,
- 91, 0, 0, 0, 0, 0, 0, 0, 0, 148,
- 174, 20, 21, 0, 0, 0, 0, 0, 0, 155,
- 0, 0, 141, 140, 95, 142, 150, 149, 178, 107,
- 24, 27, 0, 0, 0, 10, 0, 0, 0, 0,
- 0, 86, 87, 0, 0, 112, 117, 0, 0, 106,
- 83, 0, 129, 0, 126, 0, 0, 34, 0, 0,
- 4, 6, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 76, 0, 0, 0, 0, 0, 0, 0,
- 0, 152, 151, 0, 0, 0, 8, 159, 0, 0,
- 0, 0, 143, 0, 47, 0, 179, 0, 0, 0,
- 146, 0, 154, 0, 0, 0, 25, 28, 128, 27,
- 108, 110, 111, 105, 0, 116, 0, 0, 121, 122,
- 0, 124, 0, 11, 0, 119, 0, 0, 81, 84,
- 103, 58, 59, 174, 125, 40, 130, 0, 38, 0,
- 46, 75, 71, 70, 64, 65, 66, 67, 68, 69,
- 72, 0, 5, 63, 7, 62, 0, 94, 0, 137,
- 134, 135, 136, 138, 139, 60, 0, 41, 42, 9,
- 79, 0, 80, 97, 144, 0, 180, 0, 0, 0,
- 166, 147, 153, 0, 0, 26, 109, 0, 115, 0,
- 32, 175, 0, 123, 0, 113, 12, 0, 92, 120,
- 0, 0, 0, 0, 0, 0, 57, 0, 0, 0,
- 0, 0, 127, 0, 37, 74, 0, 0, 0, 133,
- 176, 73, 48, 98, 0, 43, 0, 94, 0, 94,
- 0, 0, 0, 27, 0, 22, 185, 0, 13, 118,
- 93, 85, 0, 54, 53, 55, 0, 52, 51, 82,
- 100, 101, 102, 49, 0, 61, 0, 0, 181, 99,
- 0, 157, 158, 161, 160, 173, 0, 165, 0, 104,
- 27, 0, 0, 0, 0, 0, 0, 39, 169, 0,
- 168, 0, 0, 0, 0, 94, 0, 0, 18, 0,
- 56, 0, 50, 0, 0, 0, 172, 163, 164, 0,
- 27, 0, 0, 171, 170, 44, 16, 0, 19, 0,
- 0, 0, 114, 17, 14, 0, 15
+ 0, 40, 40, 36, 36, 37, 37, 33, 33, 26,
+ 26, 24, 24, 41, 22, 42, 22, 43, 22, 20,
+ 20, 23, 30, 30, 34, 34, 35, 35, 29, 29,
+ 15, 15, 1, 1, 10, 11, 11, 11, 11, 11,
+ 11, 11, 44, 11, 12, 12, 6, 6, 3, 3,
+ 3, 3, 3, 3, 3, 3, 3, 3, 3, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 4, 4,
+ 5, 5, 7, 7, 7, 39, 39, 28, 28, 28,
+ 28, 31, 31, 9, 9, 45, 13, 32, 32, 14,
+ 14, 14, 14, 14, 14, 14, 14, 27, 27, 16,
+ 16, 46, 47, 16, 16, 16, 16, 16, 16, 16,
+ 16, 16, 16, 16, 16, 48, 16, 16, 17, 17,
+ 38, 38, 8, 8, 8, 8, 8, 8, 8, 8,
+ 8, 8, 8, 8, 8, 8, 8, 8, 8, 8,
+ 8, 8, 8, 8, 8, 8, 8, 8, 8, 8,
+ 8, 8, 8, 8, 8, 8, 8, 8, 8, 8,
+ 8, 8, 8, 8, 18, 18, 18, 18, 21, 21,
+ 21, 19, 19, 19, 25
};
-
-/* YYDEFGOTO[NTERM-NUM]. */
-static const short yydefgoto[] =
+static const short yyr2[] =
{
- -1, 4, 120, 121, 225, 95, 247, 96, 365, 360,
- 351, 63, 97, 98, 160, 158, 5, 239, 6, 39,
- 40, 310, 41, 143, 178, 99, 54, 179, 180, 100,
- 7, 249, 43, 44, 55, 275, 101, 161, 102, 174,
- 287, 187, 103, 45, 46, 47, 227, 48, 104
+ 0, 1, 1, 1, 2, 1, 2, 1, 2, 1,
+ 2, 1, 2, 0, 12, 0, 10, 0, 8, 1,
+ 1, 4, 1, 2, 1, 2, 0, 1, 0, 1,
+ 0, 1, 1, 3, 1, 1, 4, 4, 7, 3,
+ 4, 4, 0, 9, 1, 3, 1, 3, 3, 5,
+ 3, 3, 3, 3, 3, 5, 2, 1, 1, 3,
+ 5, 3, 3, 3, 3, 3, 3, 3, 3, 3,
+ 3, 3, 5, 4, 3, 2, 1, 1, 3, 3,
+ 1, 3, 0, 1, 3, 1, 1, 1, 1, 2,
+ 2, 1, 2, 1, 2, 0, 4, 1, 2, 4,
+ 4, 4, 2, 5, 2, 1, 1, 1, 2, 2,
+ 2, 0, 0, 9, 3, 2, 1, 4, 2, 3,
+ 2, 2, 3, 2, 2, 0, 3, 2, 1, 2,
+ 1, 1, 4, 3, 3, 3, 3, 3, 3, 2,
+ 2, 2, 3, 4, 1, 3, 4, 2, 2, 2,
+ 2, 2, 4, 3, 2, 1, 6, 6, 3, 6,
+ 6, 1, 8, 8, 6, 4, 1, 6, 6, 8,
+ 8, 8, 6, 1, 1, 4, 1, 2, 0, 1,
+ 3, 1, 1, 1, 4
};
-
-/* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing
- STATE-NUM. */
-#define YYPACT_NINF -323
-static const short yypact[] =
+static const short yychk[] =
{
- 680, -323, -323, -323, 34, 1573, -323, 106, -323, 29,
- 29, -323, 4106, -323, -323, 41, 4460, -73, -323, -323,
- 44, 92, 105, -323, -323, -323, 113, -323, -323, -11,
- 121, 131, 4460, 4460, 4165, 255, 255, 4460, 812, 94,
- -323, 174, 3436, -323, -323, 132, 130, -61, 30, -323,
- -323, 812, 812, 1663, 53, 64, 3929, 4106, 4460, 130,
- -21, -323, -323, 159, 4106, 4106, 4106, 3988, 4460, 65,
- 4106, 4106, 60, 60, -323, 60, -323, -323, -323, -323,
- -323, 162, 188, 188, 7, -323, 2182, 161, 196, 188,
- 188, -323, -323, 2182, 199, 176, -323, 1416, 812, 3436,
- 4224, 188, -323, 879, -323, 4106, 812, 1573, 118, 4106,
- -323, -323, 4106, 4106, 4106, 4106, 4106, 4106, 7, 4106,
- 2241, 2300, 130, 4106, 4283, 4460, 4460, 4460, 4460, 4460,
- 4106, -323, -323, 4106, 946, 1013, -323, -323, 2359, 157,
- 2359, 202, -323, 61, 3436, 2626, 133, 2023, 2023, 62,
- -323, 81, 130, 4460, 2023, 2023, -323, 214, -323, 162,
- 214, -323, -323, 209, 2123, -323, 1482, 4106, -323, -323,
- 2123, -323, 4106, -323, 1416, 156, 1080, 4106, 3811, 237,
- 83, -323, 130, -41, -323, -323, -323, 1416, 29, 1147,
- -323, 255, 3684, -323, 3684, 3684, 3684, 3684, 3684, 3684,
- -323, 2716, -323, 3605, -323, 3526, 2023, 237, 4460, 60,
- 58, 58, 60, 60, 60, 3436, 22, -323, -323, -323,
- 3436, 7, 3436, -323, -323, 2359, -323, 98, 2359, 2359,
- -323, -323, 130, 2359, 55, -323, -323, 4106, -323, 233,
- -323, -7, 2806, -323, 2806, -323, -323, 1215, -323, 238,
- 140, 4342, 7, 4342, 2418, 2477, 130, 2536, 4460, 4460,
- 4460, 4342, -323, 812, -323, -323, 4106, 2359, 2359, 130,
- -323, -323, 3436, -323, -5, 242, 2896, 239, 2986, 241,
- 1753, 149, 36, 191, 7, 242, 242, 163, -323, -323,
- -323, 225, 4106, 4401, -323, -323, 3743, 4047, 3870, 3811,
- 130, 130, 130, 3811, 1282, 3436, 1843, 1933, -323, -323,
- 29, -323, -323, -323, -323, -323, 2359, -323, 2359, -323,
- 162, 4106, 256, 259, 7, 154, 4342, -323, -323, 15,
- -323, 15, 812, 3076, 3166, 258, 1548, 3256, 242, 4106,
- -323, 225, 3811, 260, 262, 1349, -323, -323, -323, 256,
- 162, 1416, 3346, -323, -323, -323, 242, 1548, -323, 188,
- 1416, 256, -323, -323, 242, 1416, -323
+-1000, -40, -1, 2, -29, -28, 10, 15, -12, -11,
+ -10, -30, 8, 9, 55, -2, 12, -18, 13, -9,
+ -8, -19, 88, 111, -13, 106, 103, 102, 47, 90,
+ 49, 109, 110, 96, 59, 61, 91, 98, 79, 92,
+ -38, 99, 87, 46, 89, 16, 56, 57, 10, 15,
+ -29, -30, 11, 10, -17, -16, 48, 50, -26, 53,
+ -22, -23, -30, 62, 63, 97, -14, -25, 15, 52,
+ 54, 58, -39, 51, -2, 2, 100, 77, 78, -30,
+ -30, -20, 87, 90, 94, -37, -36, 39, 40, 41,
+ 42, 43, 44, 24, 45, 14, -8, 37, 36, 106,
+ -18, 13, 70, 109, 110, -4, -2, 16, 102, 103,
+ 104, 105, 108, 19, -8, -9, -8, -8, -8, 13,
+ 13, -8, -18, -18, -18, 43, 13, 13, 13, 13,
+ 13, 13, -45, -11, -17, -35, -34, 10, 18, -16,
+ -27, -34, 15, -27, 10, -46, -2, -27, -16, -17,
+ -27, -27, -2, -27, -27, -48, -35, 13, 13, -7,
+ -5, 13, -3, -18, -9, -8, -19, 13, -17, -17,
+ 13, -2, 10, -2, 10, -2, -2, -2, -2, -2,
+ -2, -2, -13, -2, -19, 96, -2, -2, 17, -33,
+ 11, -33, 17, 70, -8, -8, -8, -8, -8, -8,
+ -6, -2, 17, -6, 17, -6, 43, -8, -2, -2,
+ -2, -6, -13, -2, -2, 93, 18, -10, 10, -35,
+ -16, -27, -24, 80, -31, 18, -27, -16, -15, -19,
+ -14, -2, 14, 38, 41, -33, -4, 94, -37, -36,
+ 24, 45, -8, 70, 19, -2, 18, 18, -21, 87,
+ 95, -18, 45, 10, -2, -2, -8, -33, 20, 17,
+ 17, -8, -33, -33, -33, 17, -33, -33, -33, 16,
+ -30, -47, 10, -16, 10, 15, 45, -32, 17, -8,
+ -8, -8, -3, 13, 17, -3, -3, -3, -13, -3,
+ -19, -3, -6, -32, -32, -33, -2, -19, -2, -2,
+ -13, -13, -2, -19, -2, -2, -2, -17, 100, -35,
+ 15, -19, 10, -4, 45, 95, 20, -44, 87, 17,
+ 17, 17, 17, -33, 17, 17, -33, 17, -33, -33,
+ 17, 18, 13, -2, -35, -32, 17, -19, -3, -30,
+ -2, -13, -18, -18, -2, -2, 15, -15, -43, -17,
+ 17, 17, 17, 17, 17, 17, -35, -32, -16, 18,
+ -27, -15, -42, -32, -16, -41, -16
};
-
-/* YYPGOTO[NTERM-NUM]. */
-static const short yypgoto[] =
+static const short yydef[] =
{
- -323, -323, -146, -83, 200, -323, -323, -323, -323, -323,
- -323, -323, -323, 19, -80, -153, 234, -322, -323, 179,
- 172, -323, -323, -44, 12, 526, -174, -323, -323, -323,
- -323, -323, -32, -60, -323, -234, -162, -29, -53, -323,
- -323, -323, -13, -323, 269, -16, -323, -75, -323
+ -2, -2, 1, 2, 32, 29, 87, 88, 28, 44,
+ 35, 0, 0, 0, 0, 34, 22, 173, 0, 76,
+ 77, 174, 176, 0, 93, 0, 0, 0, 144, 0,
+ 0, 0, 0, 155, 0, 0, 161, 0, 0, 166,
+ 0, 0, 181, 182, 183, 95, 130, 131, 89, 90,
+ 33, 0, 26, 23, 0, 128, 0, 0, 111, 0,
+ 116, 0, 0, 0, 0, 0, 0, 125, 26, 9,
+ 0, 0, 82, 0, 105, 106, 0, 85, 86, 0,
+ 0, 0, 19, 20, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 75, 5, 3, 0,
+ 173, 0, 0, 150, 151, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 177, 94, 141, 139, 140, 0,
+ 0, 147, 148, 149, 154, 0, 0, 0, 0, 0,
+ 0, 0, 0, 45, 0, 0, 27, 24, 39, 129,
+ 109, 107, 26, 110, 10, 0, 0, 115, 118, 0,
+ 120, 121, 0, 123, 124, 0, 127, -2, 0, 102,
+ 83, 0, 80, 173, 57, 58, 104, 0, 0, 0,
+ 178, 0, 6, 61, 4, 62, -2, -2, -2, -2,
+ -2, -2, 69, -2, 71, 74, 0, 59, 0, 0,
+ 7, 0, 158, 0, 136, 133, 134, 135, 137, 138,
+ 0, 46, 142, 0, 145, 0, 0, 153, 0, 0,
+ 0, 0, 93, 0, 0, 0, 36, 37, 25, 108,
+ 112, 114, 0, 11, 119, 91, 122, 126, 0, 174,
+ 31, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 56, 0, 0, 0, 40, 41, 0, 179,
+ 0, 73, 0, 8, 79, 78, 132, 0, 175, 143,
+ 146, 152, 0, 0, 0, 165, 0, 0, 0, 96,
+ 0, 0, 12, 117, 92, 26, 0, 21, 97, 99,
+ 100, 101, 81, 0, 84, 0, 50, 51, 52, -2,
+ 54, 48, 0, 184, 42, 0, 60, 72, 47, 0,
+ 93, 93, 0, 0, 0, 0, 0, 0, 0, 0,
+ 26, 0, 98, 0, 0, 0, 103, 0, 180, 156,
+ 157, 159, 160, 0, 164, 167, 0, 168, 0, 0,
+ 172, 38, 0, 0, -2, 17, 0, 55, 49, 0,
+ 0, 93, 0, 0, 0, 0, 26, 0, 0, 0,
+ 162, 163, 169, 170, 171, 0, -2, 15, 18, 43,
+ 113, 0, 0, 13, 16, 0, 14
};
-
-/* YYTABLE[YYPACT[STATE-NUM]]. What to do in state STATE-NUM. If
- positive, shift that token. If negative, reduce the rule which
- number is the opposite. If zero, do what YYDEFACT says.
- If YYTABLE_NINF, syntax error. */
-#define YYTABLE_NINF -32
-static const short yytable[] =
+static const short yytok1[] =
{
- 60, 157, 74, 250, 240, 219, 236, 130, 285, 163,
- 286, 133, 61, 69, 349, 62, 60, 60, 60, 76,
- 77, 60, 149, 151, 38, 219, 60, 261, 51, 52,
- 68, 136, 254, 14, 8, 361, 284, 60, 134, 135,
- 11, 270, 60, 200, 175, 136, 131, 132, 133, 193,
- 186, 14, 60, 56, 162, 319, 64, 165, 106, 14,
- 168, 169, 136, 207, 171, 219, 131, 132, 181, 139,
- 136, 136, 184, 124, 23, 24, 25, 224, 230, 157,
- 308, 186, 186, 60, 183, 176, 131, 132, 338, 216,
- 136, 241, 23, 189, 25, 255, 258, 231, 37, 14,
- 23, 24, 25, 105, 65, 11, 153, 136, 60, 60,
- 60, 60, 60, 60, 273, 356, 49, 66, 325, 259,
- 50, 245, 260, 186, 37, 67, 38, 364, 60, 60,
- 321, 60, 60, 70, 262, 238, 186, 60, 60, 60,
- 23, 243, 25, 71, 123, 124, 271, 254, 60, 136,
- 254, 254, 254, 254, 60, 141, 291, 254, 136, 281,
- 127, 128, 60, 136, 129, 317, 129, 336, 277, 279,
- 341, 146, 156, 166, 240, 265, 60, 295, 60, 60,
- 60, 60, 60, 60, 2, 60, 173, 60, 3, 60,
- 60, 294, 60, 282, 289, 240, 254, 357, 156, 60,
- 221, 156, 159, 157, 60, 320, 60, 263, 167, 322,
- 255, 172, 191, 255, 255, 255, 255, 223, 226, 181,
- 255, 181, 181, 181, 235, 181, 60, 237, 60, 181,
- 125, 126, 127, 128, 246, 183, 129, 183, 183, 183,
- 157, 183, 60, 60, 60, 183, 136, 283, 290, 340,
- 304, 186, 309, 138, 140, 312, 60, 314, 335, 255,
- 60, 323, 60, 293, 60, 296, 297, 298, 324, 299,
- 157, 339, 273, 303, 348, 107, 353, 60, 354, 190,
- 60, 60, 60, 60, 188, 59, 0, 60, 0, 60,
- 60, 60, 186, 0, 181, 0, 0, 0, 358, 14,
- 0, 72, 73, 75, 0, 0, 78, 363, 0, 0,
- 183, 122, 366, 343, 0, 344, 0, 60, 60, 345,
- 0, 60, 122, 0, 0, 0, 60, 75, 0, 332,
- 362, 0, 0, 0, 0, 0, 60, 152, 342, 0,
- 23, 24, 25, 0, 0, 0, 0, 228, 229, 0,
- 0, 0, 0, 0, 233, 234, 0, 0, 0, 0,
- 0, 0, 0, 0, 37, 0, 0, 0, 122, 182,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 257,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 209, 210, 211, 212, 213, 214, 0,
- 0, 0, 0, 0, 0, 0, 267, 268, 0, 0,
- 0, 0, 0, 122, 122, 0, 122, 122, 0, 0,
- 0, 0, 232, 122, 122, 0, 0, 274, 0, 0,
- 0, 0, 0, 122, 0, 0, 0, 0, 0, 122,
- 0, 0, 0, 0, 0, 0, 0, 256, 0, 0,
- 140, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 122, 0, 122, 122, 122, 122, 122, 122, 0,
- 122, 0, 122, 0, 122, 122, 0, 269, 0, 0,
- 316, 318, 0, 0, 122, 0, 0, 0, 0, 122,
- 0, 122, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 329, 331, 0, 0,
- 0, 122, 0, 122, 0, 0, 0, 0, 0, 0,
- 182, 0, 182, 182, 182, 140, 182, 300, 301, 302,
- 182, 42, 0, 0, 0, 0, 0, 0, 53, 0,
- 0, 122, 0, 0, 0, 122, 0, 122, 0, 122,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 256, 0, 0, 256, 256, 256, 256, 0,
- 0, 0, 256, 0, 122, 122, 122, 0, 0, 0,
- 0, 0, 144, 145, 0, 0, 0, 0, 0, 0,
- 147, 148, 144, 144, 0, 182, 154, 155, 0, 0,
- 0, 0, 122, 122, 0, 0, 122, 0, 0, 0,
- 0, 256, 164, 0, 0, 0, 0, 0, 0, 170,
- 0, 122, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 42, 0, 42, 0, 192, 0, 0, 194, 195,
- 196, 197, 198, 199, 0, 201, 203, 205, 0, 206,
- 0, 0, 0, 0, 0, 0, 215, 0, 0, 144,
- 0, 0, 0, 0, 220, 0, 222, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- -29, 1, 0, 0, 0, 0, 0, -29, -29, 0,
- 2, -29, -29, 242, 3, -29, 0, 0, 244, 0,
- 0, 0, 0, 53, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, -29, -29, 0, -29, 0, 0,
- 0, 0, 0, -29, -29, -29, 0, -29, 0, -29,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 272, 0, 0, 276, 278, 0, -29, 0, 280,
- 0, 0, 0, 144, 0, -29, -29, -29, -29, -29,
- -29, 0, 0, 0, -29, -29, -29, 0, 0, 0,
- -29, -29, 0, 0, 0, -29, 0, -29, -29, -29,
- 0, 0, 305, 306, 307, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 79, 0, 0, 0, 0, 53, 0,
- 0, 0, 80, 11, 12, 0, 81, 13, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 333, 0, 334, 0, 0, 337, 0, 0,
- 0, 0, 0, 0, 0, 0, 14, 15, 82, 16,
- 83, 84, 85, 86, 87, 352, 18, 19, 88, 20,
- 0, 21, 89, 90, 0, 0, 0, 0, 0, 0,
- 79, 0, 0, 0, 0, 0, 0, 91, 92, 22,
- 11, 12, 0, 81, 13, 0, 185, 23, 24, 25,
- 26, 27, 28, 0, 0, 0, 29, 30, 31, 93,
- 94, 0, 32, 33, 0, 0, 0, 34, 0, 35,
- 36, 37, 0, 14, 15, 82, 16, 83, 84, 85,
- 86, 87, 0, 18, 19, 88, 20, 0, 21, 89,
- 90, 0, 0, 0, 0, 0, 0, 79, 0, 0,
- 0, 0, 0, 0, 91, 92, 22, 11, 12, 0,
- 81, 13, 0, 217, 23, 24, 25, 26, 27, 28,
- 0, 0, 0, 29, 30, 31, 93, 94, 0, 32,
- 33, 0, 0, 0, 34, 0, 35, 36, 37, 0,
- 14, 15, 82, 16, 83, 84, 85, 86, 87, 0,
- 18, 19, 88, 20, 0, 21, 89, 90, 0, 0,
- 0, 0, 0, 0, 79, 0, 0, 0, 0, 0,
- 0, 91, 92, 22, 11, 12, 0, 81, 13, 0,
- 218, 23, 24, 25, 26, 27, 28, 0, 0, 0,
- 29, 30, 31, 93, 94, 0, 32, 33, 0, 0,
- 0, 34, 0, 35, 36, 37, 0, 14, 15, 82,
- 16, 83, 84, 85, 86, 87, 0, 18, 19, 88,
- 20, 0, 21, 89, 90, 0, 0, 0, 0, 0,
- 0, 79, 0, 0, 0, 0, 0, 0, 91, 92,
- 22, 11, 12, 0, 81, 13, 0, 248, 23, 24,
- 25, 26, 27, 28, 0, 0, 0, 29, 30, 31,
- 93, 94, 0, 32, 33, 0, 0, 0, 34, 0,
- 35, 36, 37, 0, 14, 15, 82, 16, 83, 84,
- 85, 86, 87, 0, 18, 19, 88, 20, 0, 21,
- 89, 90, 0, 0, 0, 0, 0, 0, 79, 0,
- 0, 0, 0, 0, 0, 91, 92, 22, 11, 12,
- 0, 81, 13, 0, 264, 23, 24, 25, 26, 27,
- 28, 0, 0, 0, 29, 30, 31, 93, 94, 0,
- 32, 33, 0, 0, 0, 34, 0, 35, 36, 37,
- 0, 14, 15, 82, 16, 83, 84, 85, 86, 87,
- 0, 18, 19, 88, 20, 0, 21, 89, 90, 0,
- 0, 0, 0, 0, 0, 0, 79, 0, 0, 0,
- 0, 0, 91, 92, 22, 288, 11, 12, 0, 81,
- 13, 0, 23, 24, 25, 26, 27, 28, 0, 0,
- 0, 29, 30, 31, 93, 94, 0, 32, 33, 0,
- 0, 0, 34, 0, 35, 36, 37, 0, 0, 14,
- 15, 82, 16, 83, 84, 85, 86, 87, 0, 18,
- 19, 88, 20, 0, 21, 89, 90, 0, 0, 0,
- 0, 0, 0, 79, 0, 0, 0, 0, 0, 0,
- 91, 92, 22, 11, 12, 0, 81, 13, 0, 327,
- 23, 24, 25, 26, 27, 28, 0, 0, 0, 29,
- 30, 31, 93, 94, 0, 32, 33, 0, 0, 0,
- 34, 0, 35, 36, 37, 0, 14, 15, 82, 16,
- 83, 84, 85, 86, 87, 0, 18, 19, 88, 20,
- 0, 21, 89, 90, 0, 0, 0, 0, 0, 0,
- 79, 0, 0, 0, 0, 0, 0, 91, 92, 22,
- 11, 12, 0, 81, 13, 0, 355, 23, 24, 25,
- 26, 27, 28, 0, 0, 0, 29, 30, 31, 93,
- 94, 0, 32, 33, 0, 0, 0, 34, 0, 35,
- 36, 37, 0, 14, 15, 82, 16, 83, 84, 85,
- 86, 87, 0, 18, 19, 88, 20, 0, 21, 89,
- 90, 0, 0, 0, 0, 0, 0, 79, 0, 0,
- 0, 0, 0, 0, 91, 92, 22, 11, 12, 0,
- 81, 13, 0, 0, 23, 24, 25, 26, 27, 28,
- 0, 0, 0, 29, 30, 31, 93, 94, 0, 32,
- 33, 0, 0, 0, 34, 0, 35, 36, 37, 0,
- 14, 15, 82, 16, 83, 84, 85, 86, 87, 0,
- 18, 19, 88, 20, 0, 21, 89, 90, 0, 0,
- 0, 0, 0, 79, 0, 0, 0, 0, 0, 0,
- 0, 91, 92, 22, 12, 0, -31, 13, 0, 0,
- 0, 23, 24, 25, 26, 27, 28, 0, 0, 0,
- 29, 30, 31, 93, 94, 0, 32, 33, 0, 0,
- 0, 34, 0, 35, 36, 37, 14, 15, 0, 16,
- 0, 84, 0, 0, 0, 0, 18, 19, 0, 20,
- 0, 21, 0, 0, 0, 0, 0, 0, 0, 79,
- 0, 0, 0, 0, 0, 0, 0, 91, 92, 22,
- 12, 0, 0, 13, -31, 0, 0, 23, 24, 25,
- 26, 27, 28, 0, 0, 0, 29, 30, 31, 0,
- 9, 10, 32, 33, 11, 12, 0, 34, 13, 35,
- 36, 37, 14, 15, 0, 16, 0, 84, 0, 0,
- 0, 0, 18, 19, 0, 20, 0, 21, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 14, 15, 0,
- 16, 0, 0, 91, 92, 22, 17, 18, 19, 0,
- 20, 0, 21, 23, 24, 25, 26, 27, 28, 0,
- 0, 0, 29, 30, 31, 0, 0, 0, 32, 33,
- 22, 0, 0, 34, 0, 35, 36, 37, 23, 24,
- 25, 26, 27, 28, 0, 0, 0, 29, 30, 31,
- 0, 0, 136, 32, 33, 57, 108, 0, 34, 137,
- 35, 36, 37, 0, 0, 0, 109, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 110, 111, 0,
- 112, 113, 114, 115, 116, 117, 118, 14, 15, 0,
- 16, 0, 0, 0, 0, 0, 0, 18, 19, 0,
- 20, 0, 21, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 22, 0, 0, 0, 0, 0, 0, 0, 23, 24,
- 25, 26, 27, 28, 0, 119, 0, 29, 30, 31,
- 0, 0, 136, 32, 33, 57, 108, 0, 58, 315,
- 35, 36, 37, 0, 0, 0, 109, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 110, 111, 0,
- 112, 113, 114, 115, 116, 117, 118, 14, 15, 0,
- 16, 0, 0, 0, 0, 0, 0, 18, 19, 0,
- 20, 0, 21, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 22, 0, 0, 0, 0, 0, 0, 0, 23, 24,
- 25, 26, 27, 28, 0, 119, 0, 29, 30, 31,
- 0, 0, 136, 32, 33, 57, 108, 0, 58, 328,
- 35, 36, 37, 0, 0, 0, 109, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 110, 111, 0,
- 112, 113, 114, 115, 116, 117, 118, 14, 15, 0,
- 16, 0, 0, 0, 0, 0, 0, 18, 19, 0,
- 20, 0, 21, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 22, 0, 0, 0, 0, 0, 0, 0, 23, 24,
- 25, 26, 27, 28, 0, 119, 0, 29, 30, 31,
- 0, 0, 136, 32, 33, 57, 108, 0, 58, 330,
- 35, 36, 37, 0, 0, 0, 109, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 110, 111, 0,
- 112, 113, 114, 115, 116, 117, 118, 14, 15, 0,
- 16, 0, 0, 0, 0, 0, 0, 18, 19, 0,
- 20, 0, 21, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 22, 0, 0, 0, 0, 0, 0, 0, 23, 24,
- 25, 26, 27, 28, 0, 119, 0, 29, 30, 31,
- 0, 0, 136, 32, 33, 57, 108, 0, 58, 0,
- 35, 36, 37, 0, 0, 0, 109, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 110, 111, 0,
- 112, 113, 114, 115, 116, 117, 118, 14, 15, 0,
- 16, 0, 0, 0, 0, 0, 0, 18, 19, 0,
- 20, 0, 21, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 22, 0, 0, 0, 0, 0, 0, 0, 23, 24,
- 25, 26, 27, 28, 0, 119, 0, 29, 30, 31,
- 0, 0, 0, 32, 33, 0, 0, 0, 58, 0,
- 35, 36, 37, 156, 0, 57, 108, 159, 0, 0,
- 0, 0, 0, 0, 0, 0, 109, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 110, 111, 0,
- 112, 113, 114, 115, 116, 117, 118, 14, 15, 0,
- 16, 0, 0, 0, 0, 0, 0, 18, 19, 0,
- 20, 0, 21, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 156, 0, 12, 0, 159, 13, 0, 0,
- 22, 0, 0, 0, 0, 0, 0, 0, 23, 24,
- 25, 26, 27, 28, 0, 119, 0, 29, 30, 31,
- 0, 0, 0, 32, 33, 0, 14, 15, 58, 16,
- 35, 36, 37, 0, 0, 0, 18, 19, 0, 20,
- 0, 21, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 202, 0, 12, 0, 0, 13, 0, 0, 22,
- 0, 0, 0, 0, 0, 0, 0, 23, 24, 25,
- 26, 27, 28, 0, 0, 0, 29, 30, 31, 0,
- 0, 0, 32, 33, 0, 14, 15, 34, 16, 35,
- 36, 37, 0, 0, 0, 18, 19, 0, 20, 0,
- 21, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 204, 0, 12, 0, 0, 13, 0, 0, 22, 0,
- 0, 0, 0, 0, 0, 0, 23, 24, 25, 26,
- 27, 28, 0, 0, 0, 29, 30, 31, 0, 0,
- 0, 32, 33, 0, 14, 15, 34, 16, 35, 36,
- 37, 0, 0, 0, 18, 19, 0, 20, 0, 21,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 219,
- 0, 12, 0, 0, 13, 0, 0, 22, 0, 0,
- 0, 0, 0, 0, 0, 23, 24, 25, 26, 27,
- 28, 0, 0, 0, 29, 30, 31, 0, 0, 0,
- 32, 33, 0, 14, 15, 34, 16, 35, 36, 37,
- 0, 0, 0, 18, 19, 0, 20, 0, 21, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 202, 0,
- 292, 0, 0, 13, 0, 0, 22, 0, 0, 0,
- 0, 0, 0, 0, 23, 24, 25, 26, 27, 28,
- 0, 0, 0, 29, 30, 31, 0, 0, 0, 32,
- 33, 0, 14, 15, 34, 16, 35, 36, 37, 0,
- 0, 0, 18, 19, 0, 20, 0, 21, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 204, 0, 292,
- 0, 0, 13, 0, 0, 22, 0, 0, 0, 0,
- 0, 0, 0, 23, 24, 25, 26, 27, 28, 0,
- 0, 0, 29, 30, 31, 0, 0, 0, 32, 33,
- 0, 14, 15, 34, 16, 35, 36, 37, 0, 0,
- 0, 18, 19, 0, 20, 0, 21, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 219, 0, 292, 0,
- 0, 13, 0, 0, 22, 0, 0, 0, 0, 0,
- 0, 0, 23, 24, 25, 26, 27, 28, 0, 0,
- 0, 29, 30, 31, 0, 0, 0, 32, 33, 0,
- 14, 15, 34, 16, 35, 36, 37, 0, 0, 0,
- 18, 19, 0, 20, 0, 21, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 22, 0, 0, 0, 0, 0, 0,
- 0, 23, 24, 25, 26, 27, 28, 0, 0, 0,
- 29, 30, 31, 0, 0, 0, 32, 33, 57, 108,
- 0, 34, 137, 35, 36, 37, 0, 0, 0, 109,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 110, 111, 0, 112, 113, 114, 115, 116, 117, 118,
- 14, 15, 0, 16, 0, 0, 0, 0, 0, 0,
- 18, 19, 0, 20, 0, 21, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 22, 0, 0, 0, 0, 0, 0,
- 0, 23, 24, 25, 26, 27, 28, 0, 119, 0,
- 29, 30, 31, 0, 0, 0, 32, 33, 57, 108,
- 0, 58, 0, 35, 36, 37, 0, 0, 0, 109,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 110, 111, 0, 112, 113, 114, 115, 116, 117, 118,
- 14, 15, 0, 16, 0, 0, 0, 0, 0, 0,
- 18, 19, 0, 20, 0, 21, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 22, 0, 0, 0, 0, 0, 0,
- 0, 23, 24, 25, 26, 27, 28, 0, 119, 266,
- 29, 30, 31, 0, 0, 0, 32, 33, 57, 108,
- 0, 58, 273, 35, 36, 37, 0, 0, 0, 109,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 110, 111, 0, 112, 113, 114, 115, 116, 117, 118,
- 14, 15, 0, 16, 0, 0, 0, 0, 0, 0,
- 18, 19, 0, 20, 0, 21, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 22, 0, 0, 0, 0, 0, 0,
- 0, 23, 24, 25, 26, 27, 28, 0, 119, 0,
- 29, 30, 31, 0, 0, 0, 32, 33, 57, 108,
- 0, 58, 311, 35, 36, 37, 0, 0, 0, 109,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 110, 111, 0, 112, 113, 114, 115, 116, 117, 118,
- 14, 15, 0, 16, 0, 0, 0, 0, 0, 0,
- 18, 19, 0, 20, 0, 21, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 22, 0, 0, 0, 0, 0, 0,
- 0, 23, 24, 25, 26, 27, 28, 0, 119, 0,
- 29, 30, 31, 0, 0, 0, 32, 33, 57, 108,
- 0, 58, 313, 35, 36, 37, 0, 0, 0, 109,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 110, 111, 0, 112, 113, 114, 115, 116, 117, 118,
- 14, 15, 0, 16, 0, 0, 0, 0, 0, 0,
- 18, 19, 0, 20, 0, 21, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 22, 0, 0, 0, 0, 0, 0,
- 0, 23, 24, 25, 26, 27, 28, 0, 119, 0,
- 29, 30, 31, 0, 0, 0, 32, 33, 57, 108,
- 0, 58, 346, 35, 36, 37, 0, 0, 0, 109,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 110, 111, 0, 112, 113, 114, 115, 116, 117, 118,
- 14, 15, 0, 16, 0, 0, 0, 0, 0, 0,
- 18, 19, 0, 20, 0, 21, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 22, 0, 0, 0, 0, 0, 0,
- 0, 23, 24, 25, 26, 27, 28, 0, 119, 0,
- 29, 30, 31, 0, 0, 0, 32, 33, 57, 108,
- 0, 58, 347, 35, 36, 37, 0, 0, 0, 109,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 110, 111, 0, 112, 113, 114, 115, 116, 117, 118,
- 14, 15, 0, 16, 0, 0, 0, 0, 0, 0,
- 18, 19, 0, 20, 0, 21, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 22, 0, 0, 0, 0, 0, 0,
- 0, 23, 24, 25, 26, 27, 28, 0, 119, 0,
- 29, 30, 31, 0, 0, 0, 32, 33, 57, 108,
- 350, 58, 0, 35, 36, 37, 0, 0, 0, 109,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 110, 111, 0, 112, 113, 114, 115, 116, 117, 118,
- 14, 15, 0, 16, 0, 0, 0, 0, 0, 0,
- 18, 19, 0, 20, 0, 21, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 22, 0, 0, 0, 0, 0, 0,
- 0, 23, 24, 25, 26, 27, 28, 0, 119, 0,
- 29, 30, 31, 0, 0, 0, 32, 33, 57, 108,
- 0, 58, 359, 35, 36, 37, 0, 0, 0, 109,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 110, 111, 0, 112, 113, 114, 115, 116, 117, 118,
- 14, 15, 0, 16, 0, 0, 0, 0, 0, 0,
- 18, 19, 0, 20, 0, 21, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 22, 0, 0, 0, 0, 0, 0,
- 0, 23, 24, 25, 26, 27, 28, 0, 119, 0,
- 29, 30, 31, 0, 0, 0, 32, 33, 57, 108,
- 0, 58, 0, 35, 36, 37, 0, 0, 0, 109,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 110, 111, 0, 112, 113, 114, 115, 116, 117, 118,
- 14, 15, 0, 16, 0, 0, 0, 0, 0, 0,
- 18, 19, 0, 20, 0, 21, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 22, 0, 0, 0, 0, 0, 0,
- 0, 23, 24, 25, 26, 27, 28, 0, 119, 0,
- 29, 30, 31, 0, 0, 0, 32, 33, 57, 108,
- 0, 58, 0, 35, 36, 37, 0, 0, 0, 109,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 110, 0, 0, 112, 113, 114, 115, 116, 117, 118,
- 14, 15, 0, 16, 0, 0, 0, 0, 0, 0,
- 18, 19, 0, 20, 0, 21, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 22, 0, 0, 0, 0, 0, 0,
- 0, 23, 24, 25, 26, 27, 28, 57, 108, 0,
- 29, 30, 31, 0, 0, 0, 32, 33, 109, 0,
- 0, 58, 0, 35, 36, 37, 0, 0, 0, 0,
- 0, 0, 112, 113, 114, 115, 116, 117, 118, 14,
- 15, 0, 16, 0, 0, 0, 0, 0, 0, 18,
- 19, 0, 20, 0, 21, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 22, 0, 0, 0, 0, 0, 0, 0,
- 23, 24, 25, 26, 27, 28, 57, -32, 0, 29,
- 30, 31, 0, 0, 0, 32, 33, -32, 0, 0,
- 58, 0, 35, 36, 37, 0, 0, 0, 0, 0,
- 0, -32, -32, -32, -32, -32, -32, -32, 14, 15,
- 0, 16, 0, 0, 0, 0, 0, 0, 18, 19,
- 0, 20, 0, 21, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 57, 0, 0, 0, 0,
- 0, 22, 0, 0, 0, 0, 251, 0, 0, 23,
- 24, 25, 26, 27, 28, 0, 0, 110, 111, 30,
- 31, 0, 0, 0, 32, 33, 252, 14, 15, 58,
- 16, 35, 36, 37, 0, 0, 0, 18, 19, 0,
- 20, 0, 21, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 22, 0, 0, 57, 0, 0, 0, 0, 23, 24,
- 25, 26, 27, 28, 251, 253, 326, 29, 30, 31,
- 0, 0, 0, 32, 33, 110, 111, 0, 58, 0,
- 35, 36, 37, 0, 252, 14, 15, 0, 16, 0,
- 0, 0, 0, 0, 0, 18, 19, 0, 20, 0,
- 21, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 57, 0, 0, 0, 0, 0, 22, 0,
- 0, 0, 0, 251, 0, 0, 23, 24, 25, 26,
- 27, 28, 0, 253, 110, 29, 30, 31, 0, 0,
- 0, 32, 33, 252, 14, 15, 58, 16, 35, 36,
- 37, 0, 0, 0, 18, 19, 0, 20, 0, 21,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 12, 0, 0, 13, 142, 0, 22, 0, 0,
- 0, 0, 0, 0, 0, 23, 24, 25, 26, 27,
- 28, 0, 0, 0, 29, 30, 31, 0, 0, 0,
- 32, 33, 0, 14, 15, 58, 16, 35, 36, 37,
- 0, 0, 0, 18, 19, 0, 20, 0, 21, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 12, 0, 0, 13, 150, 0, 22, 0, 0, 0,
- 0, 0, 0, 0, 23, 24, 25, 26, 27, 28,
- 0, 0, 0, 29, 30, 31, 0, 0, 0, 32,
- 33, 0, 14, 15, 34, 16, 35, 36, 37, 0,
- 0, 0, 18, 19, 0, 20, 0, 21, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 57,
- 0, 0, 0, 0, 0, 22, 0, 0, 0, 0,
- 251, 0, 0, 23, 24, 25, 26, 27, 28, 0,
- 0, 0, 29, 30, 31, 0, 0, 0, 32, 33,
- 252, 14, 15, 34, 16, 35, 36, 37, 0, 0,
- 0, 18, 19, 0, 20, 0, 21, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 12, 0,
- 0, 13, 0, 0, 22, 0, 0, 0, 0, 0,
- 0, 0, 23, 24, 25, 26, 27, 28, 0, 0,
- 0, 29, 30, 31, 0, 0, 0, 32, 33, 0,
- 14, 15, 58, 16, 35, 36, 37, 0, 0, 0,
- 18, 19, 0, 20, 0, 21, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 57, 0, 0,
- 13, 0, 0, 22, 0, 0, 0, 0, 0, 0,
- 0, 23, 24, 25, 26, 27, 28, 0, 0, 0,
- 29, 30, 31, 0, 0, 0, 32, 33, 0, 14,
- 15, 34, 16, 35, 36, 37, 0, 0, 0, 18,
- 19, 0, 20, 0, 21, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 177, 0, 0, 13,
- 0, 0, 22, 0, 0, 0, 0, 0, 0, 0,
- 23, 24, 25, 26, 27, 28, 0, 0, 0, 29,
- 30, 31, 0, 0, 0, 32, 33, 0, 14, 15,
- 34, 16, 35, 36, 37, 0, 0, 0, 18, 19,
- 0, 20, 0, 21, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 57, 0, 0, 0, 0,
- 0, 22, 0, 0, 0, 0, 0, 0, 0, 23,
- 24, 25, 26, 27, 28, 0, 0, 0, 29, 30,
- 31, 0, 0, 0, 32, 33, 0, 14, 15, 34,
- 16, 35, 36, 37, 0, 0, 0, 18, 19, 0,
- 20, 0, 21, 0, 0, 0, 0, 0, 0, 0,
- 0, 208, 0, 0, 292, 0, 0, 13, 0, 0,
- 22, 0, 0, 0, 0, 0, 0, 0, 23, 24,
- 25, 26, 27, 28, 0, 0, 0, 29, 30, 31,
- 0, 0, 0, 32, 33, 0, 14, 15, 58, 16,
- 35, 36, 37, 0, 0, 0, 18, 19, 0, 20,
- 0, 21, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 57, 0, 0, 0, 0, 0, 22,
- 0, 0, 0, 0, -32, 0, 0, 23, 24, 25,
- 26, 27, 28, 0, 0, 0, 29, 30, 31, 0,
- 0, 0, 32, 33, -32, 14, 15, 34, 16, 35,
- 36, 37, 0, 0, 0, 18, 19, 0, 20, 0,
- 21, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 57, 0, 0, 0, 0, 0, 22, 0,
- 0, 0, 0, 0, 0, 0, 23, 24, 25, 26,
- 27, 28, 0, 0, 0, 0, 30, 31, 0, 0,
- 0, 32, 33, 0, 14, 15, 58, 16, 35, 36,
- 37, 0, 0, 0, 18, 19, 0, 20, 0, 21,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 22, 0, 0,
- 0, 0, 0, 0, 0, 23, 24, 25, 26, 27,
- 28, 0, 0, 0, 29, 30, 31, 0, 0, 0,
- 32, 33, 0, 0, 0, 58, 0, 35, 36, 37
+ 1, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 105, 0, 0,
+ 13, 17, 104, 102, 11, 103, 0, 16, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 95, 15,
+ 0, 0, 0, 94, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 19, 0, 20, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 12, 14, 18
};
-
-static const short yycheck[] =
+static const short yytok2[] =
{
- 16, 81, 34, 177, 166, 10, 159, 68, 242, 84,
- 244, 18, 85, 29, 336, 88, 32, 33, 34, 35,
- 36, 37, 66, 67, 5, 10, 42, 68, 9, 10,
- 41, 9, 178, 44, 0, 357, 43, 53, 51, 52,
- 11, 19, 58, 118, 97, 9, 107, 108, 18, 109,
- 103, 44, 68, 12, 83, 19, 12, 86, 39, 44,
- 89, 90, 9, 123, 93, 10, 107, 108, 100, 16,
- 9, 9, 101, 15, 85, 86, 87, 16, 16, 159,
- 85, 134, 135, 99, 100, 98, 107, 108, 322, 133,
- 9, 166, 85, 106, 87, 178, 13, 16, 109, 44,
- 85, 86, 87, 9, 12, 11, 41, 9, 124, 125,
- 126, 127, 128, 129, 16, 349, 10, 12, 292, 36,
- 14, 174, 39, 176, 109, 12, 107, 361, 144, 145,
- 283, 147, 148, 12, 187, 164, 189, 153, 154, 155,
- 85, 170, 87, 12, 12, 15, 221, 293, 164, 9,
- 296, 297, 298, 299, 170, 91, 16, 303, 9, 234,
- 102, 103, 178, 9, 106, 16, 106, 320, 228, 229,
- 16, 12, 10, 12, 336, 191, 192, 252, 194, 195,
- 196, 197, 198, 199, 10, 201, 10, 203, 14, 205,
- 206, 251, 208, 237, 247, 357, 342, 350, 10, 215,
- 43, 10, 14, 283, 220, 14, 222, 188, 12, 284,
- 293, 12, 94, 296, 297, 298, 299, 15, 85, 251,
- 303, 253, 254, 255, 10, 257, 242, 18, 244, 261,
- 100, 101, 102, 103, 78, 251, 106, 253, 254, 255,
- 320, 257, 258, 259, 260, 261, 9, 14, 10, 324,
- 263, 304, 10, 53, 54, 16, 272, 16, 318, 342,
- 276, 98, 278, 251, 280, 253, 254, 255, 43, 257,
- 350, 12, 16, 261, 16, 41, 16, 293, 16, 107,
- 296, 297, 298, 299, 105, 16, -1, 303, -1, 305,
- 306, 307, 345, -1, 326, -1, -1, -1, 351, 44,
- -1, 32, 33, 34, -1, -1, 37, 360, -1, -1,
- 326, 42, 365, 329, -1, 331, -1, 333, 334, 332,
- -1, 337, 53, -1, -1, -1, 342, 58, -1, 310,
- 359, -1, -1, -1, -1, -1, 352, 68, 326, -1,
- 85, 86, 87, -1, -1, -1, -1, 147, 148, -1,
- -1, -1, -1, -1, 154, 155, -1, -1, -1, -1,
- -1, -1, -1, -1, 109, -1, -1, -1, 99, 100,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, 179,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, 124, 125, 126, 127, 128, 129, -1,
- -1, -1, -1, -1, -1, -1, 206, 207, -1, -1,
- -1, -1, -1, 144, 145, -1, 147, 148, -1, -1,
- -1, -1, 153, 154, 155, -1, -1, 227, -1, -1,
- -1, -1, -1, 164, -1, -1, -1, -1, -1, 170,
- -1, -1, -1, -1, -1, -1, -1, 178, -1, -1,
- 250, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, 192, -1, 194, 195, 196, 197, 198, 199, -1,
- 201, -1, 203, -1, 205, 206, -1, 208, -1, -1,
- 280, 281, -1, -1, 215, -1, -1, -1, -1, 220,
- -1, 222, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, 306, 307, -1, -1,
- -1, 242, -1, 244, -1, -1, -1, -1, -1, -1,
- 251, -1, 253, 254, 255, 325, 257, 258, 259, 260,
- 261, 5, -1, -1, -1, -1, -1, -1, 12, -1,
- -1, 272, -1, -1, -1, 276, -1, 278, -1, 280,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, 293, -1, -1, 296, 297, 298, 299, -1,
- -1, -1, 303, -1, 305, 306, 307, -1, -1, -1,
- -1, -1, 56, 57, -1, -1, -1, -1, -1, -1,
- 64, 65, 66, 67, -1, 326, 70, 71, -1, -1,
- -1, -1, 333, 334, -1, -1, 337, -1, -1, -1,
- -1, 342, 86, -1, -1, -1, -1, -1, -1, 93,
- -1, 352, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, 105, -1, 107, -1, 109, -1, -1, 112, 113,
- 114, 115, 116, 117, -1, 119, 120, 121, -1, 123,
- -1, -1, -1, -1, -1, -1, 130, -1, -1, 133,
- -1, -1, -1, -1, 138, -1, 140, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- 0, 1, -1, -1, -1, -1, -1, 7, 8, -1,
- 10, 11, 12, 167, 14, 15, -1, -1, 172, -1,
- -1, -1, -1, 177, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, -1, 44, 45, -1, 47, -1, -1,
- -1, -1, -1, 53, 54, 55, -1, 57, -1, 59,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, 225, -1, -1, 228, 229, -1, 77, -1, 233,
- -1, -1, -1, 237, -1, 85, 86, 87, 88, 89,
- 90, -1, -1, -1, 94, 95, 96, -1, -1, -1,
- 100, 101, -1, -1, -1, 105, -1, 107, 108, 109,
- -1, -1, 266, 267, 268, -1, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, 1, -1, -1, -1, -1, 292, -1,
- -1, -1, 10, 11, 12, -1, 14, 15, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, 316, -1, 318, -1, -1, 321, -1, -1,
- -1, -1, -1, -1, -1, -1, 44, 45, 46, 47,
- 48, 49, 50, 51, 52, 339, 54, 55, 56, 57,
- -1, 59, 60, 61, -1, -1, -1, -1, -1, -1,
- 1, -1, -1, -1, -1, -1, -1, 75, 76, 77,
- 11, 12, -1, 14, 15, -1, 17, 85, 86, 87,
- 88, 89, 90, -1, -1, -1, 94, 95, 96, 97,
- 98, -1, 100, 101, -1, -1, -1, 105, -1, 107,
- 108, 109, -1, 44, 45, 46, 47, 48, 49, 50,
- 51, 52, -1, 54, 55, 56, 57, -1, 59, 60,
- 61, -1, -1, -1, -1, -1, -1, 1, -1, -1,
- -1, -1, -1, -1, 75, 76, 77, 11, 12, -1,
- 14, 15, -1, 17, 85, 86, 87, 88, 89, 90,
- -1, -1, -1, 94, 95, 96, 97, 98, -1, 100,
- 101, -1, -1, -1, 105, -1, 107, 108, 109, -1,
- 44, 45, 46, 47, 48, 49, 50, 51, 52, -1,
- 54, 55, 56, 57, -1, 59, 60, 61, -1, -1,
- -1, -1, -1, -1, 1, -1, -1, -1, -1, -1,
- -1, 75, 76, 77, 11, 12, -1, 14, 15, -1,
- 17, 85, 86, 87, 88, 89, 90, -1, -1, -1,
- 94, 95, 96, 97, 98, -1, 100, 101, -1, -1,
- -1, 105, -1, 107, 108, 109, -1, 44, 45, 46,
- 47, 48, 49, 50, 51, 52, -1, 54, 55, 56,
- 57, -1, 59, 60, 61, -1, -1, -1, -1, -1,
- -1, 1, -1, -1, -1, -1, -1, -1, 75, 76,
- 77, 11, 12, -1, 14, 15, -1, 17, 85, 86,
- 87, 88, 89, 90, -1, -1, -1, 94, 95, 96,
- 97, 98, -1, 100, 101, -1, -1, -1, 105, -1,
- 107, 108, 109, -1, 44, 45, 46, 47, 48, 49,
- 50, 51, 52, -1, 54, 55, 56, 57, -1, 59,
- 60, 61, -1, -1, -1, -1, -1, -1, 1, -1,
- -1, -1, -1, -1, -1, 75, 76, 77, 11, 12,
- -1, 14, 15, -1, 17, 85, 86, 87, 88, 89,
- 90, -1, -1, -1, 94, 95, 96, 97, 98, -1,
- 100, 101, -1, -1, -1, 105, -1, 107, 108, 109,
- -1, 44, 45, 46, 47, 48, 49, 50, 51, 52,
- -1, 54, 55, 56, 57, -1, 59, 60, 61, -1,
- -1, -1, -1, -1, -1, -1, 1, -1, -1, -1,
- -1, -1, 75, 76, 77, 10, 11, 12, -1, 14,
- 15, -1, 85, 86, 87, 88, 89, 90, -1, -1,
- -1, 94, 95, 96, 97, 98, -1, 100, 101, -1,
- -1, -1, 105, -1, 107, 108, 109, -1, -1, 44,
- 45, 46, 47, 48, 49, 50, 51, 52, -1, 54,
- 55, 56, 57, -1, 59, 60, 61, -1, -1, -1,
- -1, -1, -1, 1, -1, -1, -1, -1, -1, -1,
- 75, 76, 77, 11, 12, -1, 14, 15, -1, 17,
- 85, 86, 87, 88, 89, 90, -1, -1, -1, 94,
- 95, 96, 97, 98, -1, 100, 101, -1, -1, -1,
- 105, -1, 107, 108, 109, -1, 44, 45, 46, 47,
- 48, 49, 50, 51, 52, -1, 54, 55, 56, 57,
- -1, 59, 60, 61, -1, -1, -1, -1, -1, -1,
- 1, -1, -1, -1, -1, -1, -1, 75, 76, 77,
- 11, 12, -1, 14, 15, -1, 17, 85, 86, 87,
- 88, 89, 90, -1, -1, -1, 94, 95, 96, 97,
- 98, -1, 100, 101, -1, -1, -1, 105, -1, 107,
- 108, 109, -1, 44, 45, 46, 47, 48, 49, 50,
- 51, 52, -1, 54, 55, 56, 57, -1, 59, 60,
- 61, -1, -1, -1, -1, -1, -1, 1, -1, -1,
- -1, -1, -1, -1, 75, 76, 77, 11, 12, -1,
- 14, 15, -1, -1, 85, 86, 87, 88, 89, 90,
- -1, -1, -1, 94, 95, 96, 97, 98, -1, 100,
- 101, -1, -1, -1, 105, -1, 107, 108, 109, -1,
- 44, 45, 46, 47, 48, 49, 50, 51, 52, -1,
- 54, 55, 56, 57, -1, 59, 60, 61, -1, -1,
- -1, -1, -1, 1, -1, -1, -1, -1, -1, -1,
- -1, 75, 76, 77, 12, -1, 14, 15, -1, -1,
- -1, 85, 86, 87, 88, 89, 90, -1, -1, -1,
- 94, 95, 96, 97, 98, -1, 100, 101, -1, -1,
- -1, 105, -1, 107, 108, 109, 44, 45, -1, 47,
- -1, 49, -1, -1, -1, -1, 54, 55, -1, 57,
- -1, 59, -1, -1, -1, -1, -1, -1, -1, 1,
- -1, -1, -1, -1, -1, -1, -1, 75, 76, 77,
- 12, -1, -1, 15, 16, -1, -1, 85, 86, 87,
- 88, 89, 90, -1, -1, -1, 94, 95, 96, -1,
- 7, 8, 100, 101, 11, 12, -1, 105, 15, 107,
- 108, 109, 44, 45, -1, 47, -1, 49, -1, -1,
- -1, -1, 54, 55, -1, 57, -1, 59, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, 44, 45, -1,
- 47, -1, -1, 75, 76, 77, 53, 54, 55, -1,
- 57, -1, 59, 85, 86, 87, 88, 89, 90, -1,
- -1, -1, 94, 95, 96, -1, -1, -1, 100, 101,
- 77, -1, -1, 105, -1, 107, 108, 109, 85, 86,
- 87, 88, 89, 90, -1, -1, -1, 94, 95, 96,
- -1, -1, 9, 100, 101, 12, 13, -1, 105, 16,
- 107, 108, 109, -1, -1, -1, 23, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, 34, 35, -1,
- 37, 38, 39, 40, 41, 42, 43, 44, 45, -1,
- 47, -1, -1, -1, -1, -1, -1, 54, 55, -1,
- 57, -1, 59, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- 77, -1, -1, -1, -1, -1, -1, -1, 85, 86,
- 87, 88, 89, 90, -1, 92, -1, 94, 95, 96,
- -1, -1, 9, 100, 101, 12, 13, -1, 105, 16,
- 107, 108, 109, -1, -1, -1, 23, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, 34, 35, -1,
- 37, 38, 39, 40, 41, 42, 43, 44, 45, -1,
- 47, -1, -1, -1, -1, -1, -1, 54, 55, -1,
- 57, -1, 59, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- 77, -1, -1, -1, -1, -1, -1, -1, 85, 86,
- 87, 88, 89, 90, -1, 92, -1, 94, 95, 96,
- -1, -1, 9, 100, 101, 12, 13, -1, 105, 16,
- 107, 108, 109, -1, -1, -1, 23, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, 34, 35, -1,
- 37, 38, 39, 40, 41, 42, 43, 44, 45, -1,
- 47, -1, -1, -1, -1, -1, -1, 54, 55, -1,
- 57, -1, 59, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- 77, -1, -1, -1, -1, -1, -1, -1, 85, 86,
- 87, 88, 89, 90, -1, 92, -1, 94, 95, 96,
- -1, -1, 9, 100, 101, 12, 13, -1, 105, 16,
- 107, 108, 109, -1, -1, -1, 23, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, 34, 35, -1,
- 37, 38, 39, 40, 41, 42, 43, 44, 45, -1,
- 47, -1, -1, -1, -1, -1, -1, 54, 55, -1,
- 57, -1, 59, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- 77, -1, -1, -1, -1, -1, -1, -1, 85, 86,
- 87, 88, 89, 90, -1, 92, -1, 94, 95, 96,
- -1, -1, 9, 100, 101, 12, 13, -1, 105, -1,
- 107, 108, 109, -1, -1, -1, 23, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, 34, 35, -1,
- 37, 38, 39, 40, 41, 42, 43, 44, 45, -1,
- 47, -1, -1, -1, -1, -1, -1, 54, 55, -1,
- 57, -1, 59, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- 77, -1, -1, -1, -1, -1, -1, -1, 85, 86,
- 87, 88, 89, 90, -1, 92, -1, 94, 95, 96,
- -1, -1, -1, 100, 101, -1, -1, -1, 105, -1,
- 107, 108, 109, 10, -1, 12, 13, 14, -1, -1,
- -1, -1, -1, -1, -1, -1, 23, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, 34, 35, -1,
- 37, 38, 39, 40, 41, 42, 43, 44, 45, -1,
- 47, -1, -1, -1, -1, -1, -1, 54, 55, -1,
- 57, -1, 59, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, 10, -1, 12, -1, 14, 15, -1, -1,
- 77, -1, -1, -1, -1, -1, -1, -1, 85, 86,
- 87, 88, 89, 90, -1, 92, -1, 94, 95, 96,
- -1, -1, -1, 100, 101, -1, 44, 45, 105, 47,
- 107, 108, 109, -1, -1, -1, 54, 55, -1, 57,
- -1, 59, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, 10, -1, 12, -1, -1, 15, -1, -1, 77,
- -1, -1, -1, -1, -1, -1, -1, 85, 86, 87,
- 88, 89, 90, -1, -1, -1, 94, 95, 96, -1,
- -1, -1, 100, 101, -1, 44, 45, 105, 47, 107,
- 108, 109, -1, -1, -1, 54, 55, -1, 57, -1,
- 59, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- 10, -1, 12, -1, -1, 15, -1, -1, 77, -1,
- -1, -1, -1, -1, -1, -1, 85, 86, 87, 88,
- 89, 90, -1, -1, -1, 94, 95, 96, -1, -1,
- -1, 100, 101, -1, 44, 45, 105, 47, 107, 108,
- 109, -1, -1, -1, 54, 55, -1, 57, -1, 59,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, 10,
- -1, 12, -1, -1, 15, -1, -1, 77, -1, -1,
- -1, -1, -1, -1, -1, 85, 86, 87, 88, 89,
- 90, -1, -1, -1, 94, 95, 96, -1, -1, -1,
- 100, 101, -1, 44, 45, 105, 47, 107, 108, 109,
- -1, -1, -1, 54, 55, -1, 57, -1, 59, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, 10, -1,
- 12, -1, -1, 15, -1, -1, 77, -1, -1, -1,
- -1, -1, -1, -1, 85, 86, 87, 88, 89, 90,
- -1, -1, -1, 94, 95, 96, -1, -1, -1, 100,
- 101, -1, 44, 45, 105, 47, 107, 108, 109, -1,
- -1, -1, 54, 55, -1, 57, -1, 59, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, 10, -1, 12,
- -1, -1, 15, -1, -1, 77, -1, -1, -1, -1,
- -1, -1, -1, 85, 86, 87, 88, 89, 90, -1,
- -1, -1, 94, 95, 96, -1, -1, -1, 100, 101,
- -1, 44, 45, 105, 47, 107, 108, 109, -1, -1,
- -1, 54, 55, -1, 57, -1, 59, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, 10, -1, 12, -1,
- -1, 15, -1, -1, 77, -1, -1, -1, -1, -1,
- -1, -1, 85, 86, 87, 88, 89, 90, -1, -1,
- -1, 94, 95, 96, -1, -1, -1, 100, 101, -1,
- 44, 45, 105, 47, 107, 108, 109, -1, -1, -1,
- 54, 55, -1, 57, -1, 59, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, 77, -1, -1, -1, -1, -1, -1,
- -1, 85, 86, 87, 88, 89, 90, -1, -1, -1,
- 94, 95, 96, -1, -1, -1, 100, 101, 12, 13,
- -1, 105, 16, 107, 108, 109, -1, -1, -1, 23,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- 34, 35, -1, 37, 38, 39, 40, 41, 42, 43,
- 44, 45, -1, 47, -1, -1, -1, -1, -1, -1,
- 54, 55, -1, 57, -1, 59, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, 77, -1, -1, -1, -1, -1, -1,
- -1, 85, 86, 87, 88, 89, 90, -1, 92, -1,
- 94, 95, 96, -1, -1, -1, 100, 101, 12, 13,
- -1, 105, -1, 107, 108, 109, -1, -1, -1, 23,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- 34, 35, -1, 37, 38, 39, 40, 41, 42, 43,
- 44, 45, -1, 47, -1, -1, -1, -1, -1, -1,
- 54, 55, -1, 57, -1, 59, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, 77, -1, -1, -1, -1, -1, -1,
- -1, 85, 86, 87, 88, 89, 90, -1, 92, 93,
- 94, 95, 96, -1, -1, -1, 100, 101, 12, 13,
- -1, 105, 16, 107, 108, 109, -1, -1, -1, 23,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- 34, 35, -1, 37, 38, 39, 40, 41, 42, 43,
- 44, 45, -1, 47, -1, -1, -1, -1, -1, -1,
- 54, 55, -1, 57, -1, 59, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, 77, -1, -1, -1, -1, -1, -1,
- -1, 85, 86, 87, 88, 89, 90, -1, 92, -1,
- 94, 95, 96, -1, -1, -1, 100, 101, 12, 13,
- -1, 105, 16, 107, 108, 109, -1, -1, -1, 23,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- 34, 35, -1, 37, 38, 39, 40, 41, 42, 43,
- 44, 45, -1, 47, -1, -1, -1, -1, -1, -1,
- 54, 55, -1, 57, -1, 59, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, 77, -1, -1, -1, -1, -1, -1,
- -1, 85, 86, 87, 88, 89, 90, -1, 92, -1,
- 94, 95, 96, -1, -1, -1, 100, 101, 12, 13,
- -1, 105, 16, 107, 108, 109, -1, -1, -1, 23,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- 34, 35, -1, 37, 38, 39, 40, 41, 42, 43,
- 44, 45, -1, 47, -1, -1, -1, -1, -1, -1,
- 54, 55, -1, 57, -1, 59, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, 77, -1, -1, -1, -1, -1, -1,
- -1, 85, 86, 87, 88, 89, 90, -1, 92, -1,
- 94, 95, 96, -1, -1, -1, 100, 101, 12, 13,
- -1, 105, 16, 107, 108, 109, -1, -1, -1, 23,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- 34, 35, -1, 37, 38, 39, 40, 41, 42, 43,
- 44, 45, -1, 47, -1, -1, -1, -1, -1, -1,
- 54, 55, -1, 57, -1, 59, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, 77, -1, -1, -1, -1, -1, -1,
- -1, 85, 86, 87, 88, 89, 90, -1, 92, -1,
- 94, 95, 96, -1, -1, -1, 100, 101, 12, 13,
- -1, 105, 16, 107, 108, 109, -1, -1, -1, 23,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- 34, 35, -1, 37, 38, 39, 40, 41, 42, 43,
- 44, 45, -1, 47, -1, -1, -1, -1, -1, -1,
- 54, 55, -1, 57, -1, 59, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, 77, -1, -1, -1, -1, -1, -1,
- -1, 85, 86, 87, 88, 89, 90, -1, 92, -1,
- 94, 95, 96, -1, -1, -1, 100, 101, 12, 13,
- 14, 105, -1, 107, 108, 109, -1, -1, -1, 23,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- 34, 35, -1, 37, 38, 39, 40, 41, 42, 43,
- 44, 45, -1, 47, -1, -1, -1, -1, -1, -1,
- 54, 55, -1, 57, -1, 59, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, 77, -1, -1, -1, -1, -1, -1,
- -1, 85, 86, 87, 88, 89, 90, -1, 92, -1,
- 94, 95, 96, -1, -1, -1, 100, 101, 12, 13,
- -1, 105, 16, 107, 108, 109, -1, -1, -1, 23,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- 34, 35, -1, 37, 38, 39, 40, 41, 42, 43,
- 44, 45, -1, 47, -1, -1, -1, -1, -1, -1,
- 54, 55, -1, 57, -1, 59, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, 77, -1, -1, -1, -1, -1, -1,
- -1, 85, 86, 87, 88, 89, 90, -1, 92, -1,
- 94, 95, 96, -1, -1, -1, 100, 101, 12, 13,
- -1, 105, -1, 107, 108, 109, -1, -1, -1, 23,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- 34, 35, -1, 37, 38, 39, 40, 41, 42, 43,
- 44, 45, -1, 47, -1, -1, -1, -1, -1, -1,
- 54, 55, -1, 57, -1, 59, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, 77, -1, -1, -1, -1, -1, -1,
- -1, 85, 86, 87, 88, 89, 90, -1, 92, -1,
- 94, 95, 96, -1, -1, -1, 100, 101, 12, 13,
- -1, 105, -1, 107, 108, 109, -1, -1, -1, 23,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- 34, -1, -1, 37, 38, 39, 40, 41, 42, 43,
- 44, 45, -1, 47, -1, -1, -1, -1, -1, -1,
- 54, 55, -1, 57, -1, 59, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, 77, -1, -1, -1, -1, -1, -1,
- -1, 85, 86, 87, 88, 89, 90, 12, 13, -1,
- 94, 95, 96, -1, -1, -1, 100, 101, 23, -1,
- -1, 105, -1, 107, 108, 109, -1, -1, -1, -1,
- -1, -1, 37, 38, 39, 40, 41, 42, 43, 44,
- 45, -1, 47, -1, -1, -1, -1, -1, -1, 54,
- 55, -1, 57, -1, 59, -1, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, 77, -1, -1, -1, -1, -1, -1, -1,
- 85, 86, 87, 88, 89, 90, 12, 13, -1, 94,
- 95, 96, -1, -1, -1, 100, 101, 23, -1, -1,
- 105, -1, 107, 108, 109, -1, -1, -1, -1, -1,
- -1, 37, 38, 39, 40, 41, 42, 43, 44, 45,
- -1, 47, -1, -1, -1, -1, -1, -1, 54, 55,
- -1, 57, -1, 59, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, 12, -1, -1, -1, -1,
- -1, 77, -1, -1, -1, -1, 23, -1, -1, 85,
- 86, 87, 88, 89, 90, -1, -1, 34, 35, 95,
- 96, -1, -1, -1, 100, 101, 43, 44, 45, 105,
- 47, 107, 108, 109, -1, -1, -1, 54, 55, -1,
- 57, -1, 59, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- 77, -1, -1, 12, -1, -1, -1, -1, 85, 86,
- 87, 88, 89, 90, 23, 92, 93, 94, 95, 96,
- -1, -1, -1, 100, 101, 34, 35, -1, 105, -1,
- 107, 108, 109, -1, 43, 44, 45, -1, 47, -1,
- -1, -1, -1, -1, -1, 54, 55, -1, 57, -1,
- 59, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, 12, -1, -1, -1, -1, -1, 77, -1,
- -1, -1, -1, 23, -1, -1, 85, 86, 87, 88,
- 89, 90, -1, 92, 34, 94, 95, 96, -1, -1,
- -1, 100, 101, 43, 44, 45, 105, 47, 107, 108,
- 109, -1, -1, -1, 54, 55, -1, 57, -1, 59,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, 12, -1, -1, 15, 16, -1, 77, -1, -1,
- -1, -1, -1, -1, -1, 85, 86, 87, 88, 89,
- 90, -1, -1, -1, 94, 95, 96, -1, -1, -1,
- 100, 101, -1, 44, 45, 105, 47, 107, 108, 109,
- -1, -1, -1, 54, 55, -1, 57, -1, 59, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- 12, -1, -1, 15, 16, -1, 77, -1, -1, -1,
- -1, -1, -1, -1, 85, 86, 87, 88, 89, 90,
- -1, -1, -1, 94, 95, 96, -1, -1, -1, 100,
- 101, -1, 44, 45, 105, 47, 107, 108, 109, -1,
- -1, -1, 54, 55, -1, 57, -1, 59, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, 12,
- -1, -1, -1, -1, -1, 77, -1, -1, -1, -1,
- 23, -1, -1, 85, 86, 87, 88, 89, 90, -1,
- -1, -1, 94, 95, 96, -1, -1, -1, 100, 101,
- 43, 44, 45, 105, 47, 107, 108, 109, -1, -1,
- -1, 54, 55, -1, 57, -1, 59, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, 12, -1,
- -1, 15, -1, -1, 77, -1, -1, -1, -1, -1,
- -1, -1, 85, 86, 87, 88, 89, 90, -1, -1,
- -1, 94, 95, 96, -1, -1, -1, 100, 101, -1,
- 44, 45, 105, 47, 107, 108, 109, -1, -1, -1,
- 54, 55, -1, 57, -1, 59, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, 12, -1, -1,
- 15, -1, -1, 77, -1, -1, -1, -1, -1, -1,
- -1, 85, 86, 87, 88, 89, 90, -1, -1, -1,
- 94, 95, 96, -1, -1, -1, 100, 101, -1, 44,
- 45, 105, 47, 107, 108, 109, -1, -1, -1, 54,
- 55, -1, 57, -1, 59, -1, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, 12, -1, -1, 15,
- -1, -1, 77, -1, -1, -1, -1, -1, -1, -1,
- 85, 86, 87, 88, 89, 90, -1, -1, -1, 94,
- 95, 96, -1, -1, -1, 100, 101, -1, 44, 45,
- 105, 47, 107, 108, 109, -1, -1, -1, 54, 55,
- -1, 57, -1, 59, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, 12, -1, -1, -1, -1,
- -1, 77, -1, -1, -1, -1, -1, -1, -1, 85,
- 86, 87, 88, 89, 90, -1, -1, -1, 94, 95,
- 96, -1, -1, -1, 100, 101, -1, 44, 45, 105,
- 47, 107, 108, 109, -1, -1, -1, 54, 55, -1,
- 57, -1, 59, -1, -1, -1, -1, -1, -1, -1,
- -1, 68, -1, -1, 12, -1, -1, 15, -1, -1,
- 77, -1, -1, -1, -1, -1, -1, -1, 85, 86,
- 87, 88, 89, 90, -1, -1, -1, 94, 95, 96,
- -1, -1, -1, 100, 101, -1, 44, 45, 105, 47,
- 107, 108, 109, -1, -1, -1, 54, 55, -1, 57,
- -1, 59, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, 12, -1, -1, -1, -1, -1, 77,
- -1, -1, -1, -1, 23, -1, -1, 85, 86, 87,
- 88, 89, 90, -1, -1, -1, 94, 95, 96, -1,
- -1, -1, 100, 101, 43, 44, 45, 105, 47, 107,
- 108, 109, -1, -1, -1, 54, 55, -1, 57, -1,
- 59, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, 12, -1, -1, -1, -1, -1, 77, -1,
- -1, -1, -1, -1, -1, -1, 85, 86, 87, 88,
- 89, 90, -1, -1, -1, -1, 95, 96, -1, -1,
- -1, 100, 101, -1, 44, 45, 105, 47, 107, 108,
- 109, -1, -1, -1, 54, 55, -1, 57, -1, 59,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, 77, -1, -1,
- -1, -1, -1, -1, -1, 85, 86, 87, 88, 89,
- 90, -1, -1, -1, 94, 95, 96, -1, -1, -1,
- 100, 101, -1, -1, -1, 105, -1, 107, 108, 109
+ 2, 3, 4, 5, 6, 7, 8, 9, 10, 21,
+ 22, 23, 24, 25, 26, 27, 28, 29, 30, 31,
+ 32, 33, 34, 35, 36, 37, 38, 39, 40, 41,
+ 42, 43, 44, 45, 46, 47, 48, 49, 50, 51,
+ 52, 53, 54, 55, 56, 57, 58, 59, 60, 61,
+ 62, 63, 64, 65, 66, 67, 68, 69, 70, 71,
+ 72, 73, 74, 75, 76, 77, 78, 79, 80, 81,
+ 82, 83, 84, 85, 86, 87, 88, 89, 90, 91,
+ 92, 93, 96, 97, 98, 99, 100, 101, 106, 107,
+ 108, 109, 110, 111, 112
};
-
-/* YYSTOS[STATE-NUM] -- The (internal number of the) accessing
- symbol of state STATE-NUM. */
-static const unsigned char yystos[] =
+static const long yytok3[] =
{
- 0, 1, 10, 14, 112, 127, 129, 141, 0, 7,
- 8, 11, 12, 15, 44, 45, 47, 53, 54, 55,
- 57, 59, 77, 85, 86, 87, 88, 89, 90, 94,
- 95, 96, 100, 101, 105, 107, 108, 109, 124, 130,
- 131, 133, 136, 143, 144, 154, 155, 156, 158, 10,
- 14, 124, 124, 136, 137, 145, 12, 12, 105, 155,
- 156, 85, 88, 122, 12, 12, 12, 12, 41, 156,
- 12, 12, 155, 155, 143, 155, 156, 156, 155, 1,
- 10, 14, 46, 48, 49, 50, 51, 52, 56, 60,
- 61, 75, 76, 97, 98, 116, 118, 123, 124, 136,
- 140, 147, 149, 153, 159, 9, 124, 127, 13, 23,
- 34, 35, 37, 38, 39, 40, 41, 42, 43, 92,
- 113, 114, 155, 12, 15, 100, 101, 102, 103, 106,
- 68, 107, 108, 18, 153, 153, 9, 16, 115, 16,
- 115, 91, 16, 134, 136, 136, 12, 136, 136, 134,
- 16, 134, 155, 41, 136, 136, 10, 125, 126, 14,
- 125, 148, 148, 158, 136, 148, 12, 12, 148, 148,
- 136, 148, 12, 10, 150, 149, 153, 12, 135, 138,
- 139, 143, 155, 156, 148, 17, 149, 152, 130, 153,
- 131, 94, 136, 144, 136, 136, 136, 136, 136, 136,
- 158, 136, 10, 136, 10, 136, 136, 144, 68, 155,
- 155, 155, 155, 155, 155, 136, 134, 17, 17, 10,
- 136, 43, 136, 15, 16, 115, 85, 157, 115, 115,
- 16, 16, 155, 115, 115, 10, 126, 18, 148, 128,
- 147, 158, 136, 148, 136, 149, 78, 117, 17, 142,
- 137, 23, 43, 92, 113, 114, 155, 115, 13, 36,
- 39, 68, 149, 124, 17, 156, 93, 115, 115, 155,
- 19, 158, 136, 16, 115, 146, 136, 144, 136, 144,
- 136, 158, 134, 14, 43, 146, 146, 151, 10, 149,
- 10, 16, 12, 135, 144, 158, 135, 135, 135, 135,
- 155, 155, 155, 135, 153, 136, 136, 136, 85, 10,
- 132, 16, 16, 16, 16, 16, 115, 16, 115, 19,
- 14, 126, 158, 98, 43, 137, 93, 17, 16, 115,
- 16, 115, 124, 136, 136, 144, 126, 136, 146, 12,
- 158, 16, 135, 156, 156, 153, 16, 16, 16, 128,
- 14, 121, 136, 16, 16, 17, 146, 126, 149, 16,
- 120, 128, 148, 149, 146, 119, 149
+ 0
};
-
-#if ! defined (YYSIZE_T) && defined (__SIZE_TYPE__)
-# define YYSIZE_T __SIZE_TYPE__
-#endif
-#if ! defined (YYSIZE_T) && defined (size_t)
-# define YYSIZE_T size_t
-#endif
-#if ! defined (YYSIZE_T)
-# if defined (__STDC__) || defined (__cplusplus)
-# include <stddef.h> /* INFRINGES ON USER NAME SPACE */
-# define YYSIZE_T size_t
-# endif
-#endif
-#if ! defined (YYSIZE_T)
-# define YYSIZE_T unsigned int
-#endif
-
-#define yyerrok (yyerrstatus = 0)
-#define yyclearin (yychar = YYEMPTY)
-#define YYEMPTY (-2)
-#define YYEOF 0
-
-#define YYACCEPT goto yyacceptlab
-#define YYABORT goto yyabortlab
-#define YYERROR goto yyerrlab1
-
-/* Like YYERROR except do call yyerror. This remains here temporarily
- to ease the transition to the new meaning of YYERROR, for GCC.
- Once GCC version 2 has supplanted version 1, this can go. */
-
-#define YYFAIL goto yyerrlab
-
-#define YYRECOVERING() (!!yyerrstatus)
-
-#define YYBACKUP(Token, Value) \
-do \
- if (yychar == YYEMPTY && yylen == 1) \
- { \
- yychar = (Token); \
- yylval = (Value); \
- yytoken = YYTRANSLATE (yychar); \
- YYPOPSTACK; \
- goto yybackup; \
- } \
- else \
- { \
- yyerror ("syntax error: cannot back up");\
- YYERROR; \
- } \
-while (0)
-
-#define YYTERROR 1
-#define YYERRCODE 256
-
-/* YYLLOC_DEFAULT -- Compute the default location (before the actions
- are run). */
-
-#ifndef YYLLOC_DEFAULT
-# define YYLLOC_DEFAULT(Current, Rhs, N) \
- Current.first_line = Rhs[1].first_line; \
- Current.first_column = Rhs[1].first_column; \
- Current.last_line = Rhs[N].last_line; \
- Current.last_column = Rhs[N].last_column;
-#endif
-
-/* YYLEX -- calling `yylex' with the right arguments. */
-
-#ifdef YYLEX_PARAM
-# define YYLEX yylex (YYLEX_PARAM)
+#define YYFLAG -1000
+#define YYERROR goto yyerrlab
+#define YYACCEPT return(0)
+#define YYABORT return(1)
+#define yyclearin yychar = -1
+#define yyerrok yyerrflag = 0
+
+#ifdef yydebug
+#include "y.debug"
#else
-# define YYLEX yylex ()
+#define yydebug 0
+static const char* yytoknames[1]; /* for debugging */
+static const char* yystates[1]; /* for debugging */
#endif
-/* Enable debugging if requested. */
-#if YYDEBUG
-
-# ifndef YYFPRINTF
-# include <stdio.h> /* INFRINGES ON USER NAME SPACE */
-# define YYFPRINTF fprintf
-# endif
-
-# define YYDPRINTF(Args) \
-do { \
- if (yydebug) \
- YYFPRINTF Args; \
-} while (0)
-
-# define YYDSYMPRINT(Args) \
-do { \
- if (yydebug) \
- yysymprint Args; \
-} while (0)
-
-# define YYDSYMPRINTF(Title, Token, Value, Location) \
-do { \
- if (yydebug) \
- { \
- YYFPRINTF (stderr, "%s ", Title); \
- yysymprint (stderr, \
- Token, Value); \
- YYFPRINTF (stderr, "\n"); \
- } \
-} while (0)
-
-/*------------------------------------------------------------------.
-| yy_stack_print -- Print the state stack from its BOTTOM up to its |
-| TOP (cinluded). |
-`------------------------------------------------------------------*/
-
-#if defined (__STDC__) || defined (__cplusplus)
-static void
-yy_stack_print (short *bottom, short *top)
+/* parser for yacc output */
+#ifdef YYARG
+#define yynerrs yyarg->yynerrs
+#define yyerrflag yyarg->yyerrflag
+#define yyval yyarg->yyval
+#define yylval yyarg->yylval
#else
-static void
-yy_stack_print (bottom, top)
- short *bottom;
- short *top;
-#endif
-{
- YYFPRINTF (stderr, "Stack now");
- for (/* Nothing. */; bottom <= top; ++bottom)
- YYFPRINTF (stderr, " %d", *bottom);
- YYFPRINTF (stderr, "\n");
-}
-
-# define YY_STACK_PRINT(Bottom, Top) \
-do { \
- if (yydebug) \
- yy_stack_print ((Bottom), (Top)); \
-} while (0)
-
-
-/*------------------------------------------------.
-| Report that the YYRULE is going to be reduced. |
-`------------------------------------------------*/
-
-#if defined (__STDC__) || defined (__cplusplus)
-static void
-yy_reduce_print (int yyrule)
-#else
-static void
-yy_reduce_print (yyrule)
- int yyrule;
-#endif
-{
- int yyi;
- unsigned int yylineno = yyrline[yyrule];
- YYFPRINTF (stderr, "Reducing stack by rule %d (line %u), ",
- yyrule - 1, yylineno);
- /* Print the symbols being reduced, and their result. */
- for (yyi = yyprhs[yyrule]; 0 <= yyrhs[yyi]; yyi++)
- YYFPRINTF (stderr, "%s ", yytname [yyrhs[yyi]]);
- YYFPRINTF (stderr, "-> %s\n", yytname [yyr1[yyrule]]);
-}
-
-# define YY_REDUCE_PRINT(Rule) \
-do { \
- if (yydebug) \
- yy_reduce_print (Rule); \
-} while (0)
-
-/* Nonzero means print parse trace. It is left uninitialized so that
- multiple parsers can coexist. */
-int yydebug;
-#else /* !YYDEBUG */
-# define YYDPRINTF(Args)
-# define YYDSYMPRINT(Args)
-# define YYDSYMPRINTF(Title, Token, Value, Location)
-# define YY_STACK_PRINT(Bottom, Top)
-# define YY_REDUCE_PRINT(Rule)
-#endif /* !YYDEBUG */
-
-
-/* YYINITDEPTH -- initial size of the parser's stacks. */
-#ifndef YYINITDEPTH
-# define YYINITDEPTH 200
-#endif
-
-/* YYMAXDEPTH -- maximum size the stacks can grow to (effective only
- if the built-in stack extension method is used).
-
- Do not make this value too large; the results are undefined if
- SIZE_MAX < YYSTACK_BYTES (YYMAXDEPTH)
- evaluated with infinite-precision integer arithmetic. */
-
-#if YYMAXDEPTH == 0
-# undef YYMAXDEPTH
-#endif
-
-#ifndef YYMAXDEPTH
-# define YYMAXDEPTH 10000
+int yynerrs = 0; /* number of errors */
+int yyerrflag = 0; /* error recovery flag */
#endif
-
-
-#if YYERROR_VERBOSE
-
-# ifndef yystrlen
-# if defined (__GLIBC__) && defined (_STRING_H)
-# define yystrlen strlen
-# else
-/* Return the length of YYSTR. */
-static YYSIZE_T
-# if defined (__STDC__) || defined (__cplusplus)
-yystrlen (const char *yystr)
-# else
-yystrlen (yystr)
- const char *yystr;
-# endif
+static const char*
+yytokname(int yyc)
{
- register const char *yys = yystr;
-
- while (*yys++ != '\0')
- continue;
+ static char x[10];
- return yys - yystr - 1;
+ if(yyc > 0 && yyc <= sizeof(yytoknames)/sizeof(yytoknames[0]))
+ if(yytoknames[yyc-1])
+ return yytoknames[yyc-1];
+ sprintf(x, "<%d>", yyc);
+ return x;
}
-# endif
-# endif
-# ifndef yystpcpy
-# if defined (__GLIBC__) && defined (_STRING_H) && defined (_GNU_SOURCE)
-# define yystpcpy stpcpy
-# else
-/* Copy YYSRC to YYDEST, returning the address of the terminating '\0' in
- YYDEST. */
-static char *
-# if defined (__STDC__) || defined (__cplusplus)
-yystpcpy (char *yydest, const char *yysrc)
-# else
-yystpcpy (yydest, yysrc)
- char *yydest;
- const char *yysrc;
-# endif
+static const char*
+yystatname(int yys)
{
- register char *yyd = yydest;
- register const char *yys = yysrc;
+ static char x[10];
- while ((*yyd++ = *yys++) != '\0')
- continue;
-
- return yyd - 1;
+ if(yys >= 0 && yys < sizeof(yystates)/sizeof(yystates[0]))
+ if(yystates[yys])
+ return yystates[yys];
+ sprintf(x, "<%d>\n", yys);
+ return x;
}
-# endif
-# endif
-
-#endif /* !YYERROR_VERBOSE */
-
-
-#if YYDEBUG
-/*--------------------------------.
-| Print this symbol on YYOUTPUT. |
-`--------------------------------*/
-
-#if defined (__STDC__) || defined (__cplusplus)
-static void
-yysymprint (FILE *yyoutput, int yytype, YYSTYPE *yyvaluep)
+static long
+#ifdef YYARG
+yylex1(struct Yyarg *yyarg)
#else
-static void
-yysymprint (yyoutput, yytype, yyvaluep)
- FILE *yyoutput;
- int yytype;
- YYSTYPE *yyvaluep;
+yylex1(void)
#endif
{
- /* Pacify ``unused variable'' warnings. */
- (void) yyvaluep;
-
- if (yytype < YYNTOKENS)
- {
- YYFPRINTF (yyoutput, "token %s (", yytname[yytype]);
-# ifdef YYPRINT
- YYPRINT (yyoutput, yytoknum[yytype], *yyvaluep);
-# endif
- }
- else
- YYFPRINTF (yyoutput, "nterm %s (", yytname[yytype]);
+ long yychar;
+ const long *t3p;
+ int c;
- switch (yytype)
- {
- default:
- break;
- }
- YYFPRINTF (yyoutput, ")");
-}
-
-#endif /* ! YYDEBUG */
-/*-----------------------------------------------.
-| Release the memory associated to this symbol. |
-`-----------------------------------------------*/
-
-#if defined (__STDC__) || defined (__cplusplus)
-static void
-yydestruct (int yytype, YYSTYPE *yyvaluep)
+#ifdef YYARG
+ yychar = yylex(yyarg);
#else
-static void
-yydestruct (yytype, yyvaluep)
- int yytype;
- YYSTYPE *yyvaluep;
+ yychar = yylex();
#endif
-{
- /* Pacify ``unused variable'' warnings. */
- (void) yyvaluep;
-
- switch (yytype)
- {
-
- default:
- break;
- }
+ if(yychar <= 0) {
+ c = yytok1[0];
+ goto out;
+ }
+ if(yychar < sizeof(yytok1)/sizeof(yytok1[0])) {
+ c = yytok1[yychar];
+ goto out;
+ }
+ if(yychar >= YYPRIVATE)
+ if(yychar < YYPRIVATE+sizeof(yytok2)/sizeof(yytok2[0])) {
+ c = yytok2[yychar-YYPRIVATE];
+ goto out;
+ }
+ for(t3p=yytok3;; t3p+=2) {
+ c = t3p[0];
+ if(c == yychar) {
+ c = t3p[1];
+ goto out;
+ }
+ if(c == 0)
+ break;
+ }
+ c = 0;
+
+out:
+ if(c == 0)
+ c = yytok2[1]; /* unknown char */
+ if(yydebug >= 3)
+ printf("lex %.4lX %s\n", yychar, yytokname(c));
+ return c;
}
-
-/* Prevent warnings from -Wmissing-prototypes. */
-
-#ifdef YYPARSE_PARAM
-# if defined (__STDC__) || defined (__cplusplus)
-int yyparse (void *YYPARSE_PARAM);
-# else
-int yyparse ();
-# endif
-#else /* ! YYPARSE_PARAM */
-#if defined (__STDC__) || defined (__cplusplus)
-int yyparse (void);
-#else
-int yyparse ();
-#endif
-#endif /* ! YYPARSE_PARAM */
-
-
-
-/* The lookahead symbol. */
-int yychar;
-
-/* The semantic value of the lookahead symbol. */
-YYSTYPE yylval;
-
-/* Number of syntax errors so far. */
-int yynerrs;
-
-
-
-/*----------.
-| yyparse. |
-`----------*/
-
-#ifdef YYPARSE_PARAM
-# if defined (__STDC__) || defined (__cplusplus)
-int yyparse (void *YYPARSE_PARAM)
-# else
-int yyparse (YYPARSE_PARAM)
- void *YYPARSE_PARAM;
-# endif
-#else /* ! YYPARSE_PARAM */
-#if defined (__STDC__) || defined (__cplusplus)
int
-yyparse (void)
+#ifdef YYARG
+yyparse(struct Yyarg *yyarg)
#else
-int
-yyparse ()
-
-#endif
+yyparse(void)
#endif
{
-
- register int yystate;
- register int yyn;
- int yyresult;
- /* Number of tokens to shift before error messages enabled. */
- int yyerrstatus;
- /* Lookahead token as an internal (translated) token number. */
- int yytoken = 0;
-
- /* Three stacks and their tools:
- `yyss': related to states,
- `yyvs': related to semantic values,
- `yyls': related to locations.
-
- Refer to the stacks thru separate pointers, to allow yyoverflow
- to reallocate them elsewhere. */
-
- /* The state stack. */
- short yyssa[YYINITDEPTH];
- short *yyss = yyssa;
- register short *yyssp;
-
- /* The semantic value stack. */
- YYSTYPE yyvsa[YYINITDEPTH];
- YYSTYPE *yyvs = yyvsa;
- register YYSTYPE *yyvsp;
-
-
-
-#define YYPOPSTACK (yyvsp--, yyssp--)
-
- YYSIZE_T yystacksize = YYINITDEPTH;
-
- /* The variables used to return semantic value and location from the
- action routines. */
- YYSTYPE yyval;
-
-
- /* When reducing, the number of symbols on the RHS of the reduced
- rule. */
- int yylen;
-
- YYDPRINTF ((stderr, "Starting parse\n"));
-
- yystate = 0;
- yyerrstatus = 0;
- yynerrs = 0;
- yychar = YYEMPTY; /* Cause a token to be read. */
-
- /* Initialize stack pointers.
- Waste one element of value and location stack
- so that they stay on the same level as the state stack.
- The wasted elements are never initialized. */
-
- yyssp = yyss;
- yyvsp = yyvs;
-
- goto yysetstate;
-
-/*------------------------------------------------------------.
-| yynewstate -- Push a new state, which is found in yystate. |
-`------------------------------------------------------------*/
- yynewstate:
- /* In all cases, when you get here, the value and location stacks
- have just been pushed. so pushing a state here evens the stacks.
- */
- yyssp++;
-
- yysetstate:
- *yyssp = yystate;
-
- if (yyss + yystacksize - 1 <= yyssp)
- {
- /* Get the current used size of the three stacks, in elements. */
- YYSIZE_T yysize = yyssp - yyss + 1;
-
-#ifdef yyoverflow
- {
- /* Give user a chance to reallocate the stack. Use copies of
- these so that the &'s don't force the real ones into
- memory. */
- YYSTYPE *yyvs1 = yyvs;
- short *yyss1 = yyss;
-
-
- /* Each stack pointer address is followed by the size of the
- data in use in that stack, in bytes. This used to be a
- conditional around just the two extra args, but that might
- be undefined if yyoverflow is a macro. */
- yyoverflow ("parser stack overflow",
- &yyss1, yysize * sizeof (*yyssp),
- &yyvs1, yysize * sizeof (*yyvsp),
-
- &yystacksize);
-
- yyss = yyss1;
- yyvs = yyvs1;
- }
-#else /* no yyoverflow */
-# ifndef YYSTACK_RELOCATE
- goto yyoverflowlab;
-# else
- /* Extend the stack our own way. */
- if (YYMAXDEPTH <= yystacksize)
- goto yyoverflowlab;
- yystacksize *= 2;
- if (YYMAXDEPTH < yystacksize)
- yystacksize = YYMAXDEPTH;
-
- {
- short *yyss1 = yyss;
- union yyalloc *yyptr =
- (union yyalloc *) YYSTACK_ALLOC (YYSTACK_BYTES (yystacksize));
- if (! yyptr)
- goto yyoverflowlab;
- YYSTACK_RELOCATE (yyss);
- YYSTACK_RELOCATE (yyvs);
-
-# undef YYSTACK_RELOCATE
- if (yyss1 != yyssa)
- YYSTACK_FREE (yyss1);
- }
-# endif
-#endif /* no yyoverflow */
-
- yyssp = yyss + yysize - 1;
- yyvsp = yyvs + yysize - 1;
-
-
- YYDPRINTF ((stderr, "Stack size increased to %lu\n",
- (unsigned long int) yystacksize));
-
- if (yyss + yystacksize - 1 <= yyssp)
- YYABORT;
- }
-
- YYDPRINTF ((stderr, "Entering state %d\n", yystate));
-
- goto yybackup;
-
-/*-----------.
-| yybackup. |
-`-----------*/
-yybackup:
-
-/* Do appropriate processing given the current state. */
-/* Read a lookahead token if we need one and don't already have one. */
-/* yyresume: */
-
- /* First try to decide what to do without reference to lookahead token. */
-
- yyn = yypact[yystate];
- if (yyn == YYPACT_NINF)
- goto yydefault;
-
- /* Not known => get a lookahead token if don't already have one. */
-
- /* YYCHAR is either YYEMPTY or YYEOF or a valid lookahead symbol. */
- if (yychar == YYEMPTY)
- {
- YYDPRINTF ((stderr, "Reading a token: "));
- yychar = YYLEX;
- }
-
- if (yychar <= YYEOF)
- {
- yychar = yytoken = YYEOF;
- YYDPRINTF ((stderr, "Now at end of input.\n"));
- }
- else
- {
- yytoken = YYTRANSLATE (yychar);
- YYDSYMPRINTF ("Next token is", yytoken, &yylval, &yylloc);
- }
-
- /* If the proper action on seeing token YYTOKEN is to reduce or to
- detect an error, take that action. */
- yyn += yytoken;
- if (yyn < 0 || YYLAST < yyn || yycheck[yyn] != yytoken)
- goto yydefault;
- yyn = yytable[yyn];
- if (yyn <= 0)
- {
- if (yyn == 0 || yyn == YYTABLE_NINF)
- goto yyerrlab;
- yyn = -yyn;
- goto yyreduce;
- }
-
- if (yyn == YYFINAL)
- YYACCEPT;
-
- /* Shift the lookahead token. */
- YYDPRINTF ((stderr, "Shifting token %s, ", yytname[yytoken]));
-
- /* Discard the token being shifted unless it is eof. */
- if (yychar != YYEOF)
- yychar = YYEMPTY;
-
- *++yyvsp = yylval;
-
+ struct
+ {
+ YYSTYPE yyv;
+ int yys;
+ } yys[YYMAXDEPTH], *yyp, *yypt;
+ const short *yyxi;
+ int yyj, yym, yystate, yyn, yyg;
+ long yychar;
+#ifndef YYARG
+ YYSTYPE save1, save2;
+ int save3, save4;
+
+ save1 = yylval;
+ save2 = yyval;
+ save3 = yynerrs;
+ save4 = yyerrflag;
+#endif
- /* Count tokens shifted since error; after three, turn off error
- status. */
- if (yyerrstatus)
- yyerrstatus--;
+ yystate = 0;
+ yychar = -1;
+ yynerrs = 0;
+ yyerrflag = 0;
+ yyp = &yys[-1];
+ goto yystack;
+
+ret0:
+ yyn = 0;
+ goto ret;
+
+ret1:
+ yyn = 1;
+ goto ret;
+
+ret:
+#ifndef YYARG
+ yylval = save1;
+ yyval = save2;
+ yynerrs = save3;
+ yyerrflag = save4;
+#endif
+ return yyn;
- yystate = yyn;
- goto yynewstate;
+yystack:
+ /* put a state and value onto the stack */
+ if(yydebug >= 4)
+ printf("char %s in %s", yytokname(yychar), yystatname(yystate));
+ yyp++;
+ if(yyp >= &yys[YYMAXDEPTH]) {
+ yyerror("yacc stack overflow");
+ goto ret1;
+ }
+ yyp->yys = yystate;
+ yyp->yyv = yyval;
+
+yynewstate:
+ yyn = yypact[yystate];
+ if(yyn <= YYFLAG)
+ goto yydefault; /* simple state */
+ if(yychar < 0)
+#ifdef YYARG
+ yychar = yylex1(yyarg);
+#else
+ yychar = yylex1();
+#endif
+ yyn += yychar;
+ if(yyn < 0 || yyn >= YYLAST)
+ goto yydefault;
+ yyn = yyact[yyn];
+ if(yychk[yyn] == yychar) { /* valid shift */
+ yychar = -1;
+ yyval = yylval;
+ yystate = yyn;
+ if(yyerrflag > 0)
+ yyerrflag--;
+ goto yystack;
+ }
-/*-----------------------------------------------------------.
-| yydefault -- do the default action for the current state. |
-`-----------------------------------------------------------*/
yydefault:
- yyn = yydefact[yystate];
- if (yyn == 0)
- goto yyerrlab;
- goto yyreduce;
-
-
-/*-----------------------------.
-| yyreduce -- Do a reduction. |
-`-----------------------------*/
-yyreduce:
- /* yyn is the number of a rule to reduce with. */
- yylen = yyr2[yyn];
-
- /* If YYLEN is nonzero, implement the default value of the action:
- `$$ = $1'.
-
- Otherwise, the following line sets YYVAL to garbage.
- This behavior is undocumented and Bison
- users should not rely upon it. Assigning to YYVAL
- unconditionally makes the parser a bit smaller, and it avoids a
- GCC warning that YYVAL may be used uninitialized. */
- yyval = yyvsp[1-yylen];
-
-
- YY_REDUCE_PRINT (yyn);
- switch (yyn)
- {
- case 2:
-#line 98 "awkgram.y"
- { if (errorflag==0)
- winner = (Node *)stat3(PROGRAM, beginloc, yyvsp[0].p, endloc); }
- break;
-
- case 3:
-#line 100 "awkgram.y"
- { yyclearin; bracecheck(); SYNTAX("bailing out"); }
- break;
-
- case 14:
-#line 124 "awkgram.y"
- {inloop++;}
- break;
-
- case 15:
-#line 125 "awkgram.y"
- { --inloop; yyval.p = stat4(FOR, yyvsp[-9].p, notnull(yyvsp[-6].p), yyvsp[-3].p, yyvsp[0].p); }
- break;
-
- case 16:
-#line 126 "awkgram.y"
- {inloop++;}
- break;
-
- case 17:
-#line 127 "awkgram.y"
- { --inloop; yyval.p = stat4(FOR, yyvsp[-7].p, NIL, yyvsp[-3].p, yyvsp[0].p); }
- break;
-
- case 18:
-#line 128 "awkgram.y"
- {inloop++;}
- break;
-
- case 19:
-#line 129 "awkgram.y"
- { --inloop; yyval.p = stat3(IN, yyvsp[-5].p, makearr(yyvsp[-3].p), yyvsp[0].p); }
- break;
-
- case 20:
-#line 133 "awkgram.y"
- { setfname(yyvsp[0].cp); }
- break;
-
- case 21:
-#line 134 "awkgram.y"
- { setfname(yyvsp[0].cp); }
- break;
-
- case 22:
-#line 138 "awkgram.y"
- { yyval.p = notnull(yyvsp[-1].p); }
- break;
-
- case 27:
-#line 150 "awkgram.y"
- { yyval.i = 0; }
- break;
-
- case 29:
-#line 155 "awkgram.y"
- { yyval.i = 0; }
- break;
-
- case 31:
-#line 161 "awkgram.y"
- { yyval.p = 0; }
- break;
-
- case 33:
-#line 166 "awkgram.y"
- { yyval.p = 0; }
- break;
-
- case 34:
-#line 167 "awkgram.y"
- { yyval.p = yyvsp[-1].p; }
- break;
-
- case 35:
-#line 171 "awkgram.y"
- { yyval.p = notnull(yyvsp[0].p); }
- break;
-
- case 36:
-#line 175 "awkgram.y"
- { yyval.p = stat2(PASTAT, yyvsp[0].p, stat2(PRINT, rectonode(), NIL)); }
- break;
-
- case 37:
-#line 176 "awkgram.y"
- { yyval.p = stat2(PASTAT, yyvsp[-3].p, yyvsp[-1].p); }
- break;
-
- case 38:
-#line 177 "awkgram.y"
- { yyval.p = pa2stat(yyvsp[-2].p, yyvsp[0].p, stat2(PRINT, rectonode(), NIL)); }
- break;
-
- case 39:
-#line 178 "awkgram.y"
- { yyval.p = pa2stat(yyvsp[-5].p, yyvsp[-3].p, yyvsp[-1].p); }
- break;
-
- case 40:
-#line 179 "awkgram.y"
- { yyval.p = stat2(PASTAT, NIL, yyvsp[-1].p); }
- break;
-
- case 41:
-#line 181 "awkgram.y"
- { beginloc = linkum(beginloc, yyvsp[-1].p); yyval.p = 0; }
- break;
-
- case 42:
-#line 183 "awkgram.y"
- { endloc = linkum(endloc, yyvsp[-1].p); yyval.p = 0; }
- break;
-
- case 43:
-#line 184 "awkgram.y"
- {infunc++;}
- break;
-
- case 44:
-#line 185 "awkgram.y"
- { infunc--; curfname=0; defn((Cell *)yyvsp[-7].p, yyvsp[-5].p, yyvsp[-1].p); yyval.p = 0; }
- break;
-
- case 46:
-#line 190 "awkgram.y"
- { yyval.p = linkum(yyvsp[-2].p, yyvsp[0].p); }
- break;
-
- case 48:
-#line 195 "awkgram.y"
- { yyval.p = linkum(yyvsp[-2].p, yyvsp[0].p); }
- break;
-
- case 49:
-#line 199 "awkgram.y"
- { yyval.p = op2(yyvsp[-1].i, yyvsp[-2].p, yyvsp[0].p); }
- break;
-
- case 50:
-#line 201 "awkgram.y"
- { yyval.p = op3(CONDEXPR, notnull(yyvsp[-4].p), yyvsp[-2].p, yyvsp[0].p); }
- break;
-
- case 51:
-#line 203 "awkgram.y"
- { yyval.p = op2(BOR, notnull(yyvsp[-2].p), notnull(yyvsp[0].p)); }
- break;
-
- case 52:
-#line 205 "awkgram.y"
- { yyval.p = op2(AND, notnull(yyvsp[-2].p), notnull(yyvsp[0].p)); }
- break;
+ /* default state action */
+ yyn = yydef[yystate];
+ if(yyn == -2) {
+ if(yychar < 0)
+#ifdef YYARG
+ yychar = yylex1(yyarg);
+#else
+ yychar = yylex1();
+#endif
- case 53:
-#line 206 "awkgram.y"
- { yyval.p = op3(yyvsp[-1].i, NIL, yyvsp[-2].p, (Node*)makedfa(yyvsp[0].s, 0)); }
- break;
+ /* look through exception table */
+ for(yyxi=yyexca;; yyxi+=2)
+ if(yyxi[0] == -1 && yyxi[1] == yystate)
+ break;
+ for(yyxi += 2;; yyxi += 2) {
+ yyn = yyxi[0];
+ if(yyn < 0 || yyn == yychar)
+ break;
+ }
+ yyn = yyxi[1];
+ if(yyn < 0)
+ goto ret0;
+ }
+ if(yyn == 0) {
+ /* error ... attempt to resume parsing */
+ switch(yyerrflag) {
+ case 0: /* brand new error */
+ yyerror("syntax error");
+ if(yydebug >= 1) {
+ printf("%s", yystatname(yystate));
+ printf("saw %s\n", yytokname(yychar));
+ }
+ goto yyerrlab;
+ yyerrlab:
+ yynerrs++;
+
+ case 1:
+ case 2: /* incompletely recovered error ... try again */
+ yyerrflag = 3;
+
+ /* find a state where "error" is a legal shift action */
+ while(yyp >= yys) {
+ yyn = yypact[yyp->yys] + YYERRCODE;
+ if(yyn >= 0 && yyn < YYLAST) {
+ yystate = yyact[yyn]; /* simulate a shift of "error" */
+ if(yychk[yystate] == YYERRCODE)
+ goto yystack;
+ }
+
+ /* the current yyp has no shift onn "error", pop stack */
+ if(yydebug >= 2)
+ printf("error recovery pops state %d, uncovers %d\n",
+ yyp->yys, (yyp-1)->yys );
+ yyp--;
+ }
+ /* there is no state on the stack with an error shift ... abort */
+ goto ret1;
+
+ case 3: /* no shift yet; clobber input char */
+ if(yydebug >= YYEOFCODE)
+ printf("error recovery discards %s\n", yytokname(yychar));
+ if(yychar == YYEOFCODE)
+ goto ret1;
+ yychar = -1;
+ goto yynewstate; /* try again in the same state */
+ }
+ }
- case 54:
-#line 208 "awkgram.y"
- { if (constnode(yyvsp[0].p))
- yyval.p = op3(yyvsp[-1].i, NIL, yyvsp[-2].p, (Node*)makedfa(strnode(yyvsp[0].p), 0));
+ /* reduction by production yyn */
+ if(yydebug >= 2)
+ printf("reduce %d in:\n\t%s", yyn, yystatname(yystate));
+
+ yypt = yyp;
+ yyp -= yyr2[yyn];
+ yyval = (yyp+1)->yyv;
+ yym = yyn;
+
+ /* consult goto table to find next state */
+ yyn = yyr1[yyn];
+ yyg = yypgo[yyn];
+ yyj = yyg + yyp->yys + 1;
+
+ if(yyj >= YYLAST || yychk[yystate=yyact[yyj]] != -yyn)
+ yystate = yyact[yyg];
+ switch(yym) {
+
+case 1:
+#line 98 "/n/fs/fac/bwk/awk/awkgram.y"
+{ if (errorflag==0)
+ winner = (Node *)stat3(PROGRAM, beginloc, yypt[-0].yyv.p, endloc); } break;
+case 2:
+#line 100 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyclearin; bracecheck(); SYNTAX("bailing out"); } break;
+case 13:
+#line 124 "/n/fs/fac/bwk/awk/awkgram.y"
+{inloop++;} break;
+case 14:
+#line 125 "/n/fs/fac/bwk/awk/awkgram.y"
+{ --inloop; yyval.p = stat4(FOR, yypt[-9].yyv.p, notnull(yypt[-6].yyv.p), yypt[-3].yyv.p, yypt[-0].yyv.p); } break;
+case 15:
+#line 126 "/n/fs/fac/bwk/awk/awkgram.y"
+{inloop++;} break;
+case 16:
+#line 127 "/n/fs/fac/bwk/awk/awkgram.y"
+{ --inloop; yyval.p = stat4(FOR, yypt[-7].yyv.p, NIL, yypt[-3].yyv.p, yypt[-0].yyv.p); } break;
+case 17:
+#line 128 "/n/fs/fac/bwk/awk/awkgram.y"
+{inloop++;} break;
+case 18:
+#line 129 "/n/fs/fac/bwk/awk/awkgram.y"
+{ --inloop; yyval.p = stat3(IN, yypt[-5].yyv.p, makearr(yypt[-3].yyv.p), yypt[-0].yyv.p); } break;
+case 19:
+#line 133 "/n/fs/fac/bwk/awk/awkgram.y"
+{ setfname(yypt[-0].yyv.cp); } break;
+case 20:
+#line 134 "/n/fs/fac/bwk/awk/awkgram.y"
+{ setfname(yypt[-0].yyv.cp); } break;
+case 21:
+#line 138 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = notnull(yypt[-1].yyv.p); } break;
+case 26:
+#line 150 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.i = 0; } break;
+case 28:
+#line 155 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.i = 0; } break;
+case 30:
+#line 161 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = 0; } break;
+case 32:
+#line 166 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = 0; } break;
+case 33:
+#line 167 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = yypt[-1].yyv.p; } break;
+case 34:
+#line 171 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = notnull(yypt[-0].yyv.p); } break;
+case 35:
+#line 175 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = stat2(PASTAT, yypt[-0].yyv.p, stat2(PRINT, rectonode(), NIL)); } break;
+case 36:
+#line 176 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = stat2(PASTAT, yypt[-3].yyv.p, yypt[-1].yyv.p); } break;
+case 37:
+#line 177 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = pa2stat(yypt[-3].yyv.p, yypt[-0].yyv.p, stat2(PRINT, rectonode(), NIL)); } break;
+case 38:
+#line 178 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = pa2stat(yypt[-6].yyv.p, yypt[-3].yyv.p, yypt[-1].yyv.p); } break;
+case 39:
+#line 179 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = stat2(PASTAT, NIL, yypt[-1].yyv.p); } break;
+case 40:
+#line 181 "/n/fs/fac/bwk/awk/awkgram.y"
+{ beginloc = linkum(beginloc, yypt[-1].yyv.p); yyval.p = 0; } break;
+case 41:
+#line 183 "/n/fs/fac/bwk/awk/awkgram.y"
+{ endloc = linkum(endloc, yypt[-1].yyv.p); yyval.p = 0; } break;
+case 42:
+#line 184 "/n/fs/fac/bwk/awk/awkgram.y"
+{infunc++;} break;
+case 43:
+#line 185 "/n/fs/fac/bwk/awk/awkgram.y"
+{ infunc--; curfname=0; defn((Cell *)yypt[-7].yyv.p, yypt[-5].yyv.p, yypt[-1].yyv.p); yyval.p = 0; } break;
+case 45:
+#line 190 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = linkum(yypt[-2].yyv.p, yypt[-0].yyv.p); } break;
+case 47:
+#line 195 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = linkum(yypt[-2].yyv.p, yypt[-0].yyv.p); } break;
+case 48:
+#line 199 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op2(yypt[-1].yyv.i, yypt[-2].yyv.p, yypt[-0].yyv.p); } break;
+case 49:
+#line 201 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op3(CONDEXPR, notnull(yypt[-4].yyv.p), yypt[-2].yyv.p, yypt[-0].yyv.p); } break;
+case 50:
+#line 203 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op2(BOR, notnull(yypt[-2].yyv.p), notnull(yypt[-0].yyv.p)); } break;
+case 51:
+#line 205 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op2(AND, notnull(yypt[-2].yyv.p), notnull(yypt[-0].yyv.p)); } break;
+case 52:
+#line 206 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op3(yypt[-1].yyv.i, NIL, yypt[-2].yyv.p, (Node*)makedfa(yypt[-0].yyv.s, 0)); } break;
+case 53:
+#line 208 "/n/fs/fac/bwk/awk/awkgram.y"
+{ if (constnode(yypt[-0].yyv.p))
+ yyval.p = op3(yypt[-1].yyv.i, NIL, yypt[-2].yyv.p, (Node*)makedfa(strnode(yypt[-0].yyv.p), 0));
else
- yyval.p = op3(yyvsp[-1].i, (Node *)1, yyvsp[-2].p, yyvsp[0].p); }
- break;
-
- case 55:
-#line 212 "awkgram.y"
- { yyval.p = op2(INTEST, yyvsp[-2].p, makearr(yyvsp[0].p)); }
- break;
-
- case 56:
-#line 213 "awkgram.y"
- { yyval.p = op2(INTEST, yyvsp[-3].p, makearr(yyvsp[0].p)); }
- break;
-
- case 57:
-#line 214 "awkgram.y"
- { yyval.p = op2(CAT, yyvsp[-1].p, yyvsp[0].p); }
- break;
-
- case 60:
-#line 220 "awkgram.y"
- { yyval.p = op2(yyvsp[-1].i, yyvsp[-2].p, yyvsp[0].p); }
- break;
-
- case 61:
-#line 222 "awkgram.y"
- { yyval.p = op3(CONDEXPR, notnull(yyvsp[-4].p), yyvsp[-2].p, yyvsp[0].p); }
- break;
-
- case 62:
-#line 224 "awkgram.y"
- { yyval.p = op2(BOR, notnull(yyvsp[-2].p), notnull(yyvsp[0].p)); }
- break;
-
- case 63:
-#line 226 "awkgram.y"
- { yyval.p = op2(AND, notnull(yyvsp[-2].p), notnull(yyvsp[0].p)); }
- break;
-
- case 64:
-#line 227 "awkgram.y"
- { yyval.p = op2(yyvsp[-1].i, yyvsp[-2].p, yyvsp[0].p); }
- break;
-
- case 65:
-#line 228 "awkgram.y"
- { yyval.p = op2(yyvsp[-1].i, yyvsp[-2].p, yyvsp[0].p); }
- break;
-
- case 66:
-#line 229 "awkgram.y"
- { yyval.p = op2(yyvsp[-1].i, yyvsp[-2].p, yyvsp[0].p); }
- break;
-
- case 67:
-#line 230 "awkgram.y"
- { yyval.p = op2(yyvsp[-1].i, yyvsp[-2].p, yyvsp[0].p); }
- break;
-
- case 68:
-#line 231 "awkgram.y"
- { yyval.p = op2(yyvsp[-1].i, yyvsp[-2].p, yyvsp[0].p); }
- break;
-
- case 69:
-#line 232 "awkgram.y"
- { yyval.p = op2(yyvsp[-1].i, yyvsp[-2].p, yyvsp[0].p); }
- break;
-
- case 70:
-#line 233 "awkgram.y"
- { yyval.p = op3(yyvsp[-1].i, NIL, yyvsp[-2].p, (Node*)makedfa(yyvsp[0].s, 0)); }
- break;
-
- case 71:
-#line 235 "awkgram.y"
- { if (constnode(yyvsp[0].p))
- yyval.p = op3(yyvsp[-1].i, NIL, yyvsp[-2].p, (Node*)makedfa(strnode(yyvsp[0].p), 0));
+ yyval.p = op3(yypt[-1].yyv.i, (Node *)1, yypt[-2].yyv.p, yypt[-0].yyv.p); } break;
+case 54:
+#line 212 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op2(INTEST, yypt[-2].yyv.p, makearr(yypt[-0].yyv.p)); } break;
+case 55:
+#line 213 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op2(INTEST, yypt[-3].yyv.p, makearr(yypt[-0].yyv.p)); } break;
+case 56:
+#line 214 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op2(CAT, yypt[-1].yyv.p, yypt[-0].yyv.p); } break;
+case 59:
+#line 220 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op2(yypt[-1].yyv.i, yypt[-2].yyv.p, yypt[-0].yyv.p); } break;
+case 60:
+#line 222 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op3(CONDEXPR, notnull(yypt[-4].yyv.p), yypt[-2].yyv.p, yypt[-0].yyv.p); } break;
+case 61:
+#line 224 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op2(BOR, notnull(yypt[-2].yyv.p), notnull(yypt[-0].yyv.p)); } break;
+case 62:
+#line 226 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op2(AND, notnull(yypt[-2].yyv.p), notnull(yypt[-0].yyv.p)); } break;
+case 63:
+#line 227 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op2(yypt[-1].yyv.i, yypt[-2].yyv.p, yypt[-0].yyv.p); } break;
+case 64:
+#line 228 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op2(yypt[-1].yyv.i, yypt[-2].yyv.p, yypt[-0].yyv.p); } break;
+case 65:
+#line 229 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op2(yypt[-1].yyv.i, yypt[-2].yyv.p, yypt[-0].yyv.p); } break;
+case 66:
+#line 230 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op2(yypt[-1].yyv.i, yypt[-2].yyv.p, yypt[-0].yyv.p); } break;
+case 67:
+#line 231 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op2(yypt[-1].yyv.i, yypt[-2].yyv.p, yypt[-0].yyv.p); } break;
+case 68:
+#line 232 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op2(yypt[-1].yyv.i, yypt[-2].yyv.p, yypt[-0].yyv.p); } break;
+case 69:
+#line 233 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op3(yypt[-1].yyv.i, NIL, yypt[-2].yyv.p, (Node*)makedfa(yypt[-0].yyv.s, 0)); } break;
+case 70:
+#line 235 "/n/fs/fac/bwk/awk/awkgram.y"
+{ if (constnode(yypt[-0].yyv.p))
+ yyval.p = op3(yypt[-1].yyv.i, NIL, yypt[-2].yyv.p, (Node*)makedfa(strnode(yypt[-0].yyv.p), 0));
else
- yyval.p = op3(yyvsp[-1].i, (Node *)1, yyvsp[-2].p, yyvsp[0].p); }
- break;
-
- case 72:
-#line 239 "awkgram.y"
- { yyval.p = op2(INTEST, yyvsp[-2].p, makearr(yyvsp[0].p)); }
- break;
-
- case 73:
-#line 240 "awkgram.y"
- { yyval.p = op2(INTEST, yyvsp[-3].p, makearr(yyvsp[0].p)); }
- break;
-
- case 74:
-#line 241 "awkgram.y"
- {
+ yyval.p = op3(yypt[-1].yyv.i, (Node *)1, yypt[-2].yyv.p, yypt[-0].yyv.p); } break;
+case 71:
+#line 239 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op2(INTEST, yypt[-2].yyv.p, makearr(yypt[-0].yyv.p)); } break;
+case 72:
+#line 240 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op2(INTEST, yypt[-3].yyv.p, makearr(yypt[-0].yyv.p)); } break;
+case 73:
+#line 241 "/n/fs/fac/bwk/awk/awkgram.y"
+{
if (safe) SYNTAX("cmd | getline is unsafe");
- else yyval.p = op3(GETLINE, yyvsp[0].p, itonp(yyvsp[-2].i), yyvsp[-3].p); }
- break;
-
- case 75:
-#line 244 "awkgram.y"
- {
+ else yyval.p = op3(GETLINE, yypt[-0].yyv.p, itonp(yypt[-2].yyv.i), yypt[-3].yyv.p); } break;
+case 74:
+#line 244 "/n/fs/fac/bwk/awk/awkgram.y"
+{
if (safe) SYNTAX("cmd | getline is unsafe");
- else yyval.p = op3(GETLINE, (Node*)0, itonp(yyvsp[-1].i), yyvsp[-2].p); }
- break;
-
- case 76:
-#line 247 "awkgram.y"
- { yyval.p = op2(CAT, yyvsp[-1].p, yyvsp[0].p); }
- break;
-
- case 79:
-#line 253 "awkgram.y"
- { yyval.p = linkum(yyvsp[-2].p, yyvsp[0].p); }
- break;
-
- case 80:
-#line 254 "awkgram.y"
- { yyval.p = linkum(yyvsp[-2].p, yyvsp[0].p); }
- break;
-
- case 82:
-#line 259 "awkgram.y"
- { yyval.p = linkum(yyvsp[-2].p, yyvsp[0].p); }
- break;
-
- case 83:
-#line 263 "awkgram.y"
- { yyval.p = rectonode(); }
- break;
-
- case 85:
-#line 265 "awkgram.y"
- { yyval.p = yyvsp[-1].p; }
- break;
-
- case 94:
-#line 282 "awkgram.y"
- { yyval.p = op3(MATCH, NIL, rectonode(), (Node*)makedfa(yyvsp[0].s, 0)); }
- break;
-
- case 95:
-#line 283 "awkgram.y"
- { yyval.p = op1(NOT, notnull(yyvsp[0].p)); }
- break;
-
- case 96:
-#line 287 "awkgram.y"
- {startreg();}
- break;
-
- case 97:
-#line 287 "awkgram.y"
- { yyval.s = yyvsp[-1].s; }
- break;
-
- case 100:
-#line 295 "awkgram.y"
- {
+ else yyval.p = op3(GETLINE, (Node*)0, itonp(yypt[-1].yyv.i), yypt[-2].yyv.p); } break;
+case 75:
+#line 247 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op2(CAT, yypt[-1].yyv.p, yypt[-0].yyv.p); } break;
+case 78:
+#line 253 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = linkum(yypt[-2].yyv.p, yypt[-0].yyv.p); } break;
+case 79:
+#line 254 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = linkum(yypt[-2].yyv.p, yypt[-0].yyv.p); } break;
+case 81:
+#line 259 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = linkum(yypt[-2].yyv.p, yypt[-0].yyv.p); } break;
+case 82:
+#line 263 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = rectonode(); } break;
+case 84:
+#line 265 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = yypt[-1].yyv.p; } break;
+case 93:
+#line 282 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op3(MATCH, NIL, rectonode(), (Node*)makedfa(yypt[-0].yyv.s, 0)); } break;
+case 94:
+#line 283 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op1(NOT, notnull(yypt[-0].yyv.p)); } break;
+case 95:
+#line 287 "/n/fs/fac/bwk/awk/awkgram.y"
+{startreg();} break;
+case 96:
+#line 287 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.s = yypt[-1].yyv.s; } break;
+case 99:
+#line 295 "/n/fs/fac/bwk/awk/awkgram.y"
+{
if (safe) SYNTAX("print | is unsafe");
- else yyval.p = stat3(yyvsp[-3].i, yyvsp[-2].p, itonp(yyvsp[-1].i), yyvsp[0].p); }
- break;
-
- case 101:
-#line 298 "awkgram.y"
- {
+ else yyval.p = stat3(yypt[-3].yyv.i, yypt[-2].yyv.p, itonp(yypt[-1].yyv.i), yypt[-0].yyv.p); } break;
+case 100:
+#line 298 "/n/fs/fac/bwk/awk/awkgram.y"
+{
if (safe) SYNTAX("print >> is unsafe");
- else yyval.p = stat3(yyvsp[-3].i, yyvsp[-2].p, itonp(yyvsp[-1].i), yyvsp[0].p); }
- break;
-
- case 102:
-#line 301 "awkgram.y"
- {
+ else yyval.p = stat3(yypt[-3].yyv.i, yypt[-2].yyv.p, itonp(yypt[-1].yyv.i), yypt[-0].yyv.p); } break;
+case 101:
+#line 301 "/n/fs/fac/bwk/awk/awkgram.y"
+{
if (safe) SYNTAX("print > is unsafe");
- else yyval.p = stat3(yyvsp[-3].i, yyvsp[-2].p, itonp(yyvsp[-1].i), yyvsp[0].p); }
- break;
-
- case 103:
-#line 304 "awkgram.y"
- { yyval.p = stat3(yyvsp[-1].i, yyvsp[0].p, NIL, NIL); }
- break;
-
- case 104:
-#line 305 "awkgram.y"
- { yyval.p = stat2(DELETE, makearr(yyvsp[-3].p), yyvsp[-1].p); }
- break;
-
- case 105:
-#line 306 "awkgram.y"
- { yyval.p = stat2(DELETE, makearr(yyvsp[0].p), 0); }
- break;
-
- case 106:
-#line 307 "awkgram.y"
- { yyval.p = exptostat(yyvsp[0].p); }
- break;
-
- case 107:
-#line 308 "awkgram.y"
- { yyclearin; SYNTAX("illegal statement"); }
- break;
-
- case 110:
-#line 317 "awkgram.y"
- { if (!inloop) SYNTAX("break illegal outside of loops");
- yyval.p = stat1(BREAK, NIL); }
- break;
-
- case 111:
-#line 319 "awkgram.y"
- { if (!inloop) SYNTAX("continue illegal outside of loops");
- yyval.p = stat1(CONTINUE, NIL); }
- break;
-
- case 112:
-#line 321 "awkgram.y"
- {inloop++;}
- break;
-
- case 113:
-#line 321 "awkgram.y"
- {--inloop;}
- break;
-
- case 114:
-#line 322 "awkgram.y"
- { yyval.p = stat2(DO, yyvsp[-6].p, notnull(yyvsp[-2].p)); }
- break;
-
- case 115:
-#line 323 "awkgram.y"
- { yyval.p = stat1(EXIT, yyvsp[-1].p); }
- break;
-
- case 116:
-#line 324 "awkgram.y"
- { yyval.p = stat1(EXIT, NIL); }
- break;
-
- case 118:
-#line 326 "awkgram.y"
- { yyval.p = stat3(IF, yyvsp[-3].p, yyvsp[-2].p, yyvsp[0].p); }
- break;
-
- case 119:
-#line 327 "awkgram.y"
- { yyval.p = stat3(IF, yyvsp[-1].p, yyvsp[0].p, NIL); }
- break;
-
- case 120:
-#line 328 "awkgram.y"
- { yyval.p = yyvsp[-1].p; }
- break;
-
- case 121:
-#line 329 "awkgram.y"
- { if (infunc)
+ else yyval.p = stat3(yypt[-3].yyv.i, yypt[-2].yyv.p, itonp(yypt[-1].yyv.i), yypt[-0].yyv.p); } break;
+case 102:
+#line 304 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = stat3(yypt[-1].yyv.i, yypt[-0].yyv.p, NIL, NIL); } break;
+case 103:
+#line 305 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = stat2(DELETE, makearr(yypt[-3].yyv.p), yypt[-1].yyv.p); } break;
+case 104:
+#line 306 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = stat2(DELETE, makearr(yypt[-0].yyv.p), 0); } break;
+case 105:
+#line 307 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = exptostat(yypt[-0].yyv.p); } break;
+case 106:
+#line 308 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyclearin; SYNTAX("illegal statement"); } break;
+case 109:
+#line 317 "/n/fs/fac/bwk/awk/awkgram.y"
+{ if (!inloop) SYNTAX("break illegal outside of loops");
+ yyval.p = stat1(BREAK, NIL); } break;
+case 110:
+#line 319 "/n/fs/fac/bwk/awk/awkgram.y"
+{ if (!inloop) SYNTAX("continue illegal outside of loops");
+ yyval.p = stat1(CONTINUE, NIL); } break;
+case 111:
+#line 321 "/n/fs/fac/bwk/awk/awkgram.y"
+{inloop++;} break;
+case 112:
+#line 321 "/n/fs/fac/bwk/awk/awkgram.y"
+{--inloop;} break;
+case 113:
+#line 322 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = stat2(DO, yypt[-6].yyv.p, notnull(yypt[-2].yyv.p)); } break;
+case 114:
+#line 323 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = stat1(EXIT, yypt[-1].yyv.p); } break;
+case 115:
+#line 324 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = stat1(EXIT, NIL); } break;
+case 117:
+#line 326 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = stat3(IF, yypt[-3].yyv.p, yypt[-2].yyv.p, yypt[-0].yyv.p); } break;
+case 118:
+#line 327 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = stat3(IF, yypt[-1].yyv.p, yypt[-0].yyv.p, NIL); } break;
+case 119:
+#line 328 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = yypt[-1].yyv.p; } break;
+case 120:
+#line 329 "/n/fs/fac/bwk/awk/awkgram.y"
+{ if (infunc)
SYNTAX("next is illegal inside a function");
- yyval.p = stat1(NEXT, NIL); }
- break;
-
- case 122:
-#line 332 "awkgram.y"
- { if (infunc)
+ yyval.p = stat1(NEXT, NIL); } break;
+case 121:
+#line 332 "/n/fs/fac/bwk/awk/awkgram.y"
+{ if (infunc)
SYNTAX("nextfile is illegal inside a function");
- yyval.p = stat1(NEXTFILE, NIL); }
- break;
-
- case 123:
-#line 335 "awkgram.y"
- { yyval.p = stat1(RETURN, yyvsp[-1].p); }
- break;
-
- case 124:
-#line 336 "awkgram.y"
- { yyval.p = stat1(RETURN, NIL); }
- break;
-
- case 126:
-#line 338 "awkgram.y"
- {inloop++;}
- break;
-
- case 127:
-#line 338 "awkgram.y"
- { --inloop; yyval.p = stat2(WHILE, yyvsp[-2].p, yyvsp[0].p); }
- break;
-
- case 128:
-#line 339 "awkgram.y"
- { yyval.p = 0; }
- break;
-
- case 130:
-#line 344 "awkgram.y"
- { yyval.p = linkum(yyvsp[-1].p, yyvsp[0].p); }
- break;
-
- case 133:
-#line 352 "awkgram.y"
- { yyval.p = op2(DIVEQ, yyvsp[-3].p, yyvsp[0].p); }
- break;
-
- case 134:
-#line 353 "awkgram.y"
- { yyval.p = op2(ADD, yyvsp[-2].p, yyvsp[0].p); }
- break;
-
- case 135:
-#line 354 "awkgram.y"
- { yyval.p = op2(MINUS, yyvsp[-2].p, yyvsp[0].p); }
- break;
-
- case 136:
-#line 355 "awkgram.y"
- { yyval.p = op2(MULT, yyvsp[-2].p, yyvsp[0].p); }
- break;
-
- case 137:
-#line 356 "awkgram.y"
- { yyval.p = op2(DIVIDE, yyvsp[-2].p, yyvsp[0].p); }
- break;
-
- case 138:
-#line 357 "awkgram.y"
- { yyval.p = op2(MOD, yyvsp[-2].p, yyvsp[0].p); }
- break;
-
- case 139:
-#line 358 "awkgram.y"
- { yyval.p = op2(POWER, yyvsp[-2].p, yyvsp[0].p); }
- break;
-
- case 140:
-#line 359 "awkgram.y"
- { yyval.p = op1(UMINUS, yyvsp[0].p); }
- break;
-
- case 141:
-#line 360 "awkgram.y"
- { yyval.p = yyvsp[0].p; }
- break;
-
- case 142:
-#line 361 "awkgram.y"
- { yyval.p = op1(NOT, notnull(yyvsp[0].p)); }
- break;
-
- case 143:
-#line 362 "awkgram.y"
- { yyval.p = op2(BLTIN, itonp(yyvsp[-2].i), rectonode()); }
- break;
-
- case 144:
-#line 363 "awkgram.y"
- { yyval.p = op2(BLTIN, itonp(yyvsp[-3].i), yyvsp[-1].p); }
- break;
-
- case 145:
-#line 364 "awkgram.y"
- { yyval.p = op2(BLTIN, itonp(yyvsp[0].i), rectonode()); }
- break;
-
- case 146:
-#line 365 "awkgram.y"
- { yyval.p = op2(CALL, celltonode(yyvsp[-2].cp,CVAR), NIL); }
- break;
-
- case 147:
-#line 366 "awkgram.y"
- { yyval.p = op2(CALL, celltonode(yyvsp[-3].cp,CVAR), yyvsp[-1].p); }
- break;
-
- case 148:
-#line 367 "awkgram.y"
- { yyval.p = op1(CLOSE, yyvsp[0].p); }
- break;
-
- case 149:
-#line 368 "awkgram.y"
- { yyval.p = op1(PREDECR, yyvsp[0].p); }
- break;
-
- case 150:
-#line 369 "awkgram.y"
- { yyval.p = op1(PREINCR, yyvsp[0].p); }
- break;
-
- case 151:
-#line 370 "awkgram.y"
- { yyval.p = op1(POSTDECR, yyvsp[-1].p); }
- break;
-
- case 152:
-#line 371 "awkgram.y"
- { yyval.p = op1(POSTINCR, yyvsp[-1].p); }
- break;
-
- case 153:
-#line 372 "awkgram.y"
- { yyval.p = op3(GETLINE, yyvsp[-2].p, itonp(yyvsp[-1].i), yyvsp[0].p); }
- break;
-
- case 154:
-#line 373 "awkgram.y"
- { yyval.p = op3(GETLINE, NIL, itonp(yyvsp[-1].i), yyvsp[0].p); }
- break;
-
- case 155:
-#line 374 "awkgram.y"
- { yyval.p = op3(GETLINE, yyvsp[0].p, NIL, NIL); }
- break;
-
- case 156:
-#line 375 "awkgram.y"
- { yyval.p = op3(GETLINE, NIL, NIL, NIL); }
- break;
-
- case 157:
-#line 377 "awkgram.y"
- { yyval.p = op2(INDEX, yyvsp[-3].p, yyvsp[-1].p); }
- break;
-
- case 158:
-#line 379 "awkgram.y"
- { SYNTAX("index() doesn't permit regular expressions");
- yyval.p = op2(INDEX, yyvsp[-3].p, (Node*)yyvsp[-1].s); }
- break;
-
- case 159:
-#line 381 "awkgram.y"
- { yyval.p = yyvsp[-1].p; }
- break;
-
- case 160:
-#line 383 "awkgram.y"
- { yyval.p = op3(MATCHFCN, NIL, yyvsp[-3].p, (Node*)makedfa(yyvsp[-1].s, 1)); }
- break;
-
- case 161:
-#line 385 "awkgram.y"
- { if (constnode(yyvsp[-1].p))
- yyval.p = op3(MATCHFCN, NIL, yyvsp[-3].p, (Node*)makedfa(strnode(yyvsp[-1].p), 1));
+ yyval.p = stat1(NEXTFILE, NIL); } break;
+case 122:
+#line 335 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = stat1(RETURN, yypt[-1].yyv.p); } break;
+case 123:
+#line 336 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = stat1(RETURN, NIL); } break;
+case 125:
+#line 338 "/n/fs/fac/bwk/awk/awkgram.y"
+{inloop++;} break;
+case 126:
+#line 338 "/n/fs/fac/bwk/awk/awkgram.y"
+{ --inloop; yyval.p = stat2(WHILE, yypt[-2].yyv.p, yypt[-0].yyv.p); } break;
+case 127:
+#line 339 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = 0; } break;
+case 129:
+#line 344 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = linkum(yypt[-1].yyv.p, yypt[-0].yyv.p); } break;
+case 132:
+#line 352 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op2(DIVEQ, yypt[-3].yyv.p, yypt[-0].yyv.p); } break;
+case 133:
+#line 353 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op2(ADD, yypt[-2].yyv.p, yypt[-0].yyv.p); } break;
+case 134:
+#line 354 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op2(MINUS, yypt[-2].yyv.p, yypt[-0].yyv.p); } break;
+case 135:
+#line 355 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op2(MULT, yypt[-2].yyv.p, yypt[-0].yyv.p); } break;
+case 136:
+#line 356 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op2(DIVIDE, yypt[-2].yyv.p, yypt[-0].yyv.p); } break;
+case 137:
+#line 357 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op2(MOD, yypt[-2].yyv.p, yypt[-0].yyv.p); } break;
+case 138:
+#line 358 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op2(POWER, yypt[-2].yyv.p, yypt[-0].yyv.p); } break;
+case 139:
+#line 359 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op1(UMINUS, yypt[-0].yyv.p); } break;
+case 140:
+#line 360 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = yypt[-0].yyv.p; } break;
+case 141:
+#line 361 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op1(NOT, notnull(yypt[-0].yyv.p)); } break;
+case 142:
+#line 362 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op2(BLTIN, itonp(yypt[-2].yyv.i), rectonode()); } break;
+case 143:
+#line 363 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op2(BLTIN, itonp(yypt[-3].yyv.i), yypt[-1].yyv.p); } break;
+case 144:
+#line 364 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op2(BLTIN, itonp(yypt[-0].yyv.i), rectonode()); } break;
+case 145:
+#line 365 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op2(CALL, celltonode(yypt[-2].yyv.cp,CVAR), NIL); } break;
+case 146:
+#line 366 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op2(CALL, celltonode(yypt[-3].yyv.cp,CVAR), yypt[-1].yyv.p); } break;
+case 147:
+#line 367 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op1(CLOSE, yypt[-0].yyv.p); } break;
+case 148:
+#line 368 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op1(PREDECR, yypt[-0].yyv.p); } break;
+case 149:
+#line 369 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op1(PREINCR, yypt[-0].yyv.p); } break;
+case 150:
+#line 370 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op1(POSTDECR, yypt[-1].yyv.p); } break;
+case 151:
+#line 371 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op1(POSTINCR, yypt[-1].yyv.p); } break;
+case 152:
+#line 372 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op3(GETLINE, yypt[-2].yyv.p, itonp(yypt[-1].yyv.i), yypt[-0].yyv.p); } break;
+case 153:
+#line 373 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op3(GETLINE, NIL, itonp(yypt[-1].yyv.i), yypt[-0].yyv.p); } break;
+case 154:
+#line 374 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op3(GETLINE, yypt[-0].yyv.p, NIL, NIL); } break;
+case 155:
+#line 375 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op3(GETLINE, NIL, NIL, NIL); } break;
+case 156:
+#line 377 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op2(INDEX, yypt[-3].yyv.p, yypt[-1].yyv.p); } break;
+case 157:
+#line 379 "/n/fs/fac/bwk/awk/awkgram.y"
+{ SYNTAX("index() doesn't permit regular expressions");
+ yyval.p = op2(INDEX, yypt[-3].yyv.p, (Node*)yypt[-1].yyv.s); } break;
+case 158:
+#line 381 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = yypt[-1].yyv.p; } break;
+case 159:
+#line 383 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op3(MATCHFCN, NIL, yypt[-3].yyv.p, (Node*)makedfa(yypt[-1].yyv.s, 1)); } break;
+case 160:
+#line 385 "/n/fs/fac/bwk/awk/awkgram.y"
+{ if (constnode(yypt[-1].yyv.p))
+ yyval.p = op3(MATCHFCN, NIL, yypt[-3].yyv.p, (Node*)makedfa(strnode(yypt[-1].yyv.p), 1));
else
- yyval.p = op3(MATCHFCN, (Node *)1, yyvsp[-3].p, yyvsp[-1].p); }
- break;
-
- case 162:
-#line 389 "awkgram.y"
- { yyval.p = celltonode(yyvsp[0].cp, CCON); }
- break;
-
- case 163:
-#line 391 "awkgram.y"
- { yyval.p = op4(SPLIT, yyvsp[-5].p, makearr(yyvsp[-3].p), yyvsp[-1].p, (Node*)STRING); }
- break;
-
- case 164:
-#line 393 "awkgram.y"
- { yyval.p = op4(SPLIT, yyvsp[-5].p, makearr(yyvsp[-3].p), (Node*)makedfa(yyvsp[-1].s, 1), (Node *)REGEXPR); }
- break;
-
- case 165:
-#line 395 "awkgram.y"
- { yyval.p = op4(SPLIT, yyvsp[-3].p, makearr(yyvsp[-1].p), NIL, (Node*)STRING); }
- break;
-
- case 166:
-#line 396 "awkgram.y"
- { yyval.p = op1(yyvsp[-3].i, yyvsp[-1].p); }
- break;
-
- case 167:
-#line 397 "awkgram.y"
- { yyval.p = celltonode(yyvsp[0].cp, CCON); }
- break;
-
- case 168:
-#line 399 "awkgram.y"
- { yyval.p = op4(yyvsp[-5].i, NIL, (Node*)makedfa(yyvsp[-3].s, 1), yyvsp[-1].p, rectonode()); }
- break;
-
- case 169:
-#line 401 "awkgram.y"
- { if (constnode(yyvsp[-3].p))
- yyval.p = op4(yyvsp[-5].i, NIL, (Node*)makedfa(strnode(yyvsp[-3].p), 1), yyvsp[-1].p, rectonode());
+ yyval.p = op3(MATCHFCN, (Node *)1, yypt[-3].yyv.p, yypt[-1].yyv.p); } break;
+case 161:
+#line 389 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = celltonode(yypt[-0].yyv.cp, CCON); } break;
+case 162:
+#line 391 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op4(SPLIT, yypt[-5].yyv.p, makearr(yypt[-3].yyv.p), yypt[-1].yyv.p, (Node*)STRING); } break;
+case 163:
+#line 393 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op4(SPLIT, yypt[-5].yyv.p, makearr(yypt[-3].yyv.p), (Node*)makedfa(yypt[-1].yyv.s, 1), (Node *)REGEXPR); } break;
+case 164:
+#line 395 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op4(SPLIT, yypt[-3].yyv.p, makearr(yypt[-1].yyv.p), NIL, (Node*)STRING); } break;
+case 165:
+#line 396 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op1(yypt[-3].yyv.i, yypt[-1].yyv.p); } break;
+case 166:
+#line 397 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = celltonode(yypt[-0].yyv.cp, CCON); } break;
+case 167:
+#line 399 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op4(yypt[-5].yyv.i, NIL, (Node*)makedfa(yypt[-3].yyv.s, 1), yypt[-1].yyv.p, rectonode()); } break;
+case 168:
+#line 401 "/n/fs/fac/bwk/awk/awkgram.y"
+{ if (constnode(yypt[-3].yyv.p))
+ yyval.p = op4(yypt[-5].yyv.i, NIL, (Node*)makedfa(strnode(yypt[-3].yyv.p), 1), yypt[-1].yyv.p, rectonode());
else
- yyval.p = op4(yyvsp[-5].i, (Node *)1, yyvsp[-3].p, yyvsp[-1].p, rectonode()); }
- break;
-
- case 170:
-#line 406 "awkgram.y"
- { yyval.p = op4(yyvsp[-7].i, NIL, (Node*)makedfa(yyvsp[-5].s, 1), yyvsp[-3].p, yyvsp[-1].p); }
- break;
-
- case 171:
-#line 408 "awkgram.y"
- { if (constnode(yyvsp[-5].p))
- yyval.p = op4(yyvsp[-7].i, NIL, (Node*)makedfa(strnode(yyvsp[-5].p), 1), yyvsp[-3].p, yyvsp[-1].p);
+ yyval.p = op4(yypt[-5].yyv.i, (Node *)1, yypt[-3].yyv.p, yypt[-1].yyv.p, rectonode()); } break;
+case 169:
+#line 406 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op4(yypt[-7].yyv.i, NIL, (Node*)makedfa(yypt[-5].yyv.s, 1), yypt[-3].yyv.p, yypt[-1].yyv.p); } break;
+case 170:
+#line 408 "/n/fs/fac/bwk/awk/awkgram.y"
+{ if (constnode(yypt[-5].yyv.p))
+ yyval.p = op4(yypt[-7].yyv.i, NIL, (Node*)makedfa(strnode(yypt[-5].yyv.p), 1), yypt[-3].yyv.p, yypt[-1].yyv.p);
else
- yyval.p = op4(yyvsp[-7].i, (Node *)1, yyvsp[-5].p, yyvsp[-3].p, yyvsp[-1].p); }
- break;
-
- case 172:
-#line 413 "awkgram.y"
- { yyval.p = op3(SUBSTR, yyvsp[-5].p, yyvsp[-3].p, yyvsp[-1].p); }
- break;
-
- case 173:
-#line 415 "awkgram.y"
- { yyval.p = op3(SUBSTR, yyvsp[-3].p, yyvsp[-1].p, NIL); }
- break;
-
- case 176:
-#line 421 "awkgram.y"
- { yyval.p = op2(ARRAY, makearr(yyvsp[-3].p), yyvsp[-1].p); }
- break;
-
- case 177:
-#line 422 "awkgram.y"
- { yyval.p = op1(INDIRECT, celltonode(yyvsp[0].cp, CVAR)); }
- break;
-
- case 178:
-#line 423 "awkgram.y"
- { yyval.p = op1(INDIRECT, yyvsp[0].p); }
- break;
-
- case 179:
-#line 427 "awkgram.y"
- { arglist = yyval.p = 0; }
- break;
-
- case 180:
-#line 428 "awkgram.y"
- { arglist = yyval.p = celltonode(yyvsp[0].cp,CVAR); }
- break;
-
- case 181:
-#line 429 "awkgram.y"
- {
- checkdup(yyvsp[-2].p, yyvsp[0].cp);
- arglist = yyval.p = linkum(yyvsp[-2].p,celltonode(yyvsp[0].cp,CVAR)); }
- break;
-
- case 182:
-#line 435 "awkgram.y"
- { yyval.p = celltonode(yyvsp[0].cp, CVAR); }
- break;
-
- case 183:
-#line 436 "awkgram.y"
- { yyval.p = op1(ARG, itonp(yyvsp[0].i)); }
- break;
-
- case 184:
-#line 437 "awkgram.y"
- { yyval.p = op1(VARNF, (Node *) yyvsp[0].cp); }
- break;
-
- case 185:
-#line 442 "awkgram.y"
- { yyval.p = notnull(yyvsp[-1].p); }
- break;
-
-
- }
-
-/* Line 991 of yacc.c. */
-#line 3099 "y.tab.c"
-
- yyvsp -= yylen;
- yyssp -= yylen;
-
-
- YY_STACK_PRINT (yyss, yyssp);
-
- *++yyvsp = yyval;
-
-
- /* Now `shift' the result of the reduction. Determine what state
- that goes to, based on the state we popped back to and the rule
- number reduced by. */
-
- yyn = yyr1[yyn];
-
- yystate = yypgoto[yyn - YYNTOKENS] + *yyssp;
- if (0 <= yystate && yystate <= YYLAST && yycheck[yystate] == *yyssp)
- yystate = yytable[yystate];
- else
- yystate = yydefgoto[yyn - YYNTOKENS];
-
- goto yynewstate;
-
-
-/*------------------------------------.
-| yyerrlab -- here on detecting error |
-`------------------------------------*/
-yyerrlab:
- /* If not already recovering from an error, report this error. */
- if (!yyerrstatus)
- {
- ++yynerrs;
-#if YYERROR_VERBOSE
- yyn = yypact[yystate];
-
- if (YYPACT_NINF < yyn && yyn < YYLAST)
- {
- YYSIZE_T yysize = 0;
- int yytype = YYTRANSLATE (yychar);
- char *yymsg;
- int yyx, yycount;
-
- yycount = 0;
- /* Start YYX at -YYN if negative to avoid negative indexes in
- YYCHECK. */
- for (yyx = yyn < 0 ? -yyn : 0;
- yyx < (int) (sizeof (yytname) / sizeof (char *)); yyx++)
- if (yycheck[yyx + yyn] == yyx && yyx != YYTERROR)
- yysize += yystrlen (yytname[yyx]) + 15, yycount++;
- yysize += yystrlen ("syntax error, unexpected ") + 1;
- yysize += yystrlen (yytname[yytype]);
- yymsg = (char *) YYSTACK_ALLOC (yysize);
- if (yymsg != 0)
- {
- char *yyp = yystpcpy (yymsg, "syntax error, unexpected ");
- yyp = yystpcpy (yyp, yytname[yytype]);
-
- if (yycount < 5)
- {
- yycount = 0;
- for (yyx = yyn < 0 ? -yyn : 0;
- yyx < (int) (sizeof (yytname) / sizeof (char *));
- yyx++)
- if (yycheck[yyx + yyn] == yyx && yyx != YYTERROR)
- {
- const char *yyq = ! yycount ? ", expecting " : " or ";
- yyp = yystpcpy (yyp, yyq);
- yyp = yystpcpy (yyp, yytname[yyx]);
- yycount++;
- }
- }
- yyerror (yymsg);
- YYSTACK_FREE (yymsg);
- }
- else
- yyerror ("syntax error; also virtual memory exhausted");
- }
- else
-#endif /* YYERROR_VERBOSE */
- yyerror ("syntax error");
- }
-
-
-
- if (yyerrstatus == 3)
- {
- /* If just tried and failed to reuse lookahead token after an
- error, discard it. */
-
- /* Return failure if at end of input. */
- if (yychar == YYEOF)
- {
- /* Pop the error token. */
- YYPOPSTACK;
- /* Pop the rest of the stack. */
- while (yyss < yyssp)
- {
- YYDSYMPRINTF ("Error: popping", yystos[*yyssp], yyvsp, yylsp);
- yydestruct (yystos[*yyssp], yyvsp);
- YYPOPSTACK;
- }
- YYABORT;
- }
-
- YYDSYMPRINTF ("Error: discarding", yytoken, &yylval, &yylloc);
- yydestruct (yytoken, &yylval);
- yychar = YYEMPTY;
-
- }
-
- /* Else will try to reuse lookahead token after shifting the error
- token. */
- goto yyerrlab2;
-
-
-/*----------------------------------------------------.
-| yyerrlab1 -- error raised explicitly by an action. |
-`----------------------------------------------------*/
-yyerrlab1:
-
- /* Suppress GCC warning that yyerrlab1 is unused when no action
- invokes YYERROR. */
-#if defined (__GNUC_MINOR__) && 2093 <= (__GNUC__ * 1000 + __GNUC_MINOR__)
- __attribute__ ((__unused__))
-#endif
-
-
- goto yyerrlab2;
-
-
-/*---------------------------------------------------------------.
-| yyerrlab2 -- pop states until the error token can be shifted. |
-`---------------------------------------------------------------*/
-yyerrlab2:
- yyerrstatus = 3; /* Each real token shifted decrements this. */
-
- for (;;)
- {
- yyn = yypact[yystate];
- if (yyn != YYPACT_NINF)
- {
- yyn += YYTERROR;
- if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYTERROR)
- {
- yyn = yytable[yyn];
- if (0 < yyn)
- break;
- }
- }
-
- /* Pop the current state because it cannot handle the error token. */
- if (yyssp == yyss)
- YYABORT;
-
- YYDSYMPRINTF ("Error: popping", yystos[*yyssp], yyvsp, yylsp);
- yydestruct (yystos[yystate], yyvsp);
- yyvsp--;
- yystate = *--yyssp;
-
- YY_STACK_PRINT (yyss, yyssp);
- }
-
- if (yyn == YYFINAL)
- YYACCEPT;
-
- YYDPRINTF ((stderr, "Shifting error token, "));
-
- *++yyvsp = yylval;
-
-
- yystate = yyn;
- goto yynewstate;
-
-
-/*-------------------------------------.
-| yyacceptlab -- YYACCEPT comes here. |
-`-------------------------------------*/
-yyacceptlab:
- yyresult = 0;
- goto yyreturn;
-
-/*-----------------------------------.
-| yyabortlab -- YYABORT comes here. |
-`-----------------------------------*/
-yyabortlab:
- yyresult = 1;
- goto yyreturn;
-
-#ifndef yyoverflow
-/*----------------------------------------------.
-| yyoverflowlab -- parser overflow comes here. |
-`----------------------------------------------*/
-yyoverflowlab:
- yyerror ("parser stack overflow");
- yyresult = 2;
- /* Fall through. */
-#endif
-
-yyreturn:
-#ifndef yyoverflow
- if (yyss != yyssa)
- YYSTACK_FREE (yyss);
-#endif
- return yyresult;
-}
-
-
-#line 445 "awkgram.y"
-
-
-void setfname(Cell *p)
+ yyval.p = op4(yypt[-7].yyv.i, (Node *)1, yypt[-5].yyv.p, yypt[-3].yyv.p, yypt[-1].yyv.p); } break;
+case 171:
+#line 413 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op3(SUBSTR, yypt[-5].yyv.p, yypt[-3].yyv.p, yypt[-1].yyv.p); } break;
+case 172:
+#line 415 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op3(SUBSTR, yypt[-3].yyv.p, yypt[-1].yyv.p, NIL); } break;
+case 175:
+#line 421 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op2(ARRAY, makearr(yypt[-3].yyv.p), yypt[-1].yyv.p); } break;
+case 176:
+#line 422 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op1(INDIRECT, celltonode(yypt[-0].yyv.cp, CVAR)); } break;
+case 177:
+#line 423 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op1(INDIRECT, yypt[-0].yyv.p); } break;
+case 178:
+#line 427 "/n/fs/fac/bwk/awk/awkgram.y"
+{ arglist = yyval.p = 0; } break;
+case 179:
+#line 428 "/n/fs/fac/bwk/awk/awkgram.y"
+{ arglist = yyval.p = celltonode(yypt[-0].yyv.cp,CVAR); } break;
+case 180:
+#line 429 "/n/fs/fac/bwk/awk/awkgram.y"
{
- if (isarr(p))
- SYNTAX("%s is an array, not a function", p->nval);
- else if (isfcn(p))
- SYNTAX("you can't define function %s more than once", p->nval);
- curfname = p->nval;
-}
-
-int constnode(Node *p)
-{
- return isvalue(p) && ((Cell *) (p->narg[0]))->csub == CCON;
-}
-
-char *strnode(Node *p)
-{
- return ((Cell *)(p->narg[0]))->sval;
-}
-
-Node *notnull(Node *n)
-{
- switch (n->nobj) {
- case LE: case LT: case EQ: case NE: case GT: case GE:
- case BOR: case AND: case NOT:
- return n;
- default:
- return op2(NE, n, nullnode);
- }
-}
-
-void checkdup(Node *vl, Cell *cp) /* check if name already in list */
-{
- char *s = cp->nval;
- for ( ; vl; vl = vl->nnext) {
- if (strcmp(s, ((Cell *)(vl->narg[0]))->nval) == 0) {
- SYNTAX("duplicate argument %s", s);
- break;
- }
+ checkdup(yypt[-2].yyv.p, yypt[-0].yyv.cp);
+ arglist = yyval.p = linkum(yypt[-2].yyv.p,celltonode(yypt[-0].yyv.cp,CVAR)); } break;
+case 181:
+#line 435 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = celltonode(yypt[-0].yyv.cp, CVAR); } break;
+case 182:
+#line 436 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op1(ARG, itonp(yypt[-0].yyv.i)); } break;
+case 183:
+#line 437 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = op1(VARNF, (Node *) yypt[-0].yyv.cp); } break;
+case 184:
+#line 442 "/n/fs/fac/bwk/awk/awkgram.y"
+{ yyval.p = notnull(yypt[-1].yyv.p); } break;
}
+ goto yystack; /* stack new state and value */
}
-
diff --git a/lang/nawk/files/ytab.h b/lang/nawk/files/ytab.h
index 5f07f0b1219..eb18625b94e 100644
--- a/lang/nawk/files/ytab.h
+++ b/lang/nawk/files/ytab.h
@@ -1,242 +1,104 @@
-/* $NetBSD: ytab.h,v 1.1 2006/07/14 14:23:06 jlam Exp $ */
+/* $NetBSD: ytab.h,v 1.2 2014/03/12 14:20:43 ryoon Exp $ */
/* A Bison parser, made by GNU Bison 1.875. */
-/* Skeleton parser for Yacc-like parsing with Bison,
- Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002 Free Software Foundation, Inc.
-
- This program is free software; you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation; either version 2, or (at your option)
- any later version.
-
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program; if not, write to the Free Software
- Foundation, Inc., 59 Temple Place - Suite 330,
- Boston, MA 02111-1307, USA. */
-
-/* As a special exception, when this file is copied by Bison into a
- Bison output file, you may use that output file without restriction.
- This special exception was added by the Free Software Foundation
- in version 1.24 of Bison. */
-
-/* Tokens. */
-#ifndef YYTOKENTYPE
-# define YYTOKENTYPE
- /* Put the tokens into the symbol table, so that GDB and other debuggers
- know about them. */
- enum yytokentype {
- FIRSTTOKEN = 258,
- PROGRAM = 259,
- PASTAT = 260,
- PASTAT2 = 261,
- XBEGIN = 262,
- XEND = 263,
- NL = 264,
- ARRAY = 265,
- MATCH = 266,
- NOTMATCH = 267,
- MATCHOP = 268,
- FINAL = 269,
- DOT = 270,
- ALL = 271,
- CCL = 272,
- NCCL = 273,
- CHAR = 274,
- OR = 275,
- STAR = 276,
- QUEST = 277,
- PLUS = 278,
- AND = 279,
- BOR = 280,
- APPEND = 281,
- EQ = 282,
- GE = 283,
- GT = 284,
- LE = 285,
- LT = 286,
- NE = 287,
- IN = 288,
- ARG = 289,
- BLTIN = 290,
- BREAK = 291,
- CLOSE = 292,
- CONTINUE = 293,
- DELETE = 294,
- DO = 295,
- EXIT = 296,
- FOR = 297,
- FUNC = 298,
- SUB = 299,
- GSUB = 300,
- IF = 301,
- INDEX = 302,
- LSUBSTR = 303,
- MATCHFCN = 304,
- NEXT = 305,
- NEXTFILE = 306,
- ADD = 307,
- MINUS = 308,
- MULT = 309,
- DIVIDE = 310,
- MOD = 311,
- ASSIGN = 312,
- ASGNOP = 313,
- ADDEQ = 314,
- SUBEQ = 315,
- MULTEQ = 316,
- DIVEQ = 317,
- MODEQ = 318,
- POWEQ = 319,
- PRINT = 320,
- PRINTF = 321,
- SPRINTF = 322,
- ELSE = 323,
- INTEST = 324,
- CONDEXPR = 325,
- POSTINCR = 326,
- PREINCR = 327,
- POSTDECR = 328,
- PREDECR = 329,
- VAR = 330,
- IVAR = 331,
- VARNF = 332,
- CALL = 333,
- NUMBER = 334,
- STRING = 335,
- REGEXPR = 336,
- GETLINE = 337,
- SUBSTR = 338,
- SPLIT = 339,
- RETURN = 340,
- WHILE = 341,
- CAT = 342,
- UMINUS = 343,
- NOT = 344,
- POWER = 345,
- INCR = 346,
- DECR = 347,
- INDIRECT = 348,
- LASTTOKEN = 349
- };
-#endif
-#define FIRSTTOKEN 258
-#define PROGRAM 259
-#define PASTAT 260
-#define PASTAT2 261
-#define XBEGIN 262
-#define XEND 263
-#define NL 264
-#define ARRAY 265
-#define MATCH 266
-#define NOTMATCH 267
-#define MATCHOP 268
-#define FINAL 269
-#define DOT 270
-#define ALL 271
-#define CCL 272
-#define NCCL 273
-#define CHAR 274
-#define OR 275
-#define STAR 276
-#define QUEST 277
-#define PLUS 278
-#define AND 279
-#define BOR 280
-#define APPEND 281
-#define EQ 282
-#define GE 283
-#define GT 284
-#define LE 285
-#define LT 286
-#define NE 287
-#define IN 288
-#define ARG 289
-#define BLTIN 290
-#define BREAK 291
-#define CLOSE 292
-#define CONTINUE 293
-#define DELETE 294
-#define DO 295
-#define EXIT 296
-#define FOR 297
-#define FUNC 298
-#define SUB 299
-#define GSUB 300
-#define IF 301
-#define INDEX 302
-#define LSUBSTR 303
-#define MATCHFCN 304
-#define NEXT 305
-#define NEXTFILE 306
-#define ADD 307
-#define MINUS 308
-#define MULT 309
-#define DIVIDE 310
-#define MOD 311
-#define ASSIGN 312
-#define ASGNOP 313
-#define ADDEQ 314
-#define SUBEQ 315
-#define MULTEQ 316
-#define DIVEQ 317
-#define MODEQ 318
-#define POWEQ 319
-#define PRINT 320
-#define PRINTF 321
-#define SPRINTF 322
-#define ELSE 323
-#define INTEST 324
-#define CONDEXPR 325
-#define POSTINCR 326
-#define PREINCR 327
-#define POSTDECR 328
-#define PREDECR 329
-#define VAR 330
-#define IVAR 331
-#define VARNF 332
-#define CALL 333
-#define NUMBER 334
-#define STRING 335
-#define REGEXPR 336
-#define GETLINE 337
-#define SUBSTR 338
-#define SPLIT 339
-#define RETURN 340
-#define WHILE 341
-#define CAT 342
-#define UMINUS 343
-#define NOT 344
-#define POWER 345
-#define INCR 346
-#define DECR 347
-#define INDIRECT 348
-#define LASTTOKEN 349
-
-
-
-
-#if ! defined (YYSTYPE) && ! defined (YYSTYPE_IS_DECLARED)
-#line 41 "awkgram.y"
-typedef union YYSTYPE {
+typedef union {
Node *p;
Cell *cp;
int i;
char *s;
-} YYSTYPE;
-/* Line 1248 of yacc.c. */
-#line 231 "y.tab.h"
-# define yystype YYSTYPE /* obsolescent; will be withdrawn */
-# define YYSTYPE_IS_DECLARED 1
-# define YYSTYPE_IS_TRIVIAL 1
-#endif
-
-extern YYSTYPE yylval;
-
-
-
+} YYSTYPE;
+extern YYSTYPE yylval;
+#define FIRSTTOKEN 57346
+#define PROGRAM 57347
+#define PASTAT 57348
+#define PASTAT2 57349
+#define XBEGIN 57350
+#define XEND 57351
+#define NL 57352
+#define ARRAY 57353
+#define MATCH 57354
+#define NOTMATCH 57355
+#define MATCHOP 57356
+#define FINAL 57357
+#define DOT 57358
+#define ALL 57359
+#define CCL 57360
+#define NCCL 57361
+#define CHAR 57362
+#define OR 57363
+#define STAR 57364
+#define QUEST 57365
+#define PLUS 57366
+#define EMPTYRE 57367
+#define AND 57368
+#define BOR 57369
+#define APPEND 57370
+#define EQ 57371
+#define GE 57372
+#define GT 57373
+#define LE 57374
+#define LT 57375
+#define NE 57376
+#define IN 57377
+#define ARG 57378
+#define BLTIN 57379
+#define BREAK 57380
+#define CLOSE 57381
+#define CONTINUE 57382
+#define DELETE 57383
+#define DO 57384
+#define EXIT 57385
+#define FOR 57386
+#define FUNC 57387
+#define SUB 57388
+#define GSUB 57389
+#define IF 57390
+#define INDEX 57391
+#define LSUBSTR 57392
+#define MATCHFCN 57393
+#define NEXT 57394
+#define NEXTFILE 57395
+#define ADD 57396
+#define MINUS 57397
+#define MULT 57398
+#define DIVIDE 57399
+#define MOD 57400
+#define ASSIGN 57401
+#define ASGNOP 57402
+#define ADDEQ 57403
+#define SUBEQ 57404
+#define MULTEQ 57405
+#define DIVEQ 57406
+#define MODEQ 57407
+#define POWEQ 57408
+#define PRINT 57409
+#define PRINTF 57410
+#define SPRINTF 57411
+#define ELSE 57412
+#define INTEST 57413
+#define CONDEXPR 57414
+#define POSTINCR 57415
+#define PREINCR 57416
+#define POSTDECR 57417
+#define PREDECR 57418
+#define VAR 57419
+#define IVAR 57420
+#define VARNF 57421
+#define CALL 57422
+#define NUMBER 57423
+#define STRING 57424
+#define REGEXPR 57425
+#define GETLINE 57426
+#define RETURN 57427
+#define SPLIT 57428
+#define SUBSTR 57429
+#define WHILE 57430
+#define CAT 57431
+#define NOT 57432
+#define UMINUS 57433
+#define POWER 57434
+#define DECR 57435
+#define INCR 57436
+#define INDIRECT 57437
+#define LASTTOKEN 57438