3 ms·
Bantam-Coffee: A Pratt parser implementation in CoffeeScript
- breckinloggins 15y agoI was inspired by http://journal.stuffwithstuff.com/2011/03/19/pratt-parsers-expression-parsing-made-easy/ http://journal.stuffwithstuff.com/2011/03/19/pratt-parsers-e... to write my own Pratt parser* and I figured the easiest way to start would be to implement Bob's "Bantam" language in CoffeeScript. I understand why Bob chose Java (as he says, "if you can write it in Java you can write it in any language"), but I think the CoffeeScript version is easier to understand. * http://en.wikipedia.org/wiki/Pratt_parser http://en.wikipedia.org/wiki/Pratt_parser