4 ms·
For me it was mostly a fun project I've always wanted to make :) I didn't know about ts-parsec though, looks cool! I originally designed Pasukon as an alternat
by gosukiwi 6y ago
For me it was mostly a fun project I've always wanted to make :) I didn't know about ts-parsec though, looks cool!
I originally designed Pasukon as an alternative to PEGjs. A way to quickly prototype a language and generate an usable parser. What I didn't like much about PEGjs is the lack of extensibility, so I added the ability to use your own lexer and combinators to really fine-tune the parser if needed.
Also PEGjs struggles with indent-based grammars, because it can't use caching with those, and it can get quite slow. That gets solved by using a lexing step which outputs proper `INDENT` and `DEDENT` tokens.