Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » OCL » bag->asSet() operation bug
bag->asSet() operation bug [message #1213547] Wed, 27 November 2013 04:31 Go to next message
ModelGeek Mising name is currently offline ModelGeek Mising name
Messages: 501
Registered: June 2011
Senior Member
Bag->asSet() operation does not return the set with unique elements

let x : Bag(Integer) = Bag{3,3,4,4,5} in x->asSet()
if i execute the above query in "interactive xtext OCL" console i get "3,3,4,4,5" but if i execute it in "interactive OCL" then i get the correct result.

It seems a bug in pivot/xtext imlpementation.

Please check the image.
index.php/fa/16853/0/
  • Attachment: bag.jpg
    (Size: 28.47KB, Downloaded 115 times)
Re: bag->asSet() operation bug [message #1213619 is a reply to message #1213547] Wed, 27 November 2013 05:10 Go to previous messageGo to next message
Ed Willink is currently offline Ed Willink
Messages: 4036
Registered: July 2009
Senior Member
Hi

Indeed. Fixed by commit 551890f69da19012696b2dae780646c6c7e5430b on
2013-10-27 13:36:44

so if you use the Luna M3 install you should be good.

Regards

Ed Willink


On 27/11/2013 09:31, ModelGeek Mising name wrote:
> Bag->asSet() operation does not return the set with unique elements
>
> let x : Bag(Integer) = Bag{3,3,4,4,5} in x->asSet()
> if i execute the above query in "interactive xtext OCL" console i get "3,3,4,4,5" but if i execute it in "interactive OCL" then i get the correct result.
>
> It seems a bug in pivot/xtext imlpementation.
>
> Please check the image.
>
Re: bag->asSet() operation bug [message #1213784 is a reply to message #1213619] Wed, 27 November 2013 06:47 Go to previous messageGo to next message
ModelGeek Mising name is currently offline ModelGeek Mising name
Messages: 501
Registered: June 2011
Senior Member
Hi,

I have cloned the git://git.eclipse.org/gitroot/mdt/org.eclipse.ocl.git with master branch. Is this the latest and stabil code containing fixes?

Cheers,
Re: bag->asSet() operation bug [message #1213806 is a reply to message #1213784] Wed, 27 November 2013 06:56 Go to previous messageGo to next message
Ed Willink is currently offline Ed Willink
Messages: 4036
Registered: July 2009
Senior Member
Hi

No. http://projects.eclipse.org/projects/modeling.mdt.ocl | Engage shows

git://git.eclipse.org/gitroot/ocl/org.eclipse.ocl.git

Last commit on master is: commit
433579efbf90daf252e742775b2074c5116a93f1 on 2013-11-27 07:15:54

Your ref predates the availability of Gerrit contributions. Can you let
me knwo where tyou found the stale reference so that I can fix it.
(I can see lots of stale references in
http://wiki.eclipse.org/OCL/Dev/Setup so no need to tell me about those.)

Regards

Ed



On 27/11/2013 11:47, ModelGeek Mising name wrote:
> Hi,
>
> I have cloned the
> git://git.eclipse.org/gitroot/mdt/org.eclipse.ocl.git with master
> branch. Is this the latest and stabil code containing fixes?
>
> Cheers,
Re: bag->asSet() operation bug [message #1220390 is a reply to message #1213806] Wed, 11 December 2013 08:00 Go to previous messageGo to next message
ModelGeek Mising name is currently offline ModelGeek Mising name
Messages: 501
Registered: June 2011
Senior Member
Hi,

I have cloned the repository from git://git.eclipse.org/gitroot/ocl/org.eclipse.ocl.git (Master). It gives me many build errors.

what is problem in my case?

index.php/fa/16990/0/
Re: bag->asSet() operation bug [message #1220395 is a reply to message #1220390] Wed, 11 December 2013 08:35 Go to previous messageGo to next message
ModelGeek Mising name is currently offline ModelGeek Mising name
Messages: 501
Registered: June 2011
Senior Member
I have downloaded the latest version of Eclipse with modeling tools and i am getting the folloing error message when i build the workspace having ocl git repository clone.

Errors occurred during the build.
Errors running builder 'Java Builder' on project 'org.eclipse.ocl.examples.xtext.base.ui'.
java.lang.NullPointerException
Errors running builder 'Java Builder' on project 'org.eclipse.ocl.examples.xtext.essentialocl'.
java.lang.NullPointerException
Errors running builder 'Java Builder' on project 'org.eclipse.ocl.examples.xtext.markup'.
java.lang.NullPointerException

index.php/fa/16991/0/
Re: bag->asSet() operation bug [message #1220398 is a reply to message #1220395] Wed, 11 December 2013 08:56 Go to previous messageGo to next message
ModelGeek Mising name is currently offline ModelGeek Mising name
Messages: 501
Registered: June 2011
Senior Member
I have solved most of the errors.
I am having an error at class declaration of org.eclipse.ocl.examples.editor.ocl.ui.OCLCreationFactory

Multiple markers at this line
- The return types are incompatible for the inherited methods
ICreationFactory.createNodeLocator(ICSTRootEnvironment<?,?,?,?,?,?,?,?,?,?,?,?>),
AbstractCreationFactory.createNodeLocator(ICSTRootEnvironment<?,?,?,?,?,?,?,?,?,?,?,?>)
- The return types are incompatible for the inherited methods ICreationFactory.getLanguage(),
AbstractCreationFactory.getLanguage()
- The type OCLCreationFactory must implement the inherited abstract method
ICreationFactory.createNodeLocator(ICSTRootEnvironment)
- The type OCLCreationFactory must implement the inherited abstract method
ICreationFactory.createSourcePositionLocator(ICSTRootEnvironment)
- The type OCLCreationFactory must implement the inherited abstract method ICreationFactory.getAdapter(Class)


any idea?

[Updated on: Wed, 11 December 2013 09:14]

Report message to a moderator

Re: bag-&amp;amp;gt;asSet() operation bug [message #1220401 is a reply to message #1220398] Wed, 11 December 2013 09:14 Go to previous messageGo to next message
Ed Willink is currently offline Ed Willink
Messages: 4036
Registered: July 2009
Senior Member
Hi

I updated
http://wiki.eclipse.org/OCL/Dev/Setup#Getting_the_Sources_from_GIT a few
days ago.

http://eclipse.org/modeling/mdt/ocl/resources/ocl.psf should get what
you need and avoid pulling in obsolete plugins from archive that have
correspondingly obsolete dependencies.

Regards

Ed Willink


On 11/12/2013 13:56, ModelGeek Mising name wrote:
> I have solved most of the errors.
> I am having an error in import statement of
> org.eclipse.imp.runtime.PluginBase
>
> can you guide how to get org.eclipse.imp plugin?
>
>
Re: bag-&amp;amp;gt;asSet() operation bug [message #1220491 is a reply to message #1220401] Thu, 12 December 2013 02:46 Go to previous message
Ed Willink is currently offline Ed Willink
Messages: 4036
Registered: July 2009
Senior Member
Hi

Apologies. I didn't do a very good job of updating. The "Engage" tab of
http://projects.eclipse.org/projects/modeling.mdt.ocl now displays a
variety of team project set files, of which

http://git.eclipse.org/c/ocl/org.eclipse.ocl.git/plain/releng/org.eclipse.ocl.releng/psfs/ocl-all.psf?h=master

is the correct one to install everything that is needed. (It is now in
the main OCL GIT rather than the anciliary MDT pages.)

Regards

Ed Willink


On 11/12/2013 14:14, Ed Willink wrote:
> Hi
>
> I updated
> http://wiki.eclipse.org/OCL/Dev/Setup#Getting_the_Sources_from_GIT a
> few days ago.
>
> http://eclipse.org/modeling/mdt/ocl/resources/ocl.psf should get what
> you need and avoid pulling in obsolete plugins from archive that have
> correspondingly obsolete dependencies.
>
> Regards
>
> Ed Willink
>
>
> On 11/12/2013 13:56, ModelGeek Mising name wrote:
>> I have solved most of the errors.
>> I am having an error in import statement of
>> org.eclipse.imp.runtime.PluginBase
>>
>> can you guide how to get org.eclipse.imp plugin?
>>
>>
>
Previous Topic:Installing Dresden OCL plugin in Juno
Next Topic:Ternary Association
Goto Forum:
  


Current Time: Tue Sep 02 08:00:58 EDT 2014

Powered by FUDForum. Page generated in 0.02655 seconds