[antlr-interest] 'DOWN' and <UP> tokens

Johannes Luber JALuber at gmx.de
Fri Aug 21 08:44:32 PDT 2009


> Hi,
> While parsing my AST tree, I get some errors such as "no viable
> alternative
> at input 'DOWN'" or "mismatched tree node:1 expecting <UP>". What are
> those
> UP and DOWN tokens? They are not mine :)

This means that your tree grammar isn't entirely consistent with your parser. The UP and DOWN tokens are used to encode the two dimensional pare tree in a one dimensional stream. So check your rules at the appropriate place that what the parser actually creates is also expected by the tree grammar.

Johannes
> 
> -- 
> -safiye

-- 
Neu: GMX Doppel-FLAT mit Internet-Flatrate + Telefon-Flatrate
für nur 19,99 Euro/mtl.!* http://portal.gmx.net/de/go/dsl02


More information about the antlr-interest mailing list