Sha256: 96c10b24affca65225f29ef266ef707d60f17e24ea9ac855cd3501c39979f140
Contents?: true
Size: 1.55 KB
Versions: 1
Compression:
Stored size: 1.55 KB
Contents
{ "name": "inline_rules", "extras": [ {"type": "PATTERN", "value": "\\s"} ], "inline": [ "expression" ], "rules": { "program": { "type": "REPEAT1", "content": { "type": "SYMBOL", "name": "statement" } }, "statement": { "type": "SEQ", "members": [ {"type": "SYMBOL", "name": "expression"}, {"type": "STRING", "value": ";"} ] }, "expression": { "type": "CHOICE", "members": [ {"type": "SYMBOL", "name": "sum"}, {"type": "SYMBOL", "name": "product"}, {"type": "SYMBOL", "name": "number"}, {"type": "SYMBOL", "name": "parenthesized_expression"} ] }, "parenthesized_expression": { "type": "SEQ", "members": [ {"type": "STRING", "value": "("}, {"type": "SYMBOL", "name": "expression"}, {"type": "STRING", "value": ")"} ] }, "sum": { "type": "PREC_LEFT", "value": 0, "content": { "type": "SEQ", "members": [ {"type": "SYMBOL", "name": "expression"}, {"type": "STRING", "value": "+"}, {"type": "SYMBOL", "name": "expression"} ] } }, "product": { "type": "PREC_LEFT", "value": 2, "content": { "type": "SEQ", "members": [ {"type": "SYMBOL", "name": "expression"}, {"type": "STRING", "value": "*"}, {"type": "SYMBOL", "name": "expression"} ] } }, "number": {"type": "PATTERN", "value": "\\d+"} } }
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
tree-sitter-0.1.0 | ext/tree-sitter/tree-sitter/test/fixtures/test_grammars/inline_rules/grammar.json |