If I add "endoffile ::= EOF;" in SL.cup without adding "termnial EOF; ",
I'll receive an error as follows:
.....
Parsing specification from standard input...
Error at 464(7): java_cup.runtime.Symbol "EOF" has not been declared
Closing files...
------- CUP v0.10j Parser Generation Summary -------
1 error and 0 warnings
32 terminals, 34 non-terminals, and 72 productions declared,
producing 0 unique parse states.
.......
I'm really confused by the error message.
If I declare EOF terminal, CUP says "Duplicate terminal", which means
"EOF" terminal is already avaiable.
if I don't declare EOF terminal, CUP says ""EOF" has not been declared",
which means "EOF" termnial is not available.
How can I use EOF in my SL.cup? I really need to do something at end of
the sl file.
Thanks
Chao Yan
From Tom
"chao yan" <coli...@hotmail.com> wrote in message
news:dm05sm$88q$1...@rumours.uwaterloo.ca...