[antlr-interest] tree parser problem (correction)

Lloyd Dupont lloyd at galador.net
Wed Sep 4 04:07:19 PDT 2002

sorry for all syntax error !
I corrected !

I have a tree parser. and I have tree I want to read multiple time,
simplifying it each time.

let's imagine I have

file: (node1 | node2) *;
node1: #(NODE1 FOO);
node2: #(NODE2 BAR);

I want to do something with node1 on first pass and remove it.
to only have node2 on the second pass

I tryed something like:

options {
    buildAST = true;
stage1: (!node1Analysis | .) *;

stage2:! (node2Analysis) *;

where stage2 is called with getAST() produced by stage1.
unfortunately, when I do that the node2 is empty, where are all childs gone
I can't understand.
has anyone an idea, please ?

to help you I send a zipped project.....


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

-------------- next part --------------
A non-text attachment was scrubbed...
Name: glGenerator.tgz
Type: application/x-compressed
Size: 5129 bytes
Desc: not available
Url : http://www.antlr.org/pipermail/antlr-interest/attachments/20020904/c530d5a1/glGenerator.bin

More information about the antlr-interest mailing list