Here's what I'm working on in the C# port: If a target class is not present in the executable (Antlr3.exe), it tries to load Antlr3.Target.<targetname>.dll, then check for the target in there. Then it has the target return a StringTemplateGroup that knows the location of the .stg file, whether embedded in the satellite assembly or located on disk.
Sam -----Original Message----- From: [email protected] [mailto:[email protected]] On Behalf Of Rick Mann Sent: Monday, January 19, 2009 7:51 PM To: antlr-interest Interest Subject: [antlr-interest] Proposal to make writing language targets a biteasier I have grander plans, but this suggestion I think is easy to implement. First, re-org the source directories so that the runtime, Java and .stg files for a given language are kept under a combined directory structure. The Maven build would probably need to be modified to allow it to find the Java files in an arbitrary location (this way, I can work on my language target and check it into my own version control until it's ready for submission). Second, modify the 'language' option to accept an absolute path. The ANTLR tool can look for a path separator in the value, and it would use this directory (or some directory under it) on disk, rather than relative to the classpath, for loading the .stg files. The actual language string would come from the last component of the path. This allows me to skip recompiling for changes in .stg files alone, and dramatically speeds up development. I hard-coded the path in ANTLR to point to my templates directory, so it's working for me, but this should be a pretty easy change to make. I'd happily code it up and submit a patch, if you like (although I may miss some places where it's used). -- Rick List: http://www.antlr.org/mailman/listinfo/antlr-interest Unsubscribe: http://www.antlr.org/mailman/options/antlr-interest/your-email-address 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 -~----------~----~----~----~------~----~------~--~---
