| OLD | NEW |
| 1 // Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 // TODO(jmesserly, sigmund): remove these two lines: | 5 // TODO(jmesserly, sigmund): remove these two lines: |
| 6 var math = Math; | 6 var math = Math; |
| 7 var core = core || {int: { parse: Number }, print: e => console.log(e) }; | 7 var core = core || {int: { parse: Number }, print: e => console.log(e) }; |
| 8 | 8 |
| 9 var dart; | 9 var dart; |
| 10 (function (dart) { | 10 (function (dart) { |
| (...skipping 93 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 104 return obj; | 104 return obj; |
| 105 } | 105 } |
| 106 dart.as = as_; | 106 dart.as = as_; |
| 107 | 107 |
| 108 function is(obj, type) { | 108 function is(obj, type) { |
| 109 // TODO(vsm): Implement. | 109 // TODO(vsm): Implement. |
| 110 throw new core.UnimplementedError(); | 110 throw new core.UnimplementedError(); |
| 111 } | 111 } |
| 112 dart.is = is; | 112 dart.is = is; |
| 113 | 113 |
| 114 function closureWrap(obj, type) { |
| 115 // TODO(vsm): Remove this once we handle in the checker. |
| 116 return obj; |
| 117 } |
| 118 |
| 114 function isGroundType(type) { | 119 function isGroundType(type) { |
| 115 // TODO(vsm): Implement. | 120 // TODO(vsm): Implement. |
| 116 throw new core.UnimplementedError(); | 121 throw new core.UnimplementedError(); |
| 117 } | 122 } |
| 118 dart.isGroundType = isGroundType; | 123 dart.isGroundType = isGroundType; |
| 119 | 124 |
| 120 function arity(f) { | 125 function arity(f) { |
| 121 // TODO(vsm): Implement. | 126 // TODO(vsm): Implement. |
| 122 throw new core.UnimplementedError(); | 127 throw new core.UnimplementedError(); |
| 123 } | 128 } |
| (...skipping 228 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 352 var init = this[name]; | 357 var init = this[name]; |
| 353 var result = void 0; | 358 var result = void 0; |
| 354 if (init) result = init.apply(this, arguments); | 359 if (init) result = init.apply(this, arguments); |
| 355 return result === void 0 ? this : result; | 360 return result === void 0 ? this : result; |
| 356 }; | 361 }; |
| 357 // The initializer for Object | 362 // The initializer for Object |
| 358 core.Object.prototype.Object = function() {}; | 363 core.Object.prototype.Object = function() {}; |
| 359 core.Object.prototype.constructor = core.Object; | 364 core.Object.prototype.constructor = core.Object; |
| 360 | 365 |
| 361 })(dart || (dart = {})); | 366 })(dart || (dart = {})); |
| OLD | NEW |