Perl ANTLR v3 Target
Ron Blaschke, ron at rblasch.org
Early prototyping phase. Simple lexer and parser are working.
Here's a simple example. Note that everything is still subject to change.
+ Escaped characters, like '\n', are now handled properly.
+ Added error handling.
Note the "no viable alternative" error message for the unrecognized '!'.
+ Handle lexer actions
Here's another short example, similar to the one above. Note how whitespaces are put into the hidden channel (99) and newlines are skipped.
+ Simple Parser is working
Quick, what is 2 + 2? If you can't remember here's an easy way to find out. First we need a grammar.
And here's the test program.
Finally we're getting to the answer.
+ Simple expression grammar
Started real porting effort. The goal is to port one ANTLR runtime class at a time from Java to Perl, including full API coverage and documentation. First stop of the porting train: ANTLR::Runtime::BitSet.
Got the first parser working: SimpleCalc, taken from the Five minute introduction to ANTLR 3.
Ronald Blaschke (ron at rblasch org)