Grammar extracted by Vadim Zaytsev, see the Grammar Zoo entry for details: toy/fl/abstract/emf/ecore/extracted
Source used for this grammar: Guido Wachsmuth, Vadim Zaytsev, fl.ecore
, 26 June 2008 – 28 May 2009 [GitHub]
Program
, Function
, Argument
, Exp
, LiteralExp
, ArgumentExp
, IfThenElseExp
, ApplyExp
, BinaryExp
, PlusExp
, MinusExp
, EqualExp
), 0 root (—), 1 top (Program
), 0 bottom (—).[function]
2, [name]
2, [argument]
3, [definition]
, [value]
, [if]
, [then]
, [else]
, [left]
3, [right]
3.Program ::=
[function]::Function
Function ::=
[name]::string [argument]::Argument
[definition]::ExpArgument ::= [name]::string
Exp ::= LiteralExp ArgumentExp IfThenElseExp ApplyExp BinaryExp
LiteralExp ::= [value]::integer
ArgumentExp ::= [argument]::Argument
IfThenElseExp ::= [if]::Exp [then]::Exp [else]::Exp
ApplyExp ::=
[function]::Function [argument]::Exp
BinaryExp ::= PlusExp MinusExp EqualExp
PlusExp ::= [left]::Exp [right]::Exp
MinusExp ::= [left]::Exp [right]::Exp
EqualExp ::= [left]::Exp [right]::Exp