[antlr-interest] VB If elseif end if?

Monty Zukowski monty at codetransform.com
Wed Apr 28 10:06:08 PDT 2004


On Apr 27, 2004, at 11:07 AM, John D. Mitchell wrote:

>
>> This is because in VB the newline after y means your done.  However I 
>> eat
>> all newlines in the lexer.  What are the possible ways around this?
>
> ObDisclaimer. I haven't even looked at any version of Microsoft BASIC 
> in at
> least a decade.
>
> What's the actual rules for dealing with newlines in VB?  E.g., can you
> have individual expressions or "statements" which occur on multiple 
> lines
> or is the newline always a terminator (or a separator)?
>
> Basically, depending on that answer, you could inject a synthetic 
> separator
> or terminator when you see a newline.

Also you could write a parser filter that handles that.  There are 
similar issues in AREV basic.  See "Using a Parser as a TokenFilter": 
http://www.codetransform.com/filterexample.html

Monty Zukowski

ANTLR & Java Consultant -- http://www.codetransform.com
ANSI C/GCC transformation toolkit -- 
http://www.codetransform.com/gcc.html
Embrace the Decay -- http://www.codetransform.com/EmbraceDecay.html



 
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