[antlr-interest] Check out TreeWizard

Johannes Luber jaluber at gmx.de
Tue Jul 3 01:51:33 PDT 2007


Terence Parr wrote:
> howdy,
> 
> Added an entry to my "blog" (which has moved to the wiki):
> 
> http://www.antlr.org/wiki/display/~admin/2007/07/02/Exploring+Concept+of+TreeWizard
> 
> After talking with Don Bradshaw at http://www.quipoz.com in Sydney and
> after trying to convert ANTLR v3's grammar (written in v2) into v3, I
> decided to build TreeWizard. You can create, navigate, and match trees
> very easily using tree patterns that are like interpreted ANTLR patterns
> (er...well, they pretty much are).  If people find it useful etc..., it
> will make it's way into ANTLR after we've groomed it etc...  Please try
> it out and let me know if it's useful for ya... It's pretty damn cool. 
> The following executes a method in action object for every subtree that
> matches the indicated pattern.
> 
> atreewizard.visit(t, "(VARDECL %type:. %id:ID)", mylistener);
> 
> '.' (dot) is the wildcard; type and id are labels that appear in a
> hashtable for the mylistener's visit() method to chew on.
> 
> All the code is attached to the wiki page.
> 
> Ter
> 

If I see it correctly, your link points to an admin page. Unless you
want to give us your password the wiki page is inaccessible, as a quick
search after "tree wizard" confirmed it.

Best regards,
Johannes Luber


More information about the antlr-interest mailing list