Building antlr 4.1: no such property or can't access: org.antlr.tool.Grammar.indirectDelegates

428 views
Skip to first unread message

henrik sorensen

unread,
Jun 18, 2015, 2:02:23 AM6/18/15
to antlr-di...@googlegroups.com
Esteemed group,

I have had a version of ANTLR v4.1 for quite some time in my Eclipse workspace.

Now when I try to build this version using build.xml, the following error happens.
How can I decipher this?

The code hasnt changed since my last build, but I have upgraded Eclipse since.

I can't easily upgrade to latest ANTLR so any help greatly appreciated.


     [mkdir] Created dir: C:\Users\076946\git\csat-application\csat-antlr4-extension\csat-antlr4-extension\build\generated-sources\antlr3\org\antlr\v4\parse
     [java] warning(24):  template error: context [/outputFile /parser /genericParser /region__/genericParser__members /region__/genericParser__members] 32:3 no such property or can't access: org.antlr.tool.Grammar.indirectDelegates
     [java] Caused by: org.stringtemplate.v4.misc.STNoSuchPropertyException: no such property: org.antlr.tool.Grammar.indirectDelegates
     [java] at org.stringtemplate.v4.misc.ObjectModelAdaptor.throwNoSuchProperty(ObjectModelAdaptor.java:106)
     [java] at org.stringtemplate.v4.misc.ObjectModelAdaptor.lookupMethod(ObjectModelAdaptor.java:99)
     [java] at org.stringtemplate.v4.misc.ObjectModelAdaptor.getProperty(ObjectModelAdaptor.java:67)
     [java] at org.stringtemplate.v4.Interpreter.getObjectProperty(Interpreter.java:1158)
     [java] at org.stringtemplate.v4.Interpreter._exec(Interpreter.java:210)
     [java] at org.stringtemplate.v4.Interpreter.exec(Interpreter.java:145)
     [java] at org.stringtemplate.v4.Interpreter.writeObject(Interpreter.java:703)
     [java] at org.stringtemplate.v4.Interpreter.writeObjectNoOptions(Interpreter.java:635)
     [java] at org.stringtemplate.v4.Interpreter._exec(Interpreter.java:285)
     [java] at org.stringtemplate.v4.Interpreter.exec(Interpreter.java:145)
     [java] at org.stringtemplate.v4.Interpreter.writeObject(Interpreter.java:703)
     [java] at org.stringtemplate.v4.Interpreter.writeObjectNoOptions(Interpreter.java:635)
     [java] at org.stringtemplate.v4.Interpreter._exec(Interpreter.java:285)
     [java] at org.stringtemplate.v4.Interpreter.exec(Interpreter.java:145)
     [java] at org.stringtemplate.v4.Interpreter.writeObject(Interpreter.java:703)
     [java] at org.stringtemplate.v4.Interpreter.writeObjectNoOptions(Interpreter.java:635)
     [java] at org.stringtemplate.v4.Interpreter._exec(Interpreter.java:285)
     [java] at org.stringtemplate.v4.Interpreter.exec(Interpreter.java:145)
     [java] at org.stringtemplate.v4.Interpreter.writeObject(Interpreter.java:703)
     [java] at org.stringtemplate.v4.Interpreter.writeObjectNoOptions(Interpreter.java:635)
     [java] at org.stringtemplate.v4.Interpreter._exec(Interpreter.java:285)
     [java] at org.stringtemplate.v4.Interpreter.exec(Interpreter.java:145)
     [java] at org.stringtemplate.v4.ST.write(ST.java:415)
     [java] at org.antlr.codegen.CodeGenerator.write(CodeGenerator.java:1296)
     [java] at org.antlr.codegen.Target.genRecognizerFile(Target.java:98)
     [java] at org.antlr.codegen.CodeGenerator.genRecognizer(CodeGenerator.java:459)
     [java] at org.antlr.Tool.generateRecognizer(Tool.java:696)
     [java] at org.antlr.Tool.process(Tool.java:509)
     [java] at org.antlr.Tool.main(Tool.java:98)
     [java] Caused by: java.lang.reflect.InvocationTargetException
     [java] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
     [java] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
     [java] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
     [java] at java.lang.reflect.Method.invoke(Method.java:483)
     [java] at org.stringtemplate.v4.misc.Misc.invokeMethod(Misc.java:218)
     [java] at org.stringtemplate.v4.misc.ObjectModelAdaptor.lookupMethod(ObjectModelAdaptor.java:84)
     [java] ... 27 more
     [java] Caused by: java.lang.NullPointerException
     [java] at java.util.Objects.requireNonNull(Objects.java:203)
     [java] at java.util.ArrayList.removeAll(ArrayList.java:674)
     [java] at org.antlr.tool.CompositeGrammar.getIndirectDelegates(CompositeGrammar.java:226)
     [java] at org.antlr.tool.Grammar.getIndirectDelegates(Grammar.java:2722)
     [java] ... 33 more


Thanks
Henrik

henrik sorensen

unread,
Jun 19, 2015, 8:58:17 PM6/19/15
to antlr-di...@googlegroups.com
SOLVED: Needed update the antlr 3.5 version, following the instructions on:

thanks!
Henrik
Reply all
Reply to author
Forward
0 new messages