-
Notifications
You must be signed in to change notification settings - Fork 165
Backend ideas
Max Nordlund edited this page Jan 10, 2015
·
12 revisions
Ideas for new backends
It doesn't seem that there is a canonical tool such as lex/yacc in python. A list of parsing tools for is available on the python wiki: https://wiki.python.org/moin/LanguageParsing
See https://github.com/BNFC/bnfc/issues/76
We could replace those backend by a pandoc backend. This has a few advantages:
- it can generate more formats
- pandoc-types provide a nice API to create documents programatically
- we don't have to maintain a latex backend and a plain text backend separately
Jison is a port of flex/yacc in javascript so it might not be so hard to derive a javascript backend from the C one
An standard BNF notation (could be used as backend and frontend)
As in http://bnfc.readthedocs.org/en/latest/lbnf.html#the-syntactic-structure-of-bnf
Go comes with a port of yacc which should make adding this fairly easy. There is no flex/lex equivalent though.