[antlr-interest] how to find if parser ate all input?

Terence Parr parrt at cs.usfca.edu
Tue Sep 11 12:36:03 PDT 2007


On Sep 11, 2007, at 12:34 PM, Putrycz, Erik wrote:

> In my grammar unit tests, I test if the parser ate the whole input  
> string.
>
> With antlr 2.7 this was easy but I cannot figure out how to do this  
> with antlr 3.
>
> The antlrworks debugger somehow shows them in grey. How is this done?

see if input.index() >= input.size() I guess.

Ter

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.antlr.org/pipermail/antlr-interest/attachments/20070911/92bbd1c0/attachment.html 


More information about the antlr-interest mailing list