[antlr-interest] Sample scannerless parser with AST construction in unmodified ANTLR

Peter Kooiman peter at crispu.com
Sun Apr 17 10:25:24 PDT 2011


> Still, we could easily do it with a simple {...}? so ANTLR can still do it without formalism, 
> just as PEGs force you to manually say that as well. :)

Are you thinking of a validating semantic predicate after matching the keyword? Not sure if that would work always, could that not give rise to a failed predicate error message when we really just want the parser to use the identifier rule instead? Or are you thinking of a semantic predicate checking look-ahead for keyword followed by not-letter not-digit?

Peter


More information about the antlr-interest mailing list