[antlr-interest] Re: interactive envionments and non-delayed rule reduction

Monty Zukowski monty at codetransform.com
Tue Aug 3 09:23:41 PDT 2004


Well, if you don't have a line continuation character then try parsing 
the string and if it fails wait for the next string to see if it 
finishes.

What do you do if they type this?

(3 + 4)
   *5

Monty


On Aug 3, 2004, at 7:37 AM, Neurosurg wrote:

> Hi Monty
>
> --- In antlr-interest at yahoogroups.com, Monty Zukowski <monty at c...> 
> wrote:
>> Feed the parser one complete line at a time using a StringStream or
>> equivalent.  Then the end of the line will really be EOF and ANTLR 
>> will
>> know that no more is coming.
>
> hm, well, but that does not allow for multiline input like this:
>
>  (3+
>      4)*5
>
> Actually not every EOL should invoke calculation, but only those EOL,
> which finish a valid complete expression. This is actually the case 
> meant.
>
> Thank you.
> --
> Valery
>
>
>
>
> Yahoo! Groups Links
>
>
>
>
>
>
>



 
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