Is there a reasonable C++ grammar (and tree grammar) available for ANTLR 2.x?
Terence Parr Unfortunately not. C++ does not lend itself to easy parsing. Most C++ recognizers accept a very loose superset of C++ and then try to "understand" it and restrict the input to valid syntax during phases subsequent to the parse phase.
John Lilley had a C++ parser that was actually pretty good for the previous version of ANTLR (PCCTS), but I doubt it would be more than just a reference to help with a new grammar.