|Xtext Grammar - usage of 'returns' [message #1046691]
||Mon, 22 April 2013 08:39
| rohit ahuja
Registered: February 2013
Below is a part of my grammar in which i am getting some error.
Assignment returns Parameter:
name=AssignmentName '=' defaultValue=INT ';'
// The Parameter rule, is actually part of an existing ecore model, which is defined as
//name - EString
//defaultValue - INT
AssignmentName returns EString :
// i need something like [Instance].[Parameter] and the concatenated thing to go to name, but if use
//var=[Instance]'.'param=[Parameter], it doesnt work, so i have put in a validator to check it,
is there any direct way?
I have two queries:
1) is stated above
2)I am getting an error as
"Cannot find compatible feature name in sealed EClass Parameter
from imported package http.........:
The existing feature 'name' has an incompatible type 'EString'
[java.lang.String]. The expected type is 'EString'."
I am confused as to why this message is, even though the message says both are EString.
I think i am missing something. Can anyone please help?
Thanks in Advance,
Powered by FUDForum
. Page generated in 0.01786 seconds