essential-contributions / pint

Pint, the constraint-based programming language for declarative blockchains
Apache License 2.0
17 stars 3 forks source link

Switch the formatter to use `lalrpop` #789

Open mohammadfawaz opened 2 months ago

mohammadfawaz commented 2 months ago

This would be the first step towards making the formatter fully functional.

mohammadfawaz commented 2 months ago

Let's postpone the work on this until we have a full plan for how the formatter should look like.

mitchmindtree commented 2 months ago

Another option that might be easier to achieve in the short-term could be to take advantage of our tree-sitter grammar with topiary?

I haven't used topiary personally, but it sounds like it's designed to act as a universal formatter for languages with tree-sitter grammars :monocle_face: and tweag have a pretty wicked team and track record. Our tree-sitter grammar might be a little less stable as it's mostly just enough to get syntax highlighting going, but maybe that's enough for formatting too and could be worth investigating at least.