diff --git a/dist/index.mjs b/dist/index.mjs index a4c01a5..366de30 100644 --- a/dist/index.mjs +++ b/dist/index.mjs @@ -7,7 +7,11 @@ import { createRequire as __WEBPACK_EXTERNAL_createRequire } from "module"; var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) { if (k2 === undefined) k2 = k; - Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } }); + var desc = Object.getOwnPropertyDescriptor(m, k); + if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) { + desc = { enumerable: true, get: function() { return m[k]; } }; + } + Object.defineProperty(o, k2, desc); }) : (function(o, m, k, k2) { if (k2 === undefined) k2 = k; o[k2] = m[k]; @@ -20,7 +24,7 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? ( var __importStar = (this && this.__importStar) || function (mod) { if (mod && mod.__esModule) return mod; var result = {}; - if (mod != null) for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); + if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); __setModuleDefault(result, mod); return result; }; @@ -82,13 +86,13 @@ class Command { } } function escapeData(s) { - return utils_1.toCommandValue(s) + return (0, utils_1.toCommandValue)(s) .replace(/%/g, '%25') .replace(/\r/g, '%0D') .replace(/\n/g, '%0A'); } function escapeProperty(s) { - return utils_1.toCommandValue(s) + return (0, utils_1.toCommandValue)(s) .replace(/%/g, '%25') .replace(/\r/g, '%0D') .replace(/\n/g, '%0A') @@ -105,7 +109,11 @@ function escapeProperty(s) { var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) { if (k2 === undefined) k2 = k; - Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } }); + var desc = Object.getOwnPropertyDescriptor(m, k); + if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) { + desc = { enumerable: true, get: function() { return m[k]; } }; + } + Object.defineProperty(o, k2, desc); }) : (function(o, m, k, k2) { if (k2 === undefined) k2 = k; o[k2] = m[k]; @@ -118,7 +126,7 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? ( var __importStar = (this && this.__importStar) || function (mod) { if (mod && mod.__esModule) return mod; var result = {}; - if (mod != null) for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); + if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); __setModuleDefault(result, mod); return result; }; @@ -132,7 +140,7 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge }); }; Object.defineProperty(exports, "__esModule", ({ value: true })); -exports.getIDToken = exports.getState = exports.saveState = exports.group = exports.endGroup = exports.startGroup = exports.info = exports.notice = exports.warning = exports.error = exports.debug = exports.isDebug = exports.setFailed = exports.setCommandEcho = exports.setOutput = exports.getBooleanInput = exports.getMultilineInput = exports.getInput = exports.addPath = exports.setSecret = exports.exportVariable = exports.ExitCode = void 0; +exports.platform = exports.toPlatformPath = exports.toWin32Path = exports.toPosixPath = exports.markdownSummary = exports.summary = exports.getIDToken = exports.getState = exports.saveState = exports.group = exports.endGroup = exports.startGroup = exports.info = exports.notice = exports.warning = exports.error = exports.debug = exports.isDebug = exports.setFailed = exports.setCommandEcho = exports.setOutput = exports.getBooleanInput = exports.getMultilineInput = exports.getInput = exports.addPath = exports.setSecret = exports.exportVariable = exports.ExitCode = void 0; const command_1 = __nccwpck_require__(5336); const file_command_1 = __nccwpck_require__(2717); const utils_1 = __nccwpck_require__(200); @@ -152,7 +160,7 @@ var ExitCode; * A code indicating that the action was a failure */ ExitCode[ExitCode["Failure"] = 1] = "Failure"; -})(ExitCode = exports.ExitCode || (exports.ExitCode = {})); +})(ExitCode || (exports.ExitCode = ExitCode = {})); //----------------------------------------------------------------------- // Variables //----------------------------------------------------------------------- @@ -163,13 +171,13 @@ var ExitCode; */ // eslint-disable-next-line @typescript-eslint/no-explicit-any function exportVariable(name, val) { - const convertedVal = utils_1.toCommandValue(val); + const convertedVal = (0, utils_1.toCommandValue)(val); process.env[name] = convertedVal; const filePath = process.env['GITHUB_ENV'] || ''; if (filePath) { - return file_command_1.issueFileCommand('ENV', file_command_1.prepareKeyValueMessage(name, val)); + return (0, file_command_1.issueFileCommand)('ENV', (0, file_command_1.prepareKeyValueMessage)(name, val)); } - command_1.issueCommand('set-env', { name }, convertedVal); + (0, command_1.issueCommand)('set-env', { name }, convertedVal); } exports.exportVariable = exportVariable; /** @@ -177,7 +185,7 @@ exports.exportVariable = exportVariable; * @param secret value of the secret */ function setSecret(secret) { - command_1.issueCommand('add-mask', {}, secret); + (0, command_1.issueCommand)('add-mask', {}, secret); } exports.setSecret = setSecret; /** @@ -187,10 +195,10 @@ exports.setSecret = setSecret; function addPath(inputPath) { const filePath = process.env['GITHUB_PATH'] || ''; if (filePath) { - file_command_1.issueFileCommand('PATH', inputPath); + (0, file_command_1.issueFileCommand)('PATH', inputPath); } else { - command_1.issueCommand('add-path', {}, inputPath); + (0, command_1.issueCommand)('add-path', {}, inputPath); } process.env['PATH'] = `${inputPath}${path.delimiter}${process.env['PATH']}`; } @@ -265,10 +273,10 @@ exports.getBooleanInput = getBooleanInput; function setOutput(name, value) { const filePath = process.env['GITHUB_OUTPUT'] || ''; if (filePath) { - return file_command_1.issueFileCommand('OUTPUT', file_command_1.prepareKeyValueMessage(name, value)); + return (0, file_command_1.issueFileCommand)('OUTPUT', (0, file_command_1.prepareKeyValueMessage)(name, value)); } process.stdout.write(os.EOL); - command_1.issueCommand('set-output', { name }, utils_1.toCommandValue(value)); + (0, command_1.issueCommand)('set-output', { name }, (0, utils_1.toCommandValue)(value)); } exports.setOutput = setOutput; /** @@ -277,7 +285,7 @@ exports.setOutput = setOutput; * */ function setCommandEcho(enabled) { - command_1.issue('echo', enabled ? 'on' : 'off'); + (0, command_1.issue)('echo', enabled ? 'on' : 'off'); } exports.setCommandEcho = setCommandEcho; //----------------------------------------------------------------------- @@ -308,7 +316,7 @@ exports.isDebug = isDebug; * @param message debug message */ function debug(message) { - command_1.issueCommand('debug', {}, message); + (0, command_1.issueCommand)('debug', {}, message); } exports.debug = debug; /** @@ -317,7 +325,7 @@ exports.debug = debug; * @param properties optional properties to add to the annotation. */ function error(message, properties = {}) { - command_1.issueCommand('error', utils_1.toCommandProperties(properties), message instanceof Error ? message.toString() : message); + (0, command_1.issueCommand)('error', (0, utils_1.toCommandProperties)(properties), message instanceof Error ? message.toString() : message); } exports.error = error; /** @@ -326,7 +334,7 @@ exports.error = error; * @param properties optional properties to add to the annotation. */ function warning(message, properties = {}) { - command_1.issueCommand('warning', utils_1.toCommandProperties(properties), message instanceof Error ? message.toString() : message); + (0, command_1.issueCommand)('warning', (0, utils_1.toCommandProperties)(properties), message instanceof Error ? message.toString() : message); } exports.warning = warning; /** @@ -335,7 +343,7 @@ exports.warning = warning; * @param properties optional properties to add to the annotation. */ function notice(message, properties = {}) { - command_1.issueCommand('notice', utils_1.toCommandProperties(properties), message instanceof Error ? message.toString() : message); + (0, command_1.issueCommand)('notice', (0, utils_1.toCommandProperties)(properties), message instanceof Error ? message.toString() : message); } exports.notice = notice; /** @@ -354,14 +362,14 @@ exports.info = info; * @param name The name of the output group */ function startGroup(name) { - command_1.issue('group', name); + (0, command_1.issue)('group', name); } exports.startGroup = startGroup; /** * End an output group. */ function endGroup() { - command_1.issue('endgroup'); + (0, command_1.issue)('endgroup'); } exports.endGroup = endGroup; /** @@ -399,9 +407,9 @@ exports.group = group; function saveState(name, value) { const filePath = process.env['GITHUB_STATE'] || ''; if (filePath) { - return file_command_1.issueFileCommand('STATE', file_command_1.prepareKeyValueMessage(name, value)); + return (0, file_command_1.issueFileCommand)('STATE', (0, file_command_1.prepareKeyValueMessage)(name, value)); } - command_1.issueCommand('save-state', { name }, utils_1.toCommandValue(value)); + (0, command_1.issueCommand)('save-state', { name }, (0, utils_1.toCommandValue)(value)); } exports.saveState = saveState; /** @@ -437,6 +445,10 @@ var path_utils_1 = __nccwpck_require__(5720); Object.defineProperty(exports, "toPosixPath", ({ enumerable: true, get: function () { return path_utils_1.toPosixPath; } })); Object.defineProperty(exports, "toWin32Path", ({ enumerable: true, get: function () { return path_utils_1.toWin32Path; } })); Object.defineProperty(exports, "toPlatformPath", ({ enumerable: true, get: function () { return path_utils_1.toPlatformPath; } })); +/** + * Platform utilities exports + */ +exports.platform = __importStar(__nccwpck_require__(9060)); //# sourceMappingURL=core.js.map /***/ }), @@ -448,7 +460,11 @@ Object.defineProperty(exports, "toPlatformPath", ({ enumerable: true, get: funct // For internal use, subject to change. var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) { if (k2 === undefined) k2 = k; - Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } }); + var desc = Object.getOwnPropertyDescriptor(m, k); + if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) { + desc = { enumerable: true, get: function() { return m[k]; } }; + } + Object.defineProperty(o, k2, desc); }) : (function(o, m, k, k2) { if (k2 === undefined) k2 = k; o[k2] = m[k]; @@ -461,7 +477,7 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? ( var __importStar = (this && this.__importStar) || function (mod) { if (mod && mod.__esModule) return mod; var result = {}; - if (mod != null) for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); + if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); __setModuleDefault(result, mod); return result; }; @@ -469,9 +485,9 @@ Object.defineProperty(exports, "__esModule", ({ value: true })); exports.prepareKeyValueMessage = exports.issueFileCommand = void 0; // We use any as a valid input type /* eslint-disable @typescript-eslint/no-explicit-any */ +const crypto = __importStar(__nccwpck_require__(6113)); const fs = __importStar(__nccwpck_require__(7147)); const os = __importStar(__nccwpck_require__(2037)); -const uuid_1 = __nccwpck_require__(7413); const utils_1 = __nccwpck_require__(200); function issueFileCommand(command, message) { const filePath = process.env[`GITHUB_${command}`]; @@ -481,14 +497,14 @@ function issueFileCommand(command, message) { if (!fs.existsSync(filePath)) { throw new Error(`Missing file at path: ${filePath}`); } - fs.appendFileSync(filePath, `${utils_1.toCommandValue(message)}${os.EOL}`, { + fs.appendFileSync(filePath, `${(0, utils_1.toCommandValue)(message)}${os.EOL}`, { encoding: 'utf8' }); } exports.issueFileCommand = issueFileCommand; function prepareKeyValueMessage(key, value) { - const delimiter = `ghadelimiter_${uuid_1.v4()}`; - const convertedValue = utils_1.toCommandValue(value); + const delimiter = `ghadelimiter_${crypto.randomUUID()}`; + const convertedValue = (0, utils_1.toCommandValue)(value); // These should realistically never happen, but just in case someone finds a // way to exploit uuid generation let's not allow keys or values that contain // the delimiter. @@ -572,9 +588,9 @@ class OidcClient { const encodedAudience = encodeURIComponent(audience); id_token_url = `${id_token_url}&audience=${encodedAudience}`; } - core_1.debug(`ID token url is ${id_token_url}`); + (0, core_1.debug)(`ID token url is ${id_token_url}`); const id_token = yield OidcClient.getCall(id_token_url); - core_1.setSecret(id_token); + (0, core_1.setSecret)(id_token); return id_token; } catch (error) { @@ -594,7 +610,11 @@ exports.OidcClient = OidcClient; var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) { if (k2 === undefined) k2 = k; - Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } }); + var desc = Object.getOwnPropertyDescriptor(m, k); + if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) { + desc = { enumerable: true, get: function() { return m[k]; } }; + } + Object.defineProperty(o, k2, desc); }) : (function(o, m, k, k2) { if (k2 === undefined) k2 = k; o[k2] = m[k]; @@ -607,7 +627,7 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? ( var __importStar = (this && this.__importStar) || function (mod) { if (mod && mod.__esModule) return mod; var result = {}; - if (mod != null) for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); + if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); __setModuleDefault(result, mod); return result; }; @@ -652,6 +672,106 @@ exports.toPlatformPath = toPlatformPath; /***/ }), +/***/ 9060: +/***/ (function(__unused_webpack_module, exports, __nccwpck_require__) { + + +var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) { + if (k2 === undefined) k2 = k; + var desc = Object.getOwnPropertyDescriptor(m, k); + if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) { + desc = { enumerable: true, get: function() { return m[k]; } }; + } + Object.defineProperty(o, k2, desc); +}) : (function(o, m, k, k2) { + if (k2 === undefined) k2 = k; + o[k2] = m[k]; +})); +var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) { + Object.defineProperty(o, "default", { enumerable: true, value: v }); +}) : function(o, v) { + o["default"] = v; +}); +var __importStar = (this && this.__importStar) || function (mod) { + if (mod && mod.__esModule) return mod; + var result = {}; + if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); + __setModuleDefault(result, mod); + return result; +}; +var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) { + function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); } + return new (P || (P = Promise))(function (resolve, reject) { + function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } } + function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } } + function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); } + step((generator = generator.apply(thisArg, _arguments || [])).next()); + }); +}; +var __importDefault = (this && this.__importDefault) || function (mod) { + return (mod && mod.__esModule) ? mod : { "default": mod }; +}; +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.getDetails = exports.isLinux = exports.isMacOS = exports.isWindows = exports.arch = exports.platform = void 0; +const os_1 = __importDefault(__nccwpck_require__(2037)); +const exec = __importStar(__nccwpck_require__(5571)); +const getWindowsInfo = () => __awaiter(void 0, void 0, void 0, function* () { + const { stdout: version } = yield exec.getExecOutput('powershell -command "(Get-CimInstance -ClassName Win32_OperatingSystem).Version"', undefined, { + silent: true + }); + const { stdout: name } = yield exec.getExecOutput('powershell -command "(Get-CimInstance -ClassName Win32_OperatingSystem).Caption"', undefined, { + silent: true + }); + return { + name: name.trim(), + version: version.trim() + }; +}); +const getMacOsInfo = () => __awaiter(void 0, void 0, void 0, function* () { + var _a, _b, _c, _d; + const { stdout } = yield exec.getExecOutput('sw_vers', undefined, { + silent: true + }); + const version = (_b = (_a = stdout.match(/ProductVersion:\s*(.+)/)) === null || _a === void 0 ? void 0 : _a[1]) !== null && _b !== void 0 ? _b : ''; + const name = (_d = (_c = stdout.match(/ProductName:\s*(.+)/)) === null || _c === void 0 ? void 0 : _c[1]) !== null && _d !== void 0 ? _d : ''; + return { + name, + version + }; +}); +const getLinuxInfo = () => __awaiter(void 0, void 0, void 0, function* () { + const { stdout } = yield exec.getExecOutput('lsb_release', ['-i', '-r', '-s'], { + silent: true + }); + const [name, version] = stdout.trim().split('\n'); + return { + name, + version + }; +}); +exports.platform = os_1.default.platform(); +exports.arch = os_1.default.arch(); +exports.isWindows = exports.platform === 'win32'; +exports.isMacOS = exports.platform === 'darwin'; +exports.isLinux = exports.platform === 'linux'; +function getDetails() { + return __awaiter(this, void 0, void 0, function* () { + return Object.assign(Object.assign({}, (yield (exports.isWindows + ? getWindowsInfo() + : exports.isMacOS + ? getMacOsInfo() + : getLinuxInfo()))), { platform: exports.platform, + arch: exports.arch, + isWindows: exports.isWindows, + isMacOS: exports.isMacOS, + isLinux: exports.isLinux }); + }); +} +exports.getDetails = getDetails; +//# sourceMappingURL=platform.js.map + +/***/ }), + /***/ 2864: /***/ (function(__unused_webpack_module, exports, __nccwpck_require__) { @@ -2373,7 +2493,7 @@ class HttpClient { } const usingSsl = parsedUrl.protocol === 'https:'; proxyAgent = new undici_1.ProxyAgent(Object.assign({ uri: proxyUrl.href, pipelining: !this._keepAlive ? 0 : 1 }, ((proxyUrl.username || proxyUrl.password) && { - token: `${proxyUrl.username}:${proxyUrl.password}` + token: `Basic ${Buffer.from(`${proxyUrl.username}:${proxyUrl.password}`).toString('base64')}` }))); this._proxyAgentDispatcher = proxyAgent; if (usingSsl && this._ignoreSslError) { @@ -2486,11 +2606,11 @@ function getProxyUrl(reqUrl) { })(); if (proxyVar) { try { - return new URL(proxyVar); + return new DecodedURL(proxyVar); } catch (_a) { if (!proxyVar.startsWith('http://') && !proxyVar.startsWith('https://')) - return new URL(`http://${proxyVar}`); + return new DecodedURL(`http://${proxyVar}`); } } else { @@ -2549,6 +2669,19 @@ function isLoopbackAddress(host) { hostLower.startsWith('[::1]') || hostLower.startsWith('[0:0:0:0:0:0:0:1]')); } +class DecodedURL extends URL { + constructor(url, base) { + super(url, base); + this._decodedUsername = decodeURIComponent(super.username); + this._decodedPassword = decodeURIComponent(super.password); + } + get username() { + return this._decodedUsername; + } + get password() { + return this._decodedPassword; + } +} //# sourceMappingURL=proxy.js.map /***/ }), @@ -3053,7 +3186,11 @@ function copyFile(srcFile, destFile, force) { var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) { if (k2 === undefined) k2 = k; - Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } }); + var desc = Object.getOwnPropertyDescriptor(m, k); + if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) { + desc = { enumerable: true, get: function() { return m[k]; } }; + } + Object.defineProperty(o, k2, desc); }) : (function(o, m, k, k2) { if (k2 === undefined) k2 = k; o[k2] = m[k]; @@ -3066,7 +3203,7 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? ( var __importStar = (this && this.__importStar) || function (mod) { if (mod && mod.__esModule) return mod; var result = {}; - if (mod != null) for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); + if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); __setModuleDefault(result, mod); return result; }; @@ -3096,11 +3233,11 @@ function _findMatch(versionSpec, stable, candidates, archFilter) { let file; for (const candidate of candidates) { const version = candidate.version; - core_1.debug(`check ${version} satisfies ${versionSpec}`); + (0, core_1.debug)(`check ${version} satisfies ${versionSpec}`); if (semver.satisfies(version, versionSpec) && (!stable || candidate.stable === stable)) { file = candidate.files.find(item => { - core_1.debug(`${item.arch}===${archFilter} && ${item.platform}===${platFilter}`); + (0, core_1.debug)(`${item.arch}===${archFilter} && ${item.platform}===${platFilter}`); let chk = item.arch === archFilter && item.platform === platFilter; if (chk && item.platform_version) { const osVersion = module.exports._getOsVersion(); @@ -3114,7 +3251,7 @@ function _findMatch(versionSpec, stable, candidates, archFilter) { return chk; }); if (file) { - core_1.debug(`matched ${candidate.version}`); + (0, core_1.debug)(`matched ${candidate.version}`); match = candidate; break; } @@ -3152,10 +3289,7 @@ function _getOsVersion() { if (parts.length === 2 && (parts[0].trim() === 'VERSION_ID' || parts[0].trim() === 'DISTRIB_RELEASE')) { - version = parts[1] - .trim() - .replace(/^"/, '') - .replace(/"$/, ''); + version = parts[1].trim().replace(/^"/, '').replace(/"$/, ''); break; } } @@ -3187,7 +3321,11 @@ exports._readLinuxVersionFile = _readLinuxVersionFile; var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) { if (k2 === undefined) k2 = k; - Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } }); + var desc = Object.getOwnPropertyDescriptor(m, k); + if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) { + desc = { enumerable: true, get: function() { return m[k]; } }; + } + Object.defineProperty(o, k2, desc); }) : (function(o, m, k, k2) { if (k2 === undefined) k2 = k; o[k2] = m[k]; @@ -3200,7 +3338,7 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? ( var __importStar = (this && this.__importStar) || function (mod) { if (mod && mod.__esModule) return mod; var result = {}; - if (mod != null) for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); + if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); __setModuleDefault(result, mod); return result; }; @@ -3276,7 +3414,11 @@ exports.RetryHelper = RetryHelper; var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) { if (k2 === undefined) k2 = k; - Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } }); + var desc = Object.getOwnPropertyDescriptor(m, k); + if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) { + desc = { enumerable: true, get: function() { return m[k]; } }; + } + Object.defineProperty(o, k2, desc); }) : (function(o, m, k, k2) { if (k2 === undefined) k2 = k; o[k2] = m[k]; @@ -3289,7 +3431,7 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? ( var __importStar = (this && this.__importStar) || function (mod) { if (mod && mod.__esModule) return mod; var result = {}; - if (mod != null) for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); + if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); __setModuleDefault(result, mod); return result; }; @@ -3302,13 +3444,11 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge step((generator = generator.apply(thisArg, _arguments || [])).next()); }); }; -var __importDefault = (this && this.__importDefault) || function (mod) { - return (mod && mod.__esModule) ? mod : { "default": mod }; -}; Object.defineProperty(exports, "__esModule", ({ value: true })); exports.evaluateVersions = exports.isExplicitVersion = exports.findFromManifest = exports.getManifestFromRepo = exports.findAllVersions = exports.find = exports.cacheFile = exports.cacheDir = exports.extractZip = exports.extractXar = exports.extractTar = exports.extract7z = exports.downloadTool = exports.HTTPError = void 0; const core = __importStar(__nccwpck_require__(9744)); const io = __importStar(__nccwpck_require__(881)); +const crypto = __importStar(__nccwpck_require__(6113)); const fs = __importStar(__nccwpck_require__(7147)); const mm = __importStar(__nccwpck_require__(8050)); const os = __importStar(__nccwpck_require__(2037)); @@ -3318,7 +3458,6 @@ const semver = __importStar(__nccwpck_require__(2987)); const stream = __importStar(__nccwpck_require__(2781)); const util = __importStar(__nccwpck_require__(3837)); const assert_1 = __nccwpck_require__(9491); -const v4_1 = __importDefault(__nccwpck_require__(3407)); const exec_1 = __nccwpck_require__(5571); const retry_helper_1 = __nccwpck_require__(2177); class HTTPError extends Error { @@ -3343,7 +3482,7 @@ const userAgent = 'actions/tool-cache'; */ function downloadTool(url, dest, auth, headers) { return __awaiter(this, void 0, void 0, function* () { - dest = dest || path.join(_getTempDirectory(), v4_1.default()); + dest = dest || path.join(_getTempDirectory(), crypto.randomUUID()); yield io.mkdirP(path.dirname(dest)); core.debug(`Downloading ${url}`); core.debug(`Destination ${dest}`); @@ -3432,8 +3571,8 @@ function downloadToolAttempt(url, dest, auth, headers) { */ function extract7z(file, dest, _7zPath) { return __awaiter(this, void 0, void 0, function* () { - assert_1.ok(IS_WINDOWS, 'extract7z() not supported on current OS'); - assert_1.ok(file, 'parameter "file" is required'); + (0, assert_1.ok)(IS_WINDOWS, 'extract7z() not supported on current OS'); + (0, assert_1.ok)(file, 'parameter "file" is required'); dest = yield _createExtractFolder(dest); const originalCwd = process.cwd(); process.chdir(dest); @@ -3450,7 +3589,7 @@ function extract7z(file, dest, _7zPath) { const options = { silent: true }; - yield exec_1.exec(`"${_7zPath}"`, args, options); + yield (0, exec_1.exec)(`"${_7zPath}"`, args, options); } finally { process.chdir(originalCwd); @@ -3479,7 +3618,7 @@ function extract7z(file, dest, _7zPath) { }; try { const powershellPath = yield io.which('powershell', true); - yield exec_1.exec(`"${powershellPath}"`, args, options); + yield (0, exec_1.exec)(`"${powershellPath}"`, args, options); } finally { process.chdir(originalCwd); @@ -3507,7 +3646,7 @@ function extractTar(file, dest, flags = 'xz') { // Determine whether GNU tar core.debug('Checking tar --version'); let versionOutput = ''; - yield exec_1.exec('tar --version', [], { + yield (0, exec_1.exec)('tar --version', [], { ignoreReturnCode: true, silent: true, listeners: { @@ -3543,7 +3682,7 @@ function extractTar(file, dest, flags = 'xz') { args.push('--overwrite'); } args.push('-C', destArg, '-f', fileArg); - yield exec_1.exec(`tar`, args); + yield (0, exec_1.exec)(`tar`, args); return dest; }); } @@ -3558,8 +3697,8 @@ exports.extractTar = extractTar; */ function extractXar(file, dest, flags = []) { return __awaiter(this, void 0, void 0, function* () { - assert_1.ok(IS_MAC, 'extractXar() not supported on current OS'); - assert_1.ok(file, 'parameter "file" is required'); + (0, assert_1.ok)(IS_MAC, 'extractXar() not supported on current OS'); + (0, assert_1.ok)(file, 'parameter "file" is required'); dest = yield _createExtractFolder(dest); let args; if (flags instanceof Array) { @@ -3573,7 +3712,7 @@ function extractXar(file, dest, flags = []) { args.push('-v'); } const xarPath = yield io.which('xar', true); - yield exec_1.exec(`"${xarPath}"`, _unique(args)); + yield (0, exec_1.exec)(`"${xarPath}"`, _unique(args)); return dest; }); } @@ -3627,7 +3766,7 @@ function extractZipWin(file, dest) { pwshCommand ]; core.debug(`Using pwsh at path: ${pwshPath}`); - yield exec_1.exec(`"${pwshPath}"`, args); + yield (0, exec_1.exec)(`"${pwshPath}"`, args); } else { const powershellCommand = [ @@ -3648,7 +3787,7 @@ function extractZipWin(file, dest) { ]; const powershellPath = yield io.which('powershell', true); core.debug(`Using powershell at path: ${powershellPath}`); - yield exec_1.exec(`"${powershellPath}"`, args); + yield (0, exec_1.exec)(`"${powershellPath}"`, args); } }); } @@ -3660,7 +3799,7 @@ function extractZipNix(file, dest) { args.unshift('-q'); } args.unshift('-o'); //overwrite with -o, otherwise a prompt is shown which freezes the run - yield exec_1.exec(`"${unzipPath}"`, args, { cwd: dest }); + yield (0, exec_1.exec)(`"${unzipPath}"`, args, { cwd: dest }); }); } /** @@ -3837,7 +3976,7 @@ function _createExtractFolder(dest) { return __awaiter(this, void 0, void 0, function* () { if (!dest) { // create a temp dir - dest = path.join(_getTempDirectory(), v4_1.default()); + dest = path.join(_getTempDirectory(), crypto.randomUUID()); } yield io.mkdirP(dest); return dest; @@ -3910,7 +4049,7 @@ exports.evaluateVersions = evaluateVersions; */ function _getCacheDirectory() { const cacheDirectory = process.env['RUNNER_TOOL_CACHE'] || ''; - assert_1.ok(cacheDirectory, 'Expected RUNNER_TOOL_CACHE to be defined'); + (0, assert_1.ok)(cacheDirectory, 'Expected RUNNER_TOOL_CACHE to be defined'); return cacheDirectory; } /** @@ -3918,7 +4057,7 @@ function _getCacheDirectory() { */ function _getTempDirectory() { const tempDirectory = process.env['RUNNER_TEMP'] || ''; - assert_1.ok(tempDirectory, 'Expected RUNNER_TEMP to be defined'); + (0, assert_1.ok)(tempDirectory, 'Expected RUNNER_TEMP to be defined'); return tempDirectory; } /** @@ -3939,90 +4078,6 @@ function _unique(values) { } //# sourceMappingURL=tool-cache.js.map -/***/ }), - -/***/ 5761: -/***/ ((module) => { - -/** - * Convert array of 16 byte values to UUID string format of the form: - * XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX - */ -var byteToHex = []; -for (var i = 0; i < 256; ++i) { - byteToHex[i] = (i + 0x100).toString(16).substr(1); -} - -function bytesToUuid(buf, offset) { - var i = offset || 0; - var bth = byteToHex; - // join used to fix memory issue caused by concatenation: https://bugs.chromium.org/p/v8/issues/detail?id=3175#c4 - return ([ - bth[buf[i++]], bth[buf[i++]], - bth[buf[i++]], bth[buf[i++]], '-', - bth[buf[i++]], bth[buf[i++]], '-', - bth[buf[i++]], bth[buf[i++]], '-', - bth[buf[i++]], bth[buf[i++]], '-', - bth[buf[i++]], bth[buf[i++]], - bth[buf[i++]], bth[buf[i++]], - bth[buf[i++]], bth[buf[i++]] - ]).join(''); -} - -module.exports = bytesToUuid; - - -/***/ }), - -/***/ 9973: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { - -// Unique ID creation requires a high quality random # generator. In node.js -// this is pretty straight-forward - we use the crypto API. - -var crypto = __nccwpck_require__(6113); - -module.exports = function nodeRNG() { - return crypto.randomBytes(16); -}; - - -/***/ }), - -/***/ 3407: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { - -var rng = __nccwpck_require__(9973); -var bytesToUuid = __nccwpck_require__(5761); - -function v4(options, buf, offset) { - var i = buf && offset || 0; - - if (typeof(options) == 'string') { - buf = options === 'binary' ? new Array(16) : null; - options = null; - } - options = options || {}; - - var rnds = options.random || (options.rng || rng)(); - - // Per 4.4, set bits for version and `clock_seq_hi_and_reserved` - rnds[6] = (rnds[6] & 0x0f) | 0x40; - rnds[8] = (rnds[8] & 0x3f) | 0x80; - - // Copy bytes to buffer, if provided - if (buf) { - for (var ii = 0; ii < 16; ++ii) { - buf[i + ii] = rnds[ii]; - } - } - - return buf || bytesToUuid(rnds); -} - -module.exports = v4; - - /***/ }), /***/ 2987: @@ -13986,6 +14041,14 @@ const { isUint8Array, isArrayBuffer } = __nccwpck_require__(9830) const { File: UndiciFile } = __nccwpck_require__(7774) const { parseMIMEType, serializeAMimeType } = __nccwpck_require__(7318) +let random +try { + const crypto = __nccwpck_require__(6005) + random = (max) => crypto.randomInt(0, max) +} catch { + random = (max) => Math.floor(Math.random(max)) +} + let ReadableStream = globalThis.ReadableStream /** @type {globalThis['File']} */ @@ -14071,7 +14134,7 @@ function extractBody (object, keepalive = false) { // Set source to a copy of the bytes held by object. source = new Uint8Array(object.buffer.slice(object.byteOffset, object.byteOffset + object.byteLength)) } else if (util.isFormDataLike(object)) { - const boundary = `----formdata-undici-0${`${Math.floor(Math.random() * 1e11)}`.padStart(11, '0')}` + const boundary = `----formdata-undici-0${`${random(1e11)}`.padStart(11, '0')}` const prefix = `--${boundary}\r\nContent-Disposition: form-data` /*! formdata-polyfill. MIT License. Jimmy Wärting */ @@ -28040,637 +28103,6 @@ module.exports = { } -/***/ }), - -/***/ 7413: -/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { - - - -Object.defineProperty(exports, "__esModule", ({ - value: true -})); -Object.defineProperty(exports, "v1", ({ - enumerable: true, - get: function () { - return _v.default; - } -})); -Object.defineProperty(exports, "v3", ({ - enumerable: true, - get: function () { - return _v2.default; - } -})); -Object.defineProperty(exports, "v4", ({ - enumerable: true, - get: function () { - return _v3.default; - } -})); -Object.defineProperty(exports, "v5", ({ - enumerable: true, - get: function () { - return _v4.default; - } -})); -Object.defineProperty(exports, "NIL", ({ - enumerable: true, - get: function () { - return _nil.default; - } -})); -Object.defineProperty(exports, "version", ({ - enumerable: true, - get: function () { - return _version.default; - } -})); -Object.defineProperty(exports, "validate", ({ - enumerable: true, - get: function () { - return _validate.default; - } -})); -Object.defineProperty(exports, "stringify", ({ - enumerable: true, - get: function () { - return _stringify.default; - } -})); -Object.defineProperty(exports, "parse", ({ - enumerable: true, - get: function () { - return _parse.default; - } -})); - -var _v = _interopRequireDefault(__nccwpck_require__(3189)); - -var _v2 = _interopRequireDefault(__nccwpck_require__(3226)); - -var _v3 = _interopRequireDefault(__nccwpck_require__(792)); - -var _v4 = _interopRequireDefault(__nccwpck_require__(5594)); - -var _nil = _interopRequireDefault(__nccwpck_require__(9063)); - -var _version = _interopRequireDefault(__nccwpck_require__(4788)); - -var _validate = _interopRequireDefault(__nccwpck_require__(7496)); - -var _stringify = _interopRequireDefault(__nccwpck_require__(5205)); - -var _parse = _interopRequireDefault(__nccwpck_require__(6050)); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -/***/ }), - -/***/ 9088: -/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { - - - -Object.defineProperty(exports, "__esModule", ({ - value: true -})); -exports["default"] = void 0; - -var _crypto = _interopRequireDefault(__nccwpck_require__(6113)); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -function md5(bytes) { - if (Array.isArray(bytes)) { - bytes = Buffer.from(bytes); - } else if (typeof bytes === 'string') { - bytes = Buffer.from(bytes, 'utf8'); - } - - return _crypto.default.createHash('md5').update(bytes).digest(); -} - -var _default = md5; -exports["default"] = _default; - -/***/ }), - -/***/ 9063: -/***/ ((__unused_webpack_module, exports) => { - - - -Object.defineProperty(exports, "__esModule", ({ - value: true -})); -exports["default"] = void 0; -var _default = '00000000-0000-0000-0000-000000000000'; -exports["default"] = _default; - -/***/ }), - -/***/ 6050: -/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { - - - -Object.defineProperty(exports, "__esModule", ({ - value: true -})); -exports["default"] = void 0; - -var _validate = _interopRequireDefault(__nccwpck_require__(7496)); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -function parse(uuid) { - if (!(0, _validate.default)(uuid)) { - throw TypeError('Invalid UUID'); - } - - let v; - const arr = new Uint8Array(16); // Parse ########-....-....-....-............ - - arr[0] = (v = parseInt(uuid.slice(0, 8), 16)) >>> 24; - arr[1] = v >>> 16 & 0xff; - arr[2] = v >>> 8 & 0xff; - arr[3] = v & 0xff; // Parse ........-####-....-....-............ - - arr[4] = (v = parseInt(uuid.slice(9, 13), 16)) >>> 8; - arr[5] = v & 0xff; // Parse ........-....-####-....-............ - - arr[6] = (v = parseInt(uuid.slice(14, 18), 16)) >>> 8; - arr[7] = v & 0xff; // Parse ........-....-....-####-............ - - arr[8] = (v = parseInt(uuid.slice(19, 23), 16)) >>> 8; - arr[9] = v & 0xff; // Parse ........-....-....-....-############ - // (Use "/" to avoid 32-bit truncation when bit-shifting high-order bytes) - - arr[10] = (v = parseInt(uuid.slice(24, 36), 16)) / 0x10000000000 & 0xff; - arr[11] = v / 0x100000000 & 0xff; - arr[12] = v >>> 24 & 0xff; - arr[13] = v >>> 16 & 0xff; - arr[14] = v >>> 8 & 0xff; - arr[15] = v & 0xff; - return arr; -} - -var _default = parse; -exports["default"] = _default; - -/***/ }), - -/***/ 7926: -/***/ ((__unused_webpack_module, exports) => { - - - -Object.defineProperty(exports, "__esModule", ({ - value: true -})); -exports["default"] = void 0; -var _default = /^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i; -exports["default"] = _default; - -/***/ }), - -/***/ 6655: -/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { - - - -Object.defineProperty(exports, "__esModule", ({ - value: true -})); -exports["default"] = rng; - -var _crypto = _interopRequireDefault(__nccwpck_require__(6113)); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -const rnds8Pool = new Uint8Array(256); // # of random values to pre-allocate - -let poolPtr = rnds8Pool.length; - -function rng() { - if (poolPtr > rnds8Pool.length - 16) { - _crypto.default.randomFillSync(rnds8Pool); - - poolPtr = 0; - } - - return rnds8Pool.slice(poolPtr, poolPtr += 16); -} - -/***/ }), - -/***/ 2307: -/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { - - - -Object.defineProperty(exports, "__esModule", ({ - value: true -})); -exports["default"] = void 0; - -var _crypto = _interopRequireDefault(__nccwpck_require__(6113)); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -function sha1(bytes) { - if (Array.isArray(bytes)) { - bytes = Buffer.from(bytes); - } else if (typeof bytes === 'string') { - bytes = Buffer.from(bytes, 'utf8'); - } - - return _crypto.default.createHash('sha1').update(bytes).digest(); -} - -var _default = sha1; -exports["default"] = _default; - -/***/ }), - -/***/ 5205: -/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { - - - -Object.defineProperty(exports, "__esModule", ({ - value: true -})); -exports["default"] = void 0; - -var _validate = _interopRequireDefault(__nccwpck_require__(7496)); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -/** - * Convert array of 16 byte values to UUID string format of the form: - * XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX - */ -const byteToHex = []; - -for (let i = 0; i < 256; ++i) { - byteToHex.push((i + 0x100).toString(16).substr(1)); -} - -function stringify(arr, offset = 0) { - // Note: Be careful editing this code! It's been tuned for performance - // and works in ways you may not expect. See https://github.com/uuidjs/uuid/pull/434 - const uuid = (byteToHex[arr[offset + 0]] + byteToHex[arr[offset + 1]] + byteToHex[arr[offset + 2]] + byteToHex[arr[offset + 3]] + '-' + byteToHex[arr[offset + 4]] + byteToHex[arr[offset + 5]] + '-' + byteToHex[arr[offset + 6]] + byteToHex[arr[offset + 7]] + '-' + byteToHex[arr[offset + 8]] + byteToHex[arr[offset + 9]] + '-' + byteToHex[arr[offset + 10]] + byteToHex[arr[offset + 11]] + byteToHex[arr[offset + 12]] + byteToHex[arr[offset + 13]] + byteToHex[arr[offset + 14]] + byteToHex[arr[offset + 15]]).toLowerCase(); // Consistency check for valid UUID. If this throws, it's likely due to one - // of the following: - // - One or more input array values don't map to a hex octet (leading to - // "undefined" in the uuid) - // - Invalid input values for the RFC `version` or `variant` fields - - if (!(0, _validate.default)(uuid)) { - throw TypeError('Stringified UUID is invalid'); - } - - return uuid; -} - -var _default = stringify; -exports["default"] = _default; - -/***/ }), - -/***/ 3189: -/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { - - - -Object.defineProperty(exports, "__esModule", ({ - value: true -})); -exports["default"] = void 0; - -var _rng = _interopRequireDefault(__nccwpck_require__(6655)); - -var _stringify = _interopRequireDefault(__nccwpck_require__(5205)); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -// **`v1()` - Generate time-based UUID** -// -// Inspired by https://github.com/LiosK/UUID.js -// and http://docs.python.org/library/uuid.html -let _nodeId; - -let _clockseq; // Previous uuid creation time - - -let _lastMSecs = 0; -let _lastNSecs = 0; // See https://github.com/uuidjs/uuid for API details - -function v1(options, buf, offset) { - let i = buf && offset || 0; - const b = buf || new Array(16); - options = options || {}; - let node = options.node || _nodeId; - let clockseq = options.clockseq !== undefined ? options.clockseq : _clockseq; // node and clockseq need to be initialized to random values if they're not - // specified. We do this lazily to minimize issues related to insufficient - // system entropy. See #189 - - if (node == null || clockseq == null) { - const seedBytes = options.random || (options.rng || _rng.default)(); - - if (node == null) { - // Per 4.5, create and 48-bit node id, (47 random bits + multicast bit = 1) - node = _nodeId = [seedBytes[0] | 0x01, seedBytes[1], seedBytes[2], seedBytes[3], seedBytes[4], seedBytes[5]]; - } - - if (clockseq == null) { - // Per 4.2.2, randomize (14 bit) clockseq - clockseq = _clockseq = (seedBytes[6] << 8 | seedBytes[7]) & 0x3fff; - } - } // UUID timestamps are 100 nano-second units since the Gregorian epoch, - // (1582-10-15 00:00). JSNumbers aren't precise enough for this, so - // time is handled internally as 'msecs' (integer milliseconds) and 'nsecs' - // (100-nanoseconds offset from msecs) since unix epoch, 1970-01-01 00:00. - - - let msecs = options.msecs !== undefined ? options.msecs : Date.now(); // Per 4.2.1.2, use count of uuid's generated during the current clock - // cycle to simulate higher resolution clock - - let nsecs = options.nsecs !== undefined ? options.nsecs : _lastNSecs + 1; // Time since last uuid creation (in msecs) - - const dt = msecs - _lastMSecs + (nsecs - _lastNSecs) / 10000; // Per 4.2.1.2, Bump clockseq on clock regression - - if (dt < 0 && options.clockseq === undefined) { - clockseq = clockseq + 1 & 0x3fff; - } // Reset nsecs if clock regresses (new clockseq) or we've moved onto a new - // time interval - - - if ((dt < 0 || msecs > _lastMSecs) && options.nsecs === undefined) { - nsecs = 0; - } // Per 4.2.1.2 Throw error if too many uuids are requested - - - if (nsecs >= 10000) { - throw new Error("uuid.v1(): Can't create more than 10M uuids/sec"); - } - - _lastMSecs = msecs; - _lastNSecs = nsecs; - _clockseq = clockseq; // Per 4.1.4 - Convert from unix epoch to Gregorian epoch - - msecs += 12219292800000; // `time_low` - - const tl = ((msecs & 0xfffffff) * 10000 + nsecs) % 0x100000000; - b[i++] = tl >>> 24 & 0xff; - b[i++] = tl >>> 16 & 0xff; - b[i++] = tl >>> 8 & 0xff; - b[i++] = tl & 0xff; // `time_mid` - - const tmh = msecs / 0x100000000 * 10000 & 0xfffffff; - b[i++] = tmh >>> 8 & 0xff; - b[i++] = tmh & 0xff; // `time_high_and_version` - - b[i++] = tmh >>> 24 & 0xf | 0x10; // include version - - b[i++] = tmh >>> 16 & 0xff; // `clock_seq_hi_and_reserved` (Per 4.2.2 - include variant) - - b[i++] = clockseq >>> 8 | 0x80; // `clock_seq_low` - - b[i++] = clockseq & 0xff; // `node` - - for (let n = 0; n < 6; ++n) { - b[i + n] = node[n]; - } - - return buf || (0, _stringify.default)(b); -} - -var _default = v1; -exports["default"] = _default; - -/***/ }), - -/***/ 3226: -/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { - - - -Object.defineProperty(exports, "__esModule", ({ - value: true -})); -exports["default"] = void 0; - -var _v = _interopRequireDefault(__nccwpck_require__(2996)); - -var _md = _interopRequireDefault(__nccwpck_require__(9088)); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -const v3 = (0, _v.default)('v3', 0x30, _md.default); -var _default = v3; -exports["default"] = _default; - -/***/ }), - -/***/ 2996: -/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { - - - -Object.defineProperty(exports, "__esModule", ({ - value: true -})); -exports["default"] = _default; -exports.URL = exports.DNS = void 0; - -var _stringify = _interopRequireDefault(__nccwpck_require__(5205)); - -var _parse = _interopRequireDefault(__nccwpck_require__(6050)); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -function stringToBytes(str) { - str = unescape(encodeURIComponent(str)); // UTF8 escape - - const bytes = []; - - for (let i = 0; i < str.length; ++i) { - bytes.push(str.charCodeAt(i)); - } - - return bytes; -} - -const DNS = '6ba7b810-9dad-11d1-80b4-00c04fd430c8'; -exports.DNS = DNS; -const URL = '6ba7b811-9dad-11d1-80b4-00c04fd430c8'; -exports.URL = URL; - -function _default(name, version, hashfunc) { - function generateUUID(value, namespace, buf, offset) { - if (typeof value === 'string') { - value = stringToBytes(value); - } - - if (typeof namespace === 'string') { - namespace = (0, _parse.default)(namespace); - } - - if (namespace.length !== 16) { - throw TypeError('Namespace must be array-like (16 iterable integer values, 0-255)'); - } // Compute hash of namespace and value, Per 4.3 - // Future: Use spread syntax when supported on all platforms, e.g. `bytes = - // hashfunc([...namespace, ... value])` - - - let bytes = new Uint8Array(16 + value.length); - bytes.set(namespace); - bytes.set(value, namespace.length); - bytes = hashfunc(bytes); - bytes[6] = bytes[6] & 0x0f | version; - bytes[8] = bytes[8] & 0x3f | 0x80; - - if (buf) { - offset = offset || 0; - - for (let i = 0; i < 16; ++i) { - buf[offset + i] = bytes[i]; - } - - return buf; - } - - return (0, _stringify.default)(bytes); - } // Function#name is not settable on some platforms (#270) - - - try { - generateUUID.name = name; // eslint-disable-next-line no-empty - } catch (err) {} // For CommonJS default export support - - - generateUUID.DNS = DNS; - generateUUID.URL = URL; - return generateUUID; -} - -/***/ }), - -/***/ 792: -/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { - - - -Object.defineProperty(exports, "__esModule", ({ - value: true -})); -exports["default"] = void 0; - -var _rng = _interopRequireDefault(__nccwpck_require__(6655)); - -var _stringify = _interopRequireDefault(__nccwpck_require__(5205)); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -function v4(options, buf, offset) { - options = options || {}; - - const rnds = options.random || (options.rng || _rng.default)(); // Per 4.4, set bits for version and `clock_seq_hi_and_reserved` - - - rnds[6] = rnds[6] & 0x0f | 0x40; - rnds[8] = rnds[8] & 0x3f | 0x80; // Copy bytes to buffer, if provided - - if (buf) { - offset = offset || 0; - - for (let i = 0; i < 16; ++i) { - buf[offset + i] = rnds[i]; - } - - return buf; - } - - return (0, _stringify.default)(rnds); -} - -var _default = v4; -exports["default"] = _default; - -/***/ }), - -/***/ 5594: -/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { - - - -Object.defineProperty(exports, "__esModule", ({ - value: true -})); -exports["default"] = void 0; - -var _v = _interopRequireDefault(__nccwpck_require__(2996)); - -var _sha = _interopRequireDefault(__nccwpck_require__(2307)); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -const v5 = (0, _v.default)('v5', 0x50, _sha.default); -var _default = v5; -exports["default"] = _default; - -/***/ }), - -/***/ 7496: -/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { - - - -Object.defineProperty(exports, "__esModule", ({ - value: true -})); -exports["default"] = void 0; - -var _regex = _interopRequireDefault(__nccwpck_require__(7926)); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -function validate(uuid) { - return typeof uuid === 'string' && _regex.default.test(uuid); -} - -var _default = validate; -exports["default"] = _default; - -/***/ }), - -/***/ 4788: -/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { - - - -Object.defineProperty(exports, "__esModule", ({ - value: true -})); -exports["default"] = void 0; - -var _validate = _interopRequireDefault(__nccwpck_require__(7496)); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -function version(uuid) { - if (!(0, _validate.default)(uuid)) { - throw TypeError('Invalid UUID'); - } - - return parseInt(uuid.substr(14, 1), 16); -} - -var _default = version; -exports["default"] = _default; - /***/ }), /***/ 9491: @@ -28771,6 +28203,13 @@ module.exports = __WEBPACK_EXTERNAL_createRequire(import.meta.url)("net"); /***/ }), +/***/ 6005: +/***/ ((module) => { + +module.exports = __WEBPACK_EXTERNAL_createRequire(import.meta.url)("node:crypto"); + +/***/ }), + /***/ 5673: /***/ ((module) => { diff --git a/dist/main.cjs b/dist/main.cjs index 5330658..194a750 100644 --- a/dist/main.cjs +++ b/dist/main.cjs @@ -1,4 +1,4 @@ -// Generated by dart2js (NullSafetyMode.sound, csp, intern-composite-values), the Dart to JavaScript compiler version: 3.5.0-288.0.dev. +// Generated by dart2js (NullSafetyMode.sound, csp, intern-composite-values), the Dart to JavaScript compiler version: 3.8.0-91.0.dev. // The code supports the following hooks: // dartPrint(message): // if this function is defined it is called instead of the Dart [print] @@ -14,17 +14,16 @@ // is loaded. It should load and eval the javascript of `uri`, and call // successCallback. If it fails to do so, it should call errorCallback with // an error. The loadId argument is the deferred import that resulted in -// this uri being loaded. The loadPriority argument is the priority the -// library should be loaded with as specified in the code via the -// load-priority annotation (0: normal, 1: high). +// this uri being loaded. The loadPriority argument is an arbitrary argument +// string forwarded from the 'dart2js:load-priority' pragma option. // dartDeferredLibraryMultiLoader(uris, successCallback, errorCallback, loadId, loadPriority): // if this function is defined, it will be called when a deferred library // is loaded. It should load and eval the javascript of every URI in `uris`, // and call successCallback. If it fails to do so, it should call // errorCallback with an error. The loadId argument is the deferred import -// that resulted in this uri being loaded. The loadPriority argument is the -// priority the library should be loaded with as specified in the code via -// the load-priority annotation (0: normal, 1: high). +// that resulted in this uri being loaded. The loadPriority argument is an +// arbitrary argument string forwarded from the 'dart2js:load-priority' +// pragma option. // // dartCallInstrumentation(id, qualifiedName): // if this function is defined, it will be called at each entry of a @@ -127,8 +126,7 @@ }; } function makeConstList(list) { - list.immutable$list = Array; - list.fixed$length = Array; + list.$flags = 7; return list; } function convertToFastObject(properties) { @@ -290,11 +288,9 @@ return A._setArrayType(new Array($length), $E._eval$1("JSArray<0>")); }, JSArray_JSArray$markFixed(allocation, $E) { - return J.JSArray_markFixedList(A._setArrayType(allocation, $E._eval$1("JSArray<0>")), $E); - }, - JSArray_markFixedList(list, $T) { - list.fixed$length = Array; - return list; + var t1 = A._setArrayType(allocation, $E._eval$1("JSArray<0>")); + t1.$flags = 1; + return t1; }, JSArray__compareAny(a, b) { var t1 = type$.Comparable_dynamic; @@ -472,9 +468,6 @@ return receiver[a0]; return J.getInterceptor$asx(receiver).$index(receiver, a0); }, - $indexSet$ax(receiver, a0, a1) { - return J.getInterceptor$ax(receiver).$indexSet(receiver, a0, a1); - }, allMatches$1$s(receiver, a0) { return J.getInterceptor$s(receiver).allMatches$1(receiver, a0); }, @@ -484,9 +477,6 @@ compareTo$1$ns(receiver, a0) { return J.getInterceptor$ns(receiver).compareTo$1(receiver, a0); }, - contains$1$asx(receiver, a0) { - return J.getInterceptor$asx(receiver).contains$1(receiver, a0); - }, elementAt$1$ax(receiver, a0) { return J.getInterceptor$ax(receiver).elementAt$1(receiver, a0); }, @@ -542,10 +532,13 @@ A = {JS_CONST: function JS_CONST() { }, CastIterable_CastIterable(source, $S, $T) { - if ($S._eval$1("EfficientLengthIterable<0>")._is(source)) + if (type$.EfficientLengthIterable_dynamic._is(source)) return new A._EfficientLengthCastIterable(source, $S._eval$1("@<0>")._bind$1($T)._eval$1("_EfficientLengthCastIterable<1,2>")); return new A.CastIterable(source, $S._eval$1("@<0>")._bind$1($T)._eval$1("CastIterable<1,2>")); }, + LateError$fieldADI(fieldName) { + return new A.LateError("Field '" + fieldName + "' has been assigned during initialization."); + }, hexDigitValue(char) { var letter, digit = char ^ 48; @@ -594,6 +587,14 @@ this._source = t0; this.$ti = t1; }, + CastMap: function CastMap(t0, t1) { + this._source = t0; + this.$ti = t1; + }, + CastMap_forEach_closure: function CastMap_forEach_closure(t0, t1) { + this.$this = t0; + this.f = t1; + }, LateError: function LateError(t0) { this.__internal$_message = t0; }, @@ -802,6 +803,15 @@ return null; return A.getTraceFromException(jsError); }, + Primitives_trySetStackTrace(error, stackTrace) { + var jsError; + if (error.$thrownJsError == null) { + jsError = new Error(); + A.initializeExceptionWrapper(error, jsError); + error.$thrownJsError = jsError; + jsError.stack = stackTrace.toString$0(0); + } + }, iae(argument) { throw A.wrapException(A.argumentErrorValue(argument)); }, @@ -823,9 +833,9 @@ return new A.ArgumentError(true, object, null, null); }, wrapException(ex) { - return A.initializeExceptionWrapper(new Error(), ex); + return A.initializeExceptionWrapper(ex, new Error()); }, - initializeExceptionWrapper(wrapper, ex) { + initializeExceptionWrapper(ex, wrapper) { var t1; if (ex == null) ex = new A.TypeError(); @@ -841,11 +851,44 @@ toStringWrapper() { return J.toString$0$(this.dartException); }, - throwExpression(ex) { - throw A.wrapException(ex); - }, - throwExpressionWithWrapper(ex, wrapper) { - throw A.initializeExceptionWrapper(wrapper, ex); + throwExpression(ex, wrapper) { + throw A.initializeExceptionWrapper(ex, wrapper == null ? new Error() : wrapper); + }, + throwUnsupportedOperation(o, operation, verb) { + var wrapper; + if (operation == null) + operation = 0; + if (verb == null) + verb = 0; + wrapper = Error(); + A.throwExpression(A._diagnoseUnsupportedOperation(o, operation, verb), wrapper); + }, + _diagnoseUnsupportedOperation(o, encodedOperation, encodedVerb) { + var operation, table, tableLength, index, verb, object, flags, article, adjective; + if (typeof encodedOperation == "string") + operation = encodedOperation; + else { + table = "[]=;add;removeWhere;retainWhere;removeRange;setRange;setInt8;setInt16;setInt32;setUint8;setUint16;setUint32;setFloat32;setFloat64".split(";"); + tableLength = table.length; + index = encodedOperation; + if (index > tableLength) { + encodedVerb = index / tableLength | 0; + index %= tableLength; + } + operation = table[index]; + } + verb = typeof encodedVerb == "string" ? encodedVerb : "modify;remove from;add to".split(";")[encodedVerb]; + object = type$.List_dynamic._is(o) ? "list" : "ByteData"; + flags = o.$flags | 0; + article = "a "; + if ((flags & 4) !== 0) + adjective = "constant "; + else if ((flags & 2) !== 0) { + adjective = "unmodifiable "; + article = "an "; + } else + adjective = (flags & 1) !== 0 ? "fixed-length " : ""; + return new A.UnsupportedError("'" + operation + "': Cannot " + verb + " " + article + adjective + object); }, throwConcurrentModificationError(collection) { throw A.wrapException(A.ConcurrentModificationError$(collection)); @@ -990,64 +1033,12 @@ return J.get$hashCode$(object); }, fillLiteralMap(keyValuePairs, result) { - var t1, t2, index, index0, key, value, strings, table, cell, nums, rest, hash, bucket, + var index, index0, index1, $length = keyValuePairs.length; - for (t1 = result.$ti, t2 = t1._precomputed1, t1 = t1._rest[1], index = 0; index < $length;) { + for (index = 0; index < $length; index = index1) { index0 = index + 1; - key = keyValuePairs[index]; - index = index0 + 1; - value = keyValuePairs[index0]; - t2._as(key); - t1._as(value); - if (typeof key == "string") { - strings = result.__js_helper$_strings; - if (strings == null) { - table = Object.create(null); - table[""] = table; - delete table[""]; - result.__js_helper$_strings = table; - strings = table; - } - cell = strings[key]; - if (cell == null) - strings[key] = result._newLinkedCell$2(key, value); - else - cell.hashMapCellValue = value; - } else if (typeof key == "number" && (key & 0x3fffffff) === key) { - nums = result.__js_helper$_nums; - if (nums == null) { - table = Object.create(null); - table[""] = table; - delete table[""]; - result.__js_helper$_nums = table; - nums = table; - } - cell = nums[key]; - if (cell == null) - nums[key] = result._newLinkedCell$2(key, value); - else - cell.hashMapCellValue = value; - } else { - rest = result.__js_helper$_rest; - if (rest == null) { - table = Object.create(null); - table[""] = table; - delete table[""]; - result.__js_helper$_rest = table; - rest = table; - } - hash = J.get$hashCode$(key) & 1073741823; - bucket = rest[hash]; - if (bucket == null) - rest[hash] = [result._newLinkedCell$2(key, value)]; - else { - index0 = result.internalFindBucketIndex$2(bucket, key); - if (index0 >= 0) - bucket[index0].hashMapCellValue = value; - else - bucket.push(result._newLinkedCell$2(key, value)); - } - } + index1 = index0 + 1; + result.$indexSet(0, keyValuePairs[index], keyValuePairs[index0]); } return result; }, @@ -1301,9 +1292,11 @@ return closure._interceptor; }, BoundClosure__computeFieldNamed(fieldName) { - var t1, i, $name, + var names, i, $name, template = new A.BoundClosure("receiver", "interceptor"), - names = J.JSArray_markFixedList(Object.getOwnPropertyNames(template), type$.nullable_Object); + t1 = Object.getOwnPropertyNames(template); + t1.$flags = 1; + names = t1; for (t1 = names.length, i = 0; i < t1; ++i) { $name = names[i]; if (template[$name] === fieldName) @@ -1575,7 +1568,7 @@ JsLinkedHashMap: function JsLinkedHashMap(t0) { var _ = this; _.__js_helper$_length = 0; - _._last = _._first = _.__js_helper$_rest = _.__js_helper$_nums = _.__js_helper$_strings = null; + _._last = _._first = _.__js_helper$_rest = _._nums = _._strings = null; _._modifications = 0; _.$ti = t0; }, @@ -1584,16 +1577,17 @@ this.hashMapCellValue = t1; this._next = null; }, - LinkedHashMapKeyIterable: function LinkedHashMapKeyIterable(t0, t1) { - this.__js_helper$_map = t0; + LinkedHashMapKeysIterable: function LinkedHashMapKeysIterable(t0, t1) { + this._map = t0; this.$ti = t1; }, - LinkedHashMapKeyIterator: function LinkedHashMapKeyIterator(t0, t1, t2) { + LinkedHashMapKeyIterator: function LinkedHashMapKeyIterator(t0, t1, t2, t3) { var _ = this; - _.__js_helper$_map = t0; + _._map = t0; _._modifications = t1; - _.__js_helper$_current = _._cell = null; - _.$ti = t2; + _._cell = t2; + _.__js_helper$_current = null; + _.$ti = t3; }, initHooks_closure: function initHooks_closure(t0) { this.getTag = t0; @@ -1991,6 +1985,26 @@ if (t1) asFn = A._generalNullableAsCheckImplementation; } + if (testRti === type$.int) + asFn = A._asInt; + else if (testRti === type$.nullable_int) + asFn = A._asIntQ; + else if (testRti === type$.String) + asFn = A._asString; + else if (testRti === type$.nullable_String) + asFn = A._asStringQ; + else if (testRti === type$.bool) + asFn = A._asBool; + else if (testRti === type$.nullable_bool) + asFn = A._asBoolQ; + else if (testRti === type$.num) + asFn = A._asNum; + else if (testRti === type$.nullable_num) + asFn = A._asNumQ; + else if (testRti === type$.double) + asFn = A._asDouble; + else if (testRti === type$.nullable_double) + asFn = A._asDoubleQ; testRti._as = asFn; return testRti._as(object); }, @@ -2045,7 +2059,7 @@ return object; } else if (testRti._is(object)) return object; - A._failedAsCheck(object, testRti); + throw A.initializeExceptionWrapper(A._errorForAsCheck(object, testRti), new Error()); }, _generalNullableAsCheckImplementation(object) { var testRti = this; @@ -2053,17 +2067,14 @@ return object; else if (testRti._is(object)) return object; - A._failedAsCheck(object, testRti); + throw A.initializeExceptionWrapper(A._errorForAsCheck(object, testRti), new Error()); }, - _failedAsCheck(object, testRti) { - throw A.wrapException(A._TypeError$fromMessage(A._Error_compose(object, A._rtiToString(testRti, null)))); + _errorForAsCheck(object, testRti) { + return new A._TypeError("TypeError: " + A._Error_compose(object, A._rtiToString(testRti, null))); }, _Error_compose(object, checkedTypeDescription) { return A.Error_safeToString(object) + ": type '" + A._rtiToString(A._structuralTypeOf(object), null) + "' is not a subtype of type '" + checkedTypeDescription + "'"; }, - _TypeError$fromMessage(message) { - return new A._TypeError("TypeError: " + message); - }, _TypeError__TypeError$forType(object, type) { return new A._TypeError("TypeError: " + A._Error_compose(object, type)); }, @@ -2078,7 +2089,7 @@ _asObject(object) { if (object != null) return object; - throw A.wrapException(A._TypeError__TypeError$forType(object, "Object")); + throw A.initializeExceptionWrapper(A._TypeError__TypeError$forType(object, "Object"), new Error()); }, _isTop(object) { return true; @@ -2097,7 +2108,7 @@ return true; if (false === object) return false; - throw A.wrapException(A._TypeError__TypeError$forType(object, "bool")); + throw A.initializeExceptionWrapper(A._TypeError__TypeError$forType(object, "bool"), new Error()); }, _asBoolS(object) { if (true === object) @@ -2106,7 +2117,7 @@ return false; if (object == null) return object; - throw A.wrapException(A._TypeError__TypeError$forType(object, "bool")); + throw A.initializeExceptionWrapper(A._TypeError__TypeError$forType(object, "bool"), new Error()); }, _asBoolQ(object) { if (true === object) @@ -2115,26 +2126,26 @@ return false; if (object == null) return object; - throw A.wrapException(A._TypeError__TypeError$forType(object, "bool?")); + throw A.initializeExceptionWrapper(A._TypeError__TypeError$forType(object, "bool?"), new Error()); }, _asDouble(object) { if (typeof object == "number") return object; - throw A.wrapException(A._TypeError__TypeError$forType(object, "double")); + throw A.initializeExceptionWrapper(A._TypeError__TypeError$forType(object, "double"), new Error()); }, _asDoubleS(object) { if (typeof object == "number") return object; if (object == null) return object; - throw A.wrapException(A._TypeError__TypeError$forType(object, "double")); + throw A.initializeExceptionWrapper(A._TypeError__TypeError$forType(object, "double"), new Error()); }, _asDoubleQ(object) { if (typeof object == "number") return object; if (object == null) return object; - throw A.wrapException(A._TypeError__TypeError$forType(object, "double?")); + throw A.initializeExceptionWrapper(A._TypeError__TypeError$forType(object, "double?"), new Error()); }, _isInt(object) { return typeof object == "number" && Math.floor(object) === object; @@ -2142,21 +2153,21 @@ _asInt(object) { if (typeof object == "number" && Math.floor(object) === object) return object; - throw A.wrapException(A._TypeError__TypeError$forType(object, "int")); + throw A.initializeExceptionWrapper(A._TypeError__TypeError$forType(object, "int"), new Error()); }, _asIntS(object) { if (typeof object == "number" && Math.floor(object) === object) return object; if (object == null) return object; - throw A.wrapException(A._TypeError__TypeError$forType(object, "int")); + throw A.initializeExceptionWrapper(A._TypeError__TypeError$forType(object, "int"), new Error()); }, _asIntQ(object) { if (typeof object == "number" && Math.floor(object) === object) return object; if (object == null) return object; - throw A.wrapException(A._TypeError__TypeError$forType(object, "int?")); + throw A.initializeExceptionWrapper(A._TypeError__TypeError$forType(object, "int?"), new Error()); }, _isNum(object) { return typeof object == "number"; @@ -2164,21 +2175,21 @@ _asNum(object) { if (typeof object == "number") return object; - throw A.wrapException(A._TypeError__TypeError$forType(object, "num")); + throw A.initializeExceptionWrapper(A._TypeError__TypeError$forType(object, "num"), new Error()); }, _asNumS(object) { if (typeof object == "number") return object; if (object == null) return object; - throw A.wrapException(A._TypeError__TypeError$forType(object, "num")); + throw A.initializeExceptionWrapper(A._TypeError__TypeError$forType(object, "num"), new Error()); }, _asNumQ(object) { if (typeof object == "number") return object; if (object == null) return object; - throw A.wrapException(A._TypeError__TypeError$forType(object, "num?")); + throw A.initializeExceptionWrapper(A._TypeError__TypeError$forType(object, "num?"), new Error()); }, _isString(object) { return typeof object == "string"; @@ -2186,21 +2197,21 @@ _asString(object) { if (typeof object == "string") return object; - throw A.wrapException(A._TypeError__TypeError$forType(object, "String")); + throw A.initializeExceptionWrapper(A._TypeError__TypeError$forType(object, "String"), new Error()); }, _asStringS(object) { if (typeof object == "string") return object; if (object == null) return object; - throw A.wrapException(A._TypeError__TypeError$forType(object, "String")); + throw A.initializeExceptionWrapper(A._TypeError__TypeError$forType(object, "String"), new Error()); }, _asStringQ(object) { if (typeof object == "string") return object; if (object == null) return object; - throw A.wrapException(A._TypeError__TypeError$forType(object, "String?")); + throw A.initializeExceptionWrapper(A._TypeError__TypeError$forType(object, "String?"), new Error()); }, _rtiArrayToString(array, genericContext) { var s, sep, i; @@ -2244,7 +2255,7 @@ t4 = t3 - 1 - i; if (!(t4 >= 0)) return A.ioore(genericContext, t4); - typeParametersText = B.JSString_methods.$add(typeParametersText + typeSep, genericContext[t4]); + typeParametersText = typeParametersText + typeSep + genericContext[t4]; boundRti = bounds[i]; kind = boundRti._kind; if (!(kind === 2 || kind === 3 || kind === 4 || kind === 5 || boundRti === t1)) @@ -3229,10 +3240,11 @@ this._message = t0; }, _AsyncRun__initializeScheduleImmediate() { - var div, span, t1 = {}; + var t1, div, span; if (self.scheduleImmediate != null) return A.async__AsyncRun__scheduleImmediateJsOverride$closure(); if (self.MutationObserver != null && self.document != null) { + t1 = {}; div = self.document.createElement("div"); span = self.document.createElement("span"); t1.storedCallback = null; @@ -3308,10 +3320,6 @@ }($function, 1); return $.Zone__current.registerBinaryCallback$3$1(new A._wrapJsFunctionForAsync_closure($protected), type$.void, type$.int, type$.dynamic); }, - AsyncError$(error, stackTrace) { - var t1 = A.checkNotNullable(error, "error", type$.Object); - return new A.AsyncError(t1, stackTrace == null ? A.AsyncError_defaultStackTrace(error) : stackTrace); - }, AsyncError_defaultStackTrace(error) { var stackTrace; if (type$.Error._is(error)) { @@ -3321,49 +3329,63 @@ } return B.C__StringStackTrace; }, - _Future__chainCoreFutureSync(source, target) { - var t1, t2, listeners; - for (t1 = type$._Future_dynamic; t2 = source._state, (t2 & 4) !== 0;) - source = t1._as(source._resultOrListeners); - if (source === target) { - target._asyncCompleteError$2(new A.ArgumentError(true, source, null, "Cannot complete a future with itself"), A.StackTrace_current()); - return; - } - t1 = t2 | target._state & 1; - source._state = t1; - if ((t1 & 24) !== 0) { - listeners = target._removeListeners$0(); - target._cloneResult$1(source); - A._Future__propagateToListeners(target, listeners); - } else { - listeners = type$.nullable__FutureListener_dynamic_dynamic._as(target._resultOrListeners); - target._setChained$1(source); - source._prependListeners$1(listeners); - } + _interceptError(error, stackTrace) { + if ($.Zone__current === B.C__RootZone) + return null; + return null; }, - _Future__chainCoreFutureAsync(source, target) { - var t2, t3, listeners, _box_0 = {}, + _interceptUserError(error, stackTrace) { + if ($.Zone__current !== B.C__RootZone) + A._interceptError(error, stackTrace); + if (stackTrace == null) + if (type$.Error._is(error)) { + stackTrace = error.get$stackTrace(); + if (stackTrace == null) { + A.Primitives_trySetStackTrace(error, B.C__StringStackTrace); + stackTrace = B.C__StringStackTrace; + } + } else + stackTrace = B.C__StringStackTrace; + else if (type$.Error._is(error)) + A.Primitives_trySetStackTrace(error, stackTrace); + return new A.AsyncError(error, stackTrace); + }, + _Future__chainCoreFuture(source, target, sync) { + var t2, t3, ignoreError, listeners, _box_0 = {}, t1 = _box_0.source = source; for (t2 = type$._Future_dynamic; t3 = t1._state, (t3 & 4) !== 0; t1 = source) { source = t2._as(t1._resultOrListeners); _box_0.source = source; } if (t1 === target) { - target._asyncCompleteError$2(new A.ArgumentError(true, t1, null, "Cannot complete a future with itself"), A.StackTrace_current()); + t2 = A.StackTrace_current(); + target._asyncCompleteErrorObject$1(new A.AsyncError(new A.ArgumentError(true, t1, null, "Cannot complete a future with itself"), t2)); return; } - if ((t3 & 24) === 0) { + ignoreError = target._state & 1; + t2 = t1._state = t3 | ignoreError; + if ((t2 & 24) === 0) { listeners = type$.nullable__FutureListener_dynamic_dynamic._as(target._resultOrListeners); - target._setChained$1(t1); - _box_0.source._prependListeners$1(listeners); + target._state = target._state & 1 | 4; + target._resultOrListeners = t1; + t1._prependListeners$1(listeners); return; } - if ((t3 & 16) === 0 && target._resultOrListeners == null) { - target._cloneResult$1(t1); + if (!sync) + if (target._resultOrListeners == null) + t1 = (t2 & 16) === 0 || ignoreError !== 0; + else + t1 = false; + else + t1 = true; + if (t1) { + listeners = target._removeListeners$0(); + target._cloneResult$1(_box_0.source); + A._Future__propagateToListeners(target, listeners); return; } target._state ^= 2; - A._rootScheduleMicrotask(null, null, target._zone, type$.void_Function._as(new A._Future__chainCoreFutureAsync_closure(_box_0, target))); + A._rootScheduleMicrotask(null, null, target._zone, type$.void_Function._as(new A._Future__chainCoreFuture_closure(_box_0, target))); }, _Future__propagateToListeners(source, listeners) { var t2, t3, t4, _box_0, t5, t6, hasError, asyncError, nextListener, nextListener0, sourceResult, t7, zone, oldZone, result, current, _box_1 = {}, @@ -3442,7 +3464,7 @@ _box_1.source = t1; continue; } else - A._Future__chainCoreFutureSync(t1, result); + A._Future__chainCoreFuture(t1, result, true); return; } } @@ -3527,15 +3549,6 @@ $._lastCallback = entry; } }, - scheduleMicrotask(callback) { - var _null = null, - currentZone = $.Zone__current; - if (B.C__RootZone === currentZone) { - A._rootScheduleMicrotask(_null, _null, B.C__RootZone, callback); - return; - } - A._rootScheduleMicrotask(_null, _null, currentZone, type$.void_Function._as(currentZone.bindCallbackGuarded$1(callback))); - }, StreamIterator_StreamIterator(stream, $T) { A.checkNotNullable(stream, "stream", type$.Object); return new A._StreamIterator($T._eval$1("_StreamIterator<0>")); @@ -3659,18 +3672,7 @@ this._box_0 = t0; this.$this = t1; }, - _Future__chainForeignFuture_closure: function _Future__chainForeignFuture_closure(t0) { - this.$this = t0; - }, - _Future__chainForeignFuture_closure0: function _Future__chainForeignFuture_closure0(t0) { - this.$this = t0; - }, - _Future__chainForeignFuture_closure1: function _Future__chainForeignFuture_closure1(t0, t1, t2) { - this.$this = t0; - this.e = t1; - this.s = t2; - }, - _Future__chainCoreFutureAsync_closure: function _Future__chainCoreFutureAsync_closure(t0, t1) { + _Future__chainCoreFuture_closure: function _Future__chainCoreFuture_closure(t0, t1) { this._box_0 = t0; this.target = t1; }, @@ -3678,18 +3680,21 @@ this.$this = t0; this.value = t1; }, - _Future__asyncCompleteError_closure: function _Future__asyncCompleteError_closure(t0, t1, t2) { + _Future__asyncCompleteErrorObject_closure: function _Future__asyncCompleteErrorObject_closure(t0, t1) { this.$this = t0; this.error = t1; - this.stackTrace = t2; }, _Future__propagateToListeners_handleWhenCompleteCallback: function _Future__propagateToListeners_handleWhenCompleteCallback(t0, t1, t2) { this._box_0 = t0; this._box_1 = t1; this.hasError = t2; }, - _Future__propagateToListeners_handleWhenCompleteCallback_closure: function _Future__propagateToListeners_handleWhenCompleteCallback_closure(t0) { - this.originalSource = t0; + _Future__propagateToListeners_handleWhenCompleteCallback_closure: function _Future__propagateToListeners_handleWhenCompleteCallback_closure(t0, t1) { + this.joinedResult = t0; + this.originalSource = t1; + }, + _Future__propagateToListeners_handleWhenCompleteCallback_closure0: function _Future__propagateToListeners_handleWhenCompleteCallback_closure0(t0) { + this.joinedResult = t0; }, _Future__propagateToListeners_handleValueCallback: function _Future__propagateToListeners_handleValueCallback(t0, t1) { this._box_0 = t0; @@ -3738,11 +3743,12 @@ return $K._eval$1("@<0>")._bind$1($V)._eval$1("LinkedHashMap<1,2>")._as(A.fillLiteralMap(keyValuePairs, new A.JsLinkedHashMap($K._eval$1("@<0>")._bind$1($V)._eval$1("JsLinkedHashMap<1,2>")))); }, MapBase_mapToString(m) { - var result, t1 = {}; + var result, t1; if (A.isToStringVisiting(m)) return "{...}"; result = new A.StringBuffer(""); try { + t1 = {}; B.JSArray_methods.add$1($.toStringVisiting, m); result._contents += "{"; t1.first = true; @@ -3761,16 +3767,16 @@ _IdentityHashMap: function _IdentityHashMap(t0) { var _ = this; _._collection$_length = 0; - _._keys = _._collection$_rest = _._nums = _._strings = null; + _._keys = _._collection$_rest = _._collection$_nums = _._collection$_strings = null; _.$ti = t0; }, _HashMapKeyIterable: function _HashMapKeyIterable(t0, t1) { - this._map = t0; + this._collection$_map = t0; this.$ti = t1; }, _HashMapKeyIterator: function _HashMapKeyIterator(t0, t1, t2) { var _ = this; - _._map = t0; + _._collection$_map = t0; _._keys = t1; _._offset = 0; _._collection$_current = null; @@ -3784,6 +3790,30 @@ this._box_0 = t0; this.result = t1; }, + _parseJson(source, reviver) { + var e, exception, t1, parsed = null; + try { + parsed = JSON.parse(source); + } catch (exception) { + e = A.unwrapException(exception); + t1 = A.FormatException$(String(e), null, null); + throw A.wrapException(t1); + } + t1 = A._convertJsonToDartLazy(parsed); + return t1; + }, + _convertJsonToDartLazy(object) { + var i; + if (object == null) + return null; + if (typeof object != "object") + return object; + if (!Array.isArray(object)) + return new A._JsonMap(object, Object.create(null)); + for (i = 0; i < object.length; ++i) + object[i] = A._convertJsonToDartLazy(object[i]); + return object; + }, _Utf8Decoder__makeNativeUint8List(codeUnits, start, end) { var bytes, t1, i, b, $length = end - start; @@ -3844,6 +3874,14 @@ return ""; } }, + _JsonMap: function _JsonMap(t0, t1) { + this._original = t0; + this._processed = t1; + this._data = null; + }, + _JsonMapKeyIterable: function _JsonMapKeyIterable(t0) { + this._parent = t0; + }, _Utf8Decoder__decoder_closure: function _Utf8Decoder__decoder_closure() { }, _Utf8Decoder__decoderNonfatal_closure: function _Utf8Decoder__decoderNonfatal_closure() { @@ -3858,6 +3896,11 @@ }, Encoding: function Encoding() { }, + JsonCodec: function JsonCodec() { + }, + JsonDecoder: function JsonDecoder(t0) { + this._reviver = t0; + }, Utf8Codec: function Utf8Codec() { }, Utf8Decoder: function Utf8Decoder(t0) { @@ -3875,12 +3918,11 @@ throw A.wrapException(A.FormatException$(source, null, null)); }, Error__throw(error, stackTrace) { - error = A.wrapException(error); + error = A.initializeExceptionWrapper(error, new Error()); if (error == null) error = type$.Object._as(error); error.stack = stackTrace.toString$0(0); throw error; - throw A.wrapException("unreachable"); }, List_List$filled($length, fill, growable, $E) { var i, @@ -3897,7 +3939,8 @@ B.JSArray_methods.add$1(list, $E._as(t1.get$current())); if (growable) return list; - return J.JSArray_markFixedList(list, $E); + list.$flags = 1; + return list; }, List_List$of(elements, growable, $E) { var t1 = A.List_List$_of(elements, $E); @@ -3914,8 +3957,7 @@ }, List_List$unmodifiable(elements, $E) { var result = A.List_List$from(elements, false, $E); - result.fixed$length = Array; - result.immutable$list = Array; + result.$flags = 3; return result; }, String_String$fromCharCodes(charCodes, start, end) { @@ -4423,8 +4465,8 @@ var t1, _i, segment; for (t1 = segments.length, _i = 0; _i < t1; ++_i) { segment = segments[_i]; - if (J.contains$1$asx(segment, "/")) { - t1 = A.UnsupportedError$("Illegal path character " + A.S(segment)); + if (B.JSString_methods.contains$1(segment, "/")) { + t1 = A.UnsupportedError$("Illegal path character " + segment); throw A.wrapException(t1); } } @@ -4505,49 +4547,40 @@ index += 3; sectionStart = index; isNormalized = true; - } else { - if (char < 127) { - t2 = char >>> 4; - if (!(t2 < 8)) - return A.ioore(B.List_piR, t2); - t2 = (B.List_piR[t2] & 1 << (char & 15)) !== 0; - } else - t2 = false; - if (t2) { - if (isNormalized && 65 <= char && 90 >= char) { - if (buffer == null) - buffer = new A.StringBuffer(""); - if (sectionStart < index) { - buffer._contents += B.JSString_methods.substring$2(host, sectionStart, index); - sectionStart = index; - } - isNormalized = false; + } else if (char < 127 && (string$.______.charCodeAt(char) & 1) !== 0) { + if (isNormalized && 65 <= char && 90 >= char) { + if (buffer == null) + buffer = new A.StringBuffer(""); + if (sectionStart < index) { + buffer._contents += B.JSString_methods.substring$2(host, sectionStart, index); + sectionStart = index; } - ++index; - } else { - sourceLength = 1; - if ((char & 64512) === 55296 && index + 1 < end) { - t2 = index + 1; - if (!(t2 < t1)) - return A.ioore(host, t2); - tail = host.charCodeAt(t2); - if ((tail & 64512) === 56320) { - char = (char & 1023) << 10 | tail & 1023 | 65536; - sourceLength = 2; - } + isNormalized = false; + } + ++index; + } else { + sourceLength = 1; + if ((char & 64512) === 55296 && index + 1 < end) { + t2 = index + 1; + if (!(t2 < t1)) + return A.ioore(host, t2); + tail = host.charCodeAt(t2); + if ((tail & 64512) === 56320) { + char = 65536 + ((char & 1023) << 10) + (tail & 1023); + sourceLength = 2; } - slice = B.JSString_methods.substring$2(host, sectionStart, index); - if (buffer == null) { - buffer = new A.StringBuffer(""); - t2 = buffer; - } else - t2 = buffer; - t2._contents += slice; - t3 = A._Uri__escapeChar(char); - t2._contents += t3; - index += sourceLength; - sectionStart = index; } + slice = B.JSString_methods.substring$2(host, sectionStart, index); + if (buffer == null) { + buffer = new A.StringBuffer(""); + t2 = buffer; + } else + t2 = buffer; + t2._contents += slice; + t3 = A._Uri__escapeChar(char); + t2._contents += t3; + index += sourceLength; + sectionStart = index; } } if (buffer == null) @@ -4560,7 +4593,8 @@ return t1.charCodeAt(0) == 0 ? t1 : t1; }, _Uri__normalizeRegName(host, start, end) { - var t1, index, sectionStart, buffer, isNormalized, char, replacement, t2, slice, t3, sourceLength, tail; + var t1, index, sectionStart, buffer, isNormalized, char, replacement, t2, slice, t3, sourceLength, tail, + _s128_ = string$.______; for (t1 = host.length, index = start, sectionStart = index, buffer = null, isNormalized = true; index < end;) { if (!(index >= 0 && index < t1)) return A.ioore(host, index); @@ -4589,62 +4623,44 @@ index += sourceLength; sectionStart = index; isNormalized = true; - } else { - if (char < 127) { - t2 = char >>> 4; - if (!(t2 < 8)) - return A.ioore(B.List_4AN, t2); - t2 = (B.List_4AN[t2] & 1 << (char & 15)) !== 0; - } else - t2 = false; - if (t2) { - if (isNormalized && 65 <= char && 90 >= char) { - if (buffer == null) - buffer = new A.StringBuffer(""); - if (sectionStart < index) { - buffer._contents += B.JSString_methods.substring$2(host, sectionStart, index); - sectionStart = index; - } - isNormalized = false; - } - ++index; - } else { - if (char <= 93) { - t2 = char >>> 4; - if (!(t2 < 8)) - return A.ioore(B.List_VOY, t2); - t2 = (B.List_VOY[t2] & 1 << (char & 15)) !== 0; - } else - t2 = false; - if (t2) - A._Uri__fail(host, index, "Invalid character"); - else { - sourceLength = 1; - if ((char & 64512) === 55296 && index + 1 < end) { - t2 = index + 1; - if (!(t2 < t1)) - return A.ioore(host, t2); - tail = host.charCodeAt(t2); - if ((tail & 64512) === 56320) { - char = (char & 1023) << 10 | tail & 1023 | 65536; - sourceLength = 2; - } - } - slice = B.JSString_methods.substring$2(host, sectionStart, index); - if (!isNormalized) - slice = slice.toLowerCase(); - if (buffer == null) { - buffer = new A.StringBuffer(""); - t2 = buffer; - } else - t2 = buffer; - t2._contents += slice; - t3 = A._Uri__escapeChar(char); - t2._contents += t3; - index += sourceLength; + } else if (char < 127 && (_s128_.charCodeAt(char) & 32) !== 0) { + if (isNormalized && 65 <= char && 90 >= char) { + if (buffer == null) + buffer = new A.StringBuffer(""); + if (sectionStart < index) { + buffer._contents += B.JSString_methods.substring$2(host, sectionStart, index); sectionStart = index; } + isNormalized = false; + } + ++index; + } else if (char <= 93 && (_s128_.charCodeAt(char) & 1024) !== 0) + A._Uri__fail(host, index, "Invalid character"); + else { + sourceLength = 1; + if ((char & 64512) === 55296 && index + 1 < end) { + t2 = index + 1; + if (!(t2 < t1)) + return A.ioore(host, t2); + tail = host.charCodeAt(t2); + if ((tail & 64512) === 56320) { + char = 65536 + ((char & 1023) << 10) + (tail & 1023); + sourceLength = 2; + } } + slice = B.JSString_methods.substring$2(host, sectionStart, index); + if (!isNormalized) + slice = slice.toLowerCase(); + if (buffer == null) { + buffer = new A.StringBuffer(""); + t2 = buffer; + } else + t2 = buffer; + t2._contents += slice; + t3 = A._Uri__escapeChar(char); + t2._contents += t3; + index += sourceLength; + sectionStart = index; } } if (buffer == null) @@ -4659,7 +4675,7 @@ return t1.charCodeAt(0) == 0 ? t1 : t1; }, _Uri__makeScheme(scheme, start, end) { - var t1, i, containsUpperCase, codeUnit, t2; + var t1, i, containsUpperCase, codeUnit; if (start === end) return ""; t1 = scheme.length; @@ -4671,14 +4687,7 @@ if (!(i < t1)) return A.ioore(scheme, i); codeUnit = scheme.charCodeAt(i); - if (codeUnit < 128) { - t2 = codeUnit >>> 4; - if (!(t2 < 8)) - return A.ioore(B.List_GVy, t2); - t2 = (B.List_GVy[t2] & 1 << (codeUnit & 15)) !== 0; - } else - t2 = false; - if (!t2) + if (!(codeUnit < 128 && (string$.______.charCodeAt(codeUnit) & 8) !== 0)) A._Uri__fail(scheme, i, "Illegal scheme character"); if (65 <= codeUnit && codeUnit <= 90) containsUpperCase = true; @@ -4700,7 +4709,7 @@ _Uri__makeUserInfo(userInfo, start, end) { if (userInfo == null) return ""; - return A._Uri__normalizeOrSubstring(userInfo, start, end, B.List_2jN, false, false); + return A._Uri__normalizeOrSubstring(userInfo, start, end, 16, false, false); }, _Uri__makePath(path, start, end, pathSegments, scheme, hasAuthority) { var result, @@ -4709,7 +4718,7 @@ if (path == null) return isFile ? "/" : ""; else - result = A._Uri__normalizeOrSubstring(path, start, end, B.List_M2I, true, true); + result = A._Uri__normalizeOrSubstring(path, start, end, 128, true, true); if (result.length === 0) { if (isFile) return "/"; @@ -4725,16 +4734,17 @@ }, _Uri__makeQuery(query, start, end, queryParameters) { if (query != null) - return A._Uri__normalizeOrSubstring(query, start, end, B.List_42A, true, false); + return A._Uri__normalizeOrSubstring(query, start, end, 256, true, false); return null; }, _Uri__makeFragment(fragment, start, end) { if (fragment == null) return null; - return A._Uri__normalizeOrSubstring(fragment, start, end, B.List_42A, true, false); + return A._Uri__normalizeOrSubstring(fragment, start, end, 256, true, false); }, _Uri__normalizeEscape(source, index, lowerCase) { var t3, firstDigit, secondDigit, firstDigitValue, secondDigitValue, value, + _s128_ = string$.______, t1 = index + 2, t2 = source.length; if (t1 >= t2) @@ -4752,10 +4762,9 @@ return "%"; value = firstDigitValue * 16 + secondDigitValue; if (value < 127) { - t1 = B.JSInt_methods._shrOtherPositive$1(value, 4); - if (!(t1 < 8)) - return A.ioore(B.List_piR, t1); - t1 = (B.List_piR[t1] & 1 << (value & 15)) !== 0; + if (!(value >= 0)) + return A.ioore(_s128_, value); + t1 = (_s128_.charCodeAt(value) & 1) !== 0; } else t1 = false; if (t1) @@ -4767,7 +4776,7 @@ _Uri__escapeChar(char) { var codeUnits, t1, flag, encodedBytes, index, byte, t2, t3, _s16_ = "0123456789ABCDEF"; - if (char < 128) { + if (char <= 127) { codeUnits = new Uint8Array(3); codeUnits[0] = 37; t1 = char >>> 4; @@ -4811,24 +4820,18 @@ } return A.String_String$fromCharCodes(codeUnits, 0, null); }, - _Uri__normalizeOrSubstring(component, start, end, charTable, escapeDelimiters, replaceBackslash) { - var t1 = A._Uri__normalize(component, start, end, charTable, escapeDelimiters, replaceBackslash); + _Uri__normalizeOrSubstring(component, start, end, charMask, escapeDelimiters, replaceBackslash) { + var t1 = A._Uri__normalize(component, start, end, charMask, escapeDelimiters, replaceBackslash); return t1 == null ? B.JSString_methods.substring$2(component, start, end) : t1; }, - _Uri__normalize(component, start, end, charTable, escapeDelimiters, replaceBackslash) { - var t1, t2, index, sectionStart, buffer, char, t3, sourceLength, replacement, tail, t4, _null = null; + _Uri__normalize(component, start, end, charMask, escapeDelimiters, replaceBackslash) { + var t1, t2, index, sectionStart, buffer, char, sourceLength, replacement, t3, tail, _null = null, + _s128_ = string$.______; for (t1 = !escapeDelimiters, t2 = component.length, index = start, sectionStart = index, buffer = _null; index < end;) { if (!(index >= 0 && index < t2)) return A.ioore(component, index); char = component.charCodeAt(index); - if (char < 127) { - t3 = char >>> 4; - if (!(t3 < 8)) - return A.ioore(charTable, t3); - t3 = (charTable[t3] & 1 << (char & 15)) !== 0; - } else - t3 = false; - if (t3) + if (char < 127 && (_s128_.charCodeAt(char) & charMask) !== 0) ++index; else { sourceLength = 1; @@ -4844,42 +4847,31 @@ sourceLength = 3; } else if (char === 92 && replaceBackslash) replacement = "/"; - else { - t3 = false; - if (t1) - if (char <= 93) { - t3 = char >>> 4; - if (!(t3 < 8)) - return A.ioore(B.List_VOY, t3); - t3 = (B.List_VOY[t3] & 1 << (char & 15)) !== 0; - } - if (t3) { - A._Uri__fail(component, index, "Invalid character"); - sourceLength = _null; - replacement = sourceLength; - } else { - if ((char & 64512) === 55296) { - t3 = index + 1; - if (t3 < end) { - if (!(t3 < t2)) - return A.ioore(component, t3); - tail = component.charCodeAt(t3); - if ((tail & 64512) === 56320) { - char = (char & 1023) << 10 | tail & 1023 | 65536; - sourceLength = 2; - } + else if (t1 && char <= 93 && (_s128_.charCodeAt(char) & 1024) !== 0) { + A._Uri__fail(component, index, "Invalid character"); + sourceLength = _null; + replacement = sourceLength; + } else { + if ((char & 64512) === 55296) { + t3 = index + 1; + if (t3 < end) { + if (!(t3 < t2)) + return A.ioore(component, t3); + tail = component.charCodeAt(t3); + if ((tail & 64512) === 56320) { + char = 65536 + ((char & 1023) << 10) + (tail & 1023); + sourceLength = 2; } } - replacement = A._Uri__escapeChar(char); } + replacement = A._Uri__escapeChar(char); } if (buffer == null) { buffer = new A.StringBuffer(""); t3 = buffer; } else t3 = buffer; - t4 = t3._contents += B.JSString_methods.substring$2(component, sectionStart, index); - t3._contents = t4 + A.S(replacement); + t3._contents = (t3._contents += B.JSString_methods.substring$2(component, sectionStart, index)) + A.S(replacement); if (typeof sourceLength !== "number") return A.iae(sourceLength); index += sourceLength; @@ -4907,7 +4899,7 @@ output = A._setArrayType([], type$.JSArray_String); for (t1 = path.split("/"), t2 = t1.length, appendSlash = false, _i = 0; _i < t2; ++_i) { segment = t1[_i]; - if (J.$eq$(segment, "..")) { + if (segment === "..") { t3 = output.length; if (t3 !== 0) { if (0 >= t3) @@ -4971,6 +4963,7 @@ }, _Uri__escapeScheme(path) { var i, char, t2, + _s128_ = string$.______, t1 = path.length; if (t1 >= 2 && A._Uri__isAlphabeticCharacter(path.charCodeAt(0))) for (i = 1; i < t1; ++i) { @@ -4978,10 +4971,9 @@ if (char === 58) return B.JSString_methods.substring$2(path, 0, i) + "%3A" + B.JSString_methods.substring$1(path, i + 1); if (char <= 127) { - t2 = char >>> 4; - if (!(t2 < 8)) - return A.ioore(B.List_GVy, t2); - t2 = (B.List_GVy[t2] & 1 << (char & 15)) === 0; + if (!(char < 128)) + return A.ioore(_s128_, char); + t2 = (_s128_.charCodeAt(char) & 8) === 0; } else t2 = true; if (t2) @@ -5104,167 +5096,25 @@ if ((indices.length & 1) === 1) text = B.C_Base64Codec.normalize$3(text, t2, t1); else { - data = A._Uri__normalize(text, t2, t1, B.List_42A, true, false); + data = A._Uri__normalize(text, t2, t1, 256, true, false); if (data != null) text = B.JSString_methods.replaceRange$3(text, t2, t1, data); } return new A.UriData(text, indices, sourceUri); }, - _createTables() { - var _i, t1, t2, t3, b, - _s77_ = "0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz-._~!$&'()*+,;=", - _s1_ = ".", _s1_0 = ":", _s1_1 = "/", _s1_2 = "\\", _s1_3 = "?", _s1_4 = "#", _s2_ = "/\\", - tables = A._setArrayType(new Array(22), type$.JSArray_Uint8List); - for (_i = 0; _i < 22; ++_i) - tables[_i] = new Uint8Array(96); - t1 = new A._createTables_build(tables); - t2 = new A._createTables_setChars(); - t3 = new A._createTables_setRange(); - b = t1.call$2(0, 225); - t2.call$3(b, _s77_, 1); - t2.call$3(b, _s1_, 14); - t2.call$3(b, _s1_0, 34); - t2.call$3(b, _s1_1, 3); - t2.call$3(b, _s1_2, 227); - t2.call$3(b, _s1_3, 172); - t2.call$3(b, _s1_4, 205); - b = t1.call$2(14, 225); - t2.call$3(b, _s77_, 1); - t2.call$3(b, _s1_, 15); - t2.call$3(b, _s1_0, 34); - t2.call$3(b, _s2_, 234); - t2.call$3(b, _s1_3, 172); - t2.call$3(b, _s1_4, 205); - b = t1.call$2(15, 225); - t2.call$3(b, _s77_, 1); - t2.call$3(b, "%", 225); - t2.call$3(b, _s1_0, 34); - t2.call$3(b, _s1_1, 9); - t2.call$3(b, _s1_2, 233); - t2.call$3(b, _s1_3, 172); - t2.call$3(b, _s1_4, 205); - b = t1.call$2(1, 225); - t2.call$3(b, _s77_, 1); - t2.call$3(b, _s1_0, 34); - t2.call$3(b, _s1_1, 10); - t2.call$3(b, _s1_2, 234); - t2.call$3(b, _s1_3, 172); - t2.call$3(b, _s1_4, 205); - b = t1.call$2(2, 235); - t2.call$3(b, _s77_, 139); - t2.call$3(b, _s1_1, 131); - t2.call$3(b, _s1_2, 131); - t2.call$3(b, _s1_, 146); - t2.call$3(b, _s1_3, 172); - t2.call$3(b, _s1_4, 205); - b = t1.call$2(3, 235); - t2.call$3(b, _s77_, 11); - t2.call$3(b, _s1_1, 68); - t2.call$3(b, _s1_2, 68); - t2.call$3(b, _s1_, 18); - t2.call$3(b, _s1_3, 172); - t2.call$3(b, _s1_4, 205); - b = t1.call$2(4, 229); - t2.call$3(b, _s77_, 5); - t3.call$3(b, "AZ", 229); - t2.call$3(b, _s1_0, 102); - t2.call$3(b, "@", 68); - t2.call$3(b, "[", 232); - t2.call$3(b, _s1_1, 138); - t2.call$3(b, _s1_2, 138); - t2.call$3(b, _s1_3, 172); - t2.call$3(b, _s1_4, 205); - b = t1.call$2(5, 229); - t2.call$3(b, _s77_, 5); - t3.call$3(b, "AZ", 229); - t2.call$3(b, _s1_0, 102); - t2.call$3(b, "@", 68); - t2.call$3(b, _s1_1, 138); - t2.call$3(b, _s1_2, 138); - t2.call$3(b, _s1_3, 172); - t2.call$3(b, _s1_4, 205); - b = t1.call$2(6, 231); - t3.call$3(b, "19", 7); - t2.call$3(b, "@", 68); - t2.call$3(b, _s1_1, 138); - t2.call$3(b, _s1_2, 138); - t2.call$3(b, _s1_3, 172); - t2.call$3(b, _s1_4, 205); - b = t1.call$2(7, 231); - t3.call$3(b, "09", 7); - t2.call$3(b, "@", 68); - t2.call$3(b, _s1_1, 138); - t2.call$3(b, _s1_2, 138); - t2.call$3(b, _s1_3, 172); - t2.call$3(b, _s1_4, 205); - t2.call$3(t1.call$2(8, 8), "]", 5); - b = t1.call$2(9, 235); - t2.call$3(b, _s77_, 11); - t2.call$3(b, _s1_, 16); - t2.call$3(b, _s2_, 234); - t2.call$3(b, _s1_3, 172); - t2.call$3(b, _s1_4, 205); - b = t1.call$2(16, 235); - t2.call$3(b, _s77_, 11); - t2.call$3(b, _s1_, 17); - t2.call$3(b, _s2_, 234); - t2.call$3(b, _s1_3, 172); - t2.call$3(b, _s1_4, 205); - b = t1.call$2(17, 235); - t2.call$3(b, _s77_, 11); - t2.call$3(b, _s1_1, 9); - t2.call$3(b, _s1_2, 233); - t2.call$3(b, _s1_3, 172); - t2.call$3(b, _s1_4, 205); - b = t1.call$2(10, 235); - t2.call$3(b, _s77_, 11); - t2.call$3(b, _s1_, 18); - t2.call$3(b, _s1_1, 10); - t2.call$3(b, _s1_2, 234); - t2.call$3(b, _s1_3, 172); - t2.call$3(b, _s1_4, 205); - b = t1.call$2(18, 235); - t2.call$3(b, _s77_, 11); - t2.call$3(b, _s1_, 19); - t2.call$3(b, _s2_, 234); - t2.call$3(b, _s1_3, 172); - t2.call$3(b, _s1_4, 205); - b = t1.call$2(19, 235); - t2.call$3(b, _s77_, 11); - t2.call$3(b, _s2_, 234); - t2.call$3(b, _s1_3, 172); - t2.call$3(b, _s1_4, 205); - b = t1.call$2(11, 235); - t2.call$3(b, _s77_, 11); - t2.call$3(b, _s1_1, 10); - t2.call$3(b, _s1_2, 234); - t2.call$3(b, _s1_3, 172); - t2.call$3(b, _s1_4, 205); - b = t1.call$2(12, 236); - t2.call$3(b, _s77_, 12); - t2.call$3(b, _s1_3, 12); - t2.call$3(b, _s1_4, 205); - b = t1.call$2(13, 237); - t2.call$3(b, _s77_, 13); - t2.call$3(b, _s1_3, 13); - t3.call$3(t1.call$2(20, 245), "az", 21); - b = t1.call$2(21, 245); - t3.call$3(b, "az", 21); - t3.call$3(b, "09", 21); - t2.call$3(b, "+-.", 21); - return tables; - }, _scan(uri, start, end, state, indices) { - var t1, i, table, char, transition, - tables = $.$get$_scannerTables(); + var t1, i, char, t2, transition, + _s2112_ = '\xe1\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\xe1\xe1\xe1\x01\xe1\xe1\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\xe1\xe3\xe1\xe1\x01\xe1\x01\xe1\xcd\x01\xe1\x01\x01\x01\x01\x01\x01\x01\x01\x0e\x03\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01"\x01\xe1\x01\xe1\xac\xe1\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\xe1\xe1\xe1\x01\xe1\xe1\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\xe1\xea\xe1\xe1\x01\xe1\x01\xe1\xcd\x01\xe1\x01\x01\x01\x01\x01\x01\x01\x01\x01\n\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01"\x01\xe1\x01\xe1\xac\xeb\x8b\x8b\x8b\x8b\x8b\x8b\x8b\x8b\x8b\x8b\x8b\x8b\x8b\x8b\x8b\x8b\x8b\x8b\x8b\x8b\x8b\x8b\x8b\x8b\x8b\x8b\xeb\xeb\xeb\x8b\xeb\xeb\x8b\x8b\x8b\x8b\x8b\x8b\x8b\x8b\x8b\x8b\x8b\x8b\x8b\x8b\x8b\x8b\x8b\x8b\x8b\x8b\x8b\x8b\x8b\x8b\x8b\x8b\xeb\x83\xeb\xeb\x8b\xeb\x8b\xeb\xcd\x8b\xeb\x8b\x8b\x8b\x8b\x8b\x8b\x8b\x8b\x92\x83\x8b\x8b\x8b\x8b\x8b\x8b\x8b\x8b\x8b\x8b\xeb\x8b\xeb\x8b\xeb\xac\xeb\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\xeb\xeb\xeb\v\xeb\xeb\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\xebD\xeb\xeb\v\xeb\v\xeb\xcd\v\xeb\v\v\v\v\v\v\v\v\x12D\v\v\v\v\v\v\v\v\v\v\xeb\v\xeb\v\xeb\xac\xe5\x05\x05\x05\x05\x05\x05\x05\x05\x05\x05\x05\x05\x05\x05\x05\x05\x05\x05\x05\x05\x05\x05\x05\x05\x05\x05\xe5\xe5\xe5\x05\xe5D\xe5\xe5\xe5\xe5\xe5\xe5\xe5\xe5\xe5\xe5\xe5\xe5\xe5\xe5\xe5\xe5\xe5\xe5\xe5\xe5\xe5\xe5\xe5\xe5\xe5\xe5\xe8\x8a\xe5\xe5\x05\xe5\x05\xe5\xcd\x05\xe5\x05\x05\x05\x05\x05\x05\x05\x05\x05\x8a\x05\x05\x05\x05\x05\x05\x05\x05\x05\x05f\x05\xe5\x05\xe5\xac\xe5\x05\x05\x05\x05\x05\x05\x05\x05\x05\x05\x05\x05\x05\x05\x05\x05\x05\x05\x05\x05\x05\x05\x05\x05\x05\x05\xe5\xe5\xe5\x05\xe5D\xe5\xe5\xe5\xe5\xe5\xe5\xe5\xe5\xe5\xe5\xe5\xe5\xe5\xe5\xe5\xe5\xe5\xe5\xe5\xe5\xe5\xe5\xe5\xe5\xe5\xe5\xe5\x8a\xe5\xe5\x05\xe5\x05\xe5\xcd\x05\xe5\x05\x05\x05\x05\x05\x05\x05\x05\x05\x8a\x05\x05\x05\x05\x05\x05\x05\x05\x05\x05f\x05\xe5\x05\xe5\xac\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7D\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\x8a\xe7\xe7\xe7\xe7\xe7\xe7\xcd\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\x8a\xe7\x07\x07\x07\x07\x07\x07\x07\x07\x07\xe7\xe7\xe7\xe7\xe7\xac\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7D\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\x8a\xe7\xe7\xe7\xe7\xe7\xe7\xcd\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\xe7\x8a\x07\x07\x07\x07\x07\x07\x07\x07\x07\x07\xe7\xe7\xe7\xe7\xe7\xac\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\x05\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\xeb\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\xeb\xeb\xeb\v\xeb\xeb\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\xeb\xea\xeb\xeb\v\xeb\v\xeb\xcd\v\xeb\v\v\v\v\v\v\v\v\x10\xea\v\v\v\v\v\v\v\v\v\v\xeb\v\xeb\v\xeb\xac\xeb\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\xeb\xeb\xeb\v\xeb\xeb\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\xeb\xea\xeb\xeb\v\xeb\v\xeb\xcd\v\xeb\v\v\v\v\v\v\v\v\x12\n\v\v\v\v\v\v\v\v\v\v\xeb\v\xeb\v\xeb\xac\xeb\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\xeb\xeb\xeb\v\xeb\xeb\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\xeb\xea\xeb\xeb\v\xeb\v\xeb\xcd\v\xeb\v\v\v\v\v\v\v\v\v\n\v\v\v\v\v\v\v\v\v\v\xeb\v\xeb\v\xeb\xac\xec\f\f\f\f\f\f\f\f\f\f\f\f\f\f\f\f\f\f\f\f\f\f\f\f\f\f\xec\xec\xec\f\xec\xec\f\f\f\f\f\f\f\f\f\f\f\f\f\f\f\f\f\f\f\f\f\f\f\f\f\f\xec\xec\xec\xec\f\xec\f\xec\xcd\f\xec\f\f\f\f\f\f\f\f\f\xec\f\f\f\f\f\f\f\f\f\f\xec\f\xec\f\xec\f\xed\r\r\r\r\r\r\r\r\r\r\r\r\r\r\r\r\r\r\r\r\r\r\r\r\r\r\xed\xed\xed\r\xed\xed\r\r\r\r\r\r\r\r\r\r\r\r\r\r\r\r\r\r\r\r\r\r\r\r\r\r\xed\xed\xed\xed\r\xed\r\xed\xed\r\xed\r\r\r\r\r\r\r\r\r\xed\r\r\r\r\r\r\r\r\r\r\xed\r\xed\r\xed\r\xe1\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\xe1\xe1\xe1\x01\xe1\xe1\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\xe1\xea\xe1\xe1\x01\xe1\x01\xe1\xcd\x01\xe1\x01\x01\x01\x01\x01\x01\x01\x01\x0f\xea\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01"\x01\xe1\x01\xe1\xac\xe1\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\xe1\xe1\xe1\x01\xe1\xe1\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01\xe1\xe9\xe1\xe1\x01\xe1\x01\xe1\xcd\x01\xe1\x01\x01\x01\x01\x01\x01\x01\x01\x01\t\x01\x01\x01\x01\x01\x01\x01\x01\x01\x01"\x01\xe1\x01\xe1\xac\xeb\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\xeb\xeb\xeb\v\xeb\xeb\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\xeb\xea\xeb\xeb\v\xeb\v\xeb\xcd\v\xeb\v\v\v\v\v\v\v\v\x11\xea\v\v\v\v\v\v\v\v\v\v\xeb\v\xeb\v\xeb\xac\xeb\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\xeb\xeb\xeb\v\xeb\xeb\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\xeb\xe9\xeb\xeb\v\xeb\v\xeb\xcd\v\xeb\v\v\v\v\v\v\v\v\v\t\v\v\v\v\v\v\v\v\v\v\xeb\v\xeb\v\xeb\xac\xeb\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\xeb\xeb\xeb\v\xeb\xeb\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\xeb\xea\xeb\xeb\v\xeb\v\xeb\xcd\v\xeb\v\v\v\v\v\v\v\v\x13\xea\v\v\v\v\v\v\v\v\v\v\xeb\v\xeb\v\xeb\xac\xeb\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\xeb\xeb\xeb\v\xeb\xeb\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\v\xeb\xea\xeb\xeb\v\xeb\v\xeb\xcd\v\xeb\v\v\v\v\v\v\v\v\v\xea\v\v\v\v\v\v\v\v\v\v\xeb\v\xeb\v\xeb\xac\xf5\x15\x15\x15\x15\x15\x15\x15\x15\x15\x15\x15\x15\x15\x15\x15\x15\x15\x15\x15\x15\x15\x15\x15\x15\x15\x15\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\x15\x15\x15\x15\x15\x15\x15\x15\x15\x15\x15\x15\x15\x15\x15\x15\x15\x15\x15\x15\x15\x15\x15\x15\x15\x15\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\xf5\x15\xf5\x15\x15\xf5\x15\x15\x15\x15\x15\x15\x15\x15\x15\x15\xf5\xf5\xf5\xf5\xf5\xf5'; for (t1 = uri.length, i = start; i < end; ++i) { - if (!(state >= 0 && state < tables.length)) - return A.ioore(tables, state); - table = tables[state]; if (!(i < t1)) return A.ioore(uri, i); char = uri.charCodeAt(i) ^ 96; - transition = table[char > 95 ? 31 : char]; + if (char > 95) + char = 31; + t2 = state * 96 + char; + if (!(t2 < 2112)) + return A.ioore(_s2112_, t2); + transition = _s2112_.charCodeAt(t2); state = transition & 31; B.JSArray_methods.$indexSet(indices, transition >>> 5, i); } @@ -5362,13 +5212,6 @@ this._separatorIndices = t1; this._uriCache = t2; }, - _createTables_build: function _createTables_build(t0) { - this.tables = t0; - }, - _createTables_setChars: function _createTables_setChars() { - }, - _createTables_setRange: function _createTables_setRange() { - }, _SimpleUri: function _SimpleUri(t0, t1, t2, t3, t4, t5, t6, t7) { var _ = this; _._uri = t0; @@ -5632,10 +5475,10 @@ main$body(args) { var $async$goto = 0, $async$completer = A._makeAsyncAwaitCompleter(type$.void), - $async$handler = 1, $async$currentError, e, exception, $async$exception; + $async$handler = 1, $async$errorStack = [], e, exception, $async$exception; var $async$main = A._wrapJsFunctionForAsync(function($async$errorCode, $async$result) { if ($async$errorCode === 1) { - $async$currentError = $async$result; + $async$errorStack.push($async$result); $async$goto = $async$handler; } while (true) @@ -5654,7 +5497,7 @@ case 3: // catch $async$handler = 2; - $async$exception = $async$currentError; + $async$exception = $async$errorStack.pop(); e = A.unwrapException($async$exception); A._fail(A.S(e)); // goto after finally @@ -5671,7 +5514,7 @@ return A._asyncReturn(null, $async$completer); case 1: // rethrow - return A._asyncRethrow($async$currentError, $async$completer); + return A._asyncRethrow($async$errorStack.at(-1), $async$completer); } }); return A._asyncStartSync($async$main, $async$completer); @@ -5679,7 +5522,7 @@ _impl(args) { var $async$goto = 0, $async$completer = A._makeAsyncAwaitCompleter(type$.void), - $async$returnValue, flavor, raw, os, architecture, channel, version, url, toolName, sdkPath, t3, archivePath, extractedFolder, t4, pubCache, versionFilePath, t1, t2, sdk, $async$temp1; + $async$returnValue, flavor, raw, os, architecture, channel, version, url, toolName, sdkPath, t3, archivePath, extractedFolder, pubCache, versionFilePath, t1, t2, sdk, $async$temp1; var $async$_impl = A._wrapJsFunctionForAsync(function($async$errorCode, $async$result) { if ($async$errorCode === 1) return A._asyncRethrow($async$result, $async$completer); @@ -5785,7 +5628,7 @@ case 16: // else t2._as(t1.core).info(url + " ..."); - t3 = A._asStringQ(t2._as(t2._as(t1.process).env).RUNNER_TEMP); + t3 = A.Process_env(t2._as(t1.process), "RUNNER_TEMP"); t3.toString; archivePath = A.join(t3, A.ParsedPath_ParsedPath$parse(url, $.$get$url().style).get$basename()); t3 = type$.String; @@ -5807,10 +5650,9 @@ case 15: // join t3 = t2._as(t1.process); - t4 = os === "windows" ? "USERPROFILE" : "HOME"; - t4 = A._asStringQ(t2._as(t3.env)[t4]); - t4.toString; - pubCache = A.join(t4, ".pub-cache"); + t3 = A.Process_env(t3, os === "windows" ? "USERPROFILE" : "HOME"); + t3.toString; + pubCache = A.join(t3, ".pub-cache"); t2._as(t1.core).exportVariable("DART_HOME", sdkPath); t2._as(t1.core).addPath(A.join(sdkPath, "bin")); t2._as(t1.core).exportVariable("PUB_CACHE", pubCache); @@ -5819,11 +5661,11 @@ return A._asyncAwait(A.createPubOIDCToken(), $async$_impl); case 20: // returning from await. - t4 = t2._as(t1.core); + t3 = t2._as(t1.core); versionFilePath = A.join(sdkPath, "version"); - t4.setOutput("dart-version", B.JSString_methods.trim$0(A._asString(t2._as(t1.fs).readFileSync(versionFilePath, "utf8")))); + t3.setOutput("dart-version", B.JSString_methods.trim$0(A._asString(t2._as(t1.fs).readFileSync(versionFilePath, "utf8")))); $async$goto = 21; - return A._asyncAwait(A.promiseToFuture(t2._as(t2._as(t1.exec).exec("dart", A._setArrayType(["--version"], type$.JSArray_String))), type$.void), $async$_impl); + return A._asyncAwait(A.promiseToFuture(t2._as(t2._as(t1.exec).exec("dart", A._setArrayType(["--version"], type$.JSArray_String))), type$.nullable_Object), $async$_impl); case 21: // returning from await. case 1: @@ -5853,7 +5695,7 @@ createPubOIDCToken() { var $async$goto = 0, $async$completer = A._makeAsyncAwaitCompleter(type$.void), - $async$returnValue, token, t1, t2, tokenRequestUrl, tokenRequestToken; + $async$returnValue, t3, t1, t2, tokenRequestUrl, tokenRequestToken; var $async$createPubOIDCToken = A._wrapJsFunctionForAsync(function($async$errorCode, $async$result) { if ($async$errorCode === 1) return A._asyncRethrow($async$result, $async$completer); @@ -5863,8 +5705,8 @@ // Function start t1 = self; t2 = type$.JSObject; - tokenRequestUrl = A._asStringQ(t2._as(t2._as(t1.process).env).ACTIONS_ID_TOKEN_REQUEST_URL); - tokenRequestToken = A._asStringQ(t2._as(t2._as(t1.process).env).ACTIONS_ID_TOKEN_REQUEST_TOKEN); + tokenRequestUrl = A.Process_env(t2._as(t1.process), "ACTIONS_ID_TOKEN_REQUEST_URL"); + tokenRequestToken = A.Process_env(t2._as(t1.process), "ACTIONS_ID_TOKEN_REQUEST_TOKEN"); if (tokenRequestUrl == null || tokenRequestToken == null) { // goto return $async$goto = 1; @@ -5874,10 +5716,10 @@ return A._asyncAwait(A.promiseToFuture(t2._as(t2._as(t1.core).getIDToken("https://pub.dev")), type$.String), $async$createPubOIDCToken); case 3: // returning from await. - token = $async$result; - t2._as(t1.core).exportVariable("PUB_TOKEN", token); + t3 = $async$result; + t2._as(t1.core).exportVariable("PUB_TOKEN", t3); $async$goto = 4; - return A._asyncAwait(A.promiseToFuture(t2._as(t2._as(t1.exec).exec("dart", A._setArrayType(["pub", "token", "add", "https://pub.dev", "--env-var", "PUB_TOKEN"], type$.JSArray_String))), type$.void), $async$createPubOIDCToken); + return A._asyncAwait(A.promiseToFuture(t2._as(t2._as(t1.exec).exec("dart", A._setArrayType(["pub", "token", "add", "https://pub.dev", "--env-var", "PUB_TOKEN"], type$.JSArray_String))), type$.nullable_Object), $async$createPubOIDCToken); case 4: // returning from await. case 1: @@ -5890,7 +5732,7 @@ latestPublishedVersion(channel, flavor) { var $async$goto = 0, $async$completer = A._makeAsyncAwaitCompleter(type$.String), - $async$returnValue, t1, $async$temp1, $async$temp2; + $async$returnValue, t1, t2, json, $async$temp1, $async$temp2, $async$temp3, $async$temp4; var $async$latestPublishedVersion = A._wrapJsFunctionForAsync(function($async$errorCode, $async$result) { if ($async$errorCode === 1) return A._asyncRethrow($async$result, $async$completer); @@ -5898,14 +5740,22 @@ switch ($async$goto) { case 0: // Function start - t1 = type$.JSObject; - $async$temp1 = type$.FutureOr_String; - $async$temp2 = t1; + t1 = type$.String; + t2 = type$.JSObject; + $async$temp1 = type$.Map_dynamic_dynamic; + $async$temp2 = B.C_JsonCodec; + $async$temp3 = A; + $async$temp4 = t2; + $async$goto = 4; + return A._asyncAwait(A.promiseToFuture(t2._as(t2._as(new self.HttpClient("setup-dart", A._setArrayType([], type$.JSArray_Object), type$.nullable_JSObject._as(A.jsify(A.LinkedHashMap_LinkedHashMap$_literal(["allowRedirects", true, "maxRedirects", 3, "allowRetries", true, "maxRetries", 3], t1, type$.Object))))).get(string$.https_ + channel + "/" + flavor + "/latest/VERSION")), t2), $async$latestPublishedVersion); + case 4: + // returning from await. $async$goto = 3; - return A._asyncAwait(A.promiseToFuture(t1._as(t1._as(new self.HttpClient("setup-dart", A._setArrayType([], type$.JSArray_Object), type$.nullable_JSObject._as(A.jsify(A.LinkedHashMap_LinkedHashMap$_literal(["allowRedirects", true, "maxRedirects", 3, "allowRetries", true, "maxRetries", 3], type$.String, type$.Object))))).getJson(string$.https_ + channel + "/" + flavor + "/latest/VERSION")), t1), $async$latestPublishedVersion); + return A._asyncAwait($async$temp3.promiseToFuture($async$temp4._as($async$result.readBody()), t1), $async$latestPublishedVersion); case 3: // returning from await. - $async$returnValue = $async$temp1._as($async$temp2._as($async$result.result).version); + json = $async$temp1._as($async$temp2.decode$2$reviver($async$result, null)).cast$2$0(0, t1, type$.nullable_Object); + $async$returnValue = A._asString(json.$ti._eval$1("4?")._as(json._source.$index(0, "version"))); // goto return $async$goto = 1; break; @@ -5919,7 +5769,7 @@ findLatestSdkForRelease(sdkRelease) { var $async$goto = 0, $async$completer = A._makeAsyncAwaitCompleter(type$.String), - $async$returnValue, versions, semvers, t1, t2, paths, $async$temp1, $async$temp2, $async$temp3; + $async$returnValue, versions, semvers, t1, t2, json, paths, $async$temp1, $async$temp2, $async$temp3, $async$temp4; var $async$findLatestSdkForRelease = A._wrapJsFunctionForAsync(function($async$errorCode, $async$result) { if ($async$errorCode === 1) return A._asyncRethrow($async$result, $async$completer); @@ -5929,14 +5779,20 @@ // Function start t1 = type$.String; t2 = type$.JSObject; - $async$temp1 = J; - $async$temp2 = type$.List_dynamic; - $async$temp3 = t2; + $async$temp1 = type$.Map_dynamic_dynamic; + $async$temp2 = B.C_JsonCodec; + $async$temp3 = A; + $async$temp4 = t2; + $async$goto = 4; + return A._asyncAwait(A.promiseToFuture(t2._as(t2._as(new self.HttpClient("setup-dart", A._setArrayType([], type$.JSArray_Object), type$.nullable_JSObject._as(A.jsify(A.LinkedHashMap_LinkedHashMap$_literal(["allowRedirects", true, "maxRedirects", 3, "allowRetries", true, "maxRetries", 3], t1, type$.Object))))).get("https://storage.googleapis.com/storage/v1/b/dart-archive/o?prefix=" + ("channels/stable/release/" + sdkRelease + ".") + "&delimiter=/")), t2), $async$findLatestSdkForRelease); + case 4: + // returning from await. $async$goto = 3; - return A._asyncAwait(A.promiseToFuture(t2._as(t2._as(new self.HttpClient("setup-dart", A._setArrayType([], type$.JSArray_Object), type$.nullable_JSObject._as(A.jsify(A.LinkedHashMap_LinkedHashMap$_literal(["allowRedirects", true, "maxRedirects", 3, "allowRetries", true, "maxRetries", 3], t1, type$.Object))))).getJson("https://storage.googleapis.com/storage/v1/b/dart-archive/o?prefix=" + ("channels/stable/release/" + sdkRelease + ".") + "&delimiter=/")), t2), $async$findLatestSdkForRelease); + return A._asyncAwait($async$temp3.promiseToFuture($async$temp4._as($async$result.readBody()), t1), $async$findLatestSdkForRelease); case 3: // returning from await. - paths = $async$temp1.cast$1$0$ax($async$temp2._as($async$temp3._as($async$result.result).prefixes), t1); + json = $async$temp1._as($async$temp2.decode$2$reviver($async$result, null)).cast$2$0(0, t1, type$.nullable_Object); + paths = J.cast$1$0$ax(type$.List_dynamic._as(json.$ti._eval$1("4?")._as(json._source.$index(0, "prefixes"))), t1); t1 = paths.$ti; t2 = t1._eval$1("MappedListIterable"); versions = A.List_List$of(new A.MappedListIterable(paths, t1._eval$1("String(ListBase.E)")._as(new A.findLatestSdkForRelease_closure()), t2), true, t2._eval$1("ListIterable.E")); @@ -5964,7 +5820,7 @@ findLatestSdkForRelease_closure: function findLatestSdkForRelease_closure() { }, throwLateFieldADI(fieldName) { - A.throwExpressionWithWrapper(new A.LateError("Field '" + fieldName + "' has been assigned during initialization."), new Error()); + throw A.initializeExceptionWrapper(A.LateError$fieldADI(fieldName), new Error()); }, join(part1, part2) { var t1 = $.$get$context(), @@ -6009,6 +5865,10 @@ if (path.charCodeAt(t2) !== 47) return _null; return index + 3; + }, + Process_env(_this, variable) { + var t1 = A._asStringQ(type$.JSObject._as(_this.env)[variable]); + return t1 == null ? null : t1; } }, B = {}; @@ -6052,8 +5912,7 @@ get$hashCode(receiver) { return 0; }, - $isTrustedGetRuntimeType: 1, - $isNull: 1 + $isTrustedGetRuntimeType: 1 }; J.JavaScriptObject.prototype = {$isJSObject: 1}; J.LegacyJavaScriptObject.prototype = { @@ -6097,15 +5956,13 @@ }, add$1(receiver, value) { A._arrayInstanceType(receiver)._precomputed1._as(value); - if (!!receiver.fixed$length) - A.throwExpression(A.UnsupportedError$("add")); + receiver.$flags & 1 && A.throwUnsupportedOperation(receiver, 29); receiver.push(value); }, addAll$1(receiver, collection) { var t1; A._arrayInstanceType(receiver)._eval$1("Iterable<1>")._as(collection); - if (!!receiver.fixed$length) - A.throwExpression(A.UnsupportedError$("addAll")); + receiver.$flags & 1 && A.throwUnsupportedOperation(receiver, "addAll", 2); for (t1 = collection.get$iterator(collection); t1.moveNext$0();) receiver.push(t1.get$current()); }, @@ -6135,8 +5992,7 @@ var len, a, b, undefineds, i, t1 = A._arrayInstanceType(receiver); t1._eval$1("int(1,1)?")._as(compare); - if (!!receiver.immutable$list) - A.throwExpression(A.UnsupportedError$("sort")); + receiver.$flags & 2 && A.throwUnsupportedOperation(receiver, "sort"); len = receiver.length; if (len < 2) return; @@ -6205,8 +6061,7 @@ }, $indexSet(receiver, index, value) { A._arrayInstanceType(receiver)._precomputed1._as(value); - if (!!receiver.immutable$list) - A.throwExpression(A.UnsupportedError$("indexed set")); + receiver.$flags & 2 && A.throwUnsupportedOperation(receiver); if (!(index >= 0 && index < receiver.length)) throw A.wrapException(A.diagnoseIndexError(receiver, index)); receiver[index] = value; @@ -6231,16 +6086,13 @@ } t2 = _this._index; if (t2 >= $length) { - _this.set$_current(null); + _this._current = null; return false; } - _this.set$_current(t1[t2]); - ++_this._index; + _this._current = t1[t2]; + _this._index = t2 + 1; return true; }, - set$_current(_current) { - this._current = this.$ti._eval$1("1?")._as(_current); - }, $isIterator: 1 }; J.JSNumber.prototype = { @@ -6352,9 +6204,6 @@ allMatches$1(receiver, string) { return new A._StringAllMatchesIterable(string, receiver, 0); }, - $add(receiver, other) { - return receiver + other; - }, endsWith$1(receiver, other) { var otherLength = other.length, t1 = receiver.length; @@ -6504,10 +6353,6 @@ $index(_, index) { return this.$ti._rest[1]._as(J.$index$asx(this._source, index)); }, - $indexSet(_, index, value) { - var t1 = this.$ti; - J.$indexSet$ax(this._source, index, t1._precomputed1._as(t1._rest[1]._as(value))); - }, $isEfficientLengthIterable: 1, $isList: 1 }; @@ -6519,6 +6364,36 @@ return this._source; } }; + A.CastMap.prototype = { + cast$2$0(_, RK, RV) { + return new A.CastMap(this._source, this.$ti._eval$1("@<1,2>")._bind$1(RK)._bind$1(RV)._eval$1("CastMap<1,2,3,4>")); + }, + $index(_, key) { + return this.$ti._eval$1("4?")._as(this._source.$index(0, key)); + }, + forEach$1(_, f) { + this._source.forEach$1(0, new A.CastMap_forEach_closure(this, this.$ti._eval$1("~(3,4)")._as(f))); + }, + get$keys() { + var t1 = this.$ti; + return A.CastIterable_CastIterable(this._source.get$keys(), t1._precomputed1, t1._rest[2]); + }, + get$length(_) { + var t1 = this._source; + return t1.get$length(t1); + } + }; + A.CastMap_forEach_closure.prototype = { + call$2(key, value) { + var t1 = this.$this.$ti; + t1._precomputed1._as(key); + t1._rest[1]._as(value); + this.f.call$2(t1._rest[2]._as(key), t1._rest[3]._as(value)); + }, + $signature() { + return this.$this.$ti._eval$1("~(1,2)"); + } + }; A.LateError.prototype = { toString$0(_) { return "LateInitializationError: " + this.__internal$_message; @@ -6631,16 +6506,13 @@ throw A.wrapException(A.ConcurrentModificationError$(t1)); t3 = _this.__internal$_index; if (t3 >= $length) { - _this.set$__internal$_current(null); + _this.__internal$_current = null; return false; } - _this.set$__internal$_current(t2.elementAt$1(t1, t3)); + _this.__internal$_current = t2.elementAt$1(t1, t3); ++_this.__internal$_index; return true; }, - set$__internal$_current(_current) { - this.__internal$_current = this.$ti._eval$1("1?")._as(_current); - }, $isIterator: 1 }; A.MappedIterable.prototype = { @@ -6663,19 +6535,16 @@ var _this = this, t1 = _this._iterator; if (t1.moveNext$0()) { - _this.set$__internal$_current(_this._f.call$1(t1.get$current())); + _this.__internal$_current = _this._f.call$1(t1.get$current()); return true; } - _this.set$__internal$_current(null); + _this.__internal$_current = null; return false; }, get$current() { var t1 = this.__internal$_current; return t1 == null ? this.$ti._rest[1]._as(t1) : t1; }, - set$__internal$_current(_current) { - this.__internal$_current = this.$ti._eval$1("2?")._as(_current); - }, $isIterator: 1 }; A.MappedListIterable.prototype = { @@ -6727,12 +6596,7 @@ $isIterator: 1 }; A.FixedLengthListMixin.prototype = {}; - A.UnmodifiableListMixin.prototype = { - $indexSet(_, index, value) { - A._instanceType(this)._eval$1("UnmodifiableListMixin.E")._as(value); - throw A.wrapException(A.UnsupportedError$("Cannot modify an unmodifiable list")); - } - }; + A.UnmodifiableListMixin.prototype = {}; A.UnmodifiableListBase.prototype = {}; A.__CastListBase__CastIterableBase_ListMixin.prototype = {}; A.TypeErrorDecoder.prototype = { @@ -6864,19 +6728,19 @@ return this.__js_helper$_length; }, get$keys() { - return new A.LinkedHashMapKeyIterable(this, this.$ti._eval$1("LinkedHashMapKeyIterable<1>")); + return new A.LinkedHashMapKeysIterable(this, this.$ti._eval$1("LinkedHashMapKeysIterable<1>")); }, $index(_, key) { var strings, cell, t1, nums, _null = null; if (typeof key == "string") { - strings = this.__js_helper$_strings; + strings = this._strings; if (strings == null) return _null; cell = strings[key]; t1 = cell == null ? _null : cell.hashMapCellValue; return t1; } else if (typeof key == "number" && (key & 0x3fffffff) === key) { - nums = this.__js_helper$_nums; + nums = this._nums; if (nums == null) return _null; cell = nums[key]; @@ -6896,6 +6760,34 @@ return null; return bucket[index].hashMapCellValue; }, + $indexSet(_, key, value) { + var strings, nums, rest, hash, bucket, index, _this = this, + t1 = _this.$ti; + t1._precomputed1._as(key); + t1._rest[1]._as(value); + if (typeof key == "string") { + strings = _this._strings; + _this._addHashTableEntry$3(strings == null ? _this._strings = _this._newHashTable$0() : strings, key, value); + } else if (typeof key == "number" && (key & 0x3fffffff) === key) { + nums = _this._nums; + _this._addHashTableEntry$3(nums == null ? _this._nums = _this._newHashTable$0() : nums, key, value); + } else { + rest = _this.__js_helper$_rest; + if (rest == null) + rest = _this.__js_helper$_rest = _this._newHashTable$0(); + hash = J.get$hashCode$(key) & 1073741823; + bucket = rest[hash]; + if (bucket == null) + rest[hash] = [_this._newLinkedCell$2(key, value)]; + else { + index = _this.internalFindBucketIndex$2(bucket, key); + if (index >= 0) + bucket[index].hashMapCellValue = value; + else + bucket.push(_this._newLinkedCell$2(key, value)); + } + } + }, forEach$1(_, action) { var cell, modifications, _this = this; _this.$ti._eval$1("~(1,2)")._as(action); @@ -6908,6 +6800,17 @@ cell = cell._next; } }, + _addHashTableEntry$3(table, key, value) { + var cell, + t1 = this.$ti; + t1._precomputed1._as(key); + t1._rest[1]._as(value); + cell = table[key]; + if (cell == null) + table[key] = this._newLinkedCell$2(key, value); + else + cell.hashMapCellValue = value; + }, _newLinkedCell$2(key, value) { var _this = this, t1 = _this.$ti, @@ -6933,18 +6836,22 @@ toString$0(_) { return A.MapBase_mapToString(this); }, + _newHashTable$0() { + var table = Object.create(null); + table[""] = table; + delete table[""]; + return table; + }, $isLinkedHashMap: 1 }; A.LinkedHashMapCell.prototype = {}; - A.LinkedHashMapKeyIterable.prototype = { + A.LinkedHashMapKeysIterable.prototype = { get$length(_) { - return this.__js_helper$_map.__js_helper$_length; + return this._map.__js_helper$_length; }, get$iterator(_) { - var t1 = this.__js_helper$_map, - t2 = new A.LinkedHashMapKeyIterator(t1, t1._modifications, this.$ti._eval$1("LinkedHashMapKeyIterator<1>")); - t2._cell = t1._first; - return t2; + var t1 = this._map; + return new A.LinkedHashMapKeyIterator(t1, t1._modifications, t1._first, this.$ti._eval$1("LinkedHashMapKeyIterator<1>")); } }; A.LinkedHashMapKeyIterator.prototype = { @@ -6953,41 +6860,38 @@ }, moveNext$0() { var cell, _this = this, - t1 = _this.__js_helper$_map; + t1 = _this._map; if (_this._modifications !== t1._modifications) throw A.wrapException(A.ConcurrentModificationError$(t1)); cell = _this._cell; if (cell == null) { - _this.set$__js_helper$_current(null); + _this.__js_helper$_current = null; return false; } else { - _this.set$__js_helper$_current(cell.hashMapCellKey); + _this.__js_helper$_current = cell.hashMapCellKey; _this._cell = cell._next; return true; } }, - set$__js_helper$_current(_current) { - this.__js_helper$_current = this.$ti._eval$1("1?")._as(_current); - }, $isIterator: 1 }; A.initHooks_closure.prototype = { call$1(o) { return this.getTag(o); }, - $signature: 8 + $signature: 7 }; A.initHooks_closure0.prototype = { call$2(o, tag) { return this.getUnknownTag(o, tag); }, - $signature: 9 + $signature: 8 }; A.initHooks_closure1.prototype = { call$1(tag) { return this.prototypeForTag(A._asString(tag)); }, - $signature: 10 + $signature: 9 }; A.JSSyntaxRegExp.prototype = { toString$0(_) { @@ -7116,7 +7020,7 @@ }; A.NativeByteBuffer.prototype = { get$runtimeType(receiver) { - return B.Type_ByteBuffer_EOZ; + return B.Type_ByteBuffer_rqD; }, $isTrustedGetRuntimeType: 1, $isByteBuffer: 1 @@ -7124,7 +7028,7 @@ A.NativeTypedData.prototype = {}; A.NativeByteData.prototype = { get$runtimeType(receiver) { - return B.Type_ByteData_mF8; + return B.Type_ByteData_9dB; }, $isTrustedGetRuntimeType: 1, $isByteData: 1 @@ -7140,42 +7044,28 @@ A._checkValidIndex(index, receiver, receiver.length); return receiver[index]; }, - $indexSet(receiver, index, value) { - A._asDouble(value); - A._checkValidIndex(index, receiver, receiver.length); - receiver[index] = value; - }, - $isEfficientLengthIterable: 1, - $isIterable: 1, - $isList: 1 - }; - A.NativeTypedArrayOfInt.prototype = { - $indexSet(receiver, index, value) { - A._asInt(value); - A._checkValidIndex(index, receiver, receiver.length); - receiver[index] = value; - }, $isEfficientLengthIterable: 1, $isIterable: 1, $isList: 1 }; + A.NativeTypedArrayOfInt.prototype = {$isEfficientLengthIterable: 1, $isIterable: 1, $isList: 1}; A.NativeFloat32List.prototype = { get$runtimeType(receiver) { - return B.Type_Float32List_Ymk; + return B.Type_Float32List_9Kz; }, $isTrustedGetRuntimeType: 1, $isFloat32List: 1 }; A.NativeFloat64List.prototype = { get$runtimeType(receiver) { - return B.Type_Float64List_Ymk; + return B.Type_Float64List_9Kz; }, $isTrustedGetRuntimeType: 1, $isFloat64List: 1 }; A.NativeInt16List.prototype = { get$runtimeType(receiver) { - return B.Type_Int16List_cot; + return B.Type_Int16List_s5h; }, $index(receiver, index) { A._checkValidIndex(index, receiver, receiver.length); @@ -7186,7 +7076,7 @@ }; A.NativeInt32List.prototype = { get$runtimeType(receiver) { - return B.Type_Int32List_m1p; + return B.Type_Int32List_O8Z; }, $index(receiver, index) { A._checkValidIndex(index, receiver, receiver.length); @@ -7197,7 +7087,7 @@ }; A.NativeInt8List.prototype = { get$runtimeType(receiver) { - return B.Type_Int8List_woc; + return B.Type_Int8List_rFV; }, $index(receiver, index) { A._checkValidIndex(index, receiver, receiver.length); @@ -7208,7 +7098,7 @@ }; A.NativeUint16List.prototype = { get$runtimeType(receiver) { - return B.Type_Uint16List_2mh; + return B.Type_Uint16List_kmP; }, $index(receiver, index) { A._checkValidIndex(index, receiver, receiver.length); @@ -7219,7 +7109,7 @@ }; A.NativeUint32List.prototype = { get$runtimeType(receiver) { - return B.Type_Uint32List_2mh; + return B.Type_Uint32List_kmP; }, $index(receiver, index) { A._checkValidIndex(index, receiver, receiver.length); @@ -7230,7 +7120,7 @@ }; A.NativeUint8ClampedList.prototype = { get$runtimeType(receiver) { - return B.Type_Uint8ClampedList_9Bb; + return B.Type_Uint8ClampedList_04U; }, get$length(receiver) { return receiver.length; @@ -7244,7 +7134,7 @@ }; A.NativeUint8List.prototype = { get$runtimeType(receiver) { - return B.Type_Uint8List_CSc; + return B.Type_Uint8List_8Eb; }, get$length(receiver) { return receiver.length; @@ -7281,7 +7171,7 @@ }; A._TypeError.prototype = {$isTypeError: 1}; A._AsyncRun__initializeScheduleImmediate_internalCallback.prototype = { - call$1(_) { + call$1(__wc0_formal) { var t1 = this._box_0, f = t1.storedCallback; t1.storedCallback = null; @@ -7297,7 +7187,7 @@ t2 = this.span; t1.firstChild ? t1.removeChild(t2) : t1.appendChild(t2); }, - $signature: 11 + $signature: 10 }; A._AsyncRun__scheduleImmediateJsOverride_internalCallback.prototype = { call$0() { @@ -7345,9 +7235,9 @@ completeError$2(e, st) { var t1 = this._future; if (this.isSync) - t1._completeError$2(e, st); + t1._completeErrorObject$1(new A.AsyncError(e, st)); else - t1._asyncCompleteError$2(e, st); + t1._asyncCompleteErrorObject$1(new A.AsyncError(e, st)); } }; A._awaitOnObject_closure.prototype = { @@ -7360,13 +7250,13 @@ call$2(error, stackTrace) { this.bodyFunction.call$2(1, new A.ExceptionAndStackTrace(error, type$.StackTrace._as(stackTrace))); }, - $signature: 12 + $signature: 11 }; A._wrapJsFunctionForAsync_closure.prototype = { call$2(errorCode, result) { this.$protected(A._asInt(errorCode), result); }, - $signature: 13 + $signature: 12 }; A.AsyncError.prototype = { toString$0(_) { @@ -7379,14 +7269,10 @@ }; A._Completer.prototype = { completeError$2(error, stackTrace) { - var t1; - A.checkNotNullable(error, "error", type$.Object); - t1 = this.future; + var t1 = this.future; if ((t1._state & 30) !== 0) throw A.wrapException(A.StateError$("Future already completed")); - if (stackTrace == null) - stackTrace = A.AsyncError_defaultStackTrace(error); - t1._asyncCompleteError$2(error, stackTrace); + t1._asyncCompleteErrorObject$1(A._interceptUserError(error, stackTrace)); }, completeError$1(error) { return this.completeError$2(error, null); @@ -7435,31 +7321,22 @@ } }; A._Future.prototype = { - _setChained$1(source) { - this._state = this._state & 1 | 4; - this._resultOrListeners = source; - }, then$1$2$onError(f, onError, $R) { - var currentZone, result, t2, + var currentZone, result, t1 = this.$ti; t1._bind$1($R)._eval$1("1/(2)")._as(f); currentZone = $.Zone__current; if (currentZone === B.C__RootZone) { - if (onError != null && !type$.dynamic_Function_Object_StackTrace._is(onError) && !type$.dynamic_Function_Object._is(onError)) + if (!type$.dynamic_Function_Object_StackTrace._is(onError) && !type$.dynamic_Function_Object._is(onError)) throw A.wrapException(A.ArgumentError$value(onError, "onError", string$.Error_)); } else { $R._eval$1("@<0/>")._bind$1(t1._precomputed1)._eval$1("1(2)")._as(f); - if (onError != null) - onError = A._registerErrorHandler(onError, currentZone); + onError = A._registerErrorHandler(onError, currentZone); } result = new A._Future(currentZone, $R._eval$1("_Future<0>")); - t2 = onError == null ? 1 : 3; - this._addListener$1(new A._FutureListener(result, t2, f, onError, t1._eval$1("@<1>")._bind$1($R)._eval$1("_FutureListener<1,2>"))); + this._addListener$1(new A._FutureListener(result, 3, f, onError, t1._eval$1("@<1>")._bind$1($R)._eval$1("_FutureListener<1,2>"))); return result; }, - then$1$1(f, $R) { - return this.then$1$2$onError(f, null, $R); - }, _thenAwait$1$2(f, onError, $E) { var result, t1 = this.$ti; @@ -7535,17 +7412,6 @@ } return prev; }, - _chainForeignFuture$1(source) { - var e, s, exception, _this = this; - _this._state ^= 2; - try { - source.then$1$2$onError(new A._Future__chainForeignFuture_closure(_this), new A._Future__chainForeignFuture_closure0(_this), type$.Null); - } catch (exception) { - e = A.unwrapException(exception); - s = A.getTraceFromException(exception); - A.scheduleMicrotask(new A._Future__chainForeignFuture_closure1(_this, e, s)); - } - }, _completeWithValue$1(value) { var listeners, _this = this; _this.$ti._precomputed1._as(value); @@ -7554,11 +7420,22 @@ _this._resultOrListeners = value; A._Future__propagateToListeners(_this, listeners); }, - _completeError$2(error, stackTrace) { - var listeners; - type$.StackTrace._as(stackTrace); - listeners = this._removeListeners$0(); - this._setErrorObject$1(A.AsyncError$(error, stackTrace)); + _completeWithResultOf$1(source) { + var t1, listeners, _this = this; + if ((source._state & 16) !== 0) { + t1 = _this._zone === source._zone; + t1 = !(t1 || t1); + } else + t1 = false; + if (t1) + return; + listeners = _this._removeListeners$0(); + _this._cloneResult$1(source); + A._Future__propagateToListeners(_this, listeners); + }, + _completeErrorObject$1(error) { + var listeners = this._removeListeners$0(); + this._setErrorObject$1(error); A._Future__propagateToListeners(this, listeners); }, _asyncComplete$1(value) { @@ -7577,17 +7454,12 @@ A._rootScheduleMicrotask(null, null, _this._zone, type$.void_Function._as(new A._Future__asyncCompleteWithValue_closure(_this, value))); }, _chainFuture$1(value) { - var t1 = this.$ti; - t1._eval$1("Future<1>")._as(value); - if (t1._is(value)) { - A._Future__chainCoreFutureAsync(value, this); - return; - } - this._chainForeignFuture$1(value); + A._Future__chainCoreFuture(this.$ti._eval$1("Future<1>")._as(value), this, false); + return; }, - _asyncCompleteError$2(error, stackTrace) { + _asyncCompleteErrorObject$1(error) { this._state ^= 2; - A._rootScheduleMicrotask(null, null, this._zone, type$.void_Function._as(new A._Future__asyncCompleteError_closure(this, error, stackTrace))); + A._rootScheduleMicrotask(null, null, this._zone, type$.void_Function._as(new A._Future__asyncCompleteErrorObject_closure(this, error))); }, $isFuture: 1 }; @@ -7603,36 +7475,9 @@ }, $signature: 0 }; - A._Future__chainForeignFuture_closure.prototype = { - call$1(value) { - var error, stackTrace, exception, - t1 = this.$this; - t1._state ^= 2; - try { - t1._completeWithValue$1(t1.$ti._precomputed1._as(value)); - } catch (exception) { - error = A.unwrapException(exception); - stackTrace = A.getTraceFromException(exception); - t1._completeError$2(error, stackTrace); - } - }, - $signature: 3 - }; - A._Future__chainForeignFuture_closure0.prototype = { - call$2(error, stackTrace) { - this.$this._completeError$2(type$.Object._as(error), type$.StackTrace._as(stackTrace)); - }, - $signature: 14 - }; - A._Future__chainForeignFuture_closure1.prototype = { + A._Future__chainCoreFuture_closure.prototype = { call$0() { - this.$this._completeError$2(this.e, this.s); - }, - $signature: 0 - }; - A._Future__chainCoreFutureAsync_closure.prototype = { - call$0() { - A._Future__chainCoreFutureSync(this._box_0.source, this.target); + A._Future__chainCoreFuture(this._box_0.source, this.target, true); }, $signature: 0 }; @@ -7642,28 +7487,34 @@ }, $signature: 0 }; - A._Future__asyncCompleteError_closure.prototype = { + A._Future__asyncCompleteErrorObject_closure.prototype = { call$0() { - this.$this._completeError$2(this.error, this.stackTrace); + this.$this._completeErrorObject$1(this.error); }, $signature: 0 }; A._Future__propagateToListeners_handleWhenCompleteCallback.prototype = { call$0() { - var e, s, t1, exception, t2, originalSource, _this = this, completeResult = null; + var e, s, t1, exception, t2, t3, originalSource, joinedResult, _this = this, completeResult = null; try { t1 = _this._box_0.listener; completeResult = t1.result._zone.run$1$1(type$.dynamic_Function._as(t1.callback), type$.dynamic); } catch (exception) { e = A.unwrapException(exception); s = A.getTraceFromException(exception); - t1 = _this.hasError && type$.AsyncError._as(_this._box_1.source._resultOrListeners).error === e; - t2 = _this._box_0; - if (t1) - t2.listenerValueOrError = type$.AsyncError._as(_this._box_1.source._resultOrListeners); - else - t2.listenerValueOrError = A.AsyncError$(e, s); - t2.listenerHasError = true; + if (_this.hasError && type$.AsyncError._as(_this._box_1.source._resultOrListeners).error === e) { + t1 = _this._box_0; + t1.listenerValueOrError = type$.AsyncError._as(_this._box_1.source._resultOrListeners); + } else { + t1 = e; + t2 = s; + if (t2 == null) + t2 = A.AsyncError_defaultStackTrace(t1); + t3 = _this._box_0; + t3.listenerValueOrError = new A.AsyncError(t1, t2); + t1 = t3; + } + t1.listenerHasError = true; return; } if (completeResult instanceof A._Future && (completeResult._state & 24) !== 0) { @@ -7676,18 +7527,28 @@ } if (completeResult instanceof A._Future) { originalSource = _this._box_1.source; + joinedResult = new A._Future(originalSource._zone, originalSource.$ti); + completeResult.then$1$2$onError(new A._Future__propagateToListeners_handleWhenCompleteCallback_closure(joinedResult, originalSource), new A._Future__propagateToListeners_handleWhenCompleteCallback_closure0(joinedResult), type$.void); t1 = _this._box_0; - t1.listenerValueOrError = completeResult.then$1$1(new A._Future__propagateToListeners_handleWhenCompleteCallback_closure(originalSource), type$.dynamic); + t1.listenerValueOrError = joinedResult; t1.listenerHasError = false; } }, $signature: 0 }; A._Future__propagateToListeners_handleWhenCompleteCallback_closure.prototype = { - call$1(_) { - return this.originalSource; + call$1(__wc0_formal) { + this.joinedResult._completeWithResultOf$1(this.originalSource); }, - $signature: 15 + $signature: 3 + }; + A._Future__propagateToListeners_handleWhenCompleteCallback_closure0.prototype = { + call$2(e, s) { + type$.Object._as(e); + type$.StackTrace._as(s); + this.joinedResult._completeErrorObject$1(new A.AsyncError(e, s)); + }, + $signature: 13 }; A._Future__propagateToListeners_handleValueCallback.prototype = { call$0() { @@ -7702,16 +7563,20 @@ } catch (exception) { e = A.unwrapException(exception); s = A.getTraceFromException(exception); - t1 = this._box_0; - t1.listenerValueOrError = A.AsyncError$(e, s); - t1.listenerHasError = true; + t1 = e; + t2 = s; + if (t2 == null) + t2 = A.AsyncError_defaultStackTrace(t1); + t3 = this._box_0; + t3.listenerValueOrError = new A.AsyncError(t1, t2); + t3.listenerHasError = true; } }, $signature: 0 }; A._Future__propagateToListeners_handleError.prototype = { call$0() { - var asyncError, e, s, t1, exception, t2, _this = this; + var asyncError, e, s, t1, exception, t2, t3, _this = this; try { asyncError = type$.AsyncError._as(_this._box_1.source._resultOrListeners); t1 = _this._box_0; @@ -7723,12 +7588,20 @@ e = A.unwrapException(exception); s = A.getTraceFromException(exception); t1 = type$.AsyncError._as(_this._box_1.source._resultOrListeners); - t2 = _this._box_0; - if (t1.error === e) + if (t1.error === e) { + t2 = _this._box_0; t2.listenerValueOrError = t1; - else - t2.listenerValueOrError = A.AsyncError$(e, s); - t2.listenerHasError = true; + t1 = t2; + } else { + t1 = e; + t2 = s; + if (t2 == null) + t2 = A.AsyncError_defaultStackTrace(t1); + t3 = _this._box_0; + t3.listenerValueOrError = new A.AsyncError(t1, t2); + t1 = t3; + } + t1.listenerHasError = true; } }, $signature: 0 @@ -7802,10 +7675,10 @@ containsKey$1(key) { var strings, nums; if (typeof key == "string" && key !== "__proto__") { - strings = this._strings; + strings = this._collection$_strings; return strings == null ? false : strings[key] != null; } else if (typeof key == "number" && (key & 1073741823) === key) { - nums = this._nums; + nums = this._collection$_nums; return nums == null ? false : nums[key] != null; } else return this._containsKey$1(key); @@ -7819,11 +7692,11 @@ $index(_, key) { var strings, t1, nums; if (typeof key == "string" && key !== "__proto__") { - strings = this._strings; + strings = this._collection$_strings; t1 = strings == null ? null : A._HashMap__getTableEntry(strings, key); return t1; } else if (typeof key == "number" && (key & 1073741823) === key) { - nums = this._nums; + nums = this._collection$_nums; t1 = nums == null ? null : A._HashMap__getTableEntry(nums, key); return t1; } else @@ -7867,7 +7740,7 @@ var keys, $length, t2, i, key, t3, _this = this, t1 = _this.$ti; t1._eval$1("~(1,2)")._as(action); - keys = _this._computeKeys$0(); + keys = _this._collection$_computeKeys$0(); for ($length = keys.length, t2 = t1._precomputed1, t1 = t1._rest[1], i = 0; i < $length; ++i) { key = keys[i]; t2._as(key); @@ -7877,13 +7750,13 @@ throw A.wrapException(A.ConcurrentModificationError$(_this)); } }, - _computeKeys$0() { + _collection$_computeKeys$0() { var strings, index, names, entries, i, nums, rest, bucket, $length, i0, _this = this, result = _this._keys; if (result != null) return result; result = A.List_List$filled(_this._collection$_length, null, false, type$.dynamic); - strings = _this._strings; + strings = _this._collection$_strings; index = 0; if (strings != null) { names = Object.getOwnPropertyNames(strings); @@ -7893,7 +7766,7 @@ ++index; } } - nums = _this._nums; + nums = _this._collection$_nums; if (nums != null) { names = Object.getOwnPropertyNames(nums); entries = names.length; @@ -7937,11 +7810,11 @@ }; A._HashMapKeyIterable.prototype = { get$length(_) { - return this._map._collection$_length; + return this._collection$_map._collection$_length; }, get$iterator(_) { - var t1 = this._map; - return new A._HashMapKeyIterator(t1, t1._computeKeys$0(), this.$ti._eval$1("_HashMapKeyIterator<1>")); + var t1 = this._collection$_map; + return new A._HashMapKeyIterator(t1, t1._collection$_computeKeys$0(), this.$ti._eval$1("_HashMapKeyIterator<1>")); } }; A._HashMapKeyIterator.prototype = { @@ -7953,21 +7826,18 @@ var _this = this, keys = _this._keys, offset = _this._offset, - t1 = _this._map; + t1 = _this._collection$_map; if (keys !== t1._keys) throw A.wrapException(A.ConcurrentModificationError$(t1)); else if (offset >= keys.length) { - _this.set$_collection$_current(null); + _this._collection$_current = null; return false; } else { - _this.set$_collection$_current(keys[offset]); + _this._collection$_current = keys[offset]; _this._offset = offset + 1; return true; } }, - set$_collection$_current(_current) { - this._collection$_current = this.$ti._eval$1("1?")._as(_current); - }, $isIterator: 1 }; A.ListBase.prototype = { @@ -7984,13 +7854,6 @@ cast$1$0(receiver, $R) { return new A.CastList(receiver, A.instanceType(receiver)._eval$1("@")._bind$1($R)._eval$1("CastList<1,2>")); }, - fillRange$3(receiver, start, end, fill) { - var i; - A.instanceType(receiver)._eval$1("ListBase.E?")._as(fill); - A.RangeError_checkValidRange(start, end, this.get$length(receiver)); - for (i = start; i < end; ++i) - this.$indexSet(receiver, i, fill); - }, toString$0(receiver) { return A.Iterable_iterableToFullString(receiver, "[", "]"); }, @@ -7999,11 +7862,14 @@ $isList: 1 }; A.MapBase.prototype = { + cast$2$0(_, RK, RV) { + return new A.CastMap(this, A._instanceType(this)._eval$1("@")._bind$1(RK)._bind$1(RV)._eval$1("CastMap<1,2,3,4>")); + }, forEach$1(_, action) { var t2, key, t3, t1 = A._instanceType(this); - t1._eval$1("~(1,2)")._as(action); - for (t2 = this.get$keys(), t2 = t2.get$iterator(t2), t1 = t1._rest[1]; t2.moveNext$0();) { + t1._eval$1("~(MapBase.K,MapBase.V)")._as(action); + for (t2 = this.get$keys(), t2 = t2.get$iterator(t2), t1 = t1._eval$1("MapBase.V"); t2.moveNext$0();) { key = t2.get$current(); t3 = this.$index(0, key); action.call$2(key, t3 == null ? t1._as(t3) : t3); @@ -8027,12 +7893,94 @@ t1.first = false; t1 = this.result; t2 = A.S(k); - t2 = t1._contents += t2; - t1._contents = t2 + ": "; + t1._contents = (t1._contents += t2) + ": "; t2 = A.S(v); t1._contents += t2; }, - $signature: 16 + $signature: 14 + }; + A._JsonMap.prototype = { + $index(_, key) { + var result, + t1 = this._processed; + if (t1 == null) + return this._data.$index(0, key); + else if (typeof key != "string") + return null; + else { + result = t1[key]; + return typeof result == "undefined" ? this._process$1(key) : result; + } + }, + get$length(_) { + return this._processed == null ? this._data.__js_helper$_length : this._computeKeys$0().length; + }, + get$keys() { + if (this._processed == null) { + var t1 = this._data; + return new A.LinkedHashMapKeysIterable(t1, t1.$ti._eval$1("LinkedHashMapKeysIterable<1>")); + } + return new A._JsonMapKeyIterable(this); + }, + forEach$1(_, f) { + var keys, i, key, value, _this = this; + type$.void_Function_String_dynamic._as(f); + if (_this._processed == null) + return _this._data.forEach$1(0, f); + keys = _this._computeKeys$0(); + for (i = 0; i < keys.length; ++i) { + key = keys[i]; + value = _this._processed[key]; + if (typeof value == "undefined") { + value = A._convertJsonToDartLazy(_this._original[key]); + _this._processed[key] = value; + } + f.call$2(key, value); + if (keys !== _this._data) + throw A.wrapException(A.ConcurrentModificationError$(_this)); + } + }, + _computeKeys$0() { + var keys = type$.nullable_List_dynamic._as(this._data); + if (keys == null) + keys = this._data = A._setArrayType(Object.keys(this._original), type$.JSArray_String); + return keys; + }, + _process$1(key) { + var result; + if (!Object.prototype.hasOwnProperty.call(this._original, key)) + return null; + result = A._convertJsonToDartLazy(this._original[key]); + return this._processed[key] = result; + } + }; + A._JsonMapKeyIterable.prototype = { + get$length(_) { + return this._parent.get$length(0); + }, + elementAt$1(_, index) { + var t1 = this._parent; + if (t1._processed == null) + t1 = t1.get$keys().elementAt$1(0, index); + else { + t1 = t1._computeKeys$0(); + if (!(index >= 0 && index < t1.length)) + return A.ioore(t1, index); + t1 = t1[index]; + } + return t1; + }, + get$iterator(_) { + var t1 = this._parent; + if (t1._processed == null) { + t1 = t1.get$keys(); + t1 = t1.get$iterator(t1); + } else { + t1 = t1._computeKeys$0(); + t1 = new J.ArrayIterator(t1, t1.length, A._arrayInstanceType(t1)._eval$1("ArrayIterator<1>")); + } + return t1; + } }; A._Utf8Decoder__decoder_closure.prototype = { call$0() { @@ -8166,6 +8114,16 @@ A.Codec.prototype = {}; A.Converter.prototype = {}; A.Encoding.prototype = {}; + A.JsonCodec.prototype = { + decode$2$reviver(source, reviver) { + var t1 = A._parseJson(source, this.get$decoder()._reviver); + return t1; + }, + get$decoder() { + return B.JsonDecoder_null; + } + }; + A.JsonDecoder.prototype = {}; A.Utf8Codec.prototype = {}; A.Utf8Decoder.prototype = { convert$1(codeUnits) { @@ -8264,8 +8222,7 @@ break; default: t3 = A.Primitives_stringFromCharCode(_65533); - t3 = buffer._contents += t3; - buffer._contents = t3 + A.Primitives_stringFromCharCode(_65533); + buffer._contents = (buffer._contents += t3) + A.Primitives_stringFromCharCode(_65533); break; } else { @@ -8607,13 +8564,13 @@ call$2(msg, position) { throw A.wrapException(A.FormatException$("Illegal IPv4 address, " + msg, this.host, position)); }, - $signature: 17 + $signature: 15 }; A.Uri_parseIPv6Address_error.prototype = { call$2(msg, position) { throw A.wrapException(A.FormatException$("Illegal IPv6 address, " + msg, this.host, position)); }, - $signature: 18 + $signature: 16 }; A.Uri_parseIPv6Address_parseHex.prototype = { call$2(start, end) { @@ -8625,7 +8582,7 @@ this.error.call$2("each part must be in the range of `0x0..0xFFFF`", start); return value; }, - $signature: 19 + $signature: 17 }; A._Uri.prototype = { get$_text() { @@ -8676,8 +8633,7 @@ pathToSplit = B.JSString_methods.substring$1(pathToSplit, 1); result = pathToSplit.length === 0 ? B.List_empty : A.List_List$unmodifiable(new A.MappedListIterable(A._setArrayType(pathToSplit.split("/"), type$.JSArray_String), type$.dynamic_Function_String._as(A.core_Uri_decodeComponent$closure()), type$.MappedListIterable_String_dynamic), type$.String); _this.___Uri_pathSegments_FI !== $ && A.throwLateFieldADI("pathSegments"); - _this.set$___Uri_pathSegments_FI(result); - value = result; + value = _this.___Uri_pathSegments_FI = result; } return value; }, @@ -8777,9 +8733,6 @@ } return t1; }, - set$___Uri_pathSegments_FI(___Uri_pathSegments_FI) { - this.___Uri_pathSegments_FI = type$.List_String._as(___Uri_pathSegments_FI); - }, $isUri: 1, get$scheme() { return this.scheme; @@ -8801,11 +8754,11 @@ queryIndex = B.JSString_methods.indexOf$2(t2, "?", t1); end = t2.length; if (queryIndex >= 0) { - query = A._Uri__normalizeOrSubstring(t2, queryIndex + 1, end, B.List_42A, false, false); + query = A._Uri__normalizeOrSubstring(t2, queryIndex + 1, end, 256, false, false); end = queryIndex; } else query = _null; - t1 = _this._uriCache = new A._DataUri("data", "", _null, _null, A._Uri__normalizeOrSubstring(t2, t1, end, B.List_M2I, false, false), query, _null); + t1 = _this._uriCache = new A._DataUri("data", "", _null, _null, A._Uri__normalizeOrSubstring(t2, t1, end, 128, false, false), query, _null); } return t1; }, @@ -8818,48 +8771,6 @@ return t1[0] === -1 ? "data:" + t2 : t2; } }; - A._createTables_build.prototype = { - call$2(state, defaultTransition) { - var t1 = this.tables; - if (!(state < t1.length)) - return A.ioore(t1, state); - t1 = t1[state]; - B.NativeUint8List_methods.fillRange$3(t1, 0, 96, defaultTransition); - return t1; - }, - $signature: 20 - }; - A._createTables_setChars.prototype = { - call$3(target, chars, transition) { - var t1, i, t2; - for (t1 = chars.length, i = 0; i < t1; ++i) { - t2 = chars.charCodeAt(i) ^ 96; - if (!(t2 < 96)) - return A.ioore(target, t2); - target[t2] = transition; - } - }, - $signature: 6 - }; - A._createTables_setRange.prototype = { - call$3(target, range, transition) { - var i, n, - t1 = range.length; - if (0 >= t1) - return A.ioore(range, 0); - i = range.charCodeAt(0); - if (1 >= t1) - return A.ioore(range, 1); - n = range.charCodeAt(1); - for (; i <= n; ++i) { - t1 = (i ^ 96) >>> 0; - if (!(t1 < 96)) - return A.ioore(target, t1); - target[t1] = transition; - } - }, - $signature: 6 - }; A._SimpleUri.prototype = { get$hasAuthority() { return this._hostStart > 0; @@ -8959,7 +8870,7 @@ convertedMap[key] = this.call$1(o.$index(0, key)); } return convertedMap; - } else if (type$.Iterable_nullable_Object._is(o)) { + } else if (type$.Iterable_dynamic._is(o)) { convertedList = []; t1.$indexSet(0, o, convertedList); B.JSArray_methods.addAll$1(convertedList, J.map$1$1$ax(o, this, type$.dynamic)); @@ -8967,7 +8878,7 @@ } else return o; }, - $signature: 21 + $signature: 18 }; A.promiseToFuture_closure.prototype = { call$1(r) { @@ -9067,14 +8978,14 @@ call$1(part) { return A._asString(part) !== ""; }, - $signature: 22 + $signature: 19 }; A._validateArgList_closure.prototype = { call$1(arg) { A._asStringQ(arg); return arg == null ? "null" : '"' + arg + '"'; }, - $signature: 23 + $signature: 20 }; A.InternalStyle.prototype = { getRoot$1(path) { @@ -9122,16 +9033,13 @@ B.JSArray_methods.$indexSet(t2, t1 - 1, ""); }, toString$0(_) { - var t2, t3, i, t4, + var t2, t3, t4, t5, i, t1 = this.root; t1 = t1 != null ? "" + t1 : ""; - for (t2 = this.parts, t3 = this.separators, i = 0; i < t2.length; ++i, t1 = t4) { - if (!(i < t3.length)) + for (t2 = this.parts, t3 = this.separators, t4 = t2.length, t5 = t3.length, i = 0; i < t4; ++i) { + if (!(i < t5)) return A.ioore(t3, i); - t4 = A.S(t3[i]); - if (!(i < t2.length)) - return A.ioore(t2, i); - t4 = t1 + t4 + A.S(t2[i]); + t1 = t1 + t3[i] + t2[i]; } t1 += A.S(B.JSArray_methods.get$last(t3)); return t1.charCodeAt(0) == 0 ? t1 : t1; @@ -9414,7 +9322,7 @@ t1 = A.Primitives_parseInt(part, null); return t1 == null ? part : t1; }, - $signature: 24 + $signature: 21 }; A.findLatestSdkForRelease_closure.prototype = { call$1(p) { @@ -9424,7 +9332,7 @@ t1.pop(); return B.JSArray_methods.get$last(t1); }, - $signature: 7 + $signature: 6 }; (function aliases() { var _ = J.LegacyJavaScriptObject.prototype; @@ -9434,20 +9342,20 @@ var _static_2 = hunkHelpers._static_2, _static_1 = hunkHelpers._static_1, _static_0 = hunkHelpers._static_0; - _static_2(J, "_interceptors_JSArray__compareAny$closure", "JSArray__compareAny", 25); + _static_2(J, "_interceptors_JSArray__compareAny$closure", "JSArray__compareAny", 22); _static_1(A, "async__AsyncRun__scheduleImmediateJsOverride$closure", "_AsyncRun__scheduleImmediateJsOverride", 2); _static_1(A, "async__AsyncRun__scheduleImmediateWithSetImmediate$closure", "_AsyncRun__scheduleImmediateWithSetImmediate", 2); _static_1(A, "async__AsyncRun__scheduleImmediateWithTimer$closure", "_AsyncRun__scheduleImmediateWithTimer", 2); _static_0(A, "async___startMicrotaskLoop$closure", "_startMicrotaskLoop", 0); - _static_1(A, "core_Uri_decodeComponent$closure", "Uri_decodeComponent", 7); - _static_1(A, "version_Version___parse_tearOff$closure", "Version___parse_tearOff", 26); + _static_1(A, "core_Uri_decodeComponent$closure", "Uri_decodeComponent", 6); + _static_1(A, "version_Version___parse_tearOff$closure", "Version___parse_tearOff", 23); })(); (function inheritance() { var _mixin = hunkHelpers.mixin, _inherit = hunkHelpers.inherit, _inheritMany = hunkHelpers.inheritMany; _inherit(A.Object, null); - _inheritMany(A.Object, [A.JS_CONST, J.Interceptor, J.ArrayIterator, A.Iterable, A.CastIterator, A.Error, A.ListBase, A.ListIterator, A.MappedIterator, A.WhereIterator, A.WhereTypeIterator, A.FixedLengthListMixin, A.UnmodifiableListMixin, A.TypeErrorDecoder, A.NullThrownFromJavaScriptException, A.ExceptionAndStackTrace, A._StackTrace, A.Closure, A.MapBase, A.LinkedHashMapCell, A.LinkedHashMapKeyIterator, A.JSSyntaxRegExp, A._MatchImplementation, A._AllMatchesIterator, A.StringMatch, A._StringAllMatchesIterator, A.Rti, A._FunctionParameters, A._Type, A._TimerImpl, A._AsyncAwaitCompleter, A.AsyncError, A._Completer, A._FutureListener, A._Future, A._AsyncCallbackEntry, A._StreamIterator, A._Zone, A._HashMapKeyIterator, A.Codec, A.Converter, A._Utf8Decoder, A.OutOfMemoryError, A.StackOverflowError, A._Exception, A.FormatException, A.Null, A._StringStackTrace, A.StringBuffer, A._Uri, A.UriData, A._SimpleUri, A.NullRejectionException, A.DefaultEquality, A.IterableEquality, A.Context, A.Style, A.ParsedPath, A.Version]); + _inheritMany(A.Object, [A.JS_CONST, J.Interceptor, J.ArrayIterator, A.Iterable, A.CastIterator, A.MapBase, A.Closure, A.Error, A.ListBase, A.ListIterator, A.MappedIterator, A.WhereIterator, A.WhereTypeIterator, A.FixedLengthListMixin, A.UnmodifiableListMixin, A.TypeErrorDecoder, A.NullThrownFromJavaScriptException, A.ExceptionAndStackTrace, A._StackTrace, A.LinkedHashMapCell, A.LinkedHashMapKeyIterator, A.JSSyntaxRegExp, A._MatchImplementation, A._AllMatchesIterator, A.StringMatch, A._StringAllMatchesIterator, A.Rti, A._FunctionParameters, A._Type, A._TimerImpl, A._AsyncAwaitCompleter, A.AsyncError, A._Completer, A._FutureListener, A._Future, A._AsyncCallbackEntry, A._StreamIterator, A._Zone, A._HashMapKeyIterator, A.Codec, A.Converter, A._Utf8Decoder, A.OutOfMemoryError, A.StackOverflowError, A._Exception, A.FormatException, A.Null, A._StringStackTrace, A.StringBuffer, A._Uri, A.UriData, A._SimpleUri, A.NullRejectionException, A.DefaultEquality, A.IterableEquality, A.Context, A.Style, A.ParsedPath, A.Version]); _inheritMany(J.Interceptor, [J.JSBool, J.JSNull, J.JavaScriptObject, J.JavaScriptBigInt, J.JavaScriptSymbol, J.JSNumber, J.JSString]); _inheritMany(J.JavaScriptObject, [J.LegacyJavaScriptObject, J.JSArray, A.NativeByteBuffer, A.NativeTypedData]); _inheritMany(J.LegacyJavaScriptObject, [J.PlainJavaScriptObject, J.UnknownJavaScriptObject, J.JavaScriptFunction]); @@ -9458,18 +9366,18 @@ _inherit(A._EfficientLengthCastIterable, A.CastIterable); _inherit(A._CastListBase, A.__CastListBase__CastIterableBase_ListMixin); _inherit(A.CastList, A._CastListBase); + _inheritMany(A.MapBase, [A.CastMap, A.JsLinkedHashMap, A._HashMap, A._JsonMap]); + _inheritMany(A.Closure, [A.Closure2Args, A.Closure0Args, A.TearOffClosure, A.initHooks_closure, A.initHooks_closure1, A._AsyncRun__initializeScheduleImmediate_internalCallback, A._AsyncRun__initializeScheduleImmediate_closure, A._awaitOnObject_closure, A._Future__propagateToListeners_handleWhenCompleteCallback_closure, A.jsify__convert, A.promiseToFuture_closure, A.promiseToFuture_closure0, A.Context_joinAll_closure, A._validateArgList_closure, A.Version__splitParts_closure, A.findLatestSdkForRelease_closure]); + _inheritMany(A.Closure2Args, [A.CastMap_forEach_closure, A.initHooks_closure0, A._awaitOnObject_closure0, A._wrapJsFunctionForAsync_closure, A._Future__propagateToListeners_handleWhenCompleteCallback_closure0, A.MapBase_mapToString_closure, A.Uri__parseIPv4Address_error, A.Uri_parseIPv6Address_error, A.Uri_parseIPv6Address_parseHex]); _inheritMany(A.Error, [A.LateError, A.TypeError, A.JsNoSuchMethodError, A.UnknownJsTypeError, A._CyclicInitializationError, A.RuntimeError, A.AssertionError, A._Error, A.ArgumentError, A.UnsupportedError, A.UnimplementedError, A.StateError, A.ConcurrentModificationError]); _inherit(A.UnmodifiableListBase, A.ListBase); _inherit(A.CodeUnits, A.UnmodifiableListBase); - _inheritMany(A.EfficientLengthIterable, [A.ListIterable, A.LinkedHashMapKeyIterable, A._HashMapKeyIterable]); - _inheritMany(A.ListIterable, [A.SubListIterable, A.MappedListIterable]); + _inheritMany(A.EfficientLengthIterable, [A.ListIterable, A.LinkedHashMapKeysIterable, A._HashMapKeyIterable]); + _inheritMany(A.ListIterable, [A.SubListIterable, A.MappedListIterable, A._JsonMapKeyIterable]); _inherit(A.EfficientLengthMappedIterable, A.MappedIterable); _inherit(A.NullError, A.TypeError); - _inheritMany(A.Closure, [A.Closure0Args, A.Closure2Args, A.TearOffClosure, A.initHooks_closure, A.initHooks_closure1, A._AsyncRun__initializeScheduleImmediate_internalCallback, A._AsyncRun__initializeScheduleImmediate_closure, A._awaitOnObject_closure, A._Future__chainForeignFuture_closure, A._Future__propagateToListeners_handleWhenCompleteCallback_closure, A._createTables_setChars, A._createTables_setRange, A.jsify__convert, A.promiseToFuture_closure, A.promiseToFuture_closure0, A.Context_joinAll_closure, A._validateArgList_closure, A.Version__splitParts_closure, A.findLatestSdkForRelease_closure]); _inheritMany(A.TearOffClosure, [A.StaticClosure, A.BoundClosure]); _inherit(A._AssertionError, A.AssertionError); - _inheritMany(A.MapBase, [A.JsLinkedHashMap, A._HashMap]); - _inheritMany(A.Closure2Args, [A.initHooks_closure0, A._awaitOnObject_closure0, A._wrapJsFunctionForAsync_closure, A._Future__chainForeignFuture_closure0, A.MapBase_mapToString_closure, A.Uri__parseIPv4Address_error, A.Uri_parseIPv6Address_error, A.Uri_parseIPv6Address_parseHex, A._createTables_build]); _inheritMany(A.NativeTypedData, [A.NativeByteData, A.NativeTypedArray]); _inheritMany(A.NativeTypedArray, [A._NativeTypedArrayOfDouble_NativeTypedArray_ListMixin, A._NativeTypedArrayOfInt_NativeTypedArray_ListMixin]); _inherit(A._NativeTypedArrayOfDouble_NativeTypedArray_ListMixin_FixedLengthListMixin, A._NativeTypedArrayOfDouble_NativeTypedArray_ListMixin); @@ -9479,12 +9387,12 @@ _inheritMany(A.NativeTypedArrayOfDouble, [A.NativeFloat32List, A.NativeFloat64List]); _inheritMany(A.NativeTypedArrayOfInt, [A.NativeInt16List, A.NativeInt32List, A.NativeInt8List, A.NativeUint16List, A.NativeUint32List, A.NativeUint8ClampedList, A.NativeUint8List]); _inherit(A._TypeError, A._Error); - _inheritMany(A.Closure0Args, [A._AsyncRun__scheduleImmediateJsOverride_internalCallback, A._AsyncRun__scheduleImmediateWithSetImmediate_internalCallback, A._TimerImpl_internalCallback, A._Future__addListener_closure, A._Future__prependListeners_closure, A._Future__chainForeignFuture_closure1, A._Future__chainCoreFutureAsync_closure, A._Future__asyncCompleteWithValue_closure, A._Future__asyncCompleteError_closure, A._Future__propagateToListeners_handleWhenCompleteCallback, A._Future__propagateToListeners_handleValueCallback, A._Future__propagateToListeners_handleError, A._rootHandleError_closure, A._RootZone_bindCallbackGuarded_closure, A._Utf8Decoder__decoder_closure, A._Utf8Decoder__decoderNonfatal_closure]); + _inheritMany(A.Closure0Args, [A._AsyncRun__scheduleImmediateJsOverride_internalCallback, A._AsyncRun__scheduleImmediateWithSetImmediate_internalCallback, A._TimerImpl_internalCallback, A._Future__addListener_closure, A._Future__prependListeners_closure, A._Future__chainCoreFuture_closure, A._Future__asyncCompleteWithValue_closure, A._Future__asyncCompleteErrorObject_closure, A._Future__propagateToListeners_handleWhenCompleteCallback, A._Future__propagateToListeners_handleValueCallback, A._Future__propagateToListeners_handleError, A._rootHandleError_closure, A._RootZone_bindCallbackGuarded_closure, A._Utf8Decoder__decoder_closure, A._Utf8Decoder__decoderNonfatal_closure]); _inherit(A._AsyncCompleter, A._Completer); _inherit(A._RootZone, A._Zone); _inherit(A._IdentityHashMap, A._HashMap); - _inheritMany(A.Codec, [A.Base64Codec, A.Encoding]); - _inheritMany(A.Converter, [A.Base64Encoder, A.Utf8Decoder]); + _inheritMany(A.Codec, [A.Base64Codec, A.Encoding, A.JsonCodec]); + _inheritMany(A.Converter, [A.Base64Encoder, A.JsonDecoder, A.Utf8Decoder]); _inherit(A.Utf8Codec, A.Encoding); _inheritMany(A.ArgumentError, [A.RangeError, A.IndexError]); _inherit(A._DataUri, A._Uri); @@ -9501,14 +9409,15 @@ typeUniverse: {eC: new Map(), tR: {}, eT: {}, tPV: {}, sEA: []}, mangledGlobalNames: {int: "int", double: "double", num: "num", String: "String", bool: "bool", Null: "Null", List: "List", Object: "Object", Map: "Map"}, mangledNames: {}, - types: ["~()", "~(@)", "~(~())", "Null(@)", "Null()", "@()", "~(Uint8List,String,int)", "String(String)", "@(@)", "@(@,String)", "@(String)", "Null(~())", "Null(@,StackTrace)", "~(int,@)", "Null(Object,StackTrace)", "_Future<@>(@)", "~(Object?,Object?)", "~(String,int)", "~(String,int?)", "int(int,int)", "Uint8List(@,@)", "Object?(Object?)", "bool(String)", "String(String?)", "Object(String)", "int(@,@)", "Version(String)"], + types: ["~()", "~(@)", "~(~())", "Null(@)", "Null()", "@()", "String(String)", "@(@)", "@(@,String)", "@(String)", "Null(~())", "Null(@,StackTrace)", "~(int,@)", "Null(Object,StackTrace)", "~(Object?,Object?)", "~(String,int)", "~(String,int?)", "int(int,int)", "Object?(Object?)", "bool(String)", "String(String?)", "Object(String)", "int(@,@)", "Version(String)"], interceptorsByTag: null, leafTags: null, arrayRti: Symbol("$ti") }; - A._Universe_addRules(init.typeUniverse, JSON.parse('{"PlainJavaScriptObject":"LegacyJavaScriptObject","UnknownJavaScriptObject":"LegacyJavaScriptObject","JavaScriptFunction":"LegacyJavaScriptObject","JSBool":{"bool":[],"TrustedGetRuntimeType":[]},"JSNull":{"Null":[],"TrustedGetRuntimeType":[]},"JavaScriptObject":{"JSObject":[]},"LegacyJavaScriptObject":{"JSObject":[]},"JSArray":{"List":["1"],"EfficientLengthIterable":["1"],"JSObject":[],"Iterable":["1"]},"JSUnmodifiableArray":{"JSArray":["1"],"List":["1"],"EfficientLengthIterable":["1"],"JSObject":[],"Iterable":["1"]},"ArrayIterator":{"Iterator":["1"]},"JSNumber":{"double":[],"num":[],"Comparable":["num"]},"JSInt":{"double":[],"int":[],"num":[],"Comparable":["num"],"TrustedGetRuntimeType":[]},"JSNumNotInt":{"double":[],"num":[],"Comparable":["num"],"TrustedGetRuntimeType":[]},"JSString":{"String":[],"Comparable":["String"],"Pattern":[],"TrustedGetRuntimeType":[]},"_CastIterableBase":{"Iterable":["2"]},"CastIterator":{"Iterator":["2"]},"CastIterable":{"_CastIterableBase":["1","2"],"Iterable":["2"],"Iterable.E":"2"},"_EfficientLengthCastIterable":{"CastIterable":["1","2"],"_CastIterableBase":["1","2"],"EfficientLengthIterable":["2"],"Iterable":["2"],"Iterable.E":"2"},"_CastListBase":{"ListBase":["2"],"List":["2"],"_CastIterableBase":["1","2"],"EfficientLengthIterable":["2"],"Iterable":["2"]},"CastList":{"_CastListBase":["1","2"],"ListBase":["2"],"List":["2"],"_CastIterableBase":["1","2"],"EfficientLengthIterable":["2"],"Iterable":["2"],"ListBase.E":"2","Iterable.E":"2"},"LateError":{"Error":[]},"CodeUnits":{"ListBase":["int"],"UnmodifiableListMixin":["int"],"List":["int"],"EfficientLengthIterable":["int"],"Iterable":["int"],"ListBase.E":"int","UnmodifiableListMixin.E":"int"},"EfficientLengthIterable":{"Iterable":["1"]},"ListIterable":{"EfficientLengthIterable":["1"],"Iterable":["1"]},"SubListIterable":{"ListIterable":["1"],"EfficientLengthIterable":["1"],"Iterable":["1"],"Iterable.E":"1","ListIterable.E":"1"},"ListIterator":{"Iterator":["1"]},"MappedIterable":{"Iterable":["2"],"Iterable.E":"2"},"EfficientLengthMappedIterable":{"MappedIterable":["1","2"],"EfficientLengthIterable":["2"],"Iterable":["2"],"Iterable.E":"2"},"MappedIterator":{"Iterator":["2"]},"MappedListIterable":{"ListIterable":["2"],"EfficientLengthIterable":["2"],"Iterable":["2"],"Iterable.E":"2","ListIterable.E":"2"},"WhereIterable":{"Iterable":["1"],"Iterable.E":"1"},"WhereIterator":{"Iterator":["1"]},"WhereTypeIterable":{"Iterable":["1"],"Iterable.E":"1"},"WhereTypeIterator":{"Iterator":["1"]},"UnmodifiableListBase":{"ListBase":["1"],"UnmodifiableListMixin":["1"],"List":["1"],"EfficientLengthIterable":["1"],"Iterable":["1"]},"NullError":{"TypeError":[],"Error":[]},"JsNoSuchMethodError":{"Error":[]},"UnknownJsTypeError":{"Error":[]},"_StackTrace":{"StackTrace":[]},"Closure":{"Function":[]},"Closure0Args":{"Function":[]},"Closure2Args":{"Function":[]},"TearOffClosure":{"Function":[]},"StaticClosure":{"Function":[]},"BoundClosure":{"Function":[]},"_CyclicInitializationError":{"Error":[]},"RuntimeError":{"Error":[]},"_AssertionError":{"Error":[]},"JsLinkedHashMap":{"MapBase":["1","2"],"LinkedHashMap":["1","2"],"Map":["1","2"]},"LinkedHashMapKeyIterable":{"EfficientLengthIterable":["1"],"Iterable":["1"],"Iterable.E":"1"},"LinkedHashMapKeyIterator":{"Iterator":["1"]},"JSSyntaxRegExp":{"RegExp":[],"Pattern":[]},"_MatchImplementation":{"RegExpMatch":[],"Match":[]},"_AllMatchesIterable":{"Iterable":["RegExpMatch"],"Iterable.E":"RegExpMatch"},"_AllMatchesIterator":{"Iterator":["RegExpMatch"]},"StringMatch":{"Match":[]},"_StringAllMatchesIterable":{"Iterable":["Match"],"Iterable.E":"Match"},"_StringAllMatchesIterator":{"Iterator":["Match"]},"NativeByteBuffer":{"JSObject":[],"ByteBuffer":[],"TrustedGetRuntimeType":[]},"NativeTypedData":{"JSObject":[]},"NativeByteData":{"ByteData":[],"JSObject":[],"TrustedGetRuntimeType":[]},"NativeTypedArray":{"JavaScriptIndexingBehavior":["1"],"JSObject":[]},"NativeTypedArrayOfDouble":{"ListBase":["double"],"List":["double"],"JavaScriptIndexingBehavior":["double"],"EfficientLengthIterable":["double"],"JSObject":[],"Iterable":["double"],"FixedLengthListMixin":["double"]},"NativeTypedArrayOfInt":{"ListBase":["int"],"List":["int"],"JavaScriptIndexingBehavior":["int"],"EfficientLengthIterable":["int"],"JSObject":[],"Iterable":["int"],"FixedLengthListMixin":["int"]},"NativeFloat32List":{"Float32List":[],"ListBase":["double"],"List":["double"],"JavaScriptIndexingBehavior":["double"],"EfficientLengthIterable":["double"],"JSObject":[],"Iterable":["double"],"FixedLengthListMixin":["double"],"TrustedGetRuntimeType":[],"ListBase.E":"double"},"NativeFloat64List":{"Float64List":[],"ListBase":["double"],"List":["double"],"JavaScriptIndexingBehavior":["double"],"EfficientLengthIterable":["double"],"JSObject":[],"Iterable":["double"],"FixedLengthListMixin":["double"],"TrustedGetRuntimeType":[],"ListBase.E":"double"},"NativeInt16List":{"Int16List":[],"ListBase":["int"],"List":["int"],"JavaScriptIndexingBehavior":["int"],"EfficientLengthIterable":["int"],"JSObject":[],"Iterable":["int"],"FixedLengthListMixin":["int"],"TrustedGetRuntimeType":[],"ListBase.E":"int"},"NativeInt32List":{"Int32List":[],"ListBase":["int"],"List":["int"],"JavaScriptIndexingBehavior":["int"],"EfficientLengthIterable":["int"],"JSObject":[],"Iterable":["int"],"FixedLengthListMixin":["int"],"TrustedGetRuntimeType":[],"ListBase.E":"int"},"NativeInt8List":{"Int8List":[],"ListBase":["int"],"List":["int"],"JavaScriptIndexingBehavior":["int"],"EfficientLengthIterable":["int"],"JSObject":[],"Iterable":["int"],"FixedLengthListMixin":["int"],"TrustedGetRuntimeType":[],"ListBase.E":"int"},"NativeUint16List":{"Uint16List":[],"ListBase":["int"],"List":["int"],"JavaScriptIndexingBehavior":["int"],"EfficientLengthIterable":["int"],"JSObject":[],"Iterable":["int"],"FixedLengthListMixin":["int"],"TrustedGetRuntimeType":[],"ListBase.E":"int"},"NativeUint32List":{"Uint32List":[],"ListBase":["int"],"List":["int"],"JavaScriptIndexingBehavior":["int"],"EfficientLengthIterable":["int"],"JSObject":[],"Iterable":["int"],"FixedLengthListMixin":["int"],"TrustedGetRuntimeType":[],"ListBase.E":"int"},"NativeUint8ClampedList":{"Uint8ClampedList":[],"ListBase":["int"],"List":["int"],"JavaScriptIndexingBehavior":["int"],"EfficientLengthIterable":["int"],"JSObject":[],"Iterable":["int"],"FixedLengthListMixin":["int"],"TrustedGetRuntimeType":[],"ListBase.E":"int"},"NativeUint8List":{"Uint8List":[],"ListBase":["int"],"List":["int"],"JavaScriptIndexingBehavior":["int"],"EfficientLengthIterable":["int"],"JSObject":[],"Iterable":["int"],"FixedLengthListMixin":["int"],"TrustedGetRuntimeType":[],"ListBase.E":"int"},"_Error":{"Error":[]},"_TypeError":{"TypeError":[],"Error":[]},"_Future":{"Future":["1"]},"AsyncError":{"Error":[]},"_AsyncCompleter":{"_Completer":["1"]},"_Zone":{"Zone":[]},"_RootZone":{"_Zone":[],"Zone":[]},"_HashMap":{"MapBase":["1","2"],"Map":["1","2"]},"_IdentityHashMap":{"_HashMap":["1","2"],"MapBase":["1","2"],"Map":["1","2"]},"_HashMapKeyIterable":{"EfficientLengthIterable":["1"],"Iterable":["1"],"Iterable.E":"1"},"_HashMapKeyIterator":{"Iterator":["1"]},"ListBase":{"List":["1"],"EfficientLengthIterable":["1"],"Iterable":["1"]},"MapBase":{"Map":["1","2"]},"Base64Codec":{"Codec":["List","String"]},"Encoding":{"Codec":["String","List"]},"Utf8Codec":{"Codec":["String","List"]},"double":{"num":[],"Comparable":["num"]},"int":{"num":[],"Comparable":["num"]},"List":{"EfficientLengthIterable":["1"],"Iterable":["1"]},"num":{"Comparable":["num"]},"RegExpMatch":{"Match":[]},"String":{"Comparable":["String"],"Pattern":[]},"AssertionError":{"Error":[]},"TypeError":{"Error":[]},"ArgumentError":{"Error":[]},"RangeError":{"Error":[]},"IndexError":{"Error":[]},"UnsupportedError":{"Error":[]},"UnimplementedError":{"Error":[]},"StateError":{"Error":[]},"ConcurrentModificationError":{"Error":[]},"OutOfMemoryError":{"Error":[]},"StackOverflowError":{"Error":[]},"_StringStackTrace":{"StackTrace":[]},"StringBuffer":{"StringSink":[]},"_Uri":{"Uri":[]},"_SimpleUri":{"Uri":[]},"_DataUri":{"Uri":[]},"PosixStyle":{"InternalStyle":[]},"UrlStyle":{"InternalStyle":[]},"WindowsStyle":{"InternalStyle":[]},"Version":{"VersionRange":[],"Comparable":["VersionRange"]},"Int8List":{"List":["int"],"EfficientLengthIterable":["int"],"Iterable":["int"]},"Uint8List":{"List":["int"],"EfficientLengthIterable":["int"],"Iterable":["int"]},"Uint8ClampedList":{"List":["int"],"EfficientLengthIterable":["int"],"Iterable":["int"]},"Int16List":{"List":["int"],"EfficientLengthIterable":["int"],"Iterable":["int"]},"Uint16List":{"List":["int"],"EfficientLengthIterable":["int"],"Iterable":["int"]},"Int32List":{"List":["int"],"EfficientLengthIterable":["int"],"Iterable":["int"]},"Uint32List":{"List":["int"],"EfficientLengthIterable":["int"],"Iterable":["int"]},"Float32List":{"List":["double"],"EfficientLengthIterable":["double"],"Iterable":["double"]},"Float64List":{"List":["double"],"EfficientLengthIterable":["double"],"Iterable":["double"]},"VersionRange":{"Comparable":["VersionRange"]}}')); + A._Universe_addRules(init.typeUniverse, JSON.parse('{"PlainJavaScriptObject":"LegacyJavaScriptObject","UnknownJavaScriptObject":"LegacyJavaScriptObject","JavaScriptFunction":"LegacyJavaScriptObject","JSBool":{"bool":[],"TrustedGetRuntimeType":[]},"JSNull":{"TrustedGetRuntimeType":[]},"JavaScriptObject":{"JSObject":[]},"LegacyJavaScriptObject":{"JSObject":[]},"JSArray":{"List":["1"],"EfficientLengthIterable":["1"],"JSObject":[],"Iterable":["1"]},"JSUnmodifiableArray":{"JSArray":["1"],"List":["1"],"EfficientLengthIterable":["1"],"JSObject":[],"Iterable":["1"]},"ArrayIterator":{"Iterator":["1"]},"JSNumber":{"double":[],"num":[],"Comparable":["num"]},"JSInt":{"double":[],"int":[],"num":[],"Comparable":["num"],"TrustedGetRuntimeType":[]},"JSNumNotInt":{"double":[],"num":[],"Comparable":["num"],"TrustedGetRuntimeType":[]},"JSString":{"String":[],"Comparable":["String"],"Pattern":[],"TrustedGetRuntimeType":[]},"_CastIterableBase":{"Iterable":["2"]},"CastIterator":{"Iterator":["2"]},"CastIterable":{"_CastIterableBase":["1","2"],"Iterable":["2"],"Iterable.E":"2"},"_EfficientLengthCastIterable":{"CastIterable":["1","2"],"_CastIterableBase":["1","2"],"EfficientLengthIterable":["2"],"Iterable":["2"],"Iterable.E":"2"},"_CastListBase":{"ListBase":["2"],"List":["2"],"_CastIterableBase":["1","2"],"EfficientLengthIterable":["2"],"Iterable":["2"]},"CastList":{"_CastListBase":["1","2"],"ListBase":["2"],"List":["2"],"_CastIterableBase":["1","2"],"EfficientLengthIterable":["2"],"Iterable":["2"],"ListBase.E":"2","Iterable.E":"2"},"CastMap":{"MapBase":["3","4"],"Map":["3","4"],"MapBase.K":"3","MapBase.V":"4"},"LateError":{"Error":[]},"CodeUnits":{"ListBase":["int"],"UnmodifiableListMixin":["int"],"List":["int"],"EfficientLengthIterable":["int"],"Iterable":["int"],"ListBase.E":"int"},"EfficientLengthIterable":{"Iterable":["1"]},"ListIterable":{"EfficientLengthIterable":["1"],"Iterable":["1"]},"SubListIterable":{"ListIterable":["1"],"EfficientLengthIterable":["1"],"Iterable":["1"],"Iterable.E":"1","ListIterable.E":"1"},"ListIterator":{"Iterator":["1"]},"MappedIterable":{"Iterable":["2"],"Iterable.E":"2"},"EfficientLengthMappedIterable":{"MappedIterable":["1","2"],"EfficientLengthIterable":["2"],"Iterable":["2"],"Iterable.E":"2"},"MappedIterator":{"Iterator":["2"]},"MappedListIterable":{"ListIterable":["2"],"EfficientLengthIterable":["2"],"Iterable":["2"],"Iterable.E":"2","ListIterable.E":"2"},"WhereIterable":{"Iterable":["1"],"Iterable.E":"1"},"WhereIterator":{"Iterator":["1"]},"WhereTypeIterable":{"Iterable":["1"],"Iterable.E":"1"},"WhereTypeIterator":{"Iterator":["1"]},"UnmodifiableListBase":{"ListBase":["1"],"UnmodifiableListMixin":["1"],"List":["1"],"EfficientLengthIterable":["1"],"Iterable":["1"]},"NullError":{"TypeError":[],"Error":[]},"JsNoSuchMethodError":{"Error":[]},"UnknownJsTypeError":{"Error":[]},"_StackTrace":{"StackTrace":[]},"Closure":{"Function":[]},"Closure0Args":{"Function":[]},"Closure2Args":{"Function":[]},"TearOffClosure":{"Function":[]},"StaticClosure":{"Function":[]},"BoundClosure":{"Function":[]},"_CyclicInitializationError":{"Error":[]},"RuntimeError":{"Error":[]},"_AssertionError":{"Error":[]},"JsLinkedHashMap":{"MapBase":["1","2"],"LinkedHashMap":["1","2"],"Map":["1","2"],"MapBase.K":"1","MapBase.V":"2"},"LinkedHashMapKeysIterable":{"EfficientLengthIterable":["1"],"Iterable":["1"],"Iterable.E":"1"},"LinkedHashMapKeyIterator":{"Iterator":["1"]},"JSSyntaxRegExp":{"RegExp":[],"Pattern":[]},"_MatchImplementation":{"RegExpMatch":[],"Match":[]},"_AllMatchesIterable":{"Iterable":["RegExpMatch"],"Iterable.E":"RegExpMatch"},"_AllMatchesIterator":{"Iterator":["RegExpMatch"]},"StringMatch":{"Match":[]},"_StringAllMatchesIterable":{"Iterable":["Match"],"Iterable.E":"Match"},"_StringAllMatchesIterator":{"Iterator":["Match"]},"NativeByteBuffer":{"JSObject":[],"ByteBuffer":[],"TrustedGetRuntimeType":[]},"NativeTypedData":{"JSObject":[]},"NativeByteData":{"ByteData":[],"JSObject":[],"TrustedGetRuntimeType":[]},"NativeTypedArray":{"JavaScriptIndexingBehavior":["1"],"JSObject":[]},"NativeTypedArrayOfDouble":{"ListBase":["double"],"List":["double"],"JavaScriptIndexingBehavior":["double"],"EfficientLengthIterable":["double"],"JSObject":[],"Iterable":["double"],"FixedLengthListMixin":["double"]},"NativeTypedArrayOfInt":{"ListBase":["int"],"List":["int"],"JavaScriptIndexingBehavior":["int"],"EfficientLengthIterable":["int"],"JSObject":[],"Iterable":["int"],"FixedLengthListMixin":["int"]},"NativeFloat32List":{"Float32List":[],"ListBase":["double"],"List":["double"],"JavaScriptIndexingBehavior":["double"],"EfficientLengthIterable":["double"],"JSObject":[],"Iterable":["double"],"FixedLengthListMixin":["double"],"TrustedGetRuntimeType":[],"ListBase.E":"double"},"NativeFloat64List":{"Float64List":[],"ListBase":["double"],"List":["double"],"JavaScriptIndexingBehavior":["double"],"EfficientLengthIterable":["double"],"JSObject":[],"Iterable":["double"],"FixedLengthListMixin":["double"],"TrustedGetRuntimeType":[],"ListBase.E":"double"},"NativeInt16List":{"Int16List":[],"ListBase":["int"],"List":["int"],"JavaScriptIndexingBehavior":["int"],"EfficientLengthIterable":["int"],"JSObject":[],"Iterable":["int"],"FixedLengthListMixin":["int"],"TrustedGetRuntimeType":[],"ListBase.E":"int"},"NativeInt32List":{"Int32List":[],"ListBase":["int"],"List":["int"],"JavaScriptIndexingBehavior":["int"],"EfficientLengthIterable":["int"],"JSObject":[],"Iterable":["int"],"FixedLengthListMixin":["int"],"TrustedGetRuntimeType":[],"ListBase.E":"int"},"NativeInt8List":{"Int8List":[],"ListBase":["int"],"List":["int"],"JavaScriptIndexingBehavior":["int"],"EfficientLengthIterable":["int"],"JSObject":[],"Iterable":["int"],"FixedLengthListMixin":["int"],"TrustedGetRuntimeType":[],"ListBase.E":"int"},"NativeUint16List":{"Uint16List":[],"ListBase":["int"],"List":["int"],"JavaScriptIndexingBehavior":["int"],"EfficientLengthIterable":["int"],"JSObject":[],"Iterable":["int"],"FixedLengthListMixin":["int"],"TrustedGetRuntimeType":[],"ListBase.E":"int"},"NativeUint32List":{"Uint32List":[],"ListBase":["int"],"List":["int"],"JavaScriptIndexingBehavior":["int"],"EfficientLengthIterable":["int"],"JSObject":[],"Iterable":["int"],"FixedLengthListMixin":["int"],"TrustedGetRuntimeType":[],"ListBase.E":"int"},"NativeUint8ClampedList":{"Uint8ClampedList":[],"ListBase":["int"],"List":["int"],"JavaScriptIndexingBehavior":["int"],"EfficientLengthIterable":["int"],"JSObject":[],"Iterable":["int"],"FixedLengthListMixin":["int"],"TrustedGetRuntimeType":[],"ListBase.E":"int"},"NativeUint8List":{"Uint8List":[],"ListBase":["int"],"List":["int"],"JavaScriptIndexingBehavior":["int"],"EfficientLengthIterable":["int"],"JSObject":[],"Iterable":["int"],"FixedLengthListMixin":["int"],"TrustedGetRuntimeType":[],"ListBase.E":"int"},"_Error":{"Error":[]},"_TypeError":{"TypeError":[],"Error":[]},"AsyncError":{"Error":[]},"_AsyncCompleter":{"_Completer":["1"]},"_Future":{"Future":["1"]},"_Zone":{"Zone":[]},"_RootZone":{"_Zone":[],"Zone":[]},"_HashMap":{"MapBase":["1","2"],"Map":["1","2"]},"_IdentityHashMap":{"_HashMap":["1","2"],"MapBase":["1","2"],"Map":["1","2"],"MapBase.K":"1","MapBase.V":"2"},"_HashMapKeyIterable":{"EfficientLengthIterable":["1"],"Iterable":["1"],"Iterable.E":"1"},"_HashMapKeyIterator":{"Iterator":["1"]},"ListBase":{"List":["1"],"EfficientLengthIterable":["1"],"Iterable":["1"]},"MapBase":{"Map":["1","2"]},"_JsonMap":{"MapBase":["String","@"],"Map":["String","@"],"MapBase.K":"String","MapBase.V":"@"},"_JsonMapKeyIterable":{"ListIterable":["String"],"EfficientLengthIterable":["String"],"Iterable":["String"],"Iterable.E":"String","ListIterable.E":"String"},"Base64Codec":{"Codec":["List","String"]},"Encoding":{"Codec":["String","List"]},"JsonCodec":{"Codec":["Object?","String"]},"Utf8Codec":{"Codec":["String","List"]},"double":{"num":[],"Comparable":["num"]},"int":{"num":[],"Comparable":["num"]},"List":{"EfficientLengthIterable":["1"],"Iterable":["1"]},"num":{"Comparable":["num"]},"RegExpMatch":{"Match":[]},"String":{"Comparable":["String"],"Pattern":[]},"AssertionError":{"Error":[]},"TypeError":{"Error":[]},"ArgumentError":{"Error":[]},"RangeError":{"Error":[]},"IndexError":{"Error":[]},"UnsupportedError":{"Error":[]},"UnimplementedError":{"Error":[]},"StateError":{"Error":[]},"ConcurrentModificationError":{"Error":[]},"OutOfMemoryError":{"Error":[]},"StackOverflowError":{"Error":[]},"_StringStackTrace":{"StackTrace":[]},"StringBuffer":{"StringSink":[]},"_Uri":{"Uri":[]},"_SimpleUri":{"Uri":[]},"_DataUri":{"Uri":[]},"PosixStyle":{"InternalStyle":[]},"UrlStyle":{"InternalStyle":[]},"WindowsStyle":{"InternalStyle":[]},"Version":{"VersionRange":[],"Comparable":["VersionRange"]},"Int8List":{"List":["int"],"EfficientLengthIterable":["int"],"Iterable":["int"]},"Uint8List":{"List":["int"],"EfficientLengthIterable":["int"],"Iterable":["int"]},"Uint8ClampedList":{"List":["int"],"EfficientLengthIterable":["int"],"Iterable":["int"]},"Int16List":{"List":["int"],"EfficientLengthIterable":["int"],"Iterable":["int"]},"Uint16List":{"List":["int"],"EfficientLengthIterable":["int"],"Iterable":["int"]},"Int32List":{"List":["int"],"EfficientLengthIterable":["int"],"Iterable":["int"]},"Uint32List":{"List":["int"],"EfficientLengthIterable":["int"],"Iterable":["int"]},"Float32List":{"List":["double"],"EfficientLengthIterable":["double"],"Iterable":["double"]},"Float64List":{"List":["double"],"EfficientLengthIterable":["double"],"Iterable":["double"]},"VersionRange":{"Comparable":["VersionRange"]}}')); A._Universe_addErasedTypes(init.typeUniverse, JSON.parse('{"UnmodifiableListBase":1,"__CastListBase__CastIterableBase_ListMixin":2,"NativeTypedArray":1,"Converter":2}')); var string$ = { + ______: "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\u03f6\x00\u0404\u03f4 \u03f4\u03f6\u01f6\u01f6\u03f6\u03fc\u01f4\u03ff\u03ff\u0584\u03ff\u03ff\u03ff\u03ff\u03ff\u03ff\u03ff\u03ff\u03ff\u03ff\u05d4\u01f4\x00\u01f4\x00\u0504\u05c4\u03ff\u03ff\u03ff\u03ff\u03ff\u03ff\u03ff\u03ff\u03ff\u03ff\u03ff\u03ff\u03ff\u03ff\u03ff\u03ff\u03ff\u03ff\u03ff\u03ff\u03ff\u03ff\u03ff\u03ff\u03ff\u03ff\u0400\x00\u0400\u0200\u03f7\u0200\u03ff\u03ff\u03ff\u03ff\u03ff\u03ff\u03ff\u03ff\u03ff\u03ff\u03ff\u03ff\u03ff\u03ff\u03ff\u03ff\u03ff\u03ff\u03ff\u03ff\u03ff\u03ff\u03ff\u03ff\u03ff\u03ff\u0200\u0200\u0200\u03f7\x00", Error_: "Error handler must accept one Object or one Object and a StackTrace as arguments, and return a value of the returned future's type", https_: "https://storage.googleapis.com/dart-archive/channels/" }; @@ -9524,17 +9433,14 @@ Float32List: findType("Float32List"), Float64List: findType("Float64List"), Function: findType("Function"), - FutureOr_String: findType("String/"), Future_dynamic: findType("Future<@>"), Int16List: findType("Int16List"), Int32List: findType("Int32List"), Int8List: findType("Int8List"), Iterable_String: findType("Iterable"), Iterable_dynamic: findType("Iterable<@>"), - Iterable_nullable_Object: findType("Iterable"), JSArray_Object: findType("JSArray"), JSArray_String: findType("JSArray"), - JSArray_Uint8List: findType("JSArray"), JSArray_dynamic: findType("JSArray<@>"), JSArray_int: findType("JSArray"), JSArray_nullable_String: findType("JSArray"), @@ -9543,9 +9449,9 @@ JavaScriptFunction: findType("JavaScriptFunction"), JavaScriptIndexingBehavior_dynamic: findType("JavaScriptIndexingBehavior<@>"), List_Object: findType("List"), - List_String: findType("List"), List_dynamic: findType("List<@>"), List_int: findType("List"), + Map_dynamic_dynamic: findType("Map<@,@>"), MappedListIterable_String_Object: findType("MappedListIterable"), MappedListIterable_String_dynamic: findType("MappedListIterable"), Null: findType("Null"), @@ -9580,11 +9486,18 @@ legacy_Object: findType("Object*"), nullable_Future_Null: findType("Future?"), nullable_JSObject: findType("JSObject?"), + nullable_List_dynamic: findType("List<@>?"), nullable_Object: findType("Object?"), + nullable_String: findType("String?"), nullable__FutureListener_dynamic_dynamic: findType("_FutureListener<@,@>?"), + nullable_bool: findType("bool?"), + nullable_double: findType("double?"), + nullable_int: findType("int?"), + nullable_num: findType("num?"), num: findType("num"), void: findType("~"), - void_Function: findType("~()") + void_Function: findType("~()"), + void_Function_String_dynamic: findType("~(String,@)") }; })(); (function constants() { @@ -9596,7 +9509,6 @@ B.JSString_methods = J.JSString.prototype; B.JavaScriptFunction_methods = J.JavaScriptFunction.prototype; B.JavaScriptObject_methods = J.JavaScriptObject.prototype; - B.NativeUint8List_methods = A.NativeUint8List.prototype; B.PlainJavaScriptObject_methods = J.PlainJavaScriptObject.prototype; B.UnknownJavaScriptObject_methods = J.UnknownJavaScriptObject.prototype; B.C_Base64Encoder = new A.Base64Encoder(); @@ -9728,30 +9640,25 @@ }; B.C_JS_CONST3 = function(hooks) { return hooks; } ; + B.C_JsonCodec = new A.JsonCodec(); B.C_OutOfMemoryError = new A.OutOfMemoryError(); B.C_Utf8Codec = new A.Utf8Codec(); B.C__RootZone = new A._RootZone(); B.C__StringStackTrace = new A._StringStackTrace(); - B.List_2jN = A._setArrayType(makeConstList([0, 0, 32722, 12287, 65534, 34815, 65534, 18431]), type$.JSArray_int); - B.List_42A = A._setArrayType(makeConstList([0, 0, 65490, 45055, 65535, 34815, 65534, 18431]), type$.JSArray_int); - B.List_4AN = A._setArrayType(makeConstList([0, 0, 32754, 11263, 65534, 34815, 65534, 18431]), type$.JSArray_int); - B.List_GVy = A._setArrayType(makeConstList([0, 0, 26624, 1023, 65534, 2047, 65534, 2047]), type$.JSArray_int); - B.List_M2I = A._setArrayType(makeConstList([0, 0, 65490, 12287, 65535, 34815, 65534, 18431]), type$.JSArray_int); - B.List_VOY = A._setArrayType(makeConstList([0, 0, 32776, 33792, 1, 10240, 0, 0]), type$.JSArray_int); + B.JsonDecoder_null = new A.JsonDecoder(null); B.List_empty = A._setArrayType(makeConstList([]), type$.JSArray_String); - B.List_piR = A._setArrayType(makeConstList([0, 0, 24576, 1023, 65534, 34815, 65534, 18431]), type$.JSArray_int); B.List_x64_ia32_arm_arm64 = A._setArrayType(makeConstList(["x64", "ia32", "arm", "arm64"]), type$.JSArray_String); - B.Type_ByteBuffer_EOZ = A.typeLiteral("ByteBuffer"); - B.Type_ByteData_mF8 = A.typeLiteral("ByteData"); - B.Type_Float32List_Ymk = A.typeLiteral("Float32List"); - B.Type_Float64List_Ymk = A.typeLiteral("Float64List"); - B.Type_Int16List_cot = A.typeLiteral("Int16List"); - B.Type_Int32List_m1p = A.typeLiteral("Int32List"); - B.Type_Int8List_woc = A.typeLiteral("Int8List"); - B.Type_Uint16List_2mh = A.typeLiteral("Uint16List"); - B.Type_Uint32List_2mh = A.typeLiteral("Uint32List"); - B.Type_Uint8ClampedList_9Bb = A.typeLiteral("Uint8ClampedList"); - B.Type_Uint8List_CSc = A.typeLiteral("Uint8List"); + B.Type_ByteBuffer_rqD = A.typeLiteral("ByteBuffer"); + B.Type_ByteData_9dB = A.typeLiteral("ByteData"); + B.Type_Float32List_9Kz = A.typeLiteral("Float32List"); + B.Type_Float64List_9Kz = A.typeLiteral("Float64List"); + B.Type_Int16List_s5h = A.typeLiteral("Int16List"); + B.Type_Int32List_O8Z = A.typeLiteral("Int32List"); + B.Type_Int8List_rFV = A.typeLiteral("Int8List"); + B.Type_Uint16List_kmP = A.typeLiteral("Uint16List"); + B.Type_Uint32List_kmP = A.typeLiteral("Uint32List"); + B.Type_Uint8ClampedList_04U = A.typeLiteral("Uint8ClampedList"); + B.Type_Uint8List_8Eb = A.typeLiteral("Uint8List"); B.Utf8Decoder_false = new A.Utf8Decoder(false); })(); (function staticFields() { @@ -9826,7 +9733,6 @@ _lazyFinal($, "_Utf8Decoder__decoder", "$get$_Utf8Decoder__decoder", () => new A._Utf8Decoder__decoder_closure().call$0()); _lazyFinal($, "_Utf8Decoder__decoderNonfatal", "$get$_Utf8Decoder__decoderNonfatal", () => new A._Utf8Decoder__decoderNonfatal_closure().call$0()); _lazyFinal($, "_Base64Decoder__inverseAlphabet", "$get$_Base64Decoder__inverseAlphabet", () => new Int8Array(A._ensureNativeList(A._setArrayType([-2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -2, -1, -2, -2, -2, -2, -2, 62, -2, 62, -2, 63, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, -2, -2, -2, -1, -2, -2, -2, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, -2, -2, -2, -2, 63, -2, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, -2, -2, -2, -2, -2], type$.JSArray_int)))); - _lazyFinal($, "_scannerTables", "$get$_scannerTables", () => A._createTables()); _lazyFinal($, "url", "$get$url", () => { var style = $.$get$Style_url(); return new A.Context(style); @@ -9887,6 +9793,9 @@ Function.prototype.call$4 = function(a, b, c, d) { return this(a, b, c, d); }; + Function.prototype.call$2$0 = function() { + return this(); + }; Function.prototype.call$1$1 = function(a) { return this(a); }; diff --git a/dist/sig.txt b/dist/sig.txt index 1a24e07..6401ac8 100644 --- a/dist/sig.txt +++ b/dist/sig.txt @@ -1 +1 @@ -c1bf4d27eb2cefd92e24524f7a5d4613 +27f84f29568ea4f8e733983f9d71ff90 diff --git a/lib/main.dart b/lib/main.dart index bd5e3ca..e666321 100644 --- a/lib/main.dart +++ b/lib/main.dart @@ -2,8 +2,8 @@ // for details. All rights reserved. Use of this source code is governed by a // BSD-style license that can be found in the LICENSE file. +import 'dart:convert'; import 'dart:js_interop'; -import 'dart:js_util'; import 'package:path/path.dart' as path; import 'package:pub_semver/pub_semver.dart'; @@ -112,13 +112,15 @@ Future _impl(List args) async { process.env('RUNNER_TEMP')!, path.url.basename(url), ); - await promiseToFuture(toolCache.downloadTool(url, archivePath)); + await toolCache.downloadTool(url, archivePath).toDart; var extractedFolder = - await promiseToFuture(toolCache.extractZip(archivePath)); + (await toolCache.extractZip(archivePath).toDart).toDart; extractedFolder = path.join(extractedFolder, 'dart-sdk'); - sdkPath = await promiseToFuture( - toolCache.cacheDir(extractedFolder, toolName, version, architecture)); + sdkPath = (await toolCache + .cacheDir(extractedFolder, toolName, version, architecture) + .toDart) + .toDart; } final pubCache = path.join( @@ -136,10 +138,7 @@ Future _impl(List args) async { core.setOutput('dart-version', getVersionFromSdk(sdkPath)); // Report success; print version. - await promiseToFuture(exec.exec( - 'dart', - ['--version'.toJS].toJS, - )); + await exec.exec('dart', ['--version'.toJS].toJS).toDart; } String getVersionFromSdk(String sdkPath) { @@ -172,22 +171,22 @@ Future createPubOIDCToken() async { return; } - final token = - await promiseToFuture(core.getIDToken('https://pub.dev')); + final token = (await core.getIDToken('https://pub.dev').toDart).toDart; core.exportVariable('PUB_TOKEN', token); - await promiseToFuture(exec.exec( - 'dart', - [ - 'pub'.toJS, - 'token'.toJS, - 'add'.toJS, - 'https://pub.dev'.toJS, - '--env-var'.toJS, - 'PUB_TOKEN'.toJS, - ].toJS, - )); + await exec + .exec( + 'dart', + [ + 'pub'.toJS, + 'token'.toJS, + 'add'.toJS, + 'https://pub.dev'.toJS, + '--env-var'.toJS, + 'PUB_TOKEN'.toJS, + ].toJS) + .toDart; } // https://storage.googleapis.com/dart-archive/channels/stable/release/latest/VERSION @@ -206,17 +205,18 @@ Future latestPublishedVersion(String channel, String flavor) async { final http = HttpClient( 'setup-dart', [].toJS, - jsify({ + { 'allowRedirects': true, 'maxRedirects': 3, 'allowRetries': true, 'maxRetries': 3, - }) as JSObject?, + }.jsify() as JSObject?, ); - var response = await promiseToFuture(http.getJson(url)); - var result = getProperty(response, 'result'); - return getProperty(result, 'version'); + var response = (await http.get(url).toDart) as HttpClientResponse; + var data = (await response.readBody().toDart).toDart; + var json = (jsonDecode(data) as Map).cast(); + return json['version'] as String; } /// Find the latest SDK patch version for the given SDK release. @@ -230,12 +230,12 @@ Future findLatestSdkForRelease(String sdkRelease) async { final http = HttpClient( 'setup-dart', [].toJS, - jsify({ + { 'allowRedirects': true, 'maxRedirects': 3, 'allowRetries': true, 'maxRetries': 3, - }) as JSObject?, + }.jsify() as JSObject?, ); // { @@ -247,10 +247,11 @@ Future findLatestSdkForRelease(String sdkRelease) async { // "channels/stable/release/2.19.6/" // ] // } - var response = await promiseToFuture(http.getJson(url)); - var result = getProperty(response, 'result'); + var response = (await http.get(url).toDart) as HttpClientResponse; + var data = (await response.readBody().toDart).toDart; + var json = (jsonDecode(data) as Map).cast(); - final paths = (getProperty(result, 'prefixes') as List).cast(); + final paths = (json['prefixes'] as List).cast(); final versions = paths.map((p) => (p.split('/')..removeLast()).last).toList(); // Sort versions by semver and return the highest version. diff --git a/lib/node/actions/core.dart b/lib/node/actions/core.dart index 5e59252..2608103 100644 --- a/lib/node/actions/core.dart +++ b/lib/node/actions/core.dart @@ -21,6 +21,5 @@ extension type Core(JSObject obj) { external void exportVariable(String name, String value); - // JSPromise - external JSPromise getIDToken(String audience); + external JSPromise getIDToken(String audience); } diff --git a/lib/node/actions/http_client.dart b/lib/node/actions/http_client.dart index 22d7273..33e03d3 100644 --- a/lib/node/actions/http_client.dart +++ b/lib/node/actions/http_client.dart @@ -12,6 +12,12 @@ extension type HttpClient._(JSObject obj) { JSObject? requestOptions, ]); - // JSPromise - external JSPromise getJson(String requestUrl); + // JSPromise + external JSPromise get(String requestUrl); + external JSPromise getJson(String requestUrl); +} + +@JS() +extension type HttpClientResponse._(JSObject obj) { + external JSPromise readBody(); } diff --git a/lib/node/actions/tool_cache.dart b/lib/node/actions/tool_cache.dart index 33c5c85..2c61c0f 100644 --- a/lib/node/actions/tool_cache.dart +++ b/lib/node/actions/tool_cache.dart @@ -25,14 +25,13 @@ extension type ToolCache(JSObject obj) { /// @param url url of tool to download /// @param dest path to download tool /// @returns path to downloaded tool - // JSPromise - external JSPromise downloadTool(String url, [String? dest]); + external JSPromise downloadTool(String url, [String? dest]); /// Extract a zip. /// /// @param file path to the zip /// @returns path to the destination directory - external JSPromise extractZip(String file); + external JSPromise extractZip(String file); /// Caches a directory and installs it into the tool cacheDir /// @@ -41,7 +40,7 @@ extension type ToolCache(JSObject obj) { /// @param version version of the tool. semver format /// @param arch architecture of the tool. Optional. /// Defaults to machine architecture - external JSPromise cacheDir( + external JSPromise cacheDir( String sourceDir, String tool, String version, [ diff --git a/lib/node/process.dart b/lib/node/process.dart index 386a0f7..9e97972 100644 --- a/lib/node/process.dart +++ b/lib/node/process.dart @@ -3,7 +3,7 @@ // BSD-style license that can be found in the LICENSE file. import 'dart:js_interop'; -import 'dart:js_util'; +import 'dart:js_interop_unsafe'; /// Provides information about, and control over, the current Node.js process. /// Wraps https://nodejs.org/api/process.html @@ -17,7 +17,9 @@ extension type Process(JSObject obj) { external JSObject get _env; /// Read the environment variable [variable]. - String? env(String variable) => getProperty(_env, variable); + String? env(String variable) { + return _env.getProperty(variable.toJS)?.toDart; + } external int exitCode; } diff --git a/package-lock.json b/package-lock.json index ca58892..f9400fe 100644 --- a/package-lock.json +++ b/package-lock.json @@ -19,6 +19,7 @@ "version": "1.11.1", "resolved": "https://registry.npmjs.org/@actions/core/-/core-1.11.1.tgz", "integrity": "sha512-hXJCSrkwfA46Vd9Z3q4cpEpHB1rL5NG04+/rbqW9d3+CSvtB1tYe8UTpAlixa1vj0m/ULglfEK2UKxMGxCxv5A==", + "license": "MIT", "dependencies": { "@actions/exec": "^1.1.1", "@actions/http-client": "^2.0.1" @@ -37,6 +38,7 @@ "version": "2.2.3", "resolved": "https://registry.npmjs.org/@actions/http-client/-/http-client-2.2.3.tgz", "integrity": "sha512-mx8hyJi/hjFvbPokCg4uRd4ZX78t+YyRPtnKWwIl+RzNaVuFpQHfmlGVfsKEJN8LwTCvL+DfVgAM04XaHkm6bA==", + "license": "MIT", "dependencies": { "tunnel": "^0.0.6", "undici": "^5.25.4" diff --git a/pubspec.yaml b/pubspec.yaml index 36beac6..a541586 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -13,4 +13,4 @@ dependencies: dev_dependencies: args: ^2.4.0 crypto: ^3.0.0 - dart_flutter_team_lints: ^2.0.0 + dart_flutter_team_lints: ^3.0.0