home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Microsoft Programmer's Library 1.3
/
Microsoft-Programers-Library-v1.3.iso
/
sampcode
/
alde_c
/
misc
/
comm
/
yaccunx
/
simpl.y
< prev
next >
Encoding:
Amiga
Atari
Commodore
DOS
FM Towns/JPY
Macintosh
Macintosh JP
Macintosh to JP
NeXTSTEP
RISC OS/Acorn
Shift JIS
UTF-8
Wrap
Text File
|
1980-01-01
|
384 b
|
83 lines
%term ID END
%left '+'
%left '*'
%left '('
%%
exp: exp '+' term = { 1; }
| term = { 2; }
term: term '*' fact = { 3; }
| fact = { 4; }
fact: '(' exp ')' = { 5; }
| ID = { 6; }
%%