So I have been working on this for about a week, and I even bought the 
ANTLR book, but I can't seem to find how to get what seems like simple 
data out of the grammar.

Here's a very, very limited example. I am merely trying to get data out 
of CSS files. I guess the questions I have are:
1) Should I be using an AST? I assumes I would, since CSS can br broken 
down to a tree very simply, but upon further reading, it may not 
actually be beneficial since I am not trying to solve a really complex 
language issue...
2) How would one, in speudo code, get the actual data out of the following:

The input would be "aa, bb, cc" and I simply want a list of 
['aa','bb','cc']. I am not trying to process it, just get the list out 
of it, ignoring the commas, in a variable I can use.

    prog : rone (COMMA rone)*
           ;

    rone : IDENT;

    IDENT: 'a'..'z' ('a'..'z')*;
    COMMA: ',';

Thanks in advance,
    Brian

-- 
Brian Nelson
Software Engineer, Neue Software

e. br...@neuesoftware.com
c. +1 408 373 8310


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"il-antlr-interest" group.
To post to this group, send email to il-antlr-interest@googlegroups.com
To unsubscribe from this group, send email to 
il-antlr-interest+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/il-antlr-interest?hl=en
-~----------~----~----~----~------~----~------~--~---

List: http://www.antlr.org/mailman/listinfo/antlr-interest
Unsubscribe: 
http://www.antlr.org/mailman/options/antlr-interest/your-email-address

Reply via email to