siraben / tree-sitter-promela

Promela grammar for tree-sitter
MIT License
7 stars 0 forks source link

tree-sitter-promela

Promela grammar for tree-sitter.

Example querying

Motivation

Promela is a language used for specifying models, especially in distributed systems contexts. However, the tooling behind it is underdeveloped—existing highlighting for the language are often regex-based and not suitable for reuse in other tools such as linters and formatters. Having a tree-sitter grammar for the language would provide a reusable foundation for building, especially since tree-sitter provides bindings in other languages.

Current status

Most of the grammar has been implemented, I'm currently parsing example source code and fixing incorrect parses.

Building

$ npm run build && tree-sitter test

Contributing

You don't need to know JavaScript or specific details about tree-sitter to help out! Try running the parser on real Promela programs and open an issue if the parser failed where it should be succeeding.

References

The grammar is based on the YACC grammar for Promela.