1 s ::= w* Grammar w* => "gram"
2 Grammar ::= R+ => "grammar"
3 R ::= word ^"::=" Alternatives
4 | word ^"!::=" Alternatives
6 ec ::= [~\]\\\-\~] | escaped
8 Alternatives ::= EquiAlt +/ ">"
9 EquiAlt ::= Conjuncts +/ "|" => "alternatives"
11 Sequence ::= E+ ^"/" E
15 | Rewrite ^"&" Sequence
16 | Rewrite ^"&~" Sequence
18 Rewrite ::= Sequence => "rewrite"
20 | Sequence ^"=>" quoted
21 | Sequence "=>" "()" => "wrap"
23 range ::= ec => "range0" | ec ^"-" ec => "range0"
24 E ::= word => "nonTerminalY"
26 | ^"{" Alternatives "}"
27 | "[" [\~]? range* "]" => "range"
36 | "^" quoted => "care"
45 > ^"(" Alternatives ")"
52 word ::= an++ => "sify"
53 quoted ::= "\"" ([~\"\\] | escaped)* "\"" => "sify"
54 escaped ::= "\\n" => "\n"