220Re: pretty printing
- Mar 1 9:45 AMsasecp@... hath spoken:
>From: sasecp@...2.6.0 will have token streams that are perfect for this...not sure if Pete
>I have an ANTLR java parser that I'm using successfully, and I'd like to add
>some pretty-printing capabilities to it. At the moment, the lexer throws
>away comments and whitespace, but I'd like to keep the comments and maybe
>some of the whitespace depending on user configuration. I'm wondering if
>there's a good hook that would allow me to not throw away the whitespace in
>the lexer, but deal with it in the parser somehow. I certainly don't want
>to modify every rule with information about where whitespace can occur. I
>will probably be adding actions to every rule to generate the text, I just
>don't want pollute the entire grammar.
>Is there a good way to do this?
>I'm using Antlr 2.5.0 with VC++ 5.0.
Wells will be able to get the C++ output updated soon and I'm still working
- << Previous post in topic Next post in topic >>