[type]
Parser

[grammar]
grammar T;

<ImportListener("T")>
<LRWithLabelsListener("T")>

s
@after {
<ContextMember("$ctx", "r"):ToStringTree():writeln()>
<ContextMember("$ctx", "r"):WalkListener()>
}
  : r=e ;
e : e '(' eList ')' # Call
  | INT    # Int
  ;
eList : e (',' e)* ;
MULT: '*' ;
ADD : '+' ;
INT : [0-9]+ ;
ID  : [a-z]+ ;
WS : [ \t\n]+ -> skip ;

[start]
s

[input]
1(2,3)

[output]
(e (e 1) ( (eList (e 2) , (e 3)) ))
1
2
3
1 [13 6]

