[antlr-interest] Repost: ANTLRworks: Why do these rules behave differently in the embedded interpreter?
antlr at mirality.co.nz
Sat Jan 2 02:11:11 PST 2010
At 14:53 2/01/2010, Kyle Ferrio wrote:
>So, I thought, why not just build and run the target?
>Sure, codegen takes a second, and compiling to bytecode takes
>another second. So what? Small price for knowing it's right.
>Ok, but what about drawing concrete syntax trees? No problem,
>just insert actions.
Either I'm misinterpreting what you're talking about, or you're
describing what the ANTLRWorks debugger already does.
>In fact, it might even be possible to make predicates work in
>such an interp, by either "gating off" the callbacks or just
>"marking in the debugger" when we're processing a predicate.
The problem with predicates is that they're arbitrary target
language code; ANTLR simply doesn't have enough information to
emulate their functionality (for semantic predicates, at least;
syntactic predicates could be dealt with correctly). But that's
what the Debug Remote feature is for.
More information about the antlr-interest