[antlr-interest] Switching buildAST to true causes "Invalid ASTnode type" error.

Matt Benson gudnabrsam at yahoo.com
Fri Dec 2 13:06:49 PST 2005


I am not sure if you mean these errors are in a parser
or a treeparser... but whichever, if the offending
*parser and the corresponding lexer are defined in
separate files, you would want to make sure the
*TokenTypes.txt file is in your current directory when
you Tool the offending *parser's grammar file. 
Apologies if this is unrelated but I spent quite
awhile agonizing over this yesterday.

HTH,
Matt

--- Phil Ritchie <endigitalmind at yahoo.co.uk> wrote:

> 
> --- Micheal J <open.zone at virgin.net> wrote:
> 
> > > --- Peggy Fieland <madcapmaggie at yahoo.com>
> wrote:
> > > 
> > > > Did you remember to initialize the AST factory
> > when
> > > > you run your parser?
> > > > 
> > > Well I didn't but even if I do I still get the
> > same
> > > error during pasrer.series.
> > 
> > I'll look into this later Phil. All examples are
> > failing on my box for some
> > odd reason at the mo' but, I'll try and chase this
> > down.
> > 
> > Incidentally, can you run the examples (e.g. calc
> or
> > java) successfully?
> 
> Just tried the calc example and it works a treat. In
> my code COMMA has a token type of 6 in
> *TokenTypes.cs
> but the heteroList index trying to be retrieved for
> the attempted assignment to FactoryEntry in
> ASTFactory.cs is 7.
> 
> > 
> > Micheal
> > 
> > 
> 
> 
> 
> 	
> 	
> 		
>
___________________________________________________________
> 
> Yahoo! Messenger - NEW crystal clear PC to PC
> calling worldwide with voicemail
> http://uk.messenger.yahoo.com
> 



		
__________________________________ 
Start your day with Yahoo! - Make it your home page! 
http://www.yahoo.com/r/hs


More information about the antlr-interest mailing list