[antlr-interest] Problem with keeping information in Custom AST nodes

francislustman francislustman at yahoo.fr
Fri Sep 3 03:36:11 PDT 2004


Hello,

I am trying to code a chain lexer/parser/walker1/walker2
 implementing
a chain of tree transformations. My treewalkers build custom AST nodes
called MyAST. 

My expectation was that the extra attributes encoded in my custom
nodes when executing walker1 would still be there when executing walker2. 

In fact, the instruction astFactory->create(_t) generated by Antlr
does not, in my case, initialize these extra attributes, only Type and
Text are initialized correctly. 

I have subclassed the AST, not the ASTFactory, maybe that is the pb?

Can someone point me to an example so that I can try and find what I
did wrong ?

Thanks
Francis




 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/antlr-interest/

<*> To unsubscribe from this group, send an email to:
    antlr-interest-unsubscribe at yahoogroups.com

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 



More information about the antlr-interest mailing list