Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Archived » M2M (model-to-model transformation) » [ATL] result of undefined subSequence call
[ATL] result of undefined subSequence call [message #485701] Mon, 14 September 2009 14:32 Go to next message
Eclipse UserFriend
Originally posted by: loic.fejoz.realtimeatwork.com

Hi,

I got the following error:
Operation not found: [].notEmpty()

After investigation it is due to the call of notEmpty over the result of
subSequence(2, sizeOfSequence) with sizeOfSequence being strictly less
than 2.

My question is: what is the kind of this object []?
I would have expected the result to be either oclUndefined or the empty
sequence Sequence{}! Before calling notEmpty I checked for oclUndefiness
so it must be something.

Moreover looking at the code of ASMSequence, it seems that the result is
an ASMSequence anyway. So where is the bug?

< http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.m2m/org .eclipse.m2m.atl/plugins/org.eclipse.m2m.atl.engine.vm/src/o rg/eclipse/m2m/atl/engine/vm/nativelib/ASMSequence.java?revi sion=1.5&root=Modeling_Project&view=markup>

--
regards,
Loïc Fejoz
Re: [ATL] result of undefined subSequence call on EMF virtual machine [message #485703 is a reply to message #485701] Mon, 14 September 2009 14:44 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: loic.fejoz.realtimeatwork.com

Oh by the way, I am using the EMF virtual machine!
Running with the regular machine does not throw an error but seem to
still result with error...

PS: the code was maybe not the one to look at...

--
regards,
Loïc Fejoz

Loïc Fejoz a écrit :
> Hi,
>
> I got the following error:
> Operation not found: [].notEmpty()
>
> After investigation it is due to the call of notEmpty over the result of
> subSequence(2, sizeOfSequence) with sizeOfSequence being strictly less
> than 2.
>
> My question is: what is the kind of this object []?
> I would have expected the result to be either oclUndefined or the empty
> sequence Sequence{}! Before calling notEmpty I checked for oclUndefiness
> so it must be something.
>
> Moreover looking at the code of ASMSequence, it seems that the result is
> an ASMSequence anyway. So where is the bug?
>
> < http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.m2m/org .eclipse.m2m.atl/plugins/org.eclipse.m2m.atl.engine.vm/src/o rg/eclipse/m2m/atl/engine/vm/nativelib/ASMSequence.java?revi sion=1.5&root=Modeling_Project&view=markup>
>
>
Re: [ATL] result of undefined subSequence call on EMF virtual machine [message #485712 is a reply to message #485703] Mon, 14 September 2009 15:20 Go to previous messageGo to next message
William Piers is currently offline William PiersFriend
Messages: 301
Registered: July 2009
Senior Member
This is a multi-part message in MIME format.
--------------050006010100090500040306
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 8bit

Hello,

There seems to be a miss in the return type of subSequence(start, end)
when end < start. Could you report a bug about that ?
(https://bugs.eclipse.org/bugs/enter_bug.cgi?product=M2M)

Thanks in advance,

William

Lo
Re: [ATL] result of undefined subSequence call on EMF virtual machine [message #485799 is a reply to message #485712] Tue, 15 September 2009 06:40 Go to previous message
Eclipse UserFriend
Originally posted by: loic.fejoz.realtimeatwork.com

Hi,

I opened bug #289416.

I look at the UML 2.0 OCL Specification (in the semantic part), it
should be oclUndefined. In MDT/OCL, they choose to return null (see bug
#244946 [2] and the discussion [3]).

Anyway both virtual machine are not consistent...

[1] <https://bugs.eclipse.org/bugs/show_bug.cgi?id=289416>
[2] <https://bugs.eclipse.org/bugs/show_bug.cgi?id=244946>
[3]
< http://dev.eclipse.org/newslists/news.eclipse.modeling.mdt.o cl/msg01451.html>

--
Regards,
Loïc

William Piers a écrit :
> Hello,
>
> There seems to be a miss in the return type of subSequence(start, end)
> when end < start. Could you report a bug about that ?
> (https://bugs.eclipse.org/bugs/enter_bug.cgi?product=M2M)
>
> Thanks in advance,
>
> William
>
> Loïc Fejoz a écrit :
>> Oh by the way, I am using the EMF virtual machine!
>> Running with the regular machine does not throw an error but seem to
>> still result with error...
>>
>> PS: the code was maybe not the one to look at...
>>
>
Previous Topic:Using a matched rule from a lazy rule
Next Topic:[QVTO] Help on "SimpleUML to RDB" example
Goto Forum:
  


Current Time: Thu Apr 25 01:26:28 GMT 2024

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

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

Back to the top