[antlr-interest] how to let parser control lexer state.

Jim Idle jimi at temporal-wave.com
Sun Apr 29 00:28:02 PDT 2007


Syntax directed lexing opens up whole bags of worms. Perhaps we should
just delete languages that require it? ;-). But I suppose ANTLR should
be able to convert them into something sane ;-).

Jim

-----Original Message-----
From: antlr-interest-bounces at antlr.org
[mailto:antlr-interest-bounces at antlr.org] On Behalf Of femto gary
Sent: Saturday, April 28, 2007 11:26 PM
To: ANTLR Interest
Subject: Re: [antlr-interest] how to let parser control lexer state.

Hi Benjamin, actually I'm also begining writing this
lazy/rewindable tokenSource/tokenStream,
I don't think it is too difficult, will contact
you if I need help, Thanks.
and Jim Idle, the island grammar in the download
doesn't helps too, because lexing need parser's info,
while in the example, lexing doesn't need parser's info,
just new a island-grammar parser and its job will be done.
(actually , the wiki provides an island-grammar example which
lexing will be controlled by parser, but I feel it is a bit complex
so would like to write my own solution. besides, I can't find
the whole source code of metaas, (in their homepage, they
just put bin download, and in svn trunk, I can't find whole source
code.)


(besides, can the reply-to address be configured in this mailing list?
I click reply and reply to just one person and become off mailing list).


More information about the antlr-interest mailing list