When I put thing like this in my editor: "var test2 = 1 + 1 ;"
I have an error saying: "Couldn't resolve reference to JvmIdentifiableElement '+'."
I tried to look up into the code, but I don't understand what is going on.
I ended up in org.eclipse.xtext.linking.lazy.LazyLinkingResource.getEObject(String), and it fails getting the "linked object".
As far I could see, the "first" of the "triple" is ok. It is an XBinaryOperationImplCustom, in which there are two XNumberLiteralImpl operands.
But I don't understand what the "reference" (second of the triple) should be. Neither what it actually is. The debugger says it has the name "feature".
Do you have the org.eclipse.xtext.xbase.lib on your classpath? The
implementation for the basic operations is contained therein, e.g. in
the class IntegerExtensions.
Am 02.02.13 14:28, schrieb Nicolas Lalevée:
> When I put thing like this in my editor: "var test2 = 1 + 1 ;"
> I have an error saying: "Couldn't resolve reference to
> JvmIdentifiableElement '+'."
> I tried to look up into the code, but I don't understand what is going on.
>
> I ended up in
> org.eclipse.xtext.linking.lazy.LazyLinkingResource.getEObject(String),
> and it fails getting the "linked object".
>
> As far I could see, the "first" of the "triple" is ok. It is an
> XBinaryOperationImplCustom, in which there are two XNumberLiteralImpl
> operands.
>
> But I don't understand what the "reference" (second of the triple)
> should be. Neither what it actually is. The debugger says it has the
> name "feature".
>
> Here here is Xtext file:
> https://github.com/nlalevee/jst/blob/master/org.hibnet.jst/src/org/hibnet/jst/Jst.xtext
>
> Propably I am not doing stuff properly in the JVM Model inferer, I don't
> understand that part well.
> https://github.com/nlalevee/jst/blob/master/org.hibnet.jst/src/org/hibnet/jst/jvmmodel/JstJvmModelInferrer.java
>
>
Yes, I have org.eclipse.xtext.xbase.lib_2.3.1.v201208210947.jar listed in the plugin dependencies, it is listed in the launch configuration, and I can see it listed in installed plugins in the Eclipse launched for debug.
note: you have to add it to the project your my.myxbasedsl file resides in.
On 2013-02-08 20:37:36 +0000, Nicolas Lalevée said:
> Yes, I have org.eclipse.xtext.xbase.lib_2.3.1.v201208210947.jar listed
> in the plugin dependencies, it is listed in the launch configuration,
> and I can see it listed in installed plugins in the Eclipse launched
> for debug.
--
Need training, onsite consulting or any other kind of help for Xtext?
Go visit http://xtext.itemis.com or send a mail to xtext at itemis dot de
And if I am understanding it well, it is only need on the java generation phase (the sort of compilation of my template phase), not the java compilation one neither the runtime. Right ?