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 class A extends core::Object { | 5 class A extends core::Object { |
6 field dynamic field = null; | 6 field dynamic field = null; |
7 constructor •() → void | 7 constructor •() → void |
8 : super core::Object::•() | 8 : super core::Object::•() |
9 ; | 9 ; |
10 } | 10 } |
(...skipping 17 matching lines...) Expand all Loading... |
28 ; | 28 ; |
29 } | 29 } |
30 static method useAsA(self::A object) → void { | 30 static method useAsA(self::A object) → void { |
31 dynamic _ = object.field; | 31 dynamic _ = object.field; |
32 } | 32 } |
33 static method useAsB(self::B object) → void { | 33 static method useAsB(self::B object) → void { |
34 dynamic _ = object.field; | 34 dynamic _ = object.field; |
35 self::escape(object); | 35 self::escape(object); |
36 } | 36 } |
37 static method escape(dynamic x) → void { | 37 static method escape(dynamic x) → void { |
38 x.==(null) ? x = "" : null; | 38 x.==(null) ?{dynamic} x = "" : null; |
39 x.==(null) ? x = 45 : null; | 39 x.==(null) ?{dynamic} x = 45 : null; |
40 if(!(x is core::int) && !(x is core::String)) { | 40 if(!(x is core::int) && !(x is core::String)) { |
41 x.field = 45; | 41 x.field = 45; |
42 } | 42 } |
43 } | 43 } |
44 static method main() → dynamic { | 44 static method main() → dynamic { |
45 dynamic object = new self::X::•(); | 45 dynamic object = new self::X::•(); |
46 self::useAsA(new self::A::•()); | 46 self::useAsA(new self::A::•()); |
47 self::useAsA(object); | 47 self::useAsA(object); |
48 self::useAsB(new self::B::•()); | 48 self::useAsB(new self::B::•()); |
49 self::useAsB(object); | 49 self::useAsB(object); |
50 } | 50 } |
OLD | NEW |