BNF for minischeme.jj

NON-TERMINALS

Goal ::= Expression <EOF>
Expression ::= IntegerLiteral
| TrueLiteral
| FalseLiteral
| PlusExpression
| IfExpression
| LetExpression
| Identifier
| Assignment
| ProcedureExp
| Application
| RecExpression
IntegerLiteral ::= <INTEGER_LITERAL>
TrueLiteral ::= "#t"
FalseLiteral ::= "#f"
PlusExpression ::= "(" "+" Expression Expression ")"
IfExpression ::= "(" "if" Expression Expression Expression ")"
LetExpression ::= "(" "let" "(" ( Declaration )* ")" Expression ")"
Identifier ::= <IDENTIFIER>
Assignment ::= "(" "set!" Identifier Expression ")"
ProcedureExp ::= "(" "lambda" "(" ( Identifier )* ")" Expression ")"
Application ::= "(" Expression ( Expression )* ")"
RecExpression ::= "(" "letrec" "(" ( RecDeclaration )* ")" Expression ")"
Declaration ::= "(" Identifier Expression ")"
RecDeclaration ::= "(" Identifier ProcedureExp ")"