[antlr-interest] Antlrworks 1.3.1 and string template
pfa at isep.ipp.pt
pfa at isep.ipp.pt
Tue Nov 24 08:04:05 PST 2009
Hi,
I'm trying, without sucess, to run in antlrworks a simple string
template example, from the tpantlr-bundle. The following error occur:
Exception in thread "main" java.lang.IllegalArgumentException: Can't find
template assign.st; group hierarchy is [TParserTemplates]
at
org.antlr.stringtemplate.StringTemplateGroup.lookupTemplate(StringTemplateGroup.java:507)
at
org.antlr.stringtemplate.StringTemplateGroup.getInstanceOf(StringTemplateGroup.java:392)
at
org.antlr.stringtemplate.StringTemplateGroup.getInstanceOf(StringTemplateGroup.java:404)
at
org.antlr.stringtemplate.StringTemplateGroup.getInstanceOf(StringTemplateGroup.java:412)
at TParser.s(TParser.java:125)
at __Test__.main(__Test__.java:14)
The assign rule belongs to the T group (T.stg file), which is in the
project root dir (with T.g grammar). The settings are the defaults ones:
output directory, for the java files, and outputclasses directory for the
classes.
Pursuing this problem I tried 2 differents approaches:
1.
changing the generated __Test__.java code
2. replacing the generated
__Test__.java with the "hand made" Test.java (from the bundle)
In both
cases I was unable to solve the problem. Meantime I collected some more
questions:
1. In antlrworks can I use a specific test rig? I know about
the "Edit *.g Test Rig for Java" of the Run menu, and also the "Test Rig"
from the Preferences toolbox. But, what is suppose to write there, a
template? java code? I'm in the dark!
2. How can I disable the remote
debugging? In some of my tests the reported error was timeout from port
49153! But as far as I understood this is only used for remote testing. My
scenario is standalone.
I did searched for an answer in the email
repository and also in the antlrworks/antlr site. But didn't find anything.
Comments are welcome.
Pedro
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.antlr.org/pipermail/antlr-interest/attachments/20091124/658302c2/attachment.html
More information about the antlr-interest
mailing list