[antlr-interest] Error recovery - HELP
Matt Benson
gudnabrsam at yahoo.com
Wed Apr 21 12:54:00 PDT 2004
Maybe you should look into Bogdan Mitu's SATC package.
Check the ANTLR filesharing area...
-Matt
--- jduquevieira <jpdv at medialog.pt> wrote:
> I have a simple Math gramar.
> And it's used in a graphical Math editor.
>
> The editor user has to be able to write incomplete
> expressions
> like "(2+".
> And when the user writes this, I have to get an
> incomplete tree, not
> an exception.
>
> Any ideas?
> Here goes the gramar.
>
> Best regards.
>
>
>
> expression
> : equal
> ;
>
> equal
> : sum (EQUAL^ sum)*
> ;
>
> sum
> : subtraction (PLUS^ subtraction)*
> ;
>
> subtraction
> : product (MINUS^ product)*
> ;
>
> product
> : division (TIMES^ division)*
> ;
>
> division
> : number (DIV^ number)*
> ;
>
> number
> : NUMBER
> | LEFT_PARENT expression RIGHT_PARENT
> ;
>
>
>
>
>
> Yahoo! Groups Links
>
>
> antlr-interest-unsubscribe at yahoogroups.com
>
>
>
__________________________________
Do you Yahoo!?
Yahoo! Photos: High-quality 4x6 digital prints for 25¢
http://photos.yahoo.com/ph/print_splash
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/antlr-interest/
<*> To unsubscribe from this group, send an email to:
antlr-interest-unsubscribe at yahoogroups.com
<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/
More information about the antlr-interest
mailing list