[antlr-interest] ANTLRWorks, Internal ERROR with my grammar.
Terence Parr
parrt at cs.usfca.edu
Mon Jan 21 15:50:58 PST 2008
Hi, this is a known ANTLR issue where it doesn't give a good message
when you use ! or ^ and no output=AST option.
Ter
On Jan 21, 2008, at 2:14 PM, Ruslan Zasukhin wrote:
>> On 21/1/08 9:50 PM, "Ruslan Zasukhin" <sunshine at public.kherson.ua>
>> wrote:
>
> Hi Again,
>
>>> * debugger even do not starts and show dialog about INTERNAL ERROR.
>>> see attached picture.
>
> I have found reason why debugger fails to start.
>
> For this I have start reduce our grammar as much as possible and
> have come
> to this:
>
> ----------------------------------
> grammar VSQL_Parser;
>
> sql
> : sql_single EOF!
> ;
>
> sql_single : 'create' 'table' IDENT;
>
> IDENT : ('a'..'z'|'A'..'Z')+ ;
> INT : '0'..'9'+ ;
> NEWLINE:'\r'? '\n' ;
> WS : (' '|'\t')+ {skip();} ;
> ----------------------------------
>
> And we still get this internal error
> Solution is to remove ! Near to EOF!
>
> Its never mind where ! Is located.
>
> For example this also produce this error sometimes. But on the
> second run it
> seems works fine..
>
>
> ----------------------------------
> grammar VSQL_Parser;
>
> sql
> : sql_single EOF
> ;
>
> sql_single : 'create' 'table'! IDENT;
>
> IDENT : ('a'..'z'|'A'..'Z')+ ;
> INT : '0'..'9'+ ;
> NEWLINE:'\r'? '\n' ;
> WS : (' '|'\t')+ {skip();} ;
> ----------------------------------
>
>
> Why this happens? My bug? ANTRLWorks bug ?
>
>
> --
> Best regards,
>
> Ruslan Zasukhin
> VP Engineering and New Technology
> Paradigma Software, Inc
>
> Valentina - Joining Worlds of Information
> http://www.paradigmasoft.com
>
> [I feel the need: the need for speed]
>
>
More information about the antlr-interest
mailing list