is there a general advice to shortcut an alternation in a rule if one already commited subrule fails:
Example:
ENTITY : ( COMMENT | OPTION | DECLARATION | SCOPE )(s)
COMMENT : '#' <commit> m/.*/ | <error?> <reject>
OPTION : IDENT '=' <commit> VALUE { store($item{IDENT}, $item{VALUE}) } | <error?> <reject>
DECL : TYPE NAME '{' <commit> DECL_BODY '}' { store($item{TYPE}, $ITEM{NAME}, $ITEM{DECL_BODY}) } | <error?> <reject>
SCOPE : 'scope' <commit> '{' ENTITY(s) '}' | <error?> <reject>
I would like to see the immediately failure of ENTITY, if e.g. the DECL subrule fails after already commited.
Is there a general usage pattern to shortcut the ENTITY rule if an already commited subrule fails?
Best Regards Charly -- Karl Gaissmaier KIZ/Infrastructure, University of Ulm, Germany Email:[EMAIL PROTECTED] Service Group Network Tel.: ++49 731 50-22499