[antlr-interest] tree walker executes method call twice?

Safiye Celik safisce at gmail.com
Wed Aug 19 07:25:47 PDT 2009


Hi,
How do you create DoubleWalk1.jpg tree? I wanna display my tree as yours
which is more understandable for a human, but I cannot get such a tree. I
use JTree component constructed from a DefaultTreeModel component, and the
tree I get is as in the attachment, which is in expandable folder format and
not readable enough. And I could not find any component in Java to display a
tree as yours. I would be glad if you share your way. Thanks.

2009/8/19 Rob Dougan <rob_dougan at sympatico.ca>

>
> pass 1 - lex/parse produces heteroAst (nil root)
> pass 2 - heteroAst  into symbol table walker
> nodes reset
> pass 3 - heteroAst into type checking walker  (adds type info to ast)  --->
> walks twice
>
> its just a typical expression tree (C-like), the function call (abs(1.0))
> is the smallest statement I could get to fail
> but
> the tree walker always walks the input twice ... almost like the tree was
> duplicated
> hmmm
> will continue investigating ...
>
> R
> ------------------------------
> Date: Tue, 18 Aug 2009 12:58:43 -0700
> From: jimi at temporal-wave.com
> CC: antlr-interest at antlr.org
> Subject: Re: [antlr-interest] tree walker executes method call twice?
>
>
> Rob Dougan wrote:
>
>
> during testing i noticed that my tree walker seems to be walking the tree
> twice ...
>
> anyone spot a grammar problem?
>
>
> What does the input tree look like?
>
> Jim
>
>
> List: http://www.antlr.org/mailman/listinfo/antlr-interest
> Unsubscribe:
> http://www.antlr.org/mailman/options/antlr-interest/your-email-address
>
>


-- 
-safiye
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.antlr.org/pipermail/antlr-interest/attachments/20090819/a1de82ef/attachment.html 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: i_1950_0.gif
Type: image/gif
Size: 5535 bytes
Desc: not available
Url : http://www.antlr.org/pipermail/antlr-interest/attachments/20090819/a1de82ef/attachment.gif 


More information about the antlr-interest mailing list