Program:

Program  ::= Block

no references


Block:

Block    ::= ( Stmt ';' )*

referenced by:


Stmt:

Stmt     ::= VarDecl
           | Print
           | Loop
           | Exp

referenced by:


VarDecl:

VarDecl  ::= 'var' id ( '=' Exp )?

referenced by:


Print:

Print    ::= 'ava' Exp

referenced by:


Loop:

Loop     ::= ForLoop
           | WhileLoop

referenced by:


ForLoop:

ForLoop  ::= 'for' 'each' id 'in' Exp '{' Block '}'
           | 'for' id 'times' '{' Block '}'
           | 'for' '(' VarDecl ConditionalExp ')' '{' Block '}'

referenced by:


WhileLoop:

WhileLoop
         ::= 'while' '(' Exp ')' '{' Block '}'

referenced by:


Exp:

Exp      ::= FunctionExp
           | 'return' Exp
           | ConditionalExp
           | Exp1

referenced by:


FunctionExp:

FunctionExp
         ::= 'function' '(' Params ')' '->' Block 'end'

referenced by:


Call:

Call     ::= id ( id* | '(' Args? ')' | Exp* )

referenced by:


Params:

Params   ::= TypedExpList

referenced by:


Args:

Args     ::= ExpList

referenced by:


ExpList:

ExpList  ::= Exp ( ',' Exp )*

referenced by:


TypedExpList:

TypedExpList
         ::= TypedExp ( ',' TypedExp )*

referenced by:


TypedExp:

TypedExp ::= id ':' type

referenced by:


ConditionalExp:

ConditionalExp
         ::= 'if' ( Exp1 | '(' Exp1 ')' ) 'then' Block ( 'else' 'if' ( Exp1 | '(' Exp1 ')' ) 'then' Block )* ( 'else' Block )? 'end'

referenced by:


Exp1:

Exp1     ::= Exp2 ( 'or' Exp2 )*

referenced by:


Exp2:

Exp2     ::= Exp3 ( 'and' Exp3 )* ( 'both' Exp )?

referenced by:


Exp3:

Exp3     ::= Exp4 ( relop Exp4 )?

referenced by:


Exp4:

Exp4     ::= Exp5 ( appendop Exp5 )*

referenced by:


Exp5:

Exp5     ::= Exp6 ( consop Exp6 )*

referenced by:


Exp6:

Exp6     ::= Exp7 ( '…' Exp7 )?

referenced by:


Exp7:

Exp7     ::= Exp8 ( addop Exp8 )*

referenced by:


Exp8:

Exp8     ::= Exp9 ( mulop Exp9 )*

referenced by:


Exp9:

Exp9     ::= prefixop? Exp10

referenced by:


Exp10:

Exp10    ::= Exp11 postfixop?

referenced by:


Exp11:

Exp11    ::= Exp12 ( '^^' Exp12 )*

referenced by:


Exp12:

Exp12    ::= '(' Exp ')'
           | VarRef Access*
           | intlit
           | floatlit
           | stringlit
           | boolit
           | List
           | SetLiteral
           | ObjectLiteral

referenced by:


VarRef:

VarRef   ::= Assign
           | ( Call | id ) ( '[' Exp ']' )?

referenced by:


Assign:

Assign   ::= id assignop Exp

referenced by:


Access:

Access   ::= '[' Exp ']'
           | '.' Exp12

referenced by:


ObjectLiteral:

ObjectLiteral
         ::= '{' ObjExpList? '}'

referenced by:


ObjExpList:

ObjExpList
         ::= ObjExp ( ',' ObjExp )*

referenced by:


ObjExp:

ObjExp   ::= key ':' Exp

referenced by:


SetLiteral:

SetLiteral
         ::= '{' ExpList? '}'

referenced by:


List:

List     ::= '[' ExpList? ']'

referenced by:



  ... generated by Railroad Diagram Generator