On Thu, 2008-11-13 at 15:26 -0800, Yang Jiang wrote:
> Andy Tripp wrote:
> > This seems like a good goal for the new ANTLR tree rewrite mechanism.
> > Given the problem of converting a "whatever the java.g author thought
> > was reasonable" AST to a "exactly what javac needs" AST, if the
> > rewrite mechanism can make this easier than just "doing it by hand", then
> > it will be a "good" mechanism, and not just a toy.
> >
> > Having said that, it looks to me like none of the tree rewrite software
> > (e.g. TXL) out there are "good". In other words, they don't look to me 
> > like they
> > are saving anybody any work, even for this typical use case.
> >
> > I'm sure Terence could use ANTLR treewalkers to do this pretty quickly,
> > but I wonder if Jiang could, too.
> Hi Andy,
> I agree with you that rewrite from on AST to another AST could be hard :)
> 
> But what Simon was saying is to use the Antlr tree rewrite + a custom 
> TreeAdaptor to build
> the javac tree directly, rather than using the Antlr tree built from the 
> tree rewrite grammar with a tree walker,
> then generating the javac tree.

I thought about this for JavaFX but decided against it because of the
inability to append new nodes. It would mean having code in the tree
adaptor to work out when a node was 'complete' and this adds more
complication to the system for basically no gain. 

Jim


List: http://www.antlr.org:8080/mailman/listinfo/antlr-interest
Unsubscribe: 
http://www.antlr.org:8080/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