views:

57

answers:

1

I'm doing a lot of work with a DSLs at the moment and was wondering if anyone knew of a tool that could generate a parser for my bnf specification that does not require a run-time library (pure java source parser)?

I'm committed to using XTEXT for a future Eclipse plug-in but I need a nice small version for my library itself and don't want to add another jar dependency.

It seems that ANTLR requires a run-time to parse files and I performed a Google search with no avail. Can anyone help out?

Thanks,

Chris

+3  A: 

Javacc generates java parsers from BNF-like input, and does not require a runtime library. You may need to modify the BNF slightly, I think there are some caveats as to what Javacc can accept.

skaffman