Hi Martin,

For lexers you can implement CharStream (ICharStream in the C# target), and
for parsers you can implement TokenStream (ITokenStream in C# target). I've
successfully used the former for case-insensitive lexing, and the latter for
a preprocessor. ANTLRReaderStream is one of the included implementations of
CharStream, and at least for .NET offers support for "io pipes" (which
appear in the .NET framework as either TextReader (Console.In), or Stream
objects such as FileStream which can be passed as "new StreamReader(file)").

Sam

-----Original Message-----
From: [email protected]
[mailto:[email protected]] On Behalf Of Martin d'Anjou
Sent: Tuesday, March 29, 2011 11:45 PM
To: [email protected]
Subject: Re: [antlr-interest] antlr v4 wish list

Also, how about support for io pipes to decouple the lexer from the parser,
such that each could be in its own thread? Also, the input to the lexer
could be an io pipe. Might be easier to place a pre-processor in front of
the lexer this way, and also to handle gigantic files.

Martin

List: http://www.antlr.org/mailman/listinfo/antlr-interest
Unsubscribe:
http://www.antlr.org/mailman/options/antlr-interest/your-email-address


List: http://www.antlr.org/mailman/listinfo/antlr-interest
Unsubscribe: 
http://www.antlr.org/mailman/options/antlr-interest/your-email-address

-- 
You received this message because you are subscribed to the Google Groups 
"il-antlr-interest" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/il-antlr-interest?hl=en.

Reply via email to