| Index: lib/runtime/dart/_js_helper.js
|
| diff --git a/lib/runtime/dart/_js_helper.js b/lib/runtime/dart/_js_helper.js
|
| index b7ad13de7ebf87fefd6323b736869bf12fea15b5..c99ffb0e3ae61bd6e060a2e5bf4c489ecfa327b4 100644
|
| --- a/lib/runtime/dart/_js_helper.js
|
| +++ b/lib/runtime/dart/_js_helper.js
|
| @@ -102,7 +102,7 @@ var _js_helper;
|
| return new (_ConstantMapKeyIterable$(K))(this);
|
| }
|
| get values() {
|
| - return new (_internal.MappedIterable$(K, V))(this[_keys], dart.closureWrap(((key) => this[_fetch](key)).bind(this), "(K) → V"));
|
| + return new (_internal.MappedIterable$(K, V))(this[_keys], dart.as(((key) => this[_fetch](key)).bind(this), dart.throw_("Unimplemented type (K) → V")));
|
| }
|
| }
|
| ConstantStringMap[dart.implements] = () => [_internal.EfficientLength];
|
| @@ -1733,7 +1733,7 @@ var _js_helper;
|
| }
|
| static parseInt(source, radix, handleError) {
|
| if (handleError == null)
|
| - handleError = dart.closureWrap(Primitives[_throwFormatException], "(String) → int");
|
| + handleError = dart.as(Primitives[_throwFormatException], dart.throw_("Unimplemented type (String) → int"));
|
| checkString(source);
|
| let match = /^\s*[+-]?((0x[a-f0-9]+)|(\d+)|([a-z0-9]+))\s*$/i.exec(source);
|
| let digitsIndex = 1;
|
| @@ -1785,7 +1785,7 @@ var _js_helper;
|
| static parseDouble(source, handleError) {
|
| checkString(source);
|
| if (handleError == null)
|
| - handleError = dart.closureWrap(Primitives[_throwFormatException], "(String) → double");
|
| + handleError = dart.as(Primitives[_throwFormatException], dart.throw_("Unimplemented type (String) → double"));
|
| if (!/^\s*[+-]?(?:Infinity|NaN|(?:\.\d+|\d+(?:\.\d*)?)(?:[eE][+-]?\d+)?)\s*$/.test(source)) {
|
| return handleError(source);
|
| }
|
| @@ -3670,11 +3670,11 @@ var _js_helper;
|
| let hashes = dart.as(hashesMap[loadId], core.List$(core.String));
|
| if (uris == null)
|
| return dart.as(new async.Future.value(null), async.Future$(core.Null));
|
| - let indices = new core.List.generate(uris.length, dart.closureWrap((i) => i, "(int) → dynamic"));
|
| + let indices = new core.List.generate(uris.length, dart.as((i) => i, dart.throw_("Unimplemented type (int) → dynamic")));
|
| let isHunkLoaded = _foreign_helper.JS_EMBEDDED_GLOBAL('', _js_embedded_names.IS_HUNK_LOADED);
|
| let isHunkInitialized = _foreign_helper.JS_EMBEDDED_GLOBAL('', _js_embedded_names.IS_HUNK_INITIALIZED);
|
| let indicesToLoad = indices.where((i) => !isHunkLoaded(hashes.get(i))).toList();
|
| - return dart.as(async.Future.wait(dart.as(indicesToLoad.map((i) => _loadHunk(uris.get(i))), core.Iterable$(async.Future))).then(dart.closureWrap((_) => {
|
| + return dart.as(async.Future.wait(dart.as(indicesToLoad.map((i) => _loadHunk(uris.get(i))), core.Iterable$(async.Future))).then(dart.as((_) => {
|
| let indicesToInitialize = indices.where((i) => !isHunkInitialized(hashes.get(i))).toList();
|
| for (let i of indicesToInitialize) {
|
| let initializer = _foreign_helper.JS_EMBEDDED_GLOBAL('', _js_embedded_names.INITIALIZE_LOADED_HUNK);
|
| @@ -3684,13 +3684,13 @@ var _js_helper;
|
| if (dart.notNull(updated) && dart.notNull(exports.deferredLoadHook != null)) {
|
| exports.deferredLoadHook();
|
| }
|
| - }, "(List<dynamic>) → dynamic")), async.Future$(core.Null));
|
| + }, dart.throw_("Unimplemented type (List<dynamic>) → dynamic"))), async.Future$(core.Null));
|
| }
|
| // Function _loadHunk: (String) → Future<Null>
|
| function _loadHunk(hunkName) {
|
| let future = exports._loadingLibraries.get(hunkName);
|
| if (future != null) {
|
| - return dart.as(future.then(dart.closureWrap((_) => null, "(Null) → dynamic")), async.Future$(core.Null));
|
| + return dart.as(future.then(dart.as((_) => null, dart.throw_("Unimplemented type (Null) → dynamic"))), async.Future$(core.Null));
|
| }
|
| let uri = _isolate_helper.IsolateNatives.thisScript;
|
| let index = uri.lastIndexOf('/');
|
|
|