Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » TMF (Xtext) » Using FQN rule in reference rules does not work as expexcted.(Qualified name does not resolve)
Using FQN rule in reference rules does not work as expexcted. [message #1837082] Thu, 21 January 2021 17:54 Go to next message
Olaf Bigalk is currently offline Olaf BigalkFriend
Messages: 155
Registered: July 2009
Location: Berlin
Senior Member
I have the following parts in my grammar:

DynamicText:
	name=ID ":=" feature=[ecore::EStructuralFeature|QN] ("with" function=ID)
;
	
terminal QN:
	ID ('.' ID)+
;


the generated editor depicts that "DynamicText" could not be resolved.

var xxx := DynamicText.feature 


I exspected " DynamicText.feature" gets parsed together as QN and then be compared to the scope provided here.

What is wrong ?
Re: Using FQN rule in reference rules does not work as expexcted. [message #1837083 is a reply to message #1837082] Thu, 21 January 2021 18:42 Go to previous messageGo to next message
Christian Dietrich is currently offline Christian DietrichFriend
Messages: 14665
Registered: July 2009
Senior Member
afaik estructural features are not in the index so it wont work with default scoping.
maybe you can try an eclass with QN + a separate reference for the feature.
or you do a reference to an epackage and do scoping for the qualified features manually.

also see open model element dialog


Twitter : @chrdietrich
Blog : https://www.dietrich-it.de
Re: Using FQN rule in reference rules does not work as expexcted. [message #1837089 is a reply to message #1837083] Thu, 21 January 2021 22:19 Go to previous messageGo to next message
Olaf Bigalk is currently offline Olaf BigalkFriend
Messages: 155
Registered: July 2009
Location: Berlin
Senior Member
Sorry, I didn't mentioned I have a custom ScopeProvider for this feature and that delivers exactly what you see "DynamicText.feature"
That is why I am wondering about this behavior
Re: Using FQN rule in reference rules does not work as expexcted. [message #1837096 is a reply to message #1837089] Fri, 22 January 2021 04:48 Go to previous messageGo to next message
Christian Dietrich is currently offline Christian DietrichFriend
Messages: 14665
Registered: July 2009
Senior Member
Then please give more details

Twitter : @chrdietrich
Blog : https://www.dietrich-it.de
Re: Using FQN rule in reference rules does not work as expexcted. [message #1837151 is a reply to message #1837096] Fri, 22 January 2021 20:06 Go to previous messageGo to next message
Olaf Bigalk is currently offline Olaf BigalkFriend
Messages: 155
Registered: July 2009
Location: Berlin
Senior Member
Christian Dietrich wrote on Thu, 21 January 2021 23:48
Then please give more details


First Thanks for the answer.
Would you be so kind to specify which details you need to analyse the problem?

Re: Using FQN rule in reference rules does not work as expexcted. [message #1837156 is a reply to message #1837151] Fri, 22 January 2021 21:23 Go to previous messageGo to next message
Olaf Bigalk is currently offline Olaf BigalkFriend
Messages: 155
Registered: July 2009
Location: Berlin
Senior Member
The problem has disappeared some how.
Thank you for taking time for me.

Re: Using FQN rule in reference rules does not work as expexcted. [message #1837163 is a reply to message #1837156] Sat, 23 January 2021 05:44 Go to previous message
Christian Dietrich is currently offline Christian DietrichFriend
Messages: 14665
Registered: July 2009
Senior Member
I would have expected: this is how my scope provider looks like
(Code snippet oder pseudo code here)


Twitter : @chrdietrich
Blog : https://www.dietrich-it.de
Previous Topic:Import of Xtext Grammar Model
Next Topic:[Formatter2] append newLine + spaces
Goto Forum:
  


Current Time: Fri Apr 26 11:35:23 GMT 2024

Powered by FUDForum. Page generated in 0.04406 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top