Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » ATL » EMFTVM - Resolving source elements in refining mode
EMFTVM - Resolving source elements in refining mode [message #1066443] Tue, 02 July 2013 12:54 Go to next message
Michal Kleczek is currently offline Michal Kleczek
Messages: 22
Registered: May 2013
Junior Member
Hi,
I have a simple transformation that for each package creates a subpackage:
rule Package {
  from
    source : D!Package
  to
    target : D!Package
    (
    ),
    subPackage : D!Package
    (
-- this is a containment relationship
      package <- target,
      name <- 'sub'
    )
}

Running it with EMFTVM gives:
org.eclipse.m2m.atl.emftvm.util.VMException: java.lang.IllegalArgumentException: Recursive containment not allowed for xxx.xxx.PackageImpl@21592707 (name: null)

Looks like "target" is resolved to "subPackage".
Not sure if it is a bug and if there is any workaround.

Thanks,
Michal
Re: EMFTVM - Resolving source elements in refining mode [message #1066479 is a reply to message #1066443] Tue, 02 July 2013 15:34 Go to previous messageGo to next message
Dennis Wagelaar is currently offline Dennis Wagelaar
Messages: 150
Registered: September 2012
Senior Member

Op 02-07-13 18:54, Michal Kleczek schreef:
> Looks like "target" is resolved to "subPackage".

You can test if it is caused by resolve() by using '<:=' instead of '<-'. The
'<:=' operator skips the source-target trace resolving step.

Cheers,
Dennis


Cheers,
Dennis
Re: EMFTVM - Resolving source elements in refining mode [message #1066710 is a reply to message #1066479] Wed, 03 July 2013 18:21 Go to previous messageGo to next message
Michal Kleczek is currently offline Michal Kleczek
Messages: 22
Registered: May 2013
Junior Member
Dennis Wagelaar wrote on Tue, 02 July 2013 15:34
Op 02-07-13 18:54, Michal You can test if it is caused by resolve() by using '<:=' instead of '<-'. The
'<:=' operator skips the source-target trace resolving step.


Thanks - works great!
I wasn't aware of '<:=' operator - after you mentioned it I searched the docs and the only place it is present is a "fun point" in EMFTVM page Smile
Re: EMFTVM - Resolving source elements in refining mode [message #1069878 is a reply to message #1066710] Tue, 16 July 2013 15:38 Go to previous message
Dennis Wagelaar is currently offline Dennis Wagelaar
Messages: 150
Registered: September 2012
Senior Member

I've done some testing with this issue, and found that it is really a bug:

https://bugs.eclipse.org/bugs/show_bug.cgi?id=413110

The EMFTVM tracing mechanism needs to be adapted to deal with "mapsToSelf"
trace link source elements when running in refining mode.

Cheers,
Dennis


Cheers,
Dennis
Previous Topic:if else statment in a rule transformation
Next Topic:Incremental ATL
Goto Forum:
  


Current Time: Mon Jul 28 12:44:11 EDT 2014

Powered by FUDForum. Page generated in 0.02979 seconds