Dear all,
I have encountered the following problem with my grammar related to
comments:
The rule loop_header correctly matches a construct such as:
loop_ # comment
_tag1
_tag2
_tag3
However, when I later get the text matched by the rule loop_header as
"$loop_header.text", the text of the comment is still included, even though
I send the comments to the hidden channel.
Is there a way to discard the text of the comment from the text stream
matched by a rule?
loop_header
: LOOP_ ( WHITESPACE+ TAG )+ WHITESPACE
;
COMMENTS
: ( ( '#' ANY_PRINT_CHAR* EOL )+ ) { $channel = HIDDEN; }
;
Thanks,
Richard
List: http://www.antlr.org/mailman/listinfo/antlr-interest
Unsubscribe:
http://www.antlr.org/mailman/options/antlr-interest/your-email-address
--
You received this message because you are subscribed to the Google Groups
"il-antlr-interest" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/il-antlr-interest?hl=en.