Hi,

I am struggling to re-use tokens across grammars. I have two combined grammars, 
namely

ManchesterOWLSyntax.g 
OPPLScript.g

They both import a parser grammar called MOWLParser.g, 

ManchesterOWLSyntax.g  imports it directly, whereas OPPLScript.g imports 
OPPLParser.g which imports MOWLParser.g

I would have thought that all the .tokens generated files would overlap on all 
the tokens defined inside MOWLParser.g

Maybe I am missing something but if I try to generate the code I end up with 
different MOWLParser.tokens which results in different token type codes for the 
same token.

Just as example the token CONJUNCTION gets code 77 when generating OPPLScript.g 
and 56 when generating ManchesterSyntax.g

I put all the relevant files at 
http://www.cs.man.ac.uk/~iannonel/antlrexperiments/ (both the loose files and 
their zipped archive: import.zip)

Thanks in advance for any help,

Luigi

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

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

Reply via email to