CONSTRUCTOR TABLES of the Grammar G7.grm
Parameters
File G7.prm
struct parm{
int nr //tähestiku V pikkus
int tnr //tähestiku VT pikkus
int BRC //0: G on pööratav
int Pnr //Produktsioonide arv
int dep //1: sõltuv kontekst
int itl //identifikaatorite arv (Parser)
int ktl //konstantide arv (Parser)
}
nr=10 tnr=5 BRC=1 Pnr=8 dep=0 itl=0 ktl=0
Alphabet V
File G7.t
# a b 0 1 T S A B C
Scanner Table
File G7.tt
# a b 0 1
Tree of the Alphabet V
File G7.v
struct R{
int P; /* produktsiooni jrk-nr */
int sem; /* semantikakood */
int n; /* NT definitsiooni pikkus */
int *d; /* NT definitsioon */
struct R *alt; /* NT alternatiivne definitsioon */
}
struct D{
int tunnus; /* 0: NT, 1: T */
int code; /* vahekeelne kood */
int L; /* NT või id/const nime pikkus */
int loc; /* ident | const : nr */
int icx; /* itl või ktl - IT või KT index */
struct D *left; /* kahendpuu viidad (võti on T[code]) */
struct D *right;
struct R *def;
}
D 00490040: tunnus=1 code=1 L=1 loc=0 icx=0 left=00000000 right=00491C90 def=00000000 (#)
D 00491BF0: tunnus=1 code=4 L=1 loc=0 icx=0 left=00000000 right=00491BA0 def=00000000 (0)
D 00491BA0: tunnus=1 code=5 L=1 loc=0 icx=0 left=00000000 right=00491A60 def=00000000 (1)
D 00491800: tunnus=0 code=8 L=1 loc=0 icx=0 left=00000000 right=00491690 def=00491320 (A)
R 00491320: P=5 sem=0 n=2 d=004912E0 alt=00491490
d 004912E0: 10 5
R 00491490: P=4 sem=0 n=3 d=00491450 alt=00000000
d 00491450: 4 8 5
D 00491690: tunnus=0 code=9 L=1 loc=0 icx=0 left=00000000 right=004913B0 def=004911B0 (B)
R 004911B0: P=6 sem=0 n=2 d=00491170 alt=00000000
d 00491170: 10 5
D 004913B0: tunnus=0 code=10 L=1 loc=0 icx=0 left=00000000 right=00000000 def=00491090 (C)
R 00491090: P=7 sem=0 n=1 d=00491060 alt=00000000
d 00491060: 5
D 004919C0: tunnus=0 code=7 L=1 loc=0 icx=0 left=00491800 right=00000000 def=00491650 (S)
R 00491650: P=3 sem=0 n=2 d=00491610 alt=004917C0
d 00491610: 3 9
R 004917C0: P=2 sem=0 n=2 d=00491780 alt=00000000
d 00491780: 2 8
D 00491A60: tunnus=0 code=6 L=1 loc=0 icx=0 left=004919C0 right=00000000 def=00491930 (T)
R 00491930: P=1 sem=0 n=3 d=004918F0 alt=00000000
d 004918F0: 1 7 1
D 00491C90: tunnus=1 code=2 L=1 loc=0 icx=0 left=00491BF0 right=00491C40 def=00000000 (a)
D 00491C40: tunnus=1 code=3 L=1 loc=0 icx=0 left=00000000 right=00000000 def=00000000 (b)
Reduce Table
File G7.ht
struct h{
int P; /* produktsiooni jrk-nr */
int n; /* definitsiooni pikkus */
int NT; /* defineeritav nonterminal */
int *d; /* definitsioon */
int nc; /* 1 - sõltuv kontekst */
char *c; /* reservis */
struct h *same; /* sama parem pool */
struct h *col; /* põrkeviit */
}
h 00492C70: P=7 n=1 NT=10 d=00491030 nc=0 same=00000000 col=00000000 (C)
d 00491030: 5
h 00492FD0: P=1 n=3 NT=6 d=00492F90 nc=0 same=00000000 col=00000000 (T)
d 00492F90: 1 7 1
h 00492D90: P=4 n=3 NT=8 d=00492D50 nc=0 same=00000000 col=00000000 (A)
d 00492D50: 4 8 5
h 00492EB0: P=2 n=2 NT=7 d=00492E70 nc=0 same=00000000 col=00492F40 (S)
d 00492E70: 2 8
h 00492F40: P=3 n=2 NT=7 d=00492F00 nc=0 same=00000000 col=00000000 (S)
d 00492F00: 3 9
h 00492E20: P=5 n=2 NT=8 d=00492DE0 nc=0 same=00492D00 col=00000000 (A)
d 00492DE0: 10 5
h 00492D00: P=6 n=2 NT=9 d=00492CC0 nc=0 same=00000000 col=00000000 (B)
d 00492CC0: 10 5
Precedence Matrix
File G7.pm
Nr | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 |
1 | 0 | 2 | 2 | 0 | 0 | 0 | 1 | 0 | 0 | 0 |
2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