Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » TMF (Xtext) » global scope and importedURI
global scope and importedURI [message #1055460] Wed, 08 May 2013 10:39 Go to next message
Andrea Sindico is currently offline Andrea Sindico
Messages: 266
Registered: November 2010
Senior Member

I am having some troubles in configuring scoping in my DSL

In my mwe2 I have set
 // scoping and exporting API
 fragment = scoping.ImportURIScopingFragment {}
 fragment = exporting.SimpleNamesFragment {}
 


with this configuration the content assist provides all the possible references (those contained in the same file and those contained in different files within the project) despite the import. This means that without any import I still see in the content assist references to elements of the right type but defined into different files.
when I chose one of these references the compiler depicts it as an error "coulnd't resolve reference to.. " although the referenced element is defined into an imported file. Note that the import seembs to be correcty resolved as I don't see any "Imported resource could not be found." error that I would expect as I have also configured

fragment = validation.JavaValidatorFragment {
                    composedCheck = "org.eclipse.xtext.validation.ImportUriValidator"
                    composedCheck = "org.eclipse.xtext.validation.NamesAreUniqueValidator"
                } 


What am I doing wrong?


Follow me on Twitter @andreasindico

Re: global scope and importedURI [message #1057731 is a reply to message #1055460] Wed, 08 May 2013 13:37 Go to previous message
Christian Dietrich is currently offline Christian Dietrich
Messages: 6315
Registered: July 2009
Senior Member
Hi,

make sure you remove xbasefragment and javatypesfragment as well
Previous Topic:Common features not lifted to super class
Next Topic:Grammar ambiguity only when using external references
Goto Forum:
  


Current Time: Wed Sep 24 02:36:14 GMT 2014

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

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