|epsilon productions in Java CUP? firstname.lastname@example.org (Smith, Doug) (2001-12-15)|
|Re: epsilon productions in Java CUP? email@example.com (2001-12-20)|
|From:||"Smith, Doug" <firstname.lastname@example.org>|
|Date:||15 Dec 2001 00:42:08 -0500|
|Keywords:||Java, parse, question|
|Posted-Date:||15 Dec 2001 00:42:08 EST|
I'm looking for information on how to specify epsilon productions in Java
CUP. For example if one wanted to specify the grammar of valid balanced
parenthesis they would use the production:
S -> (S)S | p
where "|" means alternation and p is an epsilon or null production.
In CUP one would specify the terminals and non-terminals, the precedence and
then the grammar as above. But how does CUP understand the concept or
meaning of a null production?
I've searched every web page with every search engine I could find on Java
CUP and while there are one or two good tutorials out there I don't seem to
be able to find what I'm looking for. This is needed as part of a larger
grammar specification so any help would be greatly appreciated.
Return to the
Search the comp.compilers archives again.