[antlr-interest] How can I simulate states in antlr

Jose Ventura jose.ventura.roda at gmail.com
Thu Feb 23 03:08:01 PST 2006


I'm developing a lexical analizer for Cobol and I'm having problems with the
picture strings.

The sentence character separator in cobol is the sign '.', bud some sentence
can to contain this separator, for example in the data declaration:

01 DATA-ITEM    PIC   999.999,99 USAGE DISPLAY.

The sentence finalice with second '.'

Whit states I know how do the lexer, I will make one state SPIC than consume
all character after the token PIC until the next space, but I haven't found
the solution with antlr.

Can anyone help me?

Thanks in advance.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.antlr.org/pipermail/antlr-interest/attachments/20060223/2645ebcf/attachment.html


More information about the antlr-interest mailing list