[antlr-interest] "An Introduction to ANTLR" presentation slides
Andy Tripp
antlr at jazillian.com
Thu Feb 28 09:38:52 PST 2008
Terence Parr wrote:
>
> A syn pred simply specifies the sytnactic context that must be true
> for the parser (or lexer or tree parser) to pass.
Ah, OK. So my slide is wrong.
I guess I tend to wrongly equate "syntax" with a lexer and "semantics"
with a parser.
So a syntactic predicate can apply to lexer, parser, or treewalker.
And I guess a syntactic predicate is a specific kind of semantic
predicate. Whereas a sem pred is
any boolean expression that must be true to match, a syn pred is one
that simply says
"look ahead and see if we'll match X".
More information about the antlr-interest
mailing list