Grammar of Maparoni's expressions for tree-sitter.
Makes a good basis for grammars of other expressions that are built using nicklockwood/Expression.
The grammar is defined in grammar.js, mostly be specifying all those rules.
Rules that are prefixed with a _ will not be returned by the parser. Be mindful about that, when defining the grammar as how to build these rules depends on how they'll be used.
- When adding new functionality add new tests in the
testdirectory. - Run
tree-sitter generatefirst, and thentree-sitter testto run the suite from thetestdirectory, and check that it all passes.
- Run
tree-sitter generateto build the C files (insrc), that can be used with anything that can integrate C code - Run
tree-sitter build-wasmto build the WASM file, that can be used with JS-based tree-sitter highlighters