Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » TMF (Xtext) » Scope Provider is not deterministic.
Scope Provider is not deterministic. [message #673627] Tue, 24 May 2011 09:43 Go to next message
Ib Nielsen is currently offline Ib NielsenFriend
Messages: 2
Registered: May 2011
Junior Member
I'm using XText version 1.02 and I have a problem with my scopeprovider.

Scoping in the editor behaves differently depending on how the file containing my language is opened when the
Workbench is started.

I have 4 cases:

CASE 1:
All tabs are closed when workbench is started and I open the file with my language.
OUTCOME 1:
Everything is fine and the right scopeprovider gets called.

CASE 2:
Only a file with my language is open when workbench is started.
OUTCOME 2:
Everything is fine and the right scopeprovider gets called.

CASE 3:
Empty file with right filename extension is open when workbench is started. Then I open the file with my language.
OUTCOME 3:
My scopeprovider is not called but instead a scopeprovider on a higher level which I cannot use.

CASE 4:
A valid language file is open when workbench is started. Then I open the file with my language.
OUTCOME 4:
My scopeprovider is not called but instead a scopeprovider on a higher level which I cannot use.

Have you seen this before?

Regards Ib Nielsen
Re: Scope Provider is not deterministic. [message #674697 is a reply to message #673627] Fri, 27 May 2011 22:46 Go to previous messageGo to next message
Sebastian Zarnekow is currently offline Sebastian ZarnekowFriend
Messages: 3118
Registered: July 2009
Senior Member
Hi Ib,

what do you mean with 'ScopeProvider on a higher level is called'?
If you plugin.xml is valid (no duplicate editor registrations for the
very same file extension etc), Xtext will always take the scope provider
that was registered in the module of the right language.

Regards,
Sebastian
--
Need professional support for Eclipse Modeling?
Go visit: http://xtext.itemis.com

Am 24.05.11 11:43, schrieb Ib Nielsen:
> I'm using XText version 1.02 and I have a problem with my scopeprovider.
>
> Scoping in the editor behaves differently depending on how the file
> containing my language is opened when the
> Workbench is started.
>
> I have 4 cases:
>
> CASE 1:
> All tabs are closed when workbench is started and I open the file with
> my language.
> OUTCOME 1:
> Everything is fine and the right scopeprovider gets called.
>
> CASE 2:
> Only a file with my language is open when workbench is started.
> OUTCOME 2:
> Everything is fine and the right scopeprovider gets called.
>
> CASE 3:
> Empty file with right filename extension is open when workbench is
> started. Then I open the file with my language.
> OUTCOME 3:
> My scopeprovider is not called but instead a scopeprovider on a higher
> level which I cannot use.
>
> CASE 4:
> A valid language file is open when workbench is started. Then I open the
> file with my language.
> OUTCOME 4:
> My scopeprovider is not called but instead a scopeprovider on a higher
> level which I cannot use.
>
> Have you seen this before?
>
> Regards Ib Nielsen
>
Re: Scope Provider is not deterministic. [message #675044 is a reply to message #674697] Mon, 30 May 2011 06:40 Go to previous messageGo to next message
Ib Nielsen is currently offline Ib NielsenFriend
Messages: 2
Registered: May 2011
Junior Member
Hi Sebastian

I have a scopeprovider attached to my model. As I understand it the method names and the method signature decides which methods gets called in my scopeprovider.

Depending on HOW I open my language editor different methods gets called.

With "on a higher level" I mean another method is called in my scopeprovider that relates to a higher level in my model hierarchy and the best matching scoping rule is never called.

Regards Ib Nielsen
Re: Scope Provider is not deterministic. [message #675123 is a reply to message #675044] Mon, 30 May 2011 11:03 Go to previous message
Sebastian Zarnekow is currently offline Sebastian ZarnekowFriend
Messages: 3118
Registered: July 2009
Senior Member
Hi Ib,

please file a ticket with a reproducable example attached.

Many thanks,
Sebastian
--
Need professional support for Eclipse Modeling?
Go visit: http://xtext.itemis.com

Am 30.05.11 08:40, schrieb Ib Nielsen:
> Hi Sebastian
>
> I have a scopeprovider attached to my model. As I understand it the
> method names and the method signature decides which methods gets called
> in my scopeprovider.
>
> Depending on HOW I open my language editor different methods gets called.
> With "on a higher level" I mean another method is called in my
> scopeprovider that relates to a higher level in my model hierarchy and
> the best matching scoping rule is never called.
>
> Regards Ib Nielsen
Previous Topic:setting information in ScopeProvider and Validator from outsite
Next Topic:set up workspace for developing Xtext
Goto Forum:
  


Current Time: Thu Apr 25 19:43:48 GMT 2024

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

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

Back to the top