| modeltype Ecore uses ecore('http://www.eclipse.org/emf/2002/Ecore'); |
| |
| transformation bug414363(in srcModel:Ecore,out dest:Ecore); |
| |
| main(){} |
| |
| mapping EClass::foo2atombar () : atom:EClass, bar:EClass |
| when {self.name = "2"} |
| { |
| init {atom.name /*<warn>*/=/*</warn>*/ "2";} |
| |
| atom.name /*<warn>*/=/*</warn>*/ "2"; |
| object atom:EClass {name /*<warn>*/=/*</warn>*/ "1"}; |
| object bar: {name /*<warn>*/=/*</warn>*/ "2"}; |
| object EPackage {name /*<warn>*/=/*</warn>*/ "2"}; |
| Sequence{1,2}->object(x) EClass {name /*<warn>*/=/*</warn>*/ "nn";}; |
| Sequence{1,2}->xcollect(x | object EClass {name /*<warn>*/=/*</warn>*/ "nn";}); |
| |
| var index := 0; |
| var b = false; |
| |
| index /*<warn>*/=/*</warn>*/ 0; |
| assert fatal (index = 0); |
| log((index = 0).repr()); |
| |
| var t0 := index = 0; |
| var t1 := /*<warn>*/Tuple(name:EString) = Tuple{name = "1"}/*</warn>*/; |
| var t2 : Tuple(name:EString) = Tuple{name = "1"}; |
| |
| while(false) { |
| index /*<warn>*/=/*</warn>*/ 0; |
| }; |
| |
| if (index = 0) then { |
| index /*<warn>*/=/*</warn>*/ 0; |
| } |
| else { |
| index /*<warn>*/=/*</warn>*/ 0; |
| } |
| endif; |
| |
| if index = 0 then index /*<warn>*/=/*</warn>*/ 0 |
| else index /*<warn>*/=/*</warn>*/ 0 |
| endif; |
| |
| var ifv = if index = 0 then index = 0 |
| else index = 0 |
| endif; |
| |
| |
| |
| Sequence{}->forEach(i) { |
| index /*<warn>*/=/*</warn>*/ 0; |
| }; |
| |
| compute (x : String := "") { |
| index /*<warn>*/=/*</warn>*/ 0; |
| index /*<warn>*/=/*</warn>*/ 0; |
| }; |
| var cm = compute (x : String := "") { |
| index /*<warn>*/=/*</warn>*/ 0; |
| index /*<warn>*/=/*</warn>*/ 0; |
| }; |
| |
| switch { |
| case (0 > 2) { |
| index /*<warn>*/=/*</warn>*/ 0; |
| index /*<warn>*/=/*</warn>*/ 0; |
| }; |
| }; |
| var sw = switch { |
| case (0 > 2) { |
| index /*<warn>*/=/*</warn>*/ 0; |
| index /*<warn>*/=/*</warn>*/ 0; |
| }; |
| }; |
| |
| var swv = switch { |
| case(index = 0) index = 0; |
| }; |
| |
| switch { |
| case(index = 0) index /*<warn>*/=/*</warn>*/ 0; |
| }; |
| |
| } |
| |
| mapping EClass::foo2atombar2 () : atom:EClass, bar:EClass { |
| population {atom.name /*<warn>*/=/*</warn>*/ "2";} |
| end {atom.name /*<warn>*/=/*</warn>*/ "2";} |
| } |
| |
| constructor EClass::EClass () { |
| name /*<warn>*/=/*</warn>*/ "2"; |
| } |
| |
| /*<warn>*/query equal(i : Integer, j : Integer) : Boolean/*</warn>*/ { |
| i = j |
| } |