[antlr-interest] valid grammar does not compile

Jim Idle jimi at temporal-wave.com
Thu Nov 17 07:25:44 PST 2011


The range 'a'..'z' does not mean the letters a to z but the token numbers
assigned by ANTLR - you need to read the 5 minute getting started articles
in the WIKI or use the search on the support page.

Jim

> -----Original Message-----
> From: antlr-interest-bounces at antlr.org [mailto:antlr-interest-
> bounces at antlr.org] On Behalf Of D. Frej
> Sent: Thursday, November 17, 2011 12:15 AM
> To: antlr-interest at antlr.org
> Subject: [antlr-interest] valid grammar does not compile
>
> Hi,
>
> I build the following grammar with antlrworks:
>
> grammar questionmark;
>
> horef
>     :    '\?' ('a'..'z')
>     ;
>
> antlrworks tells me "check grammar succeeded". However, debugging does
> not works because the generated code does not compile !?
>
> My question: how does the rule have to look like so that the code
> compile?
> I want to parse text of the form ?a which should be a trivial task for
> antlr.
>
> Thanks,
>
> Didi
> --
> Empfehlen Sie GMX DSL Ihren Freunden und Bekannten und wir belohnen Sie
> mit bis zu 50,- Euro! https://freundschaftswerbung.gmx.de
>
> List: http://www.antlr.org/mailman/listinfo/antlr-interest
> Unsubscribe: http://www.antlr.org/mailman/options/antlr-interest/your-
> email-address


More information about the antlr-interest mailing list