OLD | NEW |
1 library; | 1 library; |
2 import self as self; | 2 import self as self; |
3 import "dart:core" as core; | 3 import "dart:core" as core; |
4 | 4 |
5 typedef fn = (dynamic) → dynamic; | 5 typedef fn = (dynamic) → dynamic; |
6 typedef fn2 = (dynamic, dynamic) → dynamic; | 6 typedef fn2 = (dynamic, dynamic) → dynamic; |
7 class X extends core::Object { | 7 class X extends core::Object { |
8 default constructor •() → void | 8 default constructor •() → void |
9 : super core::Object::•() | 9 : super core::Object::•() |
10 ; | 10 ; |
11 } | 11 } |
12 static method startIsolateMock(dynamic parentPort, dynamic entryPoint, dynamic a
rgs, dynamic message, dynamic isSpawnUri, dynamic controlPort, core::List<dynami
c> capabilities) → void { | 12 static method startIsolateMock(dynamic parentPort, dynamic entryPoint, dynamic a
rgs, dynamic message, dynamic isSpawnUri, dynamic controlPort, core::List<dynami
c> capabilities) → void { |
13 final Vector #context = MakeVector(7); | 13 final dynamic #context = MakeVector(7); |
14 #context[2] = entryPoint; | 14 #context[2] = entryPoint; |
15 #context[3] = args; | 15 #context[3] = args; |
16 #context[4] = message; | 16 #context[4] = message; |
17 #context[5] = isSpawnUri; | 17 #context[5] = isSpawnUri; |
18 if(!controlPort.==(null)) { | 18 if(!controlPort.==(null)) { |
19 controlPort.handler = MakeClosure<(dynamic) → dynamic>(self::closure#startIs
olateMock#function, #context); | 19 controlPort.handler = MakeClosure<(dynamic) → dynamic>(self::closure#startIs
olateMock#function, #context); |
20 } | 20 } |
21 if(!parentPort.==(null)) { | 21 if(!parentPort.==(null)) { |
22 dynamic readyMessage = core::List::_internal<dynamic>(2); | 22 dynamic readyMessage = core::List::_internal<dynamic>(2); |
23 readyMessage.[]=(0, controlPort.sendPort); | 23 readyMessage.[]=(0, controlPort.sendPort); |
24 readyMessage.[]=(1, capabilities); | 24 readyMessage.[]=(1, capabilities); |
25 capabilities = null; | 25 capabilities = null; |
26 parentPort.send(readyMessage); | 26 parentPort.send(readyMessage); |
27 } | 27 } |
28 assert(capabilities.==(null)); | 28 assert(capabilities.==(null)); |
29 #context[6] = "abc"; | 29 #context[6] = "abc"; |
30 (#context[6]).handler = MakeClosure<(dynamic) → dynamic>(self::closure#startIs
olateMock#function#1, #context); | 30 (#context[6]).handler = MakeClosure<(dynamic) → dynamic>(self::closure#startIs
olateMock#function#1, #context); |
31 (#context[6]).sendPort.send(null); | 31 (#context[6]).sendPort.send(null); |
32 } | 32 } |
33 static method main() → dynamic {} | 33 static method main() → dynamic {} |
34 static method closure#startIsolateMock#function(Vector #contextParameter, dynami
c _) → dynamic {} | 34 static method closure#startIsolateMock#function(dynamic #contextParameter, dynam
ic _) → dynamic {} |
35 static method closure#startIsolateMock#function#1(Vector #contextParameter, dyna
mic _) → dynamic { | 35 static method closure#startIsolateMock#function#1(dynamic #contextParameter, dyn
amic _) → dynamic { |
36 (#contextParameter[6]).close(); | 36 (#contextParameter[6]).close(); |
37 if(#contextParameter[5]) { | 37 if(#contextParameter[5]) { |
38 if((#contextParameter[2]) is (dynamic, dynamic) → dynamic) { | 38 if((#contextParameter[2]) is (dynamic, dynamic) → dynamic) { |
39 (#contextParameter[2]).call(#contextParameter[3], #contextParameter[4]); | 39 (#contextParameter[2]).call(#contextParameter[3], #contextParameter[4]); |
40 } | 40 } |
41 else | 41 else |
42 if((#contextParameter[2]) is (dynamic) → dynamic) { | 42 if((#contextParameter[2]) is (dynamic) → dynamic) { |
43 (#contextParameter[2]).call(#contextParameter[3]); | 43 (#contextParameter[2]).call(#contextParameter[3]); |
44 } | 44 } |
45 else { | 45 else { |
46 (#contextParameter[2]).call(); | 46 (#contextParameter[2]).call(); |
47 } | 47 } |
48 } | 48 } |
49 else { | 49 else { |
50 (#contextParameter[2]).call(#contextParameter[4]); | 50 (#contextParameter[2]).call(#contextParameter[4]); |
51 } | 51 } |
52 } | 52 } |
OLD | NEW |