[antlr-interest] Another beginner question.. about ANTLR parsing
Anthony Brenelière
abreneliere at telys.com
Sun Feb 9 14:59:38 PST 2003
Is it possible to right-parse for a specific rule ?
I have the following rule :
entity! // (supplier WHERE name="Telys"):client
: a:entityComponent (COLON! b:entity)?
{ #entity = #( #[ENTITY_RULE, "entity"], #a, #b ); }
;
..and i would like to replace it by..
entity! // (supplier WHERE name="Telys"):client
: (a:entity COLON)? b:entityComponent
{ #entity = #( #[ENTITY_RULE, "entity"], #a, #b ); }
;
..because i need to have the left-most entity to be at a higher level in
the tree, instead of the right-most entity, so i need the recursion on
the left.
I see no other solution,
If you have an idea, thanks to respond ;)
Cordially,
Anthony
Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
More information about the antlr-interest
mailing list