14401RE: [antlr-interest] Re: Bug in ANTLR C# implementation
- Dec 1, 2004The Java generated treeparser doesn't seem to have an initializeASTFactory method.
Since I'm running initializeASTFactory on the treeparser's own getASTFactory, there isn't much synching being done (by me, anyway). And all it does is set the factory's maximum anyway!
From: micheal_jor [mailto:open.zone@...]
Sent: Wed 12/1/2004 11:11 AM
Subject: [antlr-interest] Re: Bug in ANTLR C# implementation
--- In firstname.lastname@example.org, "Maassen, H.A.M."
> Well I've found out why I couldn't get any tree-rewriting actions towork - it seems to be a bug in the C# version of the (generated)
>manually adding a call to initializeASTFactory(getASTFactory()) in the
> The treeparser's method initializeASTFactory is never called. After
treeparser the problems have been fixed.
I was just about to copy your previously posted grammar to see if I
could reproduce your issues with buildAST. Never mind, seems you've
fixed it in any case.
The behaviour you describe (i.e. tree parsers being created with a
default ASTFactory) is by design. Users are supposed to use the static
method named initializeASTFactory() - or similar, it's on the
generated Parsers - to ensure their tree parser's ASTFactory is in
sync with the Parser's.
I may be wrong but, I thought this was uniform behaviour across all
Yahoo! Groups Links
- << Previous post in topic Next post in topic >>