[antlr-interest] Re: Import vocabulary

lgcraymer lgc at mail1.jpl.nasa.gov
Sat Apr 24 16:05:31 PDT 2004


ANTLR only supports one import vocabulary per grammar, and the last
one should win--there is a string variable that is set for the option.
 Supporting more than one import vocab could be done, but that would
require a scheme for numbering token types so that they don't overlap.
 Not a good idea--that would be error prone.

--Loring


--- In antlr-interest at yahoogroups.com, "Mike Lischke" <lists at l...> wrote:
> Hi,
> 
> How is the import of a vocabulary supposed to work when I import
more than one? Currently it looks like the last one wins (i.e. tokens
from previously imported vocabularies are lost). I can put everything
into one vocabulary, sure, but for a clean implementation I prefer to
keep my preprocessor vocabulary (ifdef, define etc.) separate from the
main parser vocabulary.
> 
> Mike
> --
> www.soft-gems.net



 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
     http://groups.yahoo.com/group/antlr-interest/

<*> To unsubscribe from this group, send an email to:
     antlr-interest-unsubscribe at yahoogroups.com

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



More information about the antlr-interest mailing list