Search code examples
parsingdabstract-syntax-treelexical-analysisgppg

gppg/gplex equivalent in D?


When I was working in C#, I found the gppg and gplex parser/lexer generators to be perfect for my needs. I'm wondering if there's something similar for the D programming language (i.e. a utility that, given a grammar in BNF or EBNF, outputs D code that lexes/parses that language into a abstract syntax tree).

The closest I've found is Goldie, but I'm having so much trouble understanding it that I'm not able to get anything up and running.


Solution

  • I have found Goldie pretty awesome for context-insensitive grammars, are you sure about it? Also, http://www.wikiservice.at/d/wiki.cgi?GrammarParsers lists some, no idea which are still developed. If ANTLR-D still works, it is probably on of the best choices.