From 24d423429835ceafa3fe63e59ee5071b649e6255 Mon Sep 17 00:00:00 2001 From: Dhvani Patel Date: Fri, 1 Mar 2024 09:02:27 +0000 Subject: [PATCH] feat: compile to cjs --- docs/package.json | 1 - e2e/packages/client-vanilla/package.json | 1 - e2e/packages/sync-test/package.json | 4 +- .../sync-test/setup/deployContracts.ts | 2 +- e2e/packages/sync-test/setup/startIndexer.ts | 2 +- e2e/packages/test-data/generateLogs.ts | 2 +- e2e/packages/test-data/package.json | 3 +- examples/faucet-client/package.json | 1 - examples/indexer-client/package.json | 1 - .../packages/client-phaser/package.json | 1 - .../packages/client-react/package.json | 1 - .../packages/client-vanilla/package.json | 1 - .../packages/plugin-example/package.json | 1 - .../packages/plugin-example/tsup.config.ts | 2 +- .../packages/client/package.json | 1 - package.json | 4 +- packages/abi-ts/package.json | 5 +- packages/abi-ts/tsup.config.ts | 2 +- packages/block-logs-stream/package.json | 1 - packages/block-logs-stream/tsup.config.ts | 2 +- packages/cli/package.json | 7 +- packages/cli/scripts/generate-test-tables.ts | 16 +- packages/cli/src/build.ts | 2 +- packages/cli/src/commands/devnode.ts | 2 +- packages/cli/tsup.config.ts | 2 +- packages/common/package.json | 9 +- packages/common/src/foundry/index.ts | 2 +- packages/common/tsup.config.ts | 2 +- packages/config/package.json | 3 +- packages/config/src/node/loadConfig.ts | 2 +- packages/config/tsup.config.ts | 2 +- packages/dev-tools/package.json | 1 - packages/dev-tools/tsup.config.ts | 2 +- packages/faucet/bin/faucet-server.ts | 46 +- packages/faucet/package.json | 1 - packages/faucet/tsup.config.ts | 2 +- packages/gas-report/package.json | 6 +- packages/gas-report/ts/index.ts | 8 +- packages/gas-report/tsup.config.ts | 2 +- packages/noise/build/release.wasm | Bin 3255 -> 3251 bytes packages/noise/build/release.wasm.map | 2 +- packages/noise/build/release.wat | 46 +- packages/noise/package.json | 1 - packages/noise/tsup.config.ts | 2 +- packages/phaserx/package.json | 1 - packages/phaserx/tsup.config.ts | 2 +- packages/protocol-parser/package.json | 1 - packages/protocol-parser/tsup.config.ts | 2 +- packages/react/package.json | 1 - packages/react/tsup.config.ts | 2 +- packages/recs/package.json | 1 - packages/recs/tsup.config.ts | 2 +- packages/schema-type/package.json | 1 - packages/schema-type/tsup.config.ts | 2 +- packages/services/package.json | 1 - packages/services/tsup.config.ts | 2 +- .../bin/postgres-decoded-indexer.ts | 187 +- .../store-indexer/bin/postgres-indexer.ts | 193 +- packages/store-indexer/bin/sqlite-indexer.ts | 173 +- packages/store-indexer/package.json | 1 - packages/store-indexer/tsup.config.ts | 2 +- packages/store-sync/package.json | 1 - packages/store-sync/tsup.config.ts | 2 +- packages/store/package.json | 1 - .../store/ts/scripts/generate-test-tables.ts | 8 +- .../store/ts/scripts/generate-tightcoder.ts | 16 +- packages/store/ts/scripts/tablegen.ts | 10 +- packages/store/tsup.config.ts | 2 +- packages/utils/package.json | 1 - packages/utils/tsup.config.ts | 2 +- packages/world-modules/package.json | 1 - packages/world-modules/ts/scripts/tablegen.ts | 10 +- packages/world-modules/ts/scripts/worldgen.ts | 34 +- packages/world-modules/tsup.config.ts | 2 +- packages/world/package.json | 1 - .../world/ts/scripts/generate-test-tables.ts | 9 +- packages/world/ts/scripts/tablegen.ts | 10 +- packages/world/ts/scripts/worldgen.ts | 38 +- packages/world/tsup.config.ts | 2 +- pnpm-lock.yaml | 6658 ++++++++--------- scripts/changelog.ts | 2 +- scripts/render-api-docs.ts | 2 +- templates/phaser/packages/client/package.json | 1 - .../react-ecs/packages/client/package.json | 1 - templates/react/packages/client/package.json | 1 - .../threejs/packages/client/package.json | 1 - .../vanilla/packages/client/package.json | 1 - 87 files changed, 3506 insertions(+), 4091 deletions(-) diff --git a/docs/package.json b/docs/package.json index a3b4c30688..e28208102e 100644 --- a/docs/package.json +++ b/docs/package.json @@ -4,7 +4,6 @@ "private": true, "description": "mud.dev docs", "license": "", - "type": "module", "main": "index.js", "scripts": { "build": "next build", diff --git a/e2e/packages/client-vanilla/package.json b/e2e/packages/client-vanilla/package.json index 89bf99c5ec..3bf921cb35 100644 --- a/e2e/packages/client-vanilla/package.json +++ b/e2e/packages/client-vanilla/package.json @@ -3,7 +3,6 @@ "version": "0.0.0", "private": true, "license": "MIT", - "type": "module", "scripts": { "build": "vite build", "clean": "rimraf dist", diff --git a/e2e/packages/sync-test/package.json b/e2e/packages/sync-test/package.json index b7478f5864..5b2e09ff2d 100644 --- a/e2e/packages/sync-test/package.json +++ b/e2e/packages/sync-test/package.json @@ -21,10 +21,10 @@ "@latticexyz/utils": "link:../../../packages/utils", "@viem/anvil": "^0.0.6", "abitype": "1.0.0", - "chalk": "^5.2.0", + "chalk": "4.1.2", "dotenv": "^16.0.3", "drizzle-orm": "^0.28.5", - "execa": "^7.1.1", + "execa": "^5.1.1", "happy-dom": "^12.10.3", "postgres": "3.3.5", "typescript": "5.1.6", diff --git a/e2e/packages/sync-test/setup/deployContracts.ts b/e2e/packages/sync-test/setup/deployContracts.ts index 929dfb1d61..688cdc4fc6 100644 --- a/e2e/packages/sync-test/setup/deployContracts.ts +++ b/e2e/packages/sync-test/setup/deployContracts.ts @@ -1,5 +1,5 @@ import chalk from "chalk"; -import { execa } from "execa"; +import execa from "execa"; export function deployContracts(rpc: string) { const deploymentProcess = execa("pnpm", ["mud", "deploy", "--rpc", rpc], { diff --git a/e2e/packages/sync-test/setup/startIndexer.ts b/e2e/packages/sync-test/setup/startIndexer.ts index 5bff7e397f..f082b6c7b8 100644 --- a/e2e/packages/sync-test/setup/startIndexer.ts +++ b/e2e/packages/sync-test/setup/startIndexer.ts @@ -1,5 +1,5 @@ import chalk from "chalk"; -import { execa } from "execa"; +import execa from "execa"; import { rmSync } from "node:fs"; import { cleanDatabase } from "@latticexyz/store-sync/postgres"; import { drizzle } from "drizzle-orm/postgres-js"; diff --git a/e2e/packages/test-data/generateLogs.ts b/e2e/packages/test-data/generateLogs.ts index fff5449b2f..5d7a0a9a42 100644 --- a/e2e/packages/test-data/generateLogs.ts +++ b/e2e/packages/test-data/generateLogs.ts @@ -1,4 +1,4 @@ -import { execa } from "execa"; +import execa from "execa"; import { ClientConfig, GetContractReturnType, diff --git a/e2e/packages/test-data/package.json b/e2e/packages/test-data/package.json index f44e8e616b..1902816eaf 100644 --- a/e2e/packages/test-data/package.json +++ b/e2e/packages/test-data/package.json @@ -3,7 +3,6 @@ "version": "0.0.0", "private": true, "license": "MIT", - "type": "module", "scripts": { "generate-bench-data-bulk": "tsx generate-bench-data-bulk.ts", "generate-bench-data-query": "tsx generate-bench-data-query.ts", @@ -15,7 +14,7 @@ "@latticexyz/common": "link:../../../packages/common", "@latticexyz/store": "link:../../../packages/store", "@viem/anvil": "^0.0.6", - "execa": "^7.1.1", + "execa": "^5.1.1", "tsx": "^3.12.6", "typescript": "5.1.6", "viem": "2.7.12" diff --git a/examples/faucet-client/package.json b/examples/faucet-client/package.json index e64f808787..47dcf058a4 100644 --- a/examples/faucet-client/package.json +++ b/examples/faucet-client/package.json @@ -3,7 +3,6 @@ "version": "0.0.0", "private": true, "license": "MIT", - "type": "module", "scripts": { "drip": "tsx index.ts" }, diff --git a/examples/indexer-client/package.json b/examples/indexer-client/package.json index 3ad7366071..4c592cfac0 100644 --- a/examples/indexer-client/package.json +++ b/examples/indexer-client/package.json @@ -3,7 +3,6 @@ "version": "0.0.0", "private": true, "license": "MIT", - "type": "module", "scripts": { "read-indexer": "tsx index.ts" }, diff --git a/examples/minimal/packages/client-phaser/package.json b/examples/minimal/packages/client-phaser/package.json index 16644ea096..9a98f0ad30 100644 --- a/examples/minimal/packages/client-phaser/package.json +++ b/examples/minimal/packages/client-phaser/package.json @@ -3,7 +3,6 @@ "version": "0.0.0", "private": true, "license": "MIT", - "type": "module", "scripts": { "build": "vite build", "dev": "vite", diff --git a/examples/minimal/packages/client-react/package.json b/examples/minimal/packages/client-react/package.json index 9473eb0f9e..0434690134 100644 --- a/examples/minimal/packages/client-react/package.json +++ b/examples/minimal/packages/client-react/package.json @@ -3,7 +3,6 @@ "version": "0.0.0", "private": true, "license": "MIT", - "type": "module", "scripts": { "build": "vite build", "dev": "wait-port localhost:8545 && vite", diff --git a/examples/minimal/packages/client-vanilla/package.json b/examples/minimal/packages/client-vanilla/package.json index a4566f54da..2f653565c2 100644 --- a/examples/minimal/packages/client-vanilla/package.json +++ b/examples/minimal/packages/client-vanilla/package.json @@ -3,7 +3,6 @@ "version": "0.0.0", "private": true, "license": "MIT", - "type": "module", "scripts": { "build": "vite build", "dev": "wait-port localhost:8545 && vite", diff --git a/examples/minimal/packages/plugin-example/package.json b/examples/minimal/packages/plugin-example/package.json index f21d04ca18..8bce87bc4f 100644 --- a/examples/minimal/packages/plugin-example/package.json +++ b/examples/minimal/packages/plugin-example/package.json @@ -3,7 +3,6 @@ "version": "0.0.0", "private": true, "license": "MIT", - "type": "module", "exports": { ".": "./dist/ts/library/index.js", "./register": "./dist/ts/register/index.js" diff --git a/examples/minimal/packages/plugin-example/tsup.config.ts b/examples/minimal/packages/plugin-example/tsup.config.ts index c13db6face..2a36085c5b 100644 --- a/examples/minimal/packages/plugin-example/tsup.config.ts +++ b/examples/minimal/packages/plugin-example/tsup.config.ts @@ -3,7 +3,7 @@ import { defineConfig } from "tsup"; export default defineConfig({ entry: ["ts/library/index.ts", "ts/register/index.ts"], target: "esnext", - format: ["esm"], + format: ["esm", "cjs"], dts: false, sourcemap: true, clean: true, diff --git a/examples/multiple-accounts/packages/client/package.json b/examples/multiple-accounts/packages/client/package.json index bcd7943147..6a34afc583 100644 --- a/examples/multiple-accounts/packages/client/package.json +++ b/examples/multiple-accounts/packages/client/package.json @@ -3,7 +3,6 @@ "version": "0.0.0", "private": true, "license": "MIT", - "type": "module", "scripts": { "build": "vite build", "dev": "wait-port localhost:8545 && vite", diff --git a/package.json b/package.json index bba838942d..e0bfa97d6e 100644 --- a/package.json +++ b/package.json @@ -40,9 +40,9 @@ "@typescript-eslint/eslint-plugin": "5.46.1", "@typescript-eslint/parser": "5.46.1", "bun": "^1.0.11", - "chalk": "^5.2.0", + "chalk": "4.1.2", "eslint": "8.29.0", - "execa": "^7.0.0", + "execa": "^5.1.1", "husky": ">=6", "lint-staged": ">=10", "prettier": "^2.8.4", diff --git a/packages/abi-ts/package.json b/packages/abi-ts/package.json index e0200e313c..9cc2eb6cd9 100644 --- a/packages/abi-ts/package.json +++ b/packages/abi-ts/package.json @@ -8,7 +8,6 @@ "directory": "packages/abi-ts" }, "license": "MIT", - "type": "module", "exports": { ".": "./dist/index.js" }, @@ -31,9 +30,9 @@ "test:ci": "pnpm run test" }, "dependencies": { - "chalk": "^5.3.0", + "chalk": "4.1.2", "debug": "^4.3.4", - "execa": "^7.0.0", + "execa": "^5.1.1", "glob": "^8.0.3", "yargs": "^17.7.1" }, diff --git a/packages/abi-ts/tsup.config.ts b/packages/abi-ts/tsup.config.ts index 783fa85248..f55598f382 100644 --- a/packages/abi-ts/tsup.config.ts +++ b/packages/abi-ts/tsup.config.ts @@ -3,7 +3,7 @@ import { defineConfig } from "tsup"; export default defineConfig({ entry: ["src/index.ts", "src/abi-ts.ts"], target: "esnext", - format: ["esm"], + format: ["esm", "cjs"], dts: true, sourcemap: true, clean: true, diff --git a/packages/block-logs-stream/package.json b/packages/block-logs-stream/package.json index f2986ec88e..537466e4ab 100644 --- a/packages/block-logs-stream/package.json +++ b/packages/block-logs-stream/package.json @@ -8,7 +8,6 @@ "directory": "packages/block-logs-stream" }, "license": "MIT", - "type": "module", "exports": { ".": "./dist/index.js" }, diff --git a/packages/block-logs-stream/tsup.config.ts b/packages/block-logs-stream/tsup.config.ts index 52bdfceee6..d139373ac6 100644 --- a/packages/block-logs-stream/tsup.config.ts +++ b/packages/block-logs-stream/tsup.config.ts @@ -3,7 +3,7 @@ import { defineConfig } from "tsup"; export default defineConfig({ entry: ["src/index.ts"], target: "esnext", - format: ["esm"], + format: ["esm", "cjs"], dts: true, sourcemap: true, clean: true, diff --git a/packages/cli/package.json b/packages/cli/package.json index 2c429e3b87..389533c6e5 100644 --- a/packages/cli/package.json +++ b/packages/cli/package.json @@ -8,7 +8,6 @@ "directory": "packages/cli" }, "license": "MIT", - "type": "module", "exports": { ".": "./dist/index.js" }, @@ -45,17 +44,17 @@ "@latticexyz/utils": "workspace:*", "@latticexyz/world": "workspace:*", "@latticexyz/world-modules": "workspace:*", - "chalk": "^5.0.1", + "chalk": "4.1.2", "chokidar": "^3.5.3", "debug": "^4.3.4", "dotenv": "^16.0.3", "ejs": "^3.1.8", "ethers": "^5.7.2", - "execa": "^7.0.0", + "execa": "^5.1.1", "glob": "^8.0.3", "nice-grpc-web": "^2.0.1", "openurl": "^1.1.1", - "p-retry": "^5.1.2", + "p-retry": "4.6.2", "path": "^0.12.7", "rxjs": "7.5.5", "throttle-debounce": "^5.0.0", diff --git a/packages/cli/scripts/generate-test-tables.ts b/packages/cli/scripts/generate-test-tables.ts index 450dda72fc..231a993f67 100644 --- a/packages/cli/scripts/generate-test-tables.ts +++ b/packages/cli/scripts/generate-test-tables.ts @@ -94,11 +94,13 @@ try { logError(error); } -const srcDirectory = await getSrcDirectory(); -const remappings = await getRemappings(); +(async () => { + const srcDirectory = await getSrcDirectory(); + const remappings = await getRemappings(); -if (config !== undefined) { - tablegen(config, path.join(srcDirectory, config.codegenDirectory), remappings); -} else { - process.exit(1); -} + if (config !== undefined) { + tablegen(config, path.join(srcDirectory, config.codegenDirectory), remappings); + } else { + process.exit(1); + } +})(); diff --git a/packages/cli/src/build.ts b/packages/cli/src/build.ts index 879bc1bdc3..de9dc10d89 100644 --- a/packages/cli/src/build.ts +++ b/packages/cli/src/build.ts @@ -7,7 +7,7 @@ import { WorldConfig } from "@latticexyz/world"; import { forge, getForgeConfig, getRemappings } from "@latticexyz/common/foundry"; import { getExistingContracts } from "./utils/getExistingContracts"; import { debug as parentDebug } from "./debug"; -import { execa } from "execa"; +import execa from "execa"; const debug = parentDebug.extend("runDeploy"); diff --git a/packages/cli/src/commands/devnode.ts b/packages/cli/src/commands/devnode.ts index 84378c75af..6452010c73 100644 --- a/packages/cli/src/commands/devnode.ts +++ b/packages/cli/src/commands/devnode.ts @@ -2,7 +2,7 @@ import { rmSync } from "fs"; import { homedir } from "os"; import path from "path"; import type { CommandModule } from "yargs"; -import { execa } from "execa"; +import execa from "execa"; type Options = { blocktime: number; diff --git a/packages/cli/tsup.config.ts b/packages/cli/tsup.config.ts index 8e74fd917d..c1be2262c1 100644 --- a/packages/cli/tsup.config.ts +++ b/packages/cli/tsup.config.ts @@ -20,7 +20,7 @@ const mudPackages: MudPackages = Object.fromEntries( export default defineConfig({ entry: ["src/index.ts", "src/mud.ts"], target: "esnext", - format: ["esm"], + format: ["esm", "cjs"], dts: false, sourcemap: true, clean: true, diff --git a/packages/common/package.json b/packages/common/package.json index 216270c946..087832112a 100644 --- a/packages/common/package.json +++ b/packages/common/package.json @@ -8,7 +8,6 @@ "directory": "packages/common" }, "license": "MIT", - "type": "module", "exports": { ".": "./dist/index.js", "./chains": "./dist/chains.js", @@ -56,10 +55,10 @@ "@latticexyz/schema-type": "workspace:*", "@solidity-parser/parser": "^0.16.0", "debug": "^4.3.4", - "execa": "^7.0.0", - "p-queue": "^7.4.1", - "p-retry": "^5.1.2", - "prettier": "^2.8.4", + "execa": "^5.1.1", + "p-queue": "6.6.2", + "p-retry": "4.6.2", + "prettier": "^3.2.5", "prettier-plugin-solidity": "1.1.3", "viem": "2.7.12" }, diff --git a/packages/common/src/foundry/index.ts b/packages/common/src/foundry/index.ts index b7f29ee61a..f2b3a7a88f 100644 --- a/packages/common/src/foundry/index.ts +++ b/packages/common/src/foundry/index.ts @@ -1,4 +1,4 @@ -import { execa, Options } from "execa"; +import execa, { Options } from "execa"; export interface ForgeConfig { // project diff --git a/packages/common/tsup.config.ts b/packages/common/tsup.config.ts index ba8ccf3917..4250ba5210 100644 --- a/packages/common/tsup.config.ts +++ b/packages/common/tsup.config.ts @@ -11,7 +11,7 @@ export default defineConfig({ utils: "src/utils/index.ts", }, target: "esnext", - format: ["esm"], + format: ["esm", "cjs"], dts: true, sourcemap: true, clean: true, diff --git a/packages/config/package.json b/packages/config/package.json index 2619576b50..3c105ec40e 100644 --- a/packages/config/package.json +++ b/packages/config/package.json @@ -8,7 +8,6 @@ "directory": "packages/config" }, "license": "MIT", - "type": "module", "exports": { ".": "./dist/library/index.js", "./register": "./dist/register/index.js", @@ -40,7 +39,7 @@ "@latticexyz/common": "workspace:*", "@latticexyz/schema-type": "workspace:*", "esbuild": "^0.17.15", - "find-up": "^6.3.0", + "find-up": "5.0.0", "viem": "2.7.12", "zod": "^3.21.4", "zod-validation-error": "^1.3.0" diff --git a/packages/config/src/node/loadConfig.ts b/packages/config/src/node/loadConfig.ts index 260b963102..372cf03bca 100644 --- a/packages/config/src/node/loadConfig.ts +++ b/packages/config/src/node/loadConfig.ts @@ -1,4 +1,4 @@ -import { findUp } from "find-up"; +import findUp from "find-up"; import path from "path"; import { NotInsideProjectError } from "../library/errors"; import esbuild from "esbuild"; diff --git a/packages/config/tsup.config.ts b/packages/config/tsup.config.ts index ea905447a9..c702780b11 100644 --- a/packages/config/tsup.config.ts +++ b/packages/config/tsup.config.ts @@ -3,7 +3,7 @@ import { defineConfig } from "tsup"; export default defineConfig({ entry: ["src/library/index.ts", "src/register/index.ts", "src/node/index.ts"], target: "esnext", - format: ["esm"], + format: ["esm", "cjs"], dts: true, sourcemap: true, clean: true, diff --git a/packages/dev-tools/package.json b/packages/dev-tools/package.json index b5ef1db8b4..bc1c1098ac 100644 --- a/packages/dev-tools/package.json +++ b/packages/dev-tools/package.json @@ -8,7 +8,6 @@ "directory": "packages/dev-tools" }, "license": "MIT", - "type": "module", "exports": { ".": "./dist/index.js" }, diff --git a/packages/dev-tools/tsup.config.ts b/packages/dev-tools/tsup.config.ts index 7189afad8e..9e1ac6080b 100644 --- a/packages/dev-tools/tsup.config.ts +++ b/packages/dev-tools/tsup.config.ts @@ -15,7 +15,7 @@ const bundledDeps = Object.keys(packageJson.dependencies).filter((dep) => !peerD export default defineConfig({ entry: ["src/index.ts"], target: "esnext", - format: ["esm"], + format: ["esm", "cjs"], dts: true, sourcemap: true, clean: true, diff --git a/packages/faucet/bin/faucet-server.ts b/packages/faucet/bin/faucet-server.ts index dbbd0ac73a..602004f212 100644 --- a/packages/faucet/bin/faucet-server.ts +++ b/packages/faucet/bin/faucet-server.ts @@ -21,25 +21,27 @@ const server = fastify({ logger: true, }); -await server.register(import("@fastify/compress")); -await server.register(import("@fastify/cors")); - -// k8s healthchecks -server.get("/healthz", (req, res) => res.code(200).send()); -server.get("/readyz", (req, res) => res.code(200).send()); - -// @see https://trpc.io/docs/server/adapters/fastify -server.register(fastifyTRPCPlugin, { - prefix: "/trpc", - trpcOptions: { - router: createAppRouter(), - createContext: async () => ({ - client, - faucetAccount, - dripAmount: env.DRIP_AMOUNT_ETHER, - }), - }, -}); - -await server.listen({ host: env.HOST, port: env.PORT }); -console.log(`faucet server listening on http://${env.HOST}:${env.PORT}`); +(async (): Promise => { + await server.register(import("@fastify/compress")); + await server.register(import("@fastify/cors")); + + // k8s healthchecks + server.get("/healthz", (req, res) => res.code(200).send()); + server.get("/readyz", (req, res) => res.code(200).send()); + + // @see https://trpc.io/docs/server/adapters/fastify + server.register(fastifyTRPCPlugin, { + prefix: "/trpc", + trpcOptions: { + router: createAppRouter(), + createContext: async () => ({ + client, + faucetAccount, + dripAmount: env.DRIP_AMOUNT_ETHER, + }), + }, + }); + + await server.listen({ host: env.HOST, port: env.PORT }); + console.log(`faucet server listening on http://${env.HOST}:${env.PORT}`); +})(); diff --git a/packages/faucet/package.json b/packages/faucet/package.json index c4a455a39d..00a549e107 100644 --- a/packages/faucet/package.json +++ b/packages/faucet/package.json @@ -8,7 +8,6 @@ "directory": "packages/faucet" }, "license": "MIT", - "type": "module", "exports": { ".": "./dist/src/index.js" }, diff --git a/packages/faucet/tsup.config.ts b/packages/faucet/tsup.config.ts index cadbc2f970..f663aaf794 100644 --- a/packages/faucet/tsup.config.ts +++ b/packages/faucet/tsup.config.ts @@ -3,7 +3,7 @@ import { defineConfig } from "tsup"; export default defineConfig({ entry: ["src/index.ts", "bin/faucet-server.ts"], target: "esnext", - format: ["esm"], + format: ["esm", "cjs"], dts: true, sourcemap: true, clean: true, diff --git a/packages/gas-report/package.json b/packages/gas-report/package.json index d366a4dc25..513c107f4e 100644 --- a/packages/gas-report/package.json +++ b/packages/gas-report/package.json @@ -8,7 +8,6 @@ "directory": "packages/gas-report" }, "license": "MIT", - "type": "module", "exports": { ".": "./dist/index.js" }, @@ -31,11 +30,10 @@ "test:ci": "pnpm run test" }, "dependencies": { - "chalk": "^5.3.0", + "chalk": "4.1.2", "dotenv": "^16.0.3", - "execa": "^7.0.0", + "execa": "^5.1.1", "stream-to-array": "^2.3.0", - "strip-ansi": "^7.1.0", "table": "^6.8.1", "yargs": "^17.7.1" }, diff --git a/packages/gas-report/ts/index.ts b/packages/gas-report/ts/index.ts index 322d71bd09..f029918bd1 100644 --- a/packages/gas-report/ts/index.ts +++ b/packages/gas-report/ts/index.ts @@ -1,9 +1,10 @@ import type { CommandModule } from "yargs"; import { readFileSync, writeFileSync } from "fs"; -import { execa } from "execa"; +import execa from "execa"; import chalk from "chalk"; import { table, getBorderCharacters } from "table"; -import stripAnsi from "strip-ansi"; +// TODO: Fix this import for cjs +// import stripAnsi from "strip-ansi"; import toArray from "stream-to-array"; /** @@ -127,7 +128,8 @@ async function runGasReport(options: Options): Promise { } // Extract the gas reports from the logs - const lines = logs.split("\n").map(stripAnsi); + // const lines = logs.split("\n").map(stripAnsi); + const lines = logs.split("\n"); const gasReportPattern = /^\s*GAS REPORT: (\d+) (.*)$/; const testFunctionPattern = /^\[(?:PASS|FAIL).*\] (\w+)\(\)/; // Matches "Running" for forge versions before 2024-02-15 diff --git a/packages/gas-report/tsup.config.ts b/packages/gas-report/tsup.config.ts index 289314bad7..b5f224c761 100644 --- a/packages/gas-report/tsup.config.ts +++ b/packages/gas-report/tsup.config.ts @@ -3,7 +3,7 @@ import { defineConfig } from "tsup"; export default defineConfig({ entry: ["ts/index.ts", "ts/gas-report.ts"], target: "esnext", - format: ["esm"], + format: ["esm", "cjs"], dts: true, sourcemap: true, clean: true, diff --git a/packages/noise/build/release.wasm b/packages/noise/build/release.wasm index a1b58b663e32ed4284e89e15789ee38dfe6f706a..90efce1141faca0dd119a0339a938f4d1e28e711 100644 GIT binary patch delta 145 zcmdlkxmj{T3S;-gR6XWhj0_VONKD+oF>#wR3zGul!io1JS(rieA4x@K1*V1k+zLzz z%wTF3lvZF|02BpDZnj{wVN^Jp6lixGBgLoFqnLys=#mpj{06nuPR{#J2 delta 170 zcmdlixm|KX3Sj0_VONKD+oF>#wRE8{E$rUeu4N;(1=%nSIr6&Mwm7lJ4t z7eq5bM46znKrUDmF3Skg1D4%v!f3;&;IMF!3j-LaI4oGC#Hqk2z^K3l75ZSmaPkBu ebtWLSlgWU|Vd3Q0Ozt3_33Dcpw|PFZ2qyqi&nfr- diff --git a/packages/noise/build/release.wasm.map b/packages/noise/build/release.wasm.map index 3b2c0ebb37..9f3c760db3 100644 --- a/packages/noise/build/release.wasm.map +++ b/packages/noise/build/release.wasm.map @@ -1 +1 @@ -{"version":3,"sources":["~lib/rt/common.ts","~lib/rt/tlsf.ts","~lib/shared/typeinfo.ts","~lib/rt/itcms.ts","assembly/perlin.ts","~lib/util/math.ts","~lib/util/number.ts","~lib/util/string.ts","~lib/math.ts","~lib/shared/runtime.ts","~lib/util/sort.ts","~lib/array.ts","~lib/util/error.ts"],"names":[],"mappings":"yGWiHI,AAAI,EAAc,AAAK,SAAmC,eAO1D,AANoB,MAAkB,EAAgB,6CPvDhD,EAAO,uBAEJ,EAAI,KAEJ,AAAC,GAAI,KAEL,EAAI,KAEJ,AAAC,GAAI,KAEL,EAAI,KAEJ,AAAC,GAAI,KAEL,EAAI,KAEJ,AAAC,GAAI,KAEL,EAAI,KAEJ,AAAC,GAAI,KAEL,EAAI,KAEJ,AAAC,GAAI,KAEL,EAAI,KAEJ,AAAC,GAAI,KAEL,EAAI,KAEJ,AAAC,GAAI,KAhChB,6QAJW,AAJX,AAAO,EAAI,GAAI,GAAK,EAAK,EAAI,UAAI,WAAM,qCAInB,mDAAT,AAJX,AAAO,EAAI,GAAI,GAAK,EAAK,EAAI,UAAI,WAAM,eAI5B,cAAS,2DAAT,iBAAS,0CAAT,AAJJ,EAAI,GAAI,GAAK,EAAK,EAAI,UAAI,WAAM,aAI5B,qBAAS","sourceRoot":"./release","sourcesContent":["// Alignment guarantees\n\n// @ts-ignore: decorator\n@inline export const AL_BITS: u32 = 4; // 16 bytes to fit up to v128\n// @ts-ignore: decorator\n@inline export const AL_SIZE: usize = 1 << AL_BITS;\n// @ts-ignore: decorator\n@inline export const AL_MASK: usize = AL_SIZE - 1;\n\n// Extra debugging\n\n// @ts-ignore: decorator\n@inline export const DEBUG = true;\n// @ts-ignore: decorator\n@inline export const TRACE = false;\n// @ts-ignore: decorator\n@inline export const RTRACE = isDefined(ASC_RTRACE);\n// @ts-ignore: decorator\n@inline export const PROFILE = isDefined(ASC_PROFILE);\n\n// Memory manager\n\n// ╒════════════ Memory manager block layout (32-bit) ═════════════╕\n// 3 2 1\n// 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 bits\n// ├─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┤\n// │ MM info │ -4\n// ╞>ptr═══════════════════════════════════════════════════════════╡\n// │ ... │\n@unmanaged export class BLOCK {\n /** Memory manager info. */\n mmInfo: usize;\n}\n\n/** Overhead of a memory manager block. */\n// @ts-ignore: decorator\n@inline export const BLOCK_OVERHEAD: usize = offsetof();\n\n/** Maximum size of a memory manager block's payload. */\n// @ts-ignore: decorator\n@inline export const BLOCK_MAXSIZE: usize = (1 << 30) - BLOCK_OVERHEAD;\n\n// Garbage collector\n\n// ╒══════════ Garbage collector object layout (32-bit) ═══════════╕\n// 3 2 1\n// 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 bits\n// ├─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┤\n// │ Memory manager block │ -20\n// ╞═══════════════════════════════════════════════════════════════╡\n// │ GC info │ -16\n// ├───────────────────────────────────────────────────────────────┤\n// │ GC info │ -12\n// ├───────────────────────────────────────────────────────────────┤\n// │ RT id │ -8\n// ├───────────────────────────────────────────────────────────────┤\n// │ RT size │ -4\n// ╞>ptr═══════════════════════════════════════════════════════════╡\n// │ ... │\n@unmanaged export class OBJECT extends BLOCK {\n /** Garbage collector info. */\n gcInfo: u32;\n /** Garbage collector info. */\n gcInfo2: u32;\n /** Runtime class id. */\n rtId: u32;\n /** Runtime object size. */\n rtSize: u32;\n}\n\n/** Overhead of a garbage collector object. Excludes memory manager block overhead. */\n// @ts-ignore: decorator\n@inline export const OBJECT_OVERHEAD: usize = (offsetof() - BLOCK_OVERHEAD + AL_MASK) & ~AL_MASK;\n\n/** Maximum size of a garbage collector object's payload. */\n// @ts-ignore: decorator\n@inline export const OBJECT_MAXSIZE: usize = BLOCK_MAXSIZE - OBJECT_OVERHEAD;\n\n/** Total of memory manager and garbage collector overhead. */\n// @ts-ignore: decorator\n@inline export const TOTAL_OVERHEAD: usize = BLOCK_OVERHEAD + OBJECT_OVERHEAD;\n","import { AL_BITS, AL_SIZE, AL_MASK, DEBUG, BLOCK, BLOCK_OVERHEAD, BLOCK_MAXSIZE } from \"./common\";\nimport { oninit, onalloc, onresize, onmove, onfree } from \"./rtrace\";\nimport { E_ALLOCATION_TOO_LARGE } from \"../util/error\";\n\n// === The TLSF (Two-Level Segregate Fit) memory allocator ===\n// see: http://www.gii.upv.es/tlsf/\n\n// - `ffs(x)` is equivalent to `ctz(x)` with x != 0\n// - `fls(x)` is equivalent to `sizeof(x) * 8 - clz(x) - 1`\n\n// ╒══════════════ Block size interpretation (32-bit) ═════════════╕\n// 3 2 1\n// 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 bits\n// ├─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┼─┴─┴─┴─╫─┴─┴─┴─┤\n// │ | FL │ SB = SL + AL │ ◄─ usize\n// └───────────────────────────────────────────────┴───────╨───────┘\n// FL: first level, SL: second level, AL: alignment, SB: small block\n\n// @ts-ignore: decorator\n@inline const SL_BITS: u32 = 4;\n// @ts-ignore: decorator\n@inline const SL_SIZE: u32 = 1 << SL_BITS;\n\n// @ts-ignore: decorator\n@inline const SB_BITS: u32 = SL_BITS + AL_BITS;\n// @ts-ignore: decorator\n@inline const SB_SIZE: u32 = 1 << SB_BITS;\n\n// @ts-ignore: decorator\n@inline const FL_BITS: u32 = 31 - SB_BITS;\n\n// [00]: < 256B (SB) [12]: < 1M\n// [01]: < 512B [13]: < 2M\n// [02]: < 1K [14]: < 4M\n// [03]: < 2K [15]: < 8M\n// [04]: < 4K [16]: < 16M\n// [05]: < 8K [17]: < 32M\n// [06]: < 16K [18]: < 64M\n// [07]: < 32K [19]: < 128M\n// [08]: < 64K [20]: < 256M\n// [09]: < 128K [21]: < 512M\n// [10]: < 256K [22]: <= 1G - OVERHEAD\n// [11]: < 512K\n// VMs limit to 2GB total (currently), making one 1G block max (or three 512M etc.) due to block overhead\n\n// Tags stored in otherwise unused alignment bits\n\n// @ts-ignore: decorator\n@inline const FREE: usize = 1 << 0;\n// @ts-ignore: decorator\n@inline const LEFTFREE: usize = 1 << 1;\n// @ts-ignore: decorator\n@inline const TAGS_MASK: usize = FREE | LEFTFREE; // <= AL_MASK\n\n// ╒════════════════════ Block layout (32-bit) ════════════════════╕\n// 3 2 1\n// 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 bits\n// ├─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┼─┼─┤ ┐\n// │ size │L│F│ ◄─┐ info overhead\n// ╞>ptr═══════════════════════════════════════════════════════╧═╧═╡ │ ┘\n// │ if free: ◄ prev │ ◄─┤ usize\n// ├───────────────────────────────────────────────────────────────┤ │\n// │ if free: next ► │ ◄─┤\n// ├───────────────────────────────────────────────────────────────┤ │\n// │ ... │ │ >= 0\n// ├───────────────────────────────────────────────────────────────┤ │\n// │ if free: back ▲ │ ◄─┘\n// └───────────────────────────────────────────────────────────────┘ >= MIN SIZE\n// F: FREE, L: LEFTFREE\n@unmanaged export class Block extends BLOCK {\n\n /** Previous free block, if any. Only valid if free, otherwise part of payload. */\n prev: Block | null;\n /** Next free block, if any. Only valid if free, otherwise part of payload. */\n next: Block | null;\n\n // If the block is free, there is a 'back'reference at its end pointing at its start.\n}\n\n// Block constants. A block must have a minimum size of three pointers so it can hold `prev`,\n// `next` and `back` if free.\n\n// @ts-ignore: decorator\n@inline const BLOCK_MINSIZE: usize = ((3 * sizeof() + BLOCK_OVERHEAD + AL_MASK) & ~AL_MASK) - BLOCK_OVERHEAD; // prev + next + back\n// @ts-ignore: decorator\n// @inline const BLOCK_MAXSIZE: usize = 1 << (FL_BITS + SB_BITS - 1); // exclusive, lives in common.ts\n\n/** Gets the left block of a block. Only valid if the left block is free. */\n// @ts-ignore: decorator\n@inline function GETFREELEFT(block: Block): Block {\n return load(changetype(block) - sizeof());\n}\n\n/** Gets the right block of a block by advancing to the right by its size. */\n// @ts-ignore: decorator\n@inline function GETRIGHT(block: Block): Block {\n return changetype(changetype(block) + BLOCK_OVERHEAD + (block.mmInfo & ~TAGS_MASK));\n}\n\n// ╒═════════════════════ Root layout (32-bit) ════════════════════╕\n// 3 2 1\n// 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 bits\n// ├─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┤ ┐\n// │ 0 | flMap S│ ◄────┐\n// ╞═══════════════════════════════════════════════════════════════╡ │\n// │ slMap[0] S │ ◄─┐ │\n// ├───────────────────────────────────────────────────────────────┤ │ │\n// │ slMap[1] │ ◄─┤ │\n// ├───────────────────────────────────────────────────────────────┤ u32 │\n// │ slMap[22] │ ◄─┘ │\n// ╞═══════════════════════════════════════════════════════════════╡ usize\n// │ head[0] │ ◄────┤\n// ├───────────────────────────────────────────────────────────────┤ │\n// │ ... │ ◄────┤\n// ├───────────────────────────────────────────────────────────────┤ │\n// │ head[367] │ ◄────┤\n// ╞═══════════════════════════════════════════════════════════════╡ │\n// │ tail │ ◄────┘\n// └───────────────────────────────────────────────────────────────┘ SIZE ┘\n// S: Small blocks map\n@unmanaged class Root {\n /** First level bitmap. */\n flMap: usize;\n}\n\n// Root constants. Where stuff is stored inside of the root structure.\n\n// @ts-ignore: decorator\n@inline const SL_START: usize = sizeof();\n// @ts-ignore: decorator\n@inline const SL_END: usize = SL_START + (FL_BITS << alignof());\n// @ts-ignore: decorator\n@inline const HL_START: usize = (SL_END + AL_MASK) & ~AL_MASK;\n// @ts-ignore: decorator\n@inline const HL_END: usize = HL_START + FL_BITS * SL_SIZE * sizeof();\n// @ts-ignore: decorator\n@inline const ROOT_SIZE: usize = HL_END + sizeof();\n\n// @ts-ignore: decorator\n@lazy export var ROOT: Root;\n\n/** Gets the second level map of the specified first level. */\n// @ts-ignore: decorator\n@inline function GETSL(root: Root, fl: usize): u32 {\n return load(\n changetype(root) + (fl << alignof()),\n SL_START\n );\n}\n\n/** Sets the second level map of the specified first level. */\n// @ts-ignore: decorator\n@inline function SETSL(root: Root, fl: usize, slMap: u32): void {\n store(\n changetype(root) + (fl << alignof()),\n slMap,\n SL_START\n );\n}\n\n/** Gets the head of the free list for the specified combination of first and second level. */\n// @ts-ignore: decorator\n@inline function GETHEAD(root: Root, fl: usize, sl: u32): Block | null {\n return load(\n changetype(root) + (((fl << SL_BITS) + sl) << alignof()),\n HL_START\n );\n}\n\n/** Sets the head of the free list for the specified combination of first and second level. */\n// @ts-ignore: decorator\n@inline function SETHEAD(root: Root, fl: usize, sl: u32, head: Block | null): void {\n store(\n changetype(root) + (((fl << SL_BITS) + sl) << alignof()),\n head,\n HL_START\n );\n}\n\n/** Gets the tail block.. */\n// @ts-ignore: decorator\n@inline function GETTAIL(root: Root): Block {\n return load(\n changetype(root),\n HL_END\n );\n}\n\n/** Sets the tail block. */\n// @ts-ignore: decorator\n@inline function SETTAIL(root: Root, tail: Block): void {\n store(\n changetype(root),\n tail,\n HL_END\n );\n}\n\n/** Inserts a previously used block back into the free list. */\nfunction insertBlock(root: Root, block: Block): void {\n if (DEBUG) assert(block); // cannot be null\n var blockInfo = block.mmInfo;\n if (DEBUG) assert(blockInfo & FREE); // must be free\n\n var right = GETRIGHT(block);\n var rightInfo = right.mmInfo;\n\n // merge with right block if also free\n if (rightInfo & FREE) {\n removeBlock(root, right);\n block.mmInfo = blockInfo = blockInfo + BLOCK_OVERHEAD + (rightInfo & ~TAGS_MASK); // keep block tags\n right = GETRIGHT(block);\n rightInfo = right.mmInfo;\n // 'back' is set below\n }\n\n // merge with left block if also free\n if (blockInfo & LEFTFREE) {\n let left = GETFREELEFT(block);\n let leftInfo = left.mmInfo;\n if (DEBUG) assert(leftInfo & FREE); // must be free according to right tags\n removeBlock(root, left);\n block = left;\n block.mmInfo = blockInfo = leftInfo + BLOCK_OVERHEAD + (blockInfo & ~TAGS_MASK); // keep left tags\n // 'back' is set below\n }\n\n right.mmInfo = rightInfo | LEFTFREE;\n // reference to right is no longer used now, hence rightInfo is not synced\n\n // we now know the size of the block\n var size = blockInfo & ~TAGS_MASK;\n if (DEBUG) assert(size >= BLOCK_MINSIZE); // must be a valid size\n if (DEBUG) assert(changetype(block) + BLOCK_OVERHEAD + size == changetype(right)); // must match\n\n // set 'back' to itself at the end of block\n store(changetype(right) - sizeof(), block);\n\n // mapping_insert\n var fl: usize, sl: u32;\n if (size < SB_SIZE) {\n fl = 0;\n sl = (size >> AL_BITS);\n } else {\n const inv: usize = sizeof() * 8 - 1;\n let boundedSize = min(size, BLOCK_MAXSIZE);\n fl = inv - clz(boundedSize);\n sl = ((boundedSize >> (fl - SL_BITS)) ^ (1 << SL_BITS));\n fl -= SB_BITS - 1;\n }\n if (DEBUG) assert(fl < FL_BITS && sl < SL_SIZE); // fl/sl out of range\n\n // perform insertion\n var head = GETHEAD(root, fl, sl);\n block.prev = null;\n block.next = head;\n if (head) head.prev = block;\n SETHEAD(root, fl, sl, block);\n\n // update first and second level maps\n root.flMap |= (1 << fl);\n SETSL(root, fl, GETSL(root, fl) | (1 << sl));\n}\n\n/** Removes a free block from internal lists. */\nfunction removeBlock(root: Root, block: Block): void {\n var blockInfo = block.mmInfo;\n if (DEBUG) assert(blockInfo & FREE); // must be free\n var size = blockInfo & ~TAGS_MASK;\n if (DEBUG) assert(size >= BLOCK_MINSIZE); // must be valid\n\n // mapping_insert\n var fl: usize, sl: u32;\n if (size < SB_SIZE) {\n fl = 0;\n sl = (size >> AL_BITS);\n } else {\n const inv: usize = sizeof() * 8 - 1;\n let boundedSize = min(size, BLOCK_MAXSIZE);\n fl = inv - clz(boundedSize);\n sl = ((boundedSize >> (fl - SL_BITS)) ^ (1 << SL_BITS));\n fl -= SB_BITS - 1;\n }\n if (DEBUG) assert(fl < FL_BITS && sl < SL_SIZE); // fl/sl out of range\n\n // link previous and next free block\n var prev = block.prev;\n var next = block.next;\n if (prev) prev.next = next;\n if (next) next.prev = prev;\n\n // update head if we are removing it\n if (block == GETHEAD(root, fl, sl)) {\n SETHEAD(root, fl, sl, next);\n\n // clear second level map if head is empty now\n if (!next) {\n let slMap = GETSL(root, fl);\n SETSL(root, fl, slMap &= ~(1 << sl));\n\n // clear first level map if second level is empty now\n if (!slMap) root.flMap &= ~(1 << fl);\n }\n }\n // note: does not alter left/back because it is likely that splitting\n // is performed afterwards, invalidating those changes. so, the caller\n // must perform those updates.\n}\n\n/** Searches for a free block of at least the specified size. */\nfunction searchBlock(root: Root, size: usize): Block | null {\n // size was already asserted by caller\n\n // mapping_search\n var fl: usize, sl: u32;\n if (size < SB_SIZE) {\n fl = 0;\n sl = (size >> AL_BITS);\n } else {\n const halfMaxSize = BLOCK_MAXSIZE >> 1; // don't round last fl\n const inv: usize = sizeof() * 8 - 1;\n const invRound = inv - SL_BITS;\n let requestSize = size < halfMaxSize\n ? size + (1 << (invRound - clz(size))) - 1\n : size;\n fl = inv - clz(requestSize);\n sl = ((requestSize >> (fl - SL_BITS)) ^ (1 << SL_BITS));\n fl -= SB_BITS - 1;\n }\n if (DEBUG) assert(fl < FL_BITS && sl < SL_SIZE); // fl/sl out of range\n\n // search second level\n var slMap = GETSL(root, fl) & (~0 << sl);\n var head: Block | null = null;\n if (!slMap) {\n // search next larger first level\n let flMap = root.flMap & (~0 << (fl + 1));\n if (!flMap) {\n head = null;\n } else {\n fl = ctz(flMap);\n slMap = GETSL(root, fl);\n if (DEBUG) assert(slMap); // can't be zero if fl points here\n head = GETHEAD(root, fl, ctz(slMap));\n }\n } else {\n head = GETHEAD(root, fl, ctz(slMap));\n }\n return head;\n}\n\n/** Prepares the specified block before (re-)use, possibly splitting it. */\nfunction prepareBlock(root: Root, block: Block, size: usize): void {\n // size was already asserted by caller\n\n var blockInfo = block.mmInfo;\n if (DEBUG) assert(!((size + BLOCK_OVERHEAD) & AL_MASK)); // size must be aligned so the new block is\n\n // split if the block can hold another MINSIZE block incl. overhead\n var remaining = (blockInfo & ~TAGS_MASK) - size;\n if (remaining >= BLOCK_OVERHEAD + BLOCK_MINSIZE) {\n block.mmInfo = size | (blockInfo & LEFTFREE); // also discards FREE\n\n let spare = changetype(changetype(block) + BLOCK_OVERHEAD + size);\n spare.mmInfo = (remaining - BLOCK_OVERHEAD) | FREE; // not LEFTFREE\n insertBlock(root, spare); // also sets 'back'\n\n // otherwise tag block as no longer FREE and right as no longer LEFTFREE\n } else {\n block.mmInfo = blockInfo & ~FREE;\n GETRIGHT(block).mmInfo &= ~LEFTFREE;\n }\n}\n\n/** Adds more memory to the pool. */\nfunction addMemory(root: Root, start: usize, end: usize): bool {\n if (DEBUG) assert(start <= end); // must be valid\n start = ((start + BLOCK_OVERHEAD + AL_MASK) & ~AL_MASK) - BLOCK_OVERHEAD;\n end &= ~AL_MASK;\n\n var tail = GETTAIL(root);\n var tailInfo: usize = 0;\n if (tail) { // more memory\n if (DEBUG) assert(start >= changetype(tail) + BLOCK_OVERHEAD);\n\n // merge with current tail if adjacent\n const offsetToTail = AL_SIZE;\n if (start - offsetToTail == changetype(tail)) {\n start -= offsetToTail;\n tailInfo = tail.mmInfo;\n } else {\n // We don't do this, but a user might `memory.grow` manually\n // leading to non-adjacent pages managed by TLSF.\n }\n\n } else if (DEBUG) { // first memory\n assert(start >= changetype(root) + ROOT_SIZE); // starts after root\n }\n\n // check if size is large enough for a free block and the tail block\n var size = end - start;\n if (size < BLOCK_OVERHEAD + BLOCK_MINSIZE + BLOCK_OVERHEAD) {\n return false;\n }\n\n // left size is total minus its own and the zero-length tail's header\n var leftSize = size - 2 * BLOCK_OVERHEAD;\n var left = changetype(start);\n left.mmInfo = leftSize | FREE | (tailInfo & LEFTFREE);\n left.prev = null;\n left.next = null;\n\n // tail is a zero-length used block\n tail = changetype(start + BLOCK_OVERHEAD + leftSize);\n tail.mmInfo = 0 | LEFTFREE;\n SETTAIL(root, tail);\n\n insertBlock(root, left); // also merges with free left before tail / sets 'back'\n\n return true;\n}\n\n/** Grows memory to fit at least another block of the specified size. */\nfunction growMemory(root: Root, size: usize): void {\n if (ASC_LOW_MEMORY_LIMIT) {\n unreachable();\n return;\n }\n // Here, both rounding performed in searchBlock ...\n const halfMaxSize = BLOCK_MAXSIZE >> 1;\n if (size < halfMaxSize) { // don't round last fl\n const invRound = (sizeof() * 8 - 1) - SL_BITS;\n size += (1 << (invRound - clz(size))) - 1;\n }\n // and additional BLOCK_OVERHEAD must be taken into account. If we are going\n // to merge with the tail block, that's one time, otherwise it's two times.\n var pagesBefore = memory.size();\n size += BLOCK_OVERHEAD << usize((pagesBefore << 16) - BLOCK_OVERHEAD != changetype(GETTAIL(root)));\n var pagesNeeded = (((size + 0xffff) & ~0xffff) >>> 16);\n var pagesWanted = max(pagesBefore, pagesNeeded); // double memory\n if (memory.grow(pagesWanted) < 0) {\n if (memory.grow(pagesNeeded) < 0) unreachable();\n }\n var pagesAfter = memory.size();\n addMemory(root, pagesBefore << 16, pagesAfter << 16);\n}\n\n/** Computes the size (excl. header) of a block. */\nfunction computeSize(size: usize): usize {\n // Size must be large enough and aligned minus preceeding overhead\n return size <= BLOCK_MINSIZE\n ? BLOCK_MINSIZE\n : ((size + BLOCK_OVERHEAD + AL_MASK) & ~AL_MASK) - BLOCK_OVERHEAD;\n}\n\n/** Prepares and checks an allocation size. */\nfunction prepareSize(size: usize): usize {\n if (size > BLOCK_MAXSIZE) throw new Error(E_ALLOCATION_TOO_LARGE);\n return computeSize(size);\n}\n\n/** Initializes the root structure. */\nfunction initialize(): void {\n if (isDefined(ASC_RTRACE)) oninit(__heap_base);\n var rootOffset = (__heap_base + AL_MASK) & ~AL_MASK;\n var pagesBefore = memory.size();\n var pagesNeeded = ((((rootOffset + ROOT_SIZE) + 0xffff) & ~0xffff) >>> 16);\n if (pagesNeeded > pagesBefore && memory.grow(pagesNeeded - pagesBefore) < 0) unreachable();\n var root = changetype(rootOffset);\n root.flMap = 0;\n SETTAIL(root, changetype(0));\n for (let fl: usize = 0; fl < FL_BITS; ++fl) {\n SETSL(root, fl, 0);\n for (let sl: u32 = 0; sl < SL_SIZE; ++sl) {\n SETHEAD(root, fl, sl, null);\n }\n }\n var memStart = rootOffset + ROOT_SIZE;\n if (ASC_LOW_MEMORY_LIMIT) {\n const memEnd = ASC_LOW_MEMORY_LIMIT & ~AL_MASK;\n if (memStart <= memEnd) addMemory(root, memStart, memEnd);\n else unreachable(); // low memory limit already exceeded\n } else {\n addMemory(root, memStart, memory.size() << 16);\n }\n ROOT = root;\n}\n\n/** Allocates a block of the specified size. */\nexport function allocateBlock(root: Root, size: usize): Block {\n var payloadSize = prepareSize(size);\n var block = searchBlock(root, payloadSize);\n if (!block) {\n growMemory(root, payloadSize);\n block = changetype(searchBlock(root, payloadSize));\n if (DEBUG) assert(block); // must be found now\n }\n if (DEBUG) assert((block.mmInfo & ~TAGS_MASK) >= payloadSize); // must fit\n removeBlock(root, block);\n prepareBlock(root, block, payloadSize);\n if (isDefined(ASC_RTRACE)) onalloc(block);\n return block;\n}\n\n/** Reallocates a block to the specified size. */\nexport function reallocateBlock(root: Root, block: Block, size: usize): Block {\n var payloadSize = prepareSize(size);\n var blockInfo = block.mmInfo;\n var blockSize = blockInfo & ~TAGS_MASK;\n\n // possibly split and update runtime size if it still fits\n if (payloadSize <= blockSize) {\n prepareBlock(root, block, payloadSize);\n if (isDefined(ASC_RTRACE)) {\n if (payloadSize != blockSize) onresize(block, BLOCK_OVERHEAD + blockSize);\n }\n return block;\n }\n\n // merge with right free block if merger is large enough\n var right = GETRIGHT(block);\n var rightInfo = right.mmInfo;\n if (rightInfo & FREE) {\n let mergeSize = blockSize + BLOCK_OVERHEAD + (rightInfo & ~TAGS_MASK);\n if (mergeSize >= payloadSize) {\n removeBlock(root, right);\n block.mmInfo = (blockInfo & TAGS_MASK) | mergeSize;\n prepareBlock(root, block, payloadSize);\n if (isDefined(ASC_RTRACE)) onresize(block, BLOCK_OVERHEAD + blockSize);\n return block;\n }\n }\n\n // otherwise move the block\n return moveBlock(root, block, size);\n}\n\n/** Moves a block to a new one of the specified size. */\nfunction moveBlock(root: Root, block: Block, newSize: usize): Block {\n var newBlock = allocateBlock(root, newSize);\n memory.copy(changetype(newBlock) + BLOCK_OVERHEAD, changetype(block) + BLOCK_OVERHEAD, block.mmInfo & ~TAGS_MASK);\n if (changetype(block) >= __heap_base) {\n if (isDefined(ASC_RTRACE)) onmove(block, newBlock);\n freeBlock(root, block);\n }\n return newBlock;\n}\n\n/** Frees a block. */\nexport function freeBlock(root: Root, block: Block): void {\n if (isDefined(ASC_RTRACE)) onfree(block);\n block.mmInfo = block.mmInfo | FREE;\n insertBlock(root, block);\n}\n\n/** Checks that a used block is valid to be freed or reallocated. */\nfunction checkUsedBlock(ptr: usize): Block {\n var block = changetype(ptr - BLOCK_OVERHEAD);\n assert(\n ptr != 0 && !(ptr & AL_MASK) && // must exist and be aligned\n !(block.mmInfo & FREE) // must be used\n );\n return block;\n}\n\n// @ts-ignore: decorator\n@global @unsafe\nexport function __alloc(size: usize): usize {\n if (!ROOT) initialize();\n return changetype(allocateBlock(ROOT, size)) + BLOCK_OVERHEAD;\n}\n\n// @ts-ignore: decorator\n@global @unsafe\nexport function __realloc(ptr: usize, size: usize): usize {\n if (!ROOT) initialize();\n return (ptr < __heap_base\n ? changetype(moveBlock(ROOT, checkUsedBlock(ptr), size))\n : changetype(reallocateBlock(ROOT, checkUsedBlock(ptr), size))\n ) + BLOCK_OVERHEAD;\n}\n\n// @ts-ignore: decorator\n@global @unsafe\nexport function __free(ptr: usize): void {\n if (ptr < __heap_base) return;\n if (!ROOT) initialize();\n freeBlock(ROOT, checkUsedBlock(ptr));\n}\n","// This file is shared with the compiler and must remain portable\n\n// ╒═══════════════════ Typeinfo interpretation ═══════════════════╕\n// 3 2 1\n// 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 bits\n// ├─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┤ ◄─ __rtti_base\n// │ count │\n// ╞═══════════════════════════════════════════════════════════════╡ ┐\n// │ Typeinfo#flags [id=0] │ id < count\n// ├ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ┤\n// │ Typeinfo#base [id=0] │\n// ├───────────────────────────────────────────────────────────────┤\n// │ ... │\n\n/** Runtime type information data structure. */\n@unmanaged\nexport class Typeinfo {\n /** Flags describing the shape of this class type. */\n flags: TypeinfoFlags = TypeinfoFlags.NONE;\n /** Base class id or `0` if none. */\n base: u32 = 0;\n}\n\n/** Runtime type information flags. */\nexport const enum TypeinfoFlags {\n /** No specific flags. */\n NONE = 0,\n /** Type is an `ArrayBufferView`. */\n ARRAYBUFFERVIEW = 1 << 0,\n /** Type is an `Array`. */\n ARRAY = 1 << 1,\n /** Type is a `StaticArray`. */\n STATICARRAY = 1 << 2,\n /** Type is a `Set`. */\n SET = 1 << 3,\n /** Type is a `Map`. */\n MAP = 1 << 4,\n /** Type has no outgoing pointers. */\n POINTERFREE = 1 << 5,\n /** Value alignment of 1 byte. */\n VALUE_ALIGN_0 = 1 << 6,\n /** Value alignment of 2 bytes. */\n VALUE_ALIGN_1 = 1 << 7,\n /** Value alignment of 4 bytes. */\n VALUE_ALIGN_2 = 1 << 8,\n /** Value alignment of 8 bytes. */\n VALUE_ALIGN_3 = 1 << 9,\n /** Value alignment of 16 bytes. */\n VALUE_ALIGN_4 = 1 << 10,\n /** Value is a signed type. */\n VALUE_SIGNED = 1 << 11,\n /** Value is a float type. */\n VALUE_FLOAT = 1 << 12,\n /** Value type is nullable. */\n VALUE_NULLABLE = 1 << 13,\n /** Value type is managed. */\n VALUE_MANAGED = 1 << 14,\n /** Key alignment of 1 byte. */\n KEY_ALIGN_0 = 1 << 15,\n /** Key alignment of 2 bytes. */\n KEY_ALIGN_1 = 1 << 16,\n /** Key alignment of 4 bytes. */\n KEY_ALIGN_2 = 1 << 17,\n /** Key alignment of 8 bytes. */\n KEY_ALIGN_3 = 1 << 18,\n /** Key alignment of 16 bytes. */\n KEY_ALIGN_4 = 1 << 19,\n /** Key is a signed type. */\n KEY_SIGNED = 1 << 20,\n /** Key is a float type. */\n KEY_FLOAT = 1 << 21,\n /** Key type is nullable. */\n KEY_NULLABLE = 1 << 22,\n /** Key type is managed. */\n KEY_MANAGED = 1 << 23\n}\n","import { BLOCK, BLOCK_OVERHEAD, OBJECT_OVERHEAD, OBJECT_MAXSIZE, TOTAL_OVERHEAD, DEBUG, TRACE, RTRACE, PROFILE } from \"./common\";\nimport { onvisit, oncollect, oninterrupt, onyield } from \"./rtrace\";\nimport { TypeinfoFlags } from \"../shared/typeinfo\";\nimport { E_ALLOCATION_TOO_LARGE, E_ALREADY_PINNED, E_NOT_PINNED } from \"../util/error\";\n\n// === ITCMS: An incremental Tri-Color Mark & Sweep garbage collector ===\n// Adapted from Bach Le's μgc, see: https://github.com/bullno1/ugc\n\n// ╒═════════════╤══════════════ Colors ═══════════════════════════╕\n// │ Color │ Meaning │\n// ├─────────────┼─────────────────────────────────────────────────┤\n// │ WHITE* │ Unprocessed │\n// │ BLACK* │ Processed │\n// │ GRAY │ Processed with unprocessed children │\n// │ TRANSPARENT │ Manually pinned (always reachable) │\n// └─────────────┴─────────────────────────────────────────────────┘\n// * flipped between cycles\n\n// @ts-ignore: decorator\n@lazy var white = 0;\n// @ts-ignore: decorator\n@inline const gray = 2;\n// @ts-ignore: decorator\n@inline const transparent = 3;\n// @ts-ignore: decorator\n@inline const COLOR_MASK = 3;\n\n/** Size in memory of all objects currently managed by the GC. */\n// @ts-ignore: decorator\n@lazy var total: usize = 0;\n\n/** Currently transitioning from SWEEP to MARK state. */\n// @ts-ignore: decorator\n@inline const STATE_IDLE = 0;\n/** Currently marking reachable objects. */\n// @ts-ignore: decorator\n@inline const STATE_MARK = 1;\n/** Currently sweeping unreachable objects. */\n// @ts-ignore: decorator\n@inline const STATE_SWEEP = 2;\n/** Current collector state. */\n// @ts-ignore: decorator\n@lazy var state = STATE_IDLE;\n\n// @ts-ignore: decorator\n@lazy var fromSpace = initLazy(changetype(memory.data(offsetof())));\n// @ts-ignore: decorator\n@lazy var toSpace = initLazy(changetype(memory.data(offsetof())));\n// @ts-ignore: decorator\n@lazy var pinSpace = initLazy(changetype(memory.data(offsetof())));\n// @ts-ignore: decorator\n@lazy var iter: Object; // null\n\nfunction initLazy(space: Object): Object {\n space.nextWithColor = changetype(space);\n space.prev = space;\n return space;\n}\n\n/** Visit cookie indicating scanning of an object. */\n// @ts-ignore: decorator\n@inline const VISIT_SCAN = 0;\n\n// ╒═══════════════ Managed object layout (32-bit) ════════════════╕\n// 3 2 1\n// 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 bits\n// ├─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┤\n// │ Memory manager block │\n// ╞═══════════════════════════════════════════════════════════╤═══╡\n// │ next │ C │ = nextWithColor\n// ├───────────────────────────────────────────────────────────┴───┤\n// │ prev │\n// ├───────────────────────────────────────────────────────────────┤\n// │ rtId │\n// ├───────────────────────────────────────────────────────────────┤\n// │ rtSize │\n// ╞>ptr═══════════════════════════════════════════════════════════╡\n// │ ... │\n// C: color\n\n/** Represents a managed object in memory, consisting of a header followed by the object's data. */\n@unmanaged class Object extends BLOCK {\n /** Pointer to the next object with color flags stored in the alignment bits. */\n nextWithColor: usize; // *u32\n /** Pointer to the previous object. */\n prev: Object; // *u32\n /** Runtime id. */\n rtId: u32;\n /** Runtime size. */\n rtSize: u32;\n\n /** Gets the pointer to the next object. */\n get next(): Object {\n return changetype(this.nextWithColor & ~COLOR_MASK);\n }\n\n /** Sets the pointer to the next object. */\n set next(obj: Object) {\n this.nextWithColor = changetype(obj) | (this.nextWithColor & COLOR_MASK);\n }\n\n /** Gets this object's color. */\n get color(): i32 {\n return i32(this.nextWithColor & COLOR_MASK);\n }\n\n /** Sets this object's color. */\n set color(color: i32) {\n this.nextWithColor = (this.nextWithColor & ~COLOR_MASK) | color;\n }\n\n /** Gets the size of this object in memory. */\n get size(): usize {\n return BLOCK_OVERHEAD + (this.mmInfo & ~3);\n }\n\n /** Tests if this object is pointerfree. */\n get isPointerfree(): bool {\n var rtId = this.rtId;\n return rtId <= idof() || (__typeinfo(rtId) & TypeinfoFlags.POINTERFREE) != 0;\n }\n\n /** Unlinks this object from its list. */\n unlink(): void {\n var next = this.next;\n if (next == null) {\n if (DEBUG) assert(this.prev == null && changetype(this) < __heap_base);\n return; // static data not yet linked\n }\n var prev = this.prev;\n if (DEBUG) assert(prev);\n next.prev = prev;\n prev.next = next;\n }\n\n /** Links this object to the specified list, with the given color. */\n linkTo(list: Object, withColor: i32): void {\n let prev = list.prev;\n this.nextWithColor = changetype(list) | withColor;\n this.prev = prev;\n prev.next = this;\n list.prev = this;\n }\n\n /** Marks this object as gray, that is reachable with unscanned children. */\n makeGray(): void {\n if (this == iter) iter = assert(this.prev);\n this.unlink();\n this.linkTo(toSpace, this.isPointerfree ? i32(!white) : gray);\n }\n}\n\n/** Visits all objects considered to be program roots. */\nfunction visitRoots(cookie: u32): void {\n __visit_globals(cookie);\n var pn = pinSpace;\n var iter = pn.next;\n while (iter != pn) {\n if (DEBUG) assert(iter.color == transparent);\n __visit_members(changetype(iter) + TOTAL_OVERHEAD, cookie);\n iter = iter.next;\n }\n}\n\n/** Visits all objects on the stack. */\nfunction visitStack(cookie: u32): void {\n var ptr = __stack_pointer;\n while (ptr < __heap_base) {\n __visit(load(ptr), cookie);\n ptr += sizeof();\n }\n}\n\n/** Performs a single step according to the current state. */\nfunction step(): usize {\n // Magic constants responsible for pause times. Obtained experimentally\n // using the compiler compiling itself. 2048 budget pro run by default.\n const MARKCOST = isDefined(ASC_GC_MARKCOST) ? ASC_GC_MARKCOST : 1;\n const SWEEPCOST = isDefined(ASC_GC_SWEEPCOST) ? ASC_GC_SWEEPCOST : 10;\n var obj: Object;\n switch (state) {\n case STATE_IDLE: {\n state = STATE_MARK;\n visitCount = 0;\n visitRoots(VISIT_SCAN);\n iter = toSpace;\n return visitCount * MARKCOST;\n }\n case STATE_MARK: {\n let black = i32(!white);\n obj = iter.next;\n while (obj != toSpace) {\n iter = obj;\n if (obj.color != black) { // skip already-blacks (pointerfree)\n obj.color = black;\n visitCount = 0;\n __visit_members(changetype(obj) + TOTAL_OVERHEAD, VISIT_SCAN);\n return visitCount * MARKCOST;\n }\n obj = obj.next;\n }\n visitCount = 0;\n visitRoots(VISIT_SCAN);\n obj = iter.next;\n if (obj == toSpace) {\n visitStack(VISIT_SCAN);\n obj = iter.next;\n while (obj != toSpace) {\n if (obj.color != black) {\n obj.color = black;\n __visit_members(changetype(obj) + TOTAL_OVERHEAD, VISIT_SCAN);\n }\n obj = obj.next;\n }\n let from = fromSpace;\n fromSpace = toSpace;\n toSpace = from;\n white = black;\n iter = from.next;\n state = STATE_SWEEP;\n }\n return visitCount * MARKCOST;\n }\n case STATE_SWEEP: {\n obj = iter;\n if (obj != toSpace) {\n iter = obj.next;\n if (DEBUG) assert(obj.color == i32(!white)); // old white\n free(obj);\n return SWEEPCOST;\n }\n toSpace.nextWithColor = changetype(toSpace);\n toSpace.prev = toSpace;\n state = STATE_IDLE;\n break;\n }\n }\n return 0;\n}\n\n/** Frees an object. */\nfunction free(obj: Object): void {\n if (changetype(obj) < __heap_base) {\n obj.nextWithColor = 0; // may become linked again\n obj.prev = changetype(0);\n } else {\n total -= obj.size;\n if (isDefined(__finalize)) {\n __finalize(changetype(obj) + TOTAL_OVERHEAD);\n }\n __free(changetype(obj) + BLOCK_OVERHEAD);\n }\n}\n\n// Garbage collector interface\n\n// @ts-ignore: decorator\n@global @unsafe\nexport function __new(size: usize, id: i32): usize {\n if (size >= OBJECT_MAXSIZE) throw new Error(E_ALLOCATION_TOO_LARGE);\n if (total >= threshold) interrupt();\n var obj = changetype(__alloc(OBJECT_OVERHEAD + size) - BLOCK_OVERHEAD);\n obj.rtId = id;\n obj.rtSize = size;\n obj.linkTo(fromSpace, white); // inits next/prev\n total += obj.size;\n var ptr = changetype(obj) + TOTAL_OVERHEAD;\n // may be visited before being fully initialized, so must fill\n memory.fill(ptr, 0, size);\n return ptr;\n}\n\n// @ts-ignore: decorator\n@global @unsafe\nexport function __renew(oldPtr: usize, size: usize): usize {\n var oldObj = changetype(oldPtr - TOTAL_OVERHEAD);\n // Update object size if its block is large enough\n if (size <= (oldObj.mmInfo & ~3) - OBJECT_OVERHEAD) {\n oldObj.rtSize = size;\n return oldPtr;\n }\n // If not the same object anymore, we have to move it move it due to the\n // shadow stack potentially still referencing the old object\n var newPtr = __new(size, oldObj.rtId);\n memory.copy(newPtr, oldPtr, min(size, oldObj.rtSize));\n return newPtr;\n}\n\n// @ts-ignore: decorator\n@global @unsafe\nexport function __link(parentPtr: usize, childPtr: usize, expectMultiple: bool): void {\n // Write barrier is unnecessary if non-incremental\n if (!childPtr) return;\n if (DEBUG) assert(parentPtr);\n var child = changetype(childPtr - TOTAL_OVERHEAD);\n if (child.color == white) {\n let parent = changetype(parentPtr - TOTAL_OVERHEAD);\n let parentColor = parent.color;\n if (parentColor == i32(!white)) {\n // Maintain the invariant that no black object may point to a white object.\n if (expectMultiple) {\n // Move the barrier \"backward\". Suitable for containers receiving multiple stores.\n // Avoids a barrier for subsequent objects stored into the same container.\n parent.makeGray();\n } else {\n // Move the barrier \"forward\". Suitable for objects receiving isolated stores.\n child.makeGray();\n }\n } else if (parentColor == transparent && state == STATE_MARK) {\n // Pinned objects are considered 'black' during the mark phase.\n child.makeGray();\n }\n }\n}\n\n// @ts-ignore: decorator\n@lazy var visitCount = 0;\n\n// @ts-ignore: decorator\n@global @unsafe\nexport function __visit(ptr: usize, cookie: i32): void {\n if (!ptr) return;\n let obj = changetype(ptr - TOTAL_OVERHEAD);\n if (RTRACE) if (!onvisit(obj)) return;\n if (obj.color == white) {\n obj.makeGray();\n ++visitCount;\n }\n}\n\n// @ts-ignore: decorator\n@global @unsafe\nexport function __pin(ptr: usize): usize {\n if (ptr) {\n let obj = changetype(ptr - TOTAL_OVERHEAD);\n if (obj.color == transparent) {\n throw new Error(E_ALREADY_PINNED);\n }\n obj.unlink(); // from fromSpace\n obj.linkTo(pinSpace, transparent);\n }\n return ptr;\n}\n\n// @ts-ignore: decorator\n@global @unsafe\nexport function __unpin(ptr: usize): void {\n if (!ptr) return;\n var obj = changetype(ptr - TOTAL_OVERHEAD);\n if (obj.color != transparent) {\n throw new Error(E_NOT_PINNED);\n }\n if (state == STATE_MARK) {\n // We may be right at the point after marking roots for the second time and\n // entering the sweep phase, in which case the object would be missed if it\n // is not only pinned but also a root. Make sure it isn't missed.\n obj.makeGray();\n } else {\n obj.unlink();\n obj.linkTo(fromSpace, white);\n }\n}\n\n// @ts-ignore: decorator\n@global @unsafe\nexport function __collect(): void {\n if (TRACE) trace(\"GC (full) at\", 1, total);\n if (state > STATE_IDLE) {\n // finish current cycle\n while (state != STATE_IDLE) step();\n }\n // perform a full cycle\n step();\n while (state != STATE_IDLE) step();\n threshold = (total * IDLEFACTOR / 100) + GRANULARITY;\n if (TRACE) trace(\"GC (full) done at cur/max\", 2, total, memory.size() << 16);\n if (RTRACE || PROFILE) oncollect(total);\n}\n\n// Garbage collector automation\n\n/** How often to interrupt. The default of 1024 means \"interrupt each 1024 bytes allocated\". */\n// @ts-ignore: decorator\n@inline const GRANULARITY: usize = isDefined(ASC_GC_GRANULARITY) ? ASC_GC_GRANULARITY : 1024;\n/** How long to interrupt. The default of 200% means \"run at double the speed of allocations\". */\n// @ts-ignore: decorator\n@inline const STEPFACTOR: usize = isDefined(ASC_GC_SWEEPFACTOR) ? ASC_GC_SWEEPFACTOR : 200;\n/** How long to idle. The default of 200% means \"wait for memory to double before kicking in again\". */\n// @ts-ignore: decorator\n@inline const IDLEFACTOR: usize = isDefined(ASC_GC_IDLEFACTOR) ? ASC_GC_IDLEFACTOR : 200;\n\n/** Threshold of memory used by objects to exceed before interrupting again. */\n// @ts-ignore: decorator\n@lazy var threshold: usize = ((memory.size() << 16) - __heap_base) >> 1;\n\n/** Performs a reasonable amount of incremental GC steps. */\nfunction interrupt(): void {\n if (PROFILE) oninterrupt(total);\n if (TRACE) trace(\"GC (auto) at\", 1, total);\n var budget: isize = GRANULARITY * STEPFACTOR / 100;\n do {\n budget -= step();\n if (state == STATE_IDLE) {\n if (TRACE) trace(\"└ GC (auto) done at cur/max\", 2, total, memory.size() << 16);\n threshold = (total * IDLEFACTOR / 100) + GRANULARITY;\n if (PROFILE) onyield(total);\n return;\n }\n } while (budget > 0);\n if (TRACE) trace(\"└ GC (auto) ongoing at\", 1, total);\n threshold = total + GRANULARITY * usize(total - threshold < GRANULARITY);\n if (PROFILE) onyield(total);\n}\n","// Ported from perlin reference implementation (https://cs.nyu.edu/~perlin/noise/)\n\nexport function perlin(_x: i32, _y: i32, _z: i32, denom: i32): f64 {\n // Convert fraction into f64\n let x: f64 = f64(_x) / f64(denom);\n let y: f64 = f64(_y) / f64(denom);\n let z: f64 = f64(_z) / f64(denom);\n\n // Find unit cube that contains point\n const X: i32 = i32(Math.floor(x)) & 255;\n const Y: i32 = i32(Math.floor(y)) & 255;\n const Z: i32 = i32(Math.floor(z)) & 255;\n\n // Find relative x,y,z of point in cube\n x -= Math.floor(x);\n y -= Math.floor(y);\n z -= Math.floor(z);\n\n // Compute fade curves for each x,y,z\n const u: f64 = fade(x);\n const v: f64 = fade(y);\n const w: f64 = fade(z);\n\n // Hash coordinates of the 8 cube corners\n const A: i32 = p[X] + Y;\n const AA: i32 = p[A] + Z;\n const AB: i32 = p[A + 1] + Z;\n const B: i32 = p[X + 1] + Y;\n const BA: i32 = p[B] + Z;\n const BB: i32 = p[B + 1] + Z;\n\n // Add blended results from 8 corners of cube\n const r: f64 = lerp(\n w,\n lerp(\n v,\n lerp(u, grad(p[AA], x, y, z), grad(p[BA], x - 1, y, z)),\n lerp(u, grad(p[AB], x, y - 1, z), grad(p[BB], x - 1, y - 1, z))\n ),\n lerp(\n v,\n lerp(u, grad(p[AA + 1], x, y, z - 1), grad(p[BA + 1], x - 1, y, z - 1)),\n lerp(u, grad(p[AB + 1], x, y - 1, z - 1), grad(p[BB + 1], x - 1, y - 1, z - 1))\n )\n );\n\n // Shift to range from 0 to 1\n return (r + 1) / 2;\n}\n\nfunction fade(t: f64): f64 {\n return t * t * t * (t * (t * 6 - 15) + 10);\n}\n\nfunction lerp(t: f64, a: f64, b: f64): f64 {\n return a + t * (b - a);\n}\n\nfunction grad(hash: i32, x: f64, y: f64, z: f64): f64 {\n switch (hash & 0xf) {\n case 0x0:\n return x + y;\n case 0x1:\n return -x + y;\n case 0x2:\n return x - y;\n case 0x3:\n return -x - y;\n case 0x4:\n return x + z;\n case 0x5:\n return -x + z;\n case 0x6:\n return x - z;\n case 0x7:\n return -x - z;\n case 0x8:\n return y + z;\n case 0x9:\n return -y + z;\n case 0xa:\n return y - z;\n case 0xb:\n return -y - z;\n case 0xc:\n return y + x;\n case 0xd:\n return -y + z;\n case 0xe:\n return y - x;\n case 0xf:\n return -y - z;\n default:\n return 0; // never happens\n }\n}\n\nconst p: i32[] = [\n 151, 160, 137, 91, 90, 15, 131, 13, 201, 95, 96, 53, 194, 233, 7, 225, 140, 36, 103, 30, 69, 142, 8, 99, 37, 240, 21,\n 10, 23, 190, 6, 148, 247, 120, 234, 75, 0, 26, 197, 62, 94, 252, 219, 203, 117, 35, 11, 32, 57, 177, 33, 88, 237, 149,\n 56, 87, 174, 20, 125, 136, 171, 168, 68, 175, 74, 165, 71, 134, 139, 48, 27, 166, 77, 146, 158, 231, 83, 111, 229,\n 122, 60, 211, 133, 230, 220, 105, 92, 41, 55, 46, 245, 40, 244, 102, 143, 54, 65, 25, 63, 161, 1, 216, 80, 73, 209,\n 76, 132, 187, 208, 89, 18, 169, 200, 196, 135, 130, 116, 188, 159, 86, 164, 100, 109, 198, 173, 186, 3, 64, 52, 217,\n 226, 250, 124, 123, 5, 202, 38, 147, 118, 126, 255, 82, 85, 212, 207, 206, 59, 227, 47, 16, 58, 17, 182, 189, 28, 42,\n 223, 183, 170, 213, 119, 248, 152, 2, 44, 154, 163, 70, 221, 153, 101, 155, 167, 43, 172, 9, 129, 22, 39, 253, 19, 98,\n 108, 110, 79, 113, 224, 232, 178, 185, 112, 104, 218, 246, 97, 228, 251, 34, 242, 193, 238, 210, 144, 12, 191, 179,\n 162, 241, 81, 51, 145, 235, 249, 14, 239, 107, 49, 192, 214, 31, 181, 199, 106, 157, 184, 84, 204, 176, 115, 121, 50,\n 45, 127, 4, 150, 254, 138, 236, 205, 93, 222, 114, 67, 29, 24, 72, 243, 141, 128, 195, 78, 66, 215, 61, 156, 180, 151,\n 160, 137, 91, 90, 15, 131, 13, 201, 95, 96, 53, 194, 233, 7, 225, 140, 36, 103, 30, 69, 142, 8, 99, 37, 240, 21, 10,\n 23, 190, 6, 148, 247, 120, 234, 75, 0, 26, 197, 62, 94, 252, 219, 203, 117, 35, 11, 32, 57, 177, 33, 88, 237, 149, 56,\n 87, 174, 20, 125, 136, 171, 168, 68, 175, 74, 165, 71, 134, 139, 48, 27, 166, 77, 146, 158, 231, 83, 111, 229, 122,\n 60, 211, 133, 230, 220, 105, 92, 41, 55, 46, 245, 40, 244, 102, 143, 54, 65, 25, 63, 161, 1, 216, 80, 73, 209, 76,\n 132, 187, 208, 89, 18, 169, 200, 196, 135, 130, 116, 188, 159, 86, 164, 100, 109, 198, 173, 186, 3, 64, 52, 217, 226,\n 250, 124, 123, 5, 202, 38, 147, 118, 126, 255, 82, 85, 212, 207, 206, 59, 227, 47, 16, 58, 17, 182, 189, 28, 42, 223,\n 183, 170, 213, 119, 248, 152, 2, 44, 154, 163, 70, 221, 153, 101, 155, 167, 43, 172, 9, 129, 22, 39, 253, 19, 98, 108,\n 110, 79, 113, 224, 232, 178, 185, 112, 104, 218, 246, 97, 228, 251, 34, 242, 193, 238, 210, 144, 12, 191, 179, 162,\n 241, 81, 51, 145, 235, 249, 14, 239, 107, 49, 192, 214, 31, 181, 199, 106, 157, 184, 84, 204, 176, 115, 121, 50, 45,\n 127, 4, 150, 254, 138, 236, 205, 93, 222, 114, 67, 29, 24, 72, 243, 141, 128, 195, 78, 66, 215, 61, 156, 180,\n];\n","//\n// Lookup data for exp2f\n//\n\n// @ts-ignore: decorator\n@inline const EXP2F_TABLE_BITS = 5;\n\n// @ts-ignore: decorator\n@lazy @inline const EXP2F_DATA_TAB = memory.data([\n // exp2f_data_tab[i] = uint(2^(i/N)) - (i << 52-BITS)\n // used for computing 2^(k/N) for an int |k| < 150 N as\n // double(tab[k%N] + (k << 52-BITS))\n 0x3FF0000000000000, 0x3FEFD9B0D3158574, 0x3FEFB5586CF9890F, 0x3FEF9301D0125B51,\n 0x3FEF72B83C7D517B, 0x3FEF54873168B9AA, 0x3FEF387A6E756238, 0x3FEF1E9DF51FDEE1,\n 0x3FEF06FE0A31B715, 0x3FEEF1A7373AA9CB, 0x3FEEDEA64C123422, 0x3FEECE086061892D,\n 0x3FEEBFDAD5362A27, 0x3FEEB42B569D4F82, 0x3FEEAB07DD485429, 0x3FEEA47EB03A5585,\n 0x3FEEA09E667F3BCD, 0x3FEE9F75E8EC5F74, 0x3FEEA11473EB0187, 0x3FEEA589994CCE13,\n 0x3FEEACE5422AA0DB, 0x3FEEB737B0CDC5E5, 0x3FEEC49182A3F090, 0x3FEED503B23E255D,\n 0x3FEEE89F995AD3AD, 0x3FEEFF76F2FB5E47, 0x3FEF199BDD85529C, 0x3FEF3720DCEF9069,\n 0x3FEF5818DCFBA487, 0x3FEF7C97337B9B5F, 0x3FEFA4AFA2A490DA, 0x3FEFD0765B6E4540\n]);\n\n// ULP error: 0.502 (nearest rounding.)\n// Relative error: 1.69 * 2^-34 in [-1/64, 1/64] (before rounding.)\n// Wrong count: 168353 (all nearest rounding wrong results with fma.)\n// @ts-ignore: decorator\n@inline\nexport function exp2f_lut(x: f32): f32 {\n const\n N = 1 << EXP2F_TABLE_BITS,\n N_MASK = N - 1,\n shift = reinterpret(0x4338000000000000) / N, // 0x1.8p+52\n Ox127f = reinterpret(0x7F000000);\n\n const\n C0 = reinterpret(0x3FAC6AF84B912394), // 0x1.c6af84b912394p-5\n C1 = reinterpret(0x3FCEBFCE50FAC4F3), // 0x1.ebfce50fac4f3p-3\n C2 = reinterpret(0x3FE62E42FF0C52D6); // 0x1.62e42ff0c52d6p-1\n\n var xd = x;\n var ix = reinterpret(x);\n var ux = ix >> 20 & 0x7FF;\n if (ux >= 0x430) {\n // |x| >= 128 or x is nan.\n if (ix == 0xFF800000) return 0; // x == -Inf -> 0\n if (ux >= 0x7F8) return x + x; // x == Inf/NaN -> Inf/NaN\n if (x > 0) return x * Ox127f; // x > 0 -> HugeVal (Owerflow)\n if (x <= -150) return 0; // x <= -150 -> 0 (Underflow)\n }\n\n // x = k/N + r with r in [-1/(2N), 1/(2N)] and int k.\n var kd = xd + shift;\n var ki = reinterpret(kd);\n var r = xd - (kd - shift);\n var t: u64, y: f64, s: f64;\n\n // exp2(x) = 2^(k/N) * 2^r ~= s * (C0*r^3 + C1*r^2 + C2*r + 1)\n t = load(EXP2F_DATA_TAB + ((ki & N_MASK) << alignof()));\n t += ki << (52 - EXP2F_TABLE_BITS);\n s = reinterpret(t);\n y = C2 * r + 1;\n y += (C0 * r + C1) * (r * r);\n y *= s;\n\n return y;\n}\n\n// ULP error: 0.502 (nearest rounding.)\n// Relative error: 1.69 * 2^-34 in [-ln2/64, ln2/64] (before rounding.)\n// Wrong count: 170635 (all nearest rounding wrong results with fma.)\n// @ts-ignore: decorator\n@inline\nexport function expf_lut(x: f32): f32 {\n const\n N = 1 << EXP2F_TABLE_BITS,\n N_MASK = N - 1,\n shift = reinterpret(0x4338000000000000), // 0x1.8p+52\n InvLn2N = reinterpret(0x3FF71547652B82FE) * N, // 0x1.71547652b82fep+0\n Ox1p127f = reinterpret(0x7F000000);\n\n const\n C0 = reinterpret(0x3FAC6AF84B912394) / N / N / N, // 0x1.c6af84b912394p-5\n C1 = reinterpret(0x3FCEBFCE50FAC4F3) / N / N, // 0x1.ebfce50fac4f3p-3\n C2 = reinterpret(0x3FE62E42FF0C52D6) / N; // 0x1.62e42ff0c52d6p-1\n\n var xd = x;\n var ix = reinterpret(x);\n var ux = ix >> 20 & 0x7FF;\n if (ux >= 0x42B) {\n // |x| >= 88 or x is nan.\n if (ix == 0xFF800000) return 0; // x == -Inf -> 0\n if (ux >= 0x7F8) return x + x; // x == Inf/NaN -> Inf/NaN\n if (x > reinterpret(0x42B17217)) return x * Ox1p127f; // x > log(0x1p128) ~= 88.72 -> HugeVal (Owerflow)\n if (x < reinterpret(0xC2CFF1B4)) return 0; // x < log(0x1p-150) ~= -103.97 -> 0 (Underflow)\n }\n\n // x*N/Ln2 = k + r with r in [-1/2, 1/2] and int k.\n var z = InvLn2N * xd;\n\n // Round and convert z to int, the result is in [-150*N, 128*N] and\n // ideally ties-to-even rule is used, otherwise the magnitude of r\n // can be bigger which gives larger approximation error.\n var kd = (z + shift);\n var ki = reinterpret(kd);\n var r = z - (kd - shift);\n var s: f64, y: f64, t: u64;\n\n // exp(x) = 2^(k/N) * 2^(r/N) ~= s * (C0*r^3 + C1*r^2 + C2*r + 1)\n t = load(EXP2F_DATA_TAB + ((ki & N_MASK) << alignof()));\n t += ki << (52 - EXP2F_TABLE_BITS);\n s = reinterpret(t);\n z = C0 * r + C1;\n y = C2 * r + 1;\n y += z * (r * r);\n y *= s;\n\n return y;\n}\n\n//\n// Lookup data for log2f\n//\n\n// @ts-ignore: decorator\n@inline const LOG2F_TABLE_BITS = 4;\n\n// @ts-ignore: decorator\n@lazy @inline const LOG2F_DATA_TAB = memory.data([\n reinterpret(0x3FF661EC79F8F3BE), reinterpret(0xBFDEFEC65B963019), // 0x1.661ec79f8f3bep+0, -0x1.efec65b963019p-2,\n reinterpret(0x3FF571ED4AAF883D), reinterpret(0xBFDB0B6832D4FCA4), // 0x1.571ed4aaf883dp+0, -0x1.b0b6832d4fca4p-2,\n reinterpret(0x3FF49539F0F010B0), reinterpret(0xBFD7418B0A1FB77B), // 0x1.49539f0f010bp+0 , -0x1.7418b0a1fb77bp-2,\n reinterpret(0x3FF3C995B0B80385), reinterpret(0xBFD39DE91A6DCF7B), // 0x1.3c995b0b80385p+0, -0x1.39de91a6dcf7bp-2,\n reinterpret(0x3FF30D190C8864A5), reinterpret(0xBFD01D9BF3F2B631), // 0x1.30d190c8864a5p+0, -0x1.01d9bf3f2b631p-2,\n reinterpret(0x3FF25E227B0B8EA0), reinterpret(0xBFC97C1D1B3B7AF0), // 0x1.25e227b0b8eap+0 , -0x1.97c1d1b3b7afp-3 ,\n reinterpret(0x3FF1BB4A4A1A343F), reinterpret(0xBFC2F9E393AF3C9F), // 0x1.1bb4a4a1a343fp+0, -0x1.2f9e393af3c9fp-3,\n reinterpret(0x3FF12358F08AE5BA), reinterpret(0xBFB960CBBF788D5C), // 0x1.12358f08ae5bap+0, -0x1.960cbbf788d5cp-4,\n reinterpret(0x3FF0953F419900A7), reinterpret(0xBFAA6F9DB6475FCE), // 0x1.0953f419900a7p+0, -0x1.a6f9db6475fcep-5,\n reinterpret(0x3FF0000000000000), 0, // 0x1p+0, 0x0,\n reinterpret(0x3FEE608CFD9A47AC), reinterpret(0x3FB338CA9F24F53D), // 0x1.e608cfd9a47acp-1, 0x1.338ca9f24f53dp-4,\n reinterpret(0x3FECA4B31F026AA0), reinterpret(0x3FC476A9543891BA), // 0x1.ca4b31f026aap-1 , 0x1.476a9543891bap-3,\n reinterpret(0x3FEB2036576AFCE6), reinterpret(0x3FCE840B4AC4E4D2), // 0x1.b2036576afce6p-1, 0x1.e840b4ac4e4d2p-3,\n reinterpret(0x3FE9C2D163A1AA2D), reinterpret(0x3FD40645F0C6651C), // 0x1.9c2d163a1aa2dp-1, 0x1.40645f0c6651cp-2,\n reinterpret(0x3FE886E6037841ED), reinterpret(0x3FD88E9C2C1B9FF8), // 0x1.886e6037841edp-1, 0x1.88e9c2c1b9ff8p-2,\n reinterpret(0x3FE767DCF5534862), reinterpret(0x3FDCE0A44EB17BCC) // 0x1.767dcf5534862p-1, 0x1.ce0a44eb17bccp-2\n]);\n\n// ULP error: 0.752 (nearest rounding.)\n// Relative error: 1.9 * 2^-26 (before rounding.)\n// @ts-ignore: decorator\n@inline\nexport function log2f_lut(x: f32): f32 {\n const\n N_MASK = (1 << LOG2F_TABLE_BITS) - 1,\n Ox1p23f = reinterpret(0x4B000000); // 0x1p23f\n\n const\n A0 = reinterpret(0xBFD712B6F70A7E4D), // -0x1.712b6f70a7e4dp-2\n A1 = reinterpret(0x3FDECABF496832E0), // 0x1.ecabf496832ep-2\n A2 = reinterpret(0xBFE715479FFAE3DE), // -0x1.715479ffae3dep-1\n A3 = reinterpret(0x3FF715475F35C8B8); // 0x1.715475f35c8b8p0\n\n var ux = reinterpret(x);\n // Fix sign of zero with downward rounding when x==1.\n // if (WANT_ROUNDING && predict_false(ix == 0x3f800000)) return 0;\n if (ux - 0x00800000 >= 0x7F800000 - 0x00800000) {\n // x < 0x1p-126 or inf or nan.\n if (ux * 2 == 0) return -Infinity;\n if (ux == 0x7F800000) return x; // log2(inf) == inf.\n if ((ux >> 31) || ux * 2 >= 0xFF000000) return (x - x) / (x - x);\n // x is subnormal, normalize it.\n ux = reinterpret(x * Ox1p23f);\n ux -= 23 << 23;\n }\n // x = 2^k z; where z is in range [OFF,2*OFF] and exact.\n // The range is split into N subintervals.\n // The ith subinterval contains z and c is near its center.\n var tmp = ux - 0x3F330000;\n var i = (tmp >> (23 - LOG2F_TABLE_BITS)) & N_MASK;\n var top = tmp & 0xFF800000;\n var iz = ux - top;\n var k = tmp >> 23;\n\n var invc = load(LOG2F_DATA_TAB + (i << (1 + alignof())), 0 << alignof());\n var logc = load(LOG2F_DATA_TAB + (i << (1 + alignof())), 1 << alignof());\n var z = reinterpret(iz);\n\n // log2(x) = log1p(z/c-1)/ln2 + log2(c) + k\n var r = z * invc - 1;\n var y0 = logc + k;\n\n // Pipelined polynomial evaluation to approximate log1p(r)/ln2.\n var y = A1 * r + A2;\n var p = A3 * r + y0;\n var r2 = r * r;\n y += A0 * r2;\n y = y * r2 + p;\n\n return y;\n}\n\n//\n// Lookup data for logf. See: https://git.musl-libc.org/cgit/musl/tree/src/math/logf.c\n//\n\n// @ts-ignore: decorator\n@inline const LOGF_TABLE_BITS = 4;\n\n// @ts-ignore: decorator\n@lazy @inline const LOGF_DATA_TAB = memory.data([\n reinterpret(0x3FF661EC79F8F3BE), reinterpret(0xBFD57BF7808CAADE), // 0x1.661ec79f8f3bep+0, -0x1.57bf7808caadep-2,\n reinterpret(0x3FF571ED4AAF883D), reinterpret(0xBFD2BEF0A7C06DDB), // 0x1.571ed4aaf883dp+0, -0x1.2bef0a7c06ddbp-2,\n reinterpret(0x3FF49539F0F010B0), reinterpret(0xBFD01EAE7F513A67), // 0x1.49539f0f010bp+0 , -0x1.01eae7f513a67p-2,\n reinterpret(0x3FF3C995B0B80385), reinterpret(0xBFCB31D8A68224E9), // 0x1.3c995b0b80385p+0, -0x1.b31d8a68224e9p-3,\n reinterpret(0x3FF30D190C8864A5), reinterpret(0xBFC6574F0AC07758), // 0x1.30d190c8864a5p+0, -0x1.6574f0ac07758p-3,\n reinterpret(0x3FF25E227B0B8EA0), reinterpret(0xBFC1AA2BC79C8100), // 0x1.25e227b0b8eap+0 , -0x1.1aa2bc79c81p-3 ,\n reinterpret(0x3FF1BB4A4A1A343F), reinterpret(0xBFBA4E76CE8C0E5E), // 0x1.1bb4a4a1a343fp+0, -0x1.a4e76ce8c0e5ep-4,\n reinterpret(0x3FF12358F08AE5BA), reinterpret(0xBFB1973C5A611CCC), // 0x1.12358f08ae5bap+0, -0x1.1973c5a611cccp-4,\n reinterpret(0x3FF0953F419900A7), reinterpret(0xBFA252F438E10C1E), // 0x1.0953f419900a7p+0, -0x1.252f438e10c1ep-5,\n reinterpret(0x3FF0000000000000), 0, // 0x1p+0, 0,\n reinterpret(0x3FEE608CFD9A47AC), reinterpret(0x3FAAA5AA5DF25984), // 0x1.e608cfd9a47acp-1, 0x1.aa5aa5df25984p-5,\n reinterpret(0x3FECA4B31F026AA0), reinterpret(0x3FBC5E53AA362EB4), // 0x1.ca4b31f026aap-1 , 0x1.c5e53aa362eb4p-4,\n reinterpret(0x3FEB2036576AFCE6), reinterpret(0x3FC526E57720DB08), // 0x1.b2036576afce6p-1, 0x1.526e57720db08p-3,\n reinterpret(0x3FE9C2D163A1AA2D), reinterpret(0x3FCBC2860D224770), // 0x1.9c2d163a1aa2dp-1, 0x1.bc2860d22477p-3 ,\n reinterpret(0x3FE886E6037841ED), reinterpret(0x3FD1058BC8A07EE1), // 0x1.886e6037841edp-1, 0x1.1058bc8a07ee1p-2,\n reinterpret(0x3FE767DCF5534862), reinterpret(0x3FD4043057B6EE09) // 0x1.767dcf5534862p-1, 0x1.4043057b6ee09p-2\n]);\n\n// ULP error: 0.818 (nearest rounding.)\n// Relative error: 1.957 * 2^-26 (before rounding.)\n// @ts-ignore: decorator\n@inline\nexport function logf_lut(x: f32): f32 {\n const\n N_MASK = (1 << LOGF_TABLE_BITS) - 1,\n Ox1p23f = reinterpret(0x4B000000); // 0x1p23f\n\n const\n Ln2 = reinterpret(0x3FE62E42FEFA39EF), // 0x1.62e42fefa39efp-1;\n A0 = reinterpret(0xBFD00EA348B88334), // -0x1.00ea348b88334p-2\n A1 = reinterpret(0x3FD5575B0BE00B6A), // 0x1.5575b0be00b6ap-2\n A2 = reinterpret(0xBFDFFFFEF20A4123); // -0x1.ffffef20a4123p-2\n\n var ux = reinterpret(x);\n // Fix sign of zero with downward rounding when x==1.\n // if (WANT_ROUNDING && ux == 0x3f800000) return 0;\n if (ux - 0x00800000 >= 0x7F800000 - 0x00800000) {\n // x < 0x1p-126 or inf or nan.\n if ((ux << 1) == 0) return -Infinity;\n if (ux == 0x7F800000) return x; // log(inf) == inf.\n if ((ux >> 31) || (ux << 1) >= 0xFF000000) return (x - x) / (x - x);\n // x is subnormal, normalize it.\n ux = reinterpret(x * Ox1p23f);\n ux -= 23 << 23;\n }\n // x = 2^k z; where z is in range [OFF,2*OFF] and exact.\n // The range is split into N subintervals.\n // The ith subinterval contains z and c is near its center.\n var tmp = ux - 0x3F330000;\n var i = (tmp >> (23 - LOGF_TABLE_BITS)) & N_MASK;\n var k = tmp >> 23;\n var iz = ux - (tmp & 0x1FF << 23);\n\n var invc = load(LOGF_DATA_TAB + (i << (1 + alignof())), 0 << alignof());\n var logc = load(LOGF_DATA_TAB + (i << (1 + alignof())), 1 << alignof());\n\n var z = reinterpret(iz);\n\n // log(x) = log1p(z/c-1) + log(c) + k*Ln2\n var r = z * invc - 1;\n var y0 = logc + k * Ln2;\n\n // Pipelined polynomial evaluation to approximate log1p(r).\n var r2 = r * r;\n var y = A1 * r + A2;\n y += A0 * r2;\n y = y * r2 + (y0 + r);\n\n return y;\n}\n\n//\n// Lookup data for powf. See: https://git.musl-libc.org/cgit/musl/tree/src/math/powf.c\n//\n\n// @ts-ignore: decorator\n@inline\nfunction zeroinfnanf(ux: u32): bool {\n return (ux << 1) - 1 >= (0x7f800000 << 1) - 1;\n}\n\n// Returns 0 if not int, 1 if odd int, 2 if even int. The argument is\n// the bit representation of a non-zero finite floating-point value.\n// @ts-ignore: decorator\n@inline\nfunction checkintf(iy: u32): i32 {\n var e = iy >> 23 & 0xFF;\n if (e < 0x7F ) return 0;\n if (e > 0x7F + 23) return 2;\n e = 1 << (0x7F + 23 - e);\n if (iy & (e - 1)) return 0;\n if (iy & e ) return 1;\n return 2;\n}\n\n// Subnormal input is normalized so ix has negative biased exponent.\n// Output is multiplied by N (POWF_SCALE) if TOINT_INTRINICS is set.\n// @ts-ignore: decorator\n@inline\nfunction log2f_inline(ux: u32): f64 {\n const N_MASK = (1 << LOG2F_TABLE_BITS) - 1;\n\n const\n A0 = reinterpret(0x3FD27616C9496E0B), // 0x1.27616c9496e0bp-2\n A1 = reinterpret(0xBFD71969A075C67A), // -0x1.71969a075c67ap-2\n A2 = reinterpret(0x3FDEC70A6CA7BADD), // 0x1.ec70a6ca7baddp-2\n A3 = reinterpret(0xBFE7154748BEF6C8), // -0x1.7154748bef6c8p-1\n A4 = reinterpret(0x3FF71547652AB82B); // 0x1.71547652ab82bp+0\n\n // x = 2^k z; where z is in range [OFF,2*OFF] and exact.\n // The range is split into N subintervals.\n // The ith subinterval contains z and c is near its center.\n var tmp = ux - 0x3F330000;\n var i = usize((tmp >> (23 - LOG2F_TABLE_BITS)) & N_MASK);\n var top = tmp & 0xFF800000;\n var uz = ux - top;\n var k = top >> 23;\n\n var invc = load(LOG2F_DATA_TAB + (i << (1 + alignof())), 0 << alignof());\n var logc = load(LOG2F_DATA_TAB + (i << (1 + alignof())), 1 << alignof());\n var z = reinterpret(uz);\n\n // log2(x) = log1p(z/c-1)/ln2 + log2(c) + k\n var r = z * invc - 1;\n var y0 = logc + k;\n\n // Pipelined polynomial evaluation to approximate log1p(r)/ln2.\n var y = A0 * r + A1;\n var p = A2 * r + A3;\n var q = A4 * r + y0;\n\n r *= r;\n q += p * r;\n y = y * (r * r) + q;\n\n return y;\n}\n\n// The output of log2 and thus the input of exp2 is either scaled by N\n// (in case of fast toint intrinsics) or not. The unscaled xd must be\n// in [-1021,1023], sign_bias sets the sign of the result.\n// @ts-ignore: decorator\n@inline\nfunction exp2f_inline(xd: f64, signBias: u32): f32 {\n const\n N = 1 << EXP2F_TABLE_BITS,\n N_MASK = N - 1,\n shift = reinterpret(0x4338000000000000) / N; // 0x1.8p+52\n\n const\n C0 = reinterpret(0x3FAC6AF84B912394), // 0x1.c6af84b912394p-5\n C1 = reinterpret(0x3FCEBFCE50FAC4F3), // 0x1.ebfce50fac4f3p-3\n C2 = reinterpret(0x3FE62E42FF0C52D6); // 0x1.62e42ff0c52d6p-1\n\n // x = k/N + r with r in [-1/(2N), 1/(2N)]\n var kd = (xd + shift);\n var ki = reinterpret(kd);\n var r = xd - (kd - shift);\n var t: u64, z: f64, y: f64, s: f64;\n\n // exp2(x) = 2^(k/N) * 2^r ~= s * (C0*r^3 + C1*r^2 + C2*r + 1)\n t = load(EXP2F_DATA_TAB + ((ki & N_MASK) << alignof()));\n t += (ki + signBias) << (52 - EXP2F_TABLE_BITS);\n s = reinterpret(t);\n z = C0 * r + C1;\n y = C2 * r + 1;\n y += z * (r * r);\n y *= s;\n return y;\n}\n\n// @ts-ignore: decorator\n@inline\nfunction xflowf(sign: u32, y: f32): f32 {\n return select(-y, y, sign) * y;\n}\n\n// @ts-ignore: decorator\n@inline\nfunction oflowf(sign: u32): f32 {\n return xflowf(sign, reinterpret(0x70000000)); // 0x1p97f\n}\n\n// @ts-ignore: decorator\n@inline\nfunction uflowf(sign: u32): f32 {\n return xflowf(sign, reinterpret(0x10000000)); // 0x1p-95f\n}\n\n// @ts-ignore: decorator\n@inline\nexport function powf_lut(x: f32, y: f32): f32 {\n const\n Ox1p23f = reinterpret(0x4B000000), // 0x1p23f\n UPPER_LIMIT = reinterpret(0x405FFFFFFFD1D571), // 0x1.fffffffd1d571p+6\n LOWER_LIMIT = -150.0,\n SIGN_BIAS = 1 << (EXP2F_TABLE_BITS + 11);\n\n var signBias: u32 = 0;\n var ix = reinterpret(x);\n var iy = reinterpret(y);\n var ny = 0;\n\n if (i32(ix - 0x00800000 >= 0x7f800000 - 0x00800000) | (ny = i32(zeroinfnanf(iy)))) {\n // Either (x < 0x1p-126 or inf or nan) or (y is 0 or inf or nan).\n if (ny) {\n if ((iy << 1) == 0) return 1.0;\n if (ix == 0x3F800000) return NaN; // original: 1.0\n if ((ix << 1) > (0x7F800000 << 1) || (iy << 1) > (0x7F800000 << 1)) return x + y;\n if ((ix << 1) == (0x3F800000 << 1)) return NaN; // original: 1.0\n if (((ix << 1) < (0x3F800000 << 1)) == !(iy >> 31)) return 0; // |x| < 1 && y==inf or |x| > 1 && y==-inf.\n return y * y;\n }\n if (zeroinfnanf(ix)) {\n let x2 = x * x;\n if ((ix >> 31) && checkintf(iy) == 1) x2 = -x2;\n return iy < 0 ? 1 / x2 : x2;\n }\n // x and y are non-zero finite.\n if (ix < 0) {\n // Finite x < 0.\n let yint = checkintf(iy);\n if (yint == 0) return (x - x) / (x - x);\n if (yint == 1) signBias = SIGN_BIAS;\n ix &= 0x7FFFFFFF;\n }\n if (ix < 0x00800000) {\n // Normalize subnormal x so exponent becomes negative.\n ix = reinterpret(x * Ox1p23f);\n ix &= 0x7FFFFFFF;\n ix -= 23 << 23;\n }\n }\n var logx = log2f_inline(ix);\n var ylogx = y * logx; // cannot overflow, y is single prec.\n if ((reinterpret(ylogx) >> 47 & 0xFFFF) >= 0x80BF) { // reinterpret(126.0) >> 47\n // |y * log(x)| >= 126\n if (ylogx > UPPER_LIMIT) return oflowf(signBias); // overflow\n if (ylogx <= LOWER_LIMIT) return uflowf(signBias); // underflow\n }\n return exp2f_inline(ylogx, signBias);\n}\n\n//\n// Lookup data for exp. See: https://git.musl-libc.org/cgit/musl/tree/src/math/exp.c\n//\n\n// @ts-ignore: decorator\n@inline const EXP_TABLE_BITS = 7;\n\n// @ts-ignore: decorator\n@lazy @inline const EXP_DATA_TAB = memory.data([\n 0x0000000000000000, 0x3FF0000000000000,\n 0x3C9B3B4F1A88BF6E, 0x3FEFF63DA9FB3335,\n 0xBC7160139CD8DC5D, 0x3FEFEC9A3E778061,\n 0xBC905E7A108766D1, 0x3FEFE315E86E7F85,\n 0x3C8CD2523567F613, 0x3FEFD9B0D3158574,\n 0xBC8BCE8023F98EFA, 0x3FEFD06B29DDF6DE,\n 0x3C60F74E61E6C861, 0x3FEFC74518759BC8,\n 0x3C90A3E45B33D399, 0x3FEFBE3ECAC6F383,\n 0x3C979AA65D837B6D, 0x3FEFB5586CF9890F,\n 0x3C8EB51A92FDEFFC, 0x3FEFAC922B7247F7,\n 0x3C3EBE3D702F9CD1, 0x3FEFA3EC32D3D1A2,\n 0xBC6A033489906E0B, 0x3FEF9B66AFFED31B,\n 0xBC9556522A2FBD0E, 0x3FEF9301D0125B51,\n 0xBC5080EF8C4EEA55, 0x3FEF8ABDC06C31CC,\n 0xBC91C923B9D5F416, 0x3FEF829AAEA92DE0,\n 0x3C80D3E3E95C55AF, 0x3FEF7A98C8A58E51,\n 0xBC801B15EAA59348, 0x3FEF72B83C7D517B,\n 0xBC8F1FF055DE323D, 0x3FEF6AF9388C8DEA,\n 0x3C8B898C3F1353BF, 0x3FEF635BEB6FCB75,\n 0xBC96D99C7611EB26, 0x3FEF5BE084045CD4,\n 0x3C9AECF73E3A2F60, 0x3FEF54873168B9AA,\n 0xBC8FE782CB86389D, 0x3FEF4D5022FCD91D,\n 0x3C8A6F4144A6C38D, 0x3FEF463B88628CD6,\n 0x3C807A05B0E4047D, 0x3FEF3F49917DDC96,\n 0x3C968EFDE3A8A894, 0x3FEF387A6E756238,\n 0x3C875E18F274487D, 0x3FEF31CE4FB2A63F,\n 0x3C80472B981FE7F2, 0x3FEF2B4565E27CDD,\n 0xBC96B87B3F71085E, 0x3FEF24DFE1F56381,\n 0x3C82F7E16D09AB31, 0x3FEF1E9DF51FDEE1,\n 0xBC3D219B1A6FBFFA, 0x3FEF187FD0DAD990,\n 0x3C8B3782720C0AB4, 0x3FEF1285A6E4030B,\n 0x3C6E149289CECB8F, 0x3FEF0CAFA93E2F56,\n 0x3C834D754DB0ABB6, 0x3FEF06FE0A31B715,\n 0x3C864201E2AC744C, 0x3FEF0170FC4CD831,\n 0x3C8FDD395DD3F84A, 0x3FEEFC08B26416FF,\n 0xBC86A3803B8E5B04, 0x3FEEF6C55F929FF1,\n 0xBC924AEDCC4B5068, 0x3FEEF1A7373AA9CB,\n 0xBC9907F81B512D8E, 0x3FEEECAE6D05D866,\n 0xBC71D1E83E9436D2, 0x3FEEE7DB34E59FF7,\n 0xBC991919B3CE1B15, 0x3FEEE32DC313A8E5,\n 0x3C859F48A72A4C6D, 0x3FEEDEA64C123422,\n 0xBC9312607A28698A, 0x3FEEDA4504AC801C,\n 0xBC58A78F4817895B, 0x3FEED60A21F72E2A,\n 0xBC7C2C9B67499A1B, 0x3FEED1F5D950A897,\n 0x3C4363ED60C2AC11, 0x3FEECE086061892D,\n 0x3C9666093B0664EF, 0x3FEECA41ED1D0057,\n 0x3C6ECCE1DAA10379, 0x3FEEC6A2B5C13CD0,\n 0x3C93FF8E3F0F1230, 0x3FEEC32AF0D7D3DE,\n 0x3C7690CEBB7AAFB0, 0x3FEEBFDAD5362A27,\n 0x3C931DBDEB54E077, 0x3FEEBCB299FDDD0D,\n 0xBC8F94340071A38E, 0x3FEEB9B2769D2CA7,\n 0xBC87DECCDC93A349, 0x3FEEB6DAA2CF6642,\n 0xBC78DEC6BD0F385F, 0x3FEEB42B569D4F82,\n 0xBC861246EC7B5CF6, 0x3FEEB1A4CA5D920F,\n 0x3C93350518FDD78E, 0x3FEEAF4736B527DA,\n 0x3C7B98B72F8A9B05, 0x3FEEAD12D497C7FD,\n 0x3C9063E1E21C5409, 0x3FEEAB07DD485429,\n 0x3C34C7855019C6EA, 0x3FEEA9268A5946B7,\n 0x3C9432E62B64C035, 0x3FEEA76F15AD2148,\n 0xBC8CE44A6199769F, 0x3FEEA5E1B976DC09,\n 0xBC8C33C53BEF4DA8, 0x3FEEA47EB03A5585,\n 0xBC845378892BE9AE, 0x3FEEA34634CCC320,\n 0xBC93CEDD78565858, 0x3FEEA23882552225,\n 0x3C5710AA807E1964, 0x3FEEA155D44CA973,\n 0xBC93B3EFBF5E2228, 0x3FEEA09E667F3BCD,\n 0xBC6A12AD8734B982, 0x3FEEA012750BDABF,\n 0xBC6367EFB86DA9EE, 0x3FEE9FB23C651A2F,\n 0xBC80DC3D54E08851, 0x3FEE9F7DF9519484,\n 0xBC781F647E5A3ECF, 0x3FEE9F75E8EC5F74,\n 0xBC86EE4AC08B7DB0, 0x3FEE9F9A48A58174,\n 0xBC8619321E55E68A, 0x3FEE9FEB564267C9,\n 0x3C909CCB5E09D4D3, 0x3FEEA0694FDE5D3F,\n 0xBC7B32DCB94DA51D, 0x3FEEA11473EB0187,\n 0x3C94ECFD5467C06B, 0x3FEEA1ED0130C132,\n 0x3C65EBE1ABD66C55, 0x3FEEA2F336CF4E62,\n 0xBC88A1C52FB3CF42, 0x3FEEA427543E1A12,\n 0xBC9369B6F13B3734, 0x3FEEA589994CCE13,\n 0xBC805E843A19FF1E, 0x3FEEA71A4623C7AD,\n 0xBC94D450D872576E, 0x3FEEA8D99B4492ED,\n 0x3C90AD675B0E8A00, 0x3FEEAAC7D98A6699,\n 0x3C8DB72FC1F0EAB4, 0x3FEEACE5422AA0DB,\n 0xBC65B6609CC5E7FF, 0x3FEEAF3216B5448C,\n 0x3C7BF68359F35F44, 0x3FEEB1AE99157736,\n 0xBC93091FA71E3D83, 0x3FEEB45B0B91FFC6,\n 0xBC5DA9B88B6C1E29, 0x3FEEB737B0CDC5E5,\n 0xBC6C23F97C90B959, 0x3FEEBA44CBC8520F,\n 0xBC92434322F4F9AA, 0x3FEEBD829FDE4E50,\n 0xBC85CA6CD7668E4B, 0x3FEEC0F170CA07BA,\n 0x3C71AFFC2B91CE27, 0x3FEEC49182A3F090,\n 0x3C6DD235E10A73BB, 0x3FEEC86319E32323,\n 0xBC87C50422622263, 0x3FEECC667B5DE565,\n 0x3C8B1C86E3E231D5, 0x3FEED09BEC4A2D33,\n 0xBC91BBD1D3BCBB15, 0x3FEED503B23E255D,\n 0x3C90CC319CEE31D2, 0x3FEED99E1330B358,\n 0x3C8469846E735AB3, 0x3FEEDE6B5579FDBF,\n 0xBC82DFCD978E9DB4, 0x3FEEE36BBFD3F37A,\n 0x3C8C1A7792CB3387, 0x3FEEE89F995AD3AD,\n 0xBC907B8F4AD1D9FA, 0x3FEEEE07298DB666,\n 0xBC55C3D956DCAEBA, 0x3FEEF3A2B84F15FB,\n 0xBC90A40E3DA6F640, 0x3FEEF9728DE5593A,\n 0xBC68D6F438AD9334, 0x3FEEFF76F2FB5E47,\n 0xBC91EEE26B588A35, 0x3FEF05B030A1064A,\n 0x3C74FFD70A5FDDCD, 0x3FEF0C1E904BC1D2,\n 0xBC91BDFBFA9298AC, 0x3FEF12C25BD71E09,\n 0x3C736EAE30AF0CB3, 0x3FEF199BDD85529C,\n 0x3C8EE3325C9FFD94, 0x3FEF20AB5FFFD07A,\n 0x3C84E08FD10959AC, 0x3FEF27F12E57D14B,\n 0x3C63CDAF384E1A67, 0x3FEF2F6D9406E7B5,\n 0x3C676B2C6C921968, 0x3FEF3720DCEF9069,\n 0xBC808A1883CCB5D2, 0x3FEF3F0B555DC3FA,\n 0xBC8FAD5D3FFFFA6F, 0x3FEF472D4A07897C,\n 0xBC900DAE3875A949, 0x3FEF4F87080D89F2,\n 0x3C74A385A63D07A7, 0x3FEF5818DCFBA487,\n 0xBC82919E2040220F, 0x3FEF60E316C98398,\n 0x3C8E5A50D5C192AC, 0x3FEF69E603DB3285,\n 0x3C843A59AC016B4B, 0x3FEF7321F301B460,\n 0xBC82D52107B43E1F, 0x3FEF7C97337B9B5F,\n 0xBC892AB93B470DC9, 0x3FEF864614F5A129,\n 0x3C74B604603A88D3, 0x3FEF902EE78B3FF6,\n 0x3C83C5EC519D7271, 0x3FEF9A51FBC74C83,\n 0xBC8FF7128FD391F0, 0x3FEFA4AFA2A490DA,\n 0xBC8DAE98E223747D, 0x3FEFAF482D8E67F1,\n 0x3C8EC3BC41AA2008, 0x3FEFBA1BEE615A27,\n 0x3C842B94C3A9EB32, 0x3FEFC52B376BBA97,\n 0x3C8A64A931D185EE, 0x3FEFD0765B6E4540,\n 0xBC8E37BAE43BE3ED, 0x3FEFDBFDAD9CBE14,\n 0x3C77893B4D91CD9D, 0x3FEFE7C1819E90D8,\n 0x3C5305C14160CC89, 0x3FEFF3C22B8F71F1\n]);\n\n// Handle cases that may overflow or underflow when computing the result that\n// is scale*(1+TMP) without intermediate rounding. The bit representation of\n// scale is in SBITS, however it has a computed exponent that may have\n// overflown into the sign bit so that needs to be adjusted before using it as\n// a double. (int32_t)KI is the k used in the argument reduction and exponent\n// adjustment of scale, positive k here means the result may overflow and\n// negative k means the result may underflow.\n// @ts-ignore: decorator\n@inline\nfunction specialcase(tmp: f64, sbits: u64, ki: u64): f64 {\n const\n Ox1p_1022 = reinterpret(0x0010000000000000), // 0x1p-1022\n Ox1p1009 = reinterpret(0x7F00000000000000); // 0x1p1009\n\n var scale: f64;\n if (!(ki & 0x80000000)) {\n // k > 0, the exponent of scale might have overflowed by <= 460.\n sbits -= u64(1009) << 52;\n scale = reinterpret(sbits);\n return Ox1p1009 * (scale + scale * tmp); // 0x1p1009\n }\n // k < 0, need special care in the subnormal range.\n sbits += u64(1022) << 52;\n // Note: sbits is signed scale.\n scale = reinterpret(sbits);\n var y = scale + scale * tmp;\n if (abs(y) < 1.0) {\n // Round y to the right precision before scaling it into the subnormal\n // range to avoid double rounding that can cause 0.5+E/2 ulp error where\n // E is the worst-case ulp error outside the subnormal range. So this\n // is only useful if the goal is better than 1 ulp worst-case error.\n let one = copysign(1.0, y);\n let lo = scale - y + scale * tmp;\n let hi = one + y;\n lo = one - hi + y + lo;\n y = (hi + lo) - one;\n // Fix the sign of 0.\n if (y == 0.0) y = reinterpret(sbits & 0x8000000000000000);\n }\n return y * Ox1p_1022;\n}\n\n// @ts-ignore: decorator\n@inline\nexport function exp_lut(x: f64): f64 {\n const\n N = 1 << EXP_TABLE_BITS,\n N_MASK = N - 1;\n\n const\n InvLn2N = reinterpret(0x3FF71547652B82FE) * N, // 0x1.71547652b82fep0\n NegLn2hiN = reinterpret(0xBF762E42FEFA0000), // -0x1.62e42fefa0000p-8\n NegLn2loN = reinterpret(0xBD0CF79ABC9E3B3A), // -0x1.cf79abc9e3b3ap-47\n shift = reinterpret(0x4338000000000000); // 0x1.8p52;\n\n const\n C2 = reinterpret(0x3FDFFFFFFFFFFDBD), // __exp_data.poly[0] (0x1.ffffffffffdbdp-2)\n C3 = reinterpret(0x3FC555555555543C), // __exp_data.poly[1] (0x1.555555555543cp-3)\n C4 = reinterpret(0x3FA55555CF172B91), // __exp_data.poly[2] (0x1.55555cf172b91p-5)\n C5 = reinterpret(0x3F81111167A4D017); // __exp_data.poly[3] (0x1.1111167a4d017p-7)\n\n var ux = reinterpret(x);\n var abstop = u32(ux >> 52) & 0x7FF;\n if (abstop - 0x3C9 >= 0x03F) {\n if (abstop - 0x3C9 >= 0x80000000) return 1;\n if (abstop >= 0x409) {\n if (ux == 0xFFF0000000000000) return 0;\n if (abstop >= 0x7FF) {\n return 1.0 + x;\n } else {\n return select(0, Infinity, ux < 0);\n }\n }\n // Large x is special cased below.\n abstop = 0;\n }\n\n // exp(x) = 2^(k/N) * exp(r), with exp(r) in [2^(-1/2N),2^(1/2N)]\n // x = ln2/N*k + r, with int k and r in [-ln2/2N, ln2/2N]\n var z = InvLn2N * x;\n // #if TOINT_INTRINSICS\n // \tkd = roundtoint(z);\n // \tki = converttoint(z);\n // #elif EXP_USE_TOINT_NARROW\n // \t// z - kd is in [-0.5-2^-16, 0.5] in all rounding modes.\n // var kd = z + shift;\n // var ki = reinterpret(kd) >> 16;\n // var kd = ki;\n // #else\n // z - kd is in [-1, 1] in non-nearest rounding modes.\n var kd = z + shift;\n var ki = reinterpret(kd);\n kd -= shift;\n // #endif\n var r = x + kd * NegLn2hiN + kd * NegLn2loN;\n // 2^(k/N) ~= scale * (1 + tail).\n var idx = usize((ki & N_MASK) << 1);\n var top = ki << (52 - EXP_TABLE_BITS);\n\n var tail = reinterpret(load(EXP_DATA_TAB + (idx << alignof()))); // T[idx]\n // This is only a valid scale when -1023*N < k < 1024*N\n var sbits = load(EXP_DATA_TAB + (idx << alignof()), 1 << alignof()) + top; // T[idx + 1]\n // exp(x) = 2^(k/N) * exp(r) ~= scale + scale * (tail + exp(r) - 1).\n // Evaluation is optimized assuming superscalar pipelined execution.\n var r2 = r * r;\n // Without fma the worst case error is 0.25/N ulp larger.\n // Worst case error is less than 0.5+1.11/N+(abs poly error * 2^53) ulp.\n var tmp = tail + r + r2 * (C2 + r * C3) + r2 * r2 * (C4 + r * C5);\n if (abstop == 0) return specialcase(tmp, sbits, ki);\n var scale = reinterpret(sbits);\n // Note: tmp == 0 or |tmp| > 2^-200 and scale > 2^-739, so there\n // is no spurious underflow here even without fma.\n return scale + scale * tmp;\n}\n\n//\n// Lookup data for exp2. See: https://git.musl-libc.org/cgit/musl/tree/src/math/exp2.c\n//\n\n// Handle cases that may overflow or underflow when computing the result that\n// is scale*(1+TMP) without intermediate rounding. The bit representation of\n// scale is in SBITS, however it has a computed exponent that may have\n// overflown into the sign bit so that needs to be adjusted before using it as\n// a double. (int32_t)KI is the k used in the argument reduction and exponent\n// adjustment of scale, positive k here means the result may overflow and\n// negative k means the result may underflow.\n// @ts-ignore: decorator\n@inline\nfunction specialcase2(tmp: f64, sbits: u64, ki: u64): f64 {\n const Ox1p_1022 = reinterpret(0x10000000000000); // 0x1p-1022\n var scale: f64;\n if ((ki & 0x80000000) == 0) {\n // k > 0, the exponent of scale might have overflowed by 1\n sbits -= u64(1) << 52;\n scale = reinterpret(sbits);\n return 2 * (scale * tmp + scale);\n }\n // k < 0, need special care in the subnormal range\n sbits += u64(1022) << 52;\n scale = reinterpret(sbits);\n var y = scale * tmp + scale;\n if (y < 1.0) {\n // Round y to the right precision before scaling it into the subnormal\n // range to avoid double rounding that can cause 0.5+E/2 ulp error where\n // E is the worst-case ulp error outside the subnormal range. So this\n // is only useful if the goal is better than 1 ulp worst-case error.\n let hi: f64, lo: f64;\n lo = scale - y + scale * tmp;\n hi = 1.0 + y;\n lo = 1.0 - hi + y + lo;\n y = (hi + lo) - 1.0;\n }\n return y * Ox1p_1022;\n}\n\n// @ts-ignore: decorator\n@inline\nexport function exp2_lut(x: f64): f64 {\n const\n N = 1 << EXP_TABLE_BITS,\n N_MASK = N - 1,\n shift = reinterpret(0x4338000000000000) / N; // 0x1.8p52\n\n const\n C1 = reinterpret(0x3FE62E42FEFA39EF), // 0x1.62e42fefa39efp-1\n C2 = reinterpret(0x3FCEBFBDFF82C424), // 0x1.ebfbdff82c424p-3\n C3 = reinterpret(0x3FAC6B08D70CF4B5), // 0x1.c6b08d70cf4b5p-5\n C4 = reinterpret(0x3F83B2ABD24650CC), // 0x1.3b2abd24650ccp-7\n C5 = reinterpret(0x3F55D7E09B4E3A84); // 0x1.5d7e09b4e3a84p-10\n\n var ux = reinterpret(x);\n var abstop = u32(ux >> 52) & 0x7ff;\n if (abstop - 0x3C9 >= 0x03F) {\n if (abstop - 0x3C9 >= 0x80000000) return 1.0;\n if (abstop >= 0x409) {\n if (ux == 0xFFF0000000000000) return 0;\n if (abstop >= 0x7FF) return 1.0 + x;\n if (ux >= 0) return Infinity;\n else if (ux >= 0xC090CC0000000000) return 0;\n }\n if ((ux << 1) > 0x811A000000000000) abstop = 0; // Large x is special cased below.\n }\n\n // exp2(x) = 2^(k/N) * 2^r, with 2^r in [2^(-1/2N),2^(1/2N)].\n // x = k/N + r, with int k and r in [-1/2N, 1/2N]\n var kd = x + shift;\n var ki = reinterpret(kd);\n kd -= shift; // k/N for int k\n var r = x - kd;\n // 2^(k/N) ~= scale * (1 + tail)\n var idx = usize((ki & N_MASK) << 1);\n var top = ki << (52 - EXP_TABLE_BITS);\n\n var tail = reinterpret(load(EXP_DATA_TAB + (idx << alignof()), 0 << alignof())); // T[idx])\n // This is only a valid scale when -1023*N < k < 1024*N\n var sbits = load(EXP_DATA_TAB + (idx << alignof()), 1 << alignof()) + top; // T[idx + 1]\n // exp2(x) = 2^(k/N) * 2^r ~= scale + scale * (tail + 2^r - 1).\n // Evaluation is optimized assuming superscalar pipelined execution\n var r2 = r * r;\n // Without fma the worst case error is 0.5/N ulp larger.\n // Worst case error is less than 0.5+0.86/N+(abs poly error * 2^53) ulp.\n var tmp = tail + r * C1 + r2 * (C2 + r * C3) + r2 * r2 * (C4 + r * C5);\n if (abstop == 0) return specialcase2(tmp, sbits, ki);\n var scale = reinterpret(sbits);\n // Note: tmp == 0 or |tmp| > 2^-65 and scale > 2^-928, so there\n // is no spurious underflow here even without fma.\n return scale * tmp + scale;\n}\n\n//\n// Lookup data for log2. See: https://git.musl-libc.org/cgit/musl/tree/src/math/log2.c\n//\n\n// @ts-ignore: decorator\n@inline const LOG2_TABLE_BITS = 6;\n\n/* Algorithm:\n\n x = 2^k z\n log2(x) = k + log2(c) + log2(z/c)\n log2(z/c) = poly(z/c - 1)\n\nwhere z is in [1.6p-1; 1.6p0] which is split into N subintervals and z falls\ninto the ith one, then table entries are computed as\n\n tab[i].invc = 1/c\n tab[i].logc = (double)log2(c)\n tab2[i].chi = (double)c\n tab2[i].clo = (double)(c - (double)c)\n\nwhere c is near the center of the subinterval and is chosen by trying +-2^29\nfloating point invc candidates around 1/center and selecting one for which\n\n 1) the rounding error in 0x1.8p10 + logc is 0,\n 2) the rounding error in z - chi - clo is < 0x1p-64 and\n 3) the rounding error in (double)log2(c) is minimized (< 0x1p-68).\n\nNote: 1) ensures that k + logc can be computed without rounding error, 2)\nensures that z/c - 1 can be computed as (z - chi - clo)*invc with close to a\nsingle rounding error when there is no fast fma for z*invc - 1, 3) ensures\nthat logc + poly(z/c - 1) has small error, however near x == 1 when\n|log2(x)| < 0x1p-4, this is not enough so that is special cased. */\n\n// @ts-ignore: decorator\n@lazy @inline const LOG2_DATA_TAB1 = memory.data([\n // invc , logc\n reinterpret(0x3FF724286BB1ACF8), reinterpret(0xBFE1095FEECDB000),\n reinterpret(0x3FF6E1F766D2CCA1), reinterpret(0xBFE08494BD76D000),\n reinterpret(0x3FF6A13D0E30D48A), reinterpret(0xBFE00143AEE8F800),\n reinterpret(0x3FF661EC32D06C85), reinterpret(0xBFDEFEC5360B4000),\n reinterpret(0x3FF623FA951198F8), reinterpret(0xBFDDFDD91AB7E000),\n reinterpret(0x3FF5E75BA4CF026C), reinterpret(0xBFDCFFAE0CC79000),\n reinterpret(0x3FF5AC055A214FB8), reinterpret(0xBFDC043811FDA000),\n reinterpret(0x3FF571ED0F166E1E), reinterpret(0xBFDB0B67323AE000),\n reinterpret(0x3FF53909590BF835), reinterpret(0xBFDA152F5A2DB000),\n reinterpret(0x3FF5014FED61ADDD), reinterpret(0xBFD9217F5AF86000),\n reinterpret(0x3FF4CAB88E487BD0), reinterpret(0xBFD8304DB0719000),\n reinterpret(0x3FF49539B4334FEE), reinterpret(0xBFD74189F9A9E000),\n reinterpret(0x3FF460CBDFAFD569), reinterpret(0xBFD6552BB5199000),\n reinterpret(0x3FF42D664EE4B953), reinterpret(0xBFD56B23A29B1000),\n reinterpret(0x3FF3FB01111DD8A6), reinterpret(0xBFD483650F5FA000),\n reinterpret(0x3FF3C995B70C5836), reinterpret(0xBFD39DE937F6A000),\n reinterpret(0x3FF3991C4AB6FD4A), reinterpret(0xBFD2BAA1538D6000),\n reinterpret(0x3FF3698E0CE099B5), reinterpret(0xBFD1D98340CA4000),\n reinterpret(0x3FF33AE48213E7B2), reinterpret(0xBFD0FA853A40E000),\n reinterpret(0x3FF30D191985BDB1), reinterpret(0xBFD01D9C32E73000),\n reinterpret(0x3FF2E025CAB271D7), reinterpret(0xBFCE857DA2FA6000),\n reinterpret(0x3FF2B404CF13CD82), reinterpret(0xBFCCD3C8633D8000),\n reinterpret(0x3FF288B02C7CCB50), reinterpret(0xBFCB26034C14A000),\n reinterpret(0x3FF25E2263944DE5), reinterpret(0xBFC97C1C2F4FE000),\n reinterpret(0x3FF234563D8615B1), reinterpret(0xBFC7D6023F800000),\n reinterpret(0x3FF20B46E33EAF38), reinterpret(0xBFC633A71A05E000),\n reinterpret(0x3FF1E2EEFDCDA3DD), reinterpret(0xBFC494F5E9570000),\n reinterpret(0x3FF1BB4A580B3930), reinterpret(0xBFC2F9E424E0A000),\n reinterpret(0x3FF19453847F2200), reinterpret(0xBFC162595AFDC000),\n reinterpret(0x3FF16E06C0D5D73C), reinterpret(0xBFBF9C9A75BD8000),\n reinterpret(0x3FF1485F47B7E4C2), reinterpret(0xBFBC7B575BF9C000),\n reinterpret(0x3FF12358AD0085D1), reinterpret(0xBFB960C60FF48000),\n reinterpret(0x3FF0FEF00F532227), reinterpret(0xBFB64CE247B60000),\n reinterpret(0x3FF0DB2077D03A8F), reinterpret(0xBFB33F78B2014000),\n reinterpret(0x3FF0B7E6D65980D9), reinterpret(0xBFB0387D1A42C000),\n reinterpret(0x3FF0953EFE7B408D), reinterpret(0xBFAA6F9208B50000),\n reinterpret(0x3FF07325CAC53B83), reinterpret(0xBFA47A954F770000),\n reinterpret(0x3FF05197E40D1B5C), reinterpret(0xBF9D23A8C50C0000),\n reinterpret(0x3FF03091C1208EA2), reinterpret(0xBF916A2629780000),\n reinterpret(0x3FF0101025B37E21), reinterpret(0xBF7720F8D8E80000),\n reinterpret(0x3FEFC07EF9CAA76B), reinterpret(0x3F86FE53B1500000),\n reinterpret(0x3FEF4465D3F6F184), reinterpret(0x3FA11CCCE10F8000),\n reinterpret(0x3FEECC079F84107F), reinterpret(0x3FAC4DFC8C8B8000),\n reinterpret(0x3FEE573A99975AE8), reinterpret(0x3FB3AA321E574000),\n reinterpret(0x3FEDE5D6F0BD3DE6), reinterpret(0x3FB918A0D08B8000),\n reinterpret(0x3FED77B681FF38B3), reinterpret(0x3FBE72E9DA044000),\n reinterpret(0x3FED0CB5724DE943), reinterpret(0x3FC1DCD2507F6000),\n reinterpret(0x3FECA4B2DC0E7563), reinterpret(0x3FC476AB03DEA000),\n reinterpret(0x3FEC3F8EE8D6CB51), reinterpret(0x3FC7074377E22000),\n reinterpret(0x3FEBDD2B4F020C4C), reinterpret(0x3FC98EDE8BA94000),\n reinterpret(0x3FEB7D6C006015CA), reinterpret(0x3FCC0DB86AD2E000),\n reinterpret(0x3FEB20366E2E338F), reinterpret(0x3FCE840AAFCEE000),\n reinterpret(0x3FEAC57026295039), reinterpret(0x3FD0790AB4678000),\n reinterpret(0x3FEA6D01BC2731DD), reinterpret(0x3FD1AC056801C000),\n reinterpret(0x3FEA16D3BC3FF18B), reinterpret(0x3FD2DB11D4FEE000),\n reinterpret(0x3FE9C2D14967FEAD), reinterpret(0x3FD406464EC58000),\n reinterpret(0x3FE970E4F47C9902), reinterpret(0x3FD52DBE093AF000),\n reinterpret(0x3FE920FB3982BCF2), reinterpret(0x3FD651902050D000),\n reinterpret(0x3FE8D30187F759F1), reinterpret(0x3FD771D2CDEAF000),\n reinterpret(0x3FE886E5EBB9F66D), reinterpret(0x3FD88E9C857D9000),\n reinterpret(0x3FE83C97B658B994), reinterpret(0x3FD9A80155E16000),\n reinterpret(0x3FE7F405FFC61022), reinterpret(0x3FDABE186ED3D000),\n reinterpret(0x3FE7AD22181415CA), reinterpret(0x3FDBD0F2AEA0E000),\n reinterpret(0x3FE767DCF99EFF8C), reinterpret(0x3FDCE0A43DBF4000)\n]);\n\n// @ts-ignore: decorator\n@lazy @inline const LOG2_DATA_TAB2 = memory.data([\n // chi , clo\n reinterpret(0x3FE6200012B90A8E), reinterpret(0x3C8904AB0644B605),\n reinterpret(0x3FE66000045734A6), reinterpret(0x3C61FF9BEA62F7A9),\n reinterpret(0x3FE69FFFC325F2C5), reinterpret(0x3C827ECFCB3C90BA),\n reinterpret(0x3FE6E00038B95A04), reinterpret(0x3C88FF8856739326),\n reinterpret(0x3FE71FFFE09994E3), reinterpret(0x3C8AFD40275F82B1),\n reinterpret(0x3FE7600015590E10), reinterpret(0xBC72FD75B4238341),\n reinterpret(0x3FE7A00012655BD5), reinterpret(0x3C7808E67C242B76),\n reinterpret(0x3FE7E0003259E9A6), reinterpret(0xBC6208E426F622B7),\n reinterpret(0x3FE81FFFEDB4B2D2), reinterpret(0xBC8402461EA5C92F),\n reinterpret(0x3FE860002DFAFCC3), reinterpret(0x3C6DF7F4A2F29A1F),\n reinterpret(0x3FE89FFFF78C6B50), reinterpret(0xBC8E0453094995FD),\n reinterpret(0x3FE8E00039671566), reinterpret(0xBC8A04F3BEC77B45),\n reinterpret(0x3FE91FFFE2BF1745), reinterpret(0xBC77FA34400E203C),\n reinterpret(0x3FE95FFFCC5C9FD1), reinterpret(0xBC76FF8005A0695D),\n reinterpret(0x3FE9A0003BBA4767), reinterpret(0x3C70F8C4C4EC7E03),\n reinterpret(0x3FE9DFFFE7B92DA5), reinterpret(0x3C8E7FD9478C4602),\n reinterpret(0x3FEA1FFFD72EFDAF), reinterpret(0xBC6A0C554DCDAE7E),\n reinterpret(0x3FEA5FFFDE04FF95), reinterpret(0x3C867DA98CE9B26B),\n reinterpret(0x3FEA9FFFCA5E8D2B), reinterpret(0xBC8284C9B54C13DE),\n reinterpret(0x3FEADFFFDDAD03EA), reinterpret(0x3C5812C8EA602E3C),\n reinterpret(0x3FEB1FFFF10D3D4D), reinterpret(0xBC8EFADDAD27789C),\n reinterpret(0x3FEB5FFFCE21165A), reinterpret(0x3C53CB1719C61237),\n reinterpret(0x3FEB9FFFD950E674), reinterpret(0x3C73F7D94194CE00),\n reinterpret(0x3FEBE000139CA8AF), reinterpret(0x3C750AC4215D9BC0),\n reinterpret(0x3FEC20005B46DF99), reinterpret(0x3C6BEEA653E9C1C9),\n reinterpret(0x3FEC600040B9F7AE), reinterpret(0xBC7C079F274A70D6),\n reinterpret(0x3FECA0006255FD8A), reinterpret(0xBC7A0B4076E84C1F),\n reinterpret(0x3FECDFFFD94C095D), reinterpret(0x3C88F933F99AB5D7),\n reinterpret(0x3FED1FFFF975D6CF), reinterpret(0xBC582C08665FE1BE),\n reinterpret(0x3FED5FFFA2561C93), reinterpret(0xBC7B04289BD295F3),\n reinterpret(0x3FED9FFF9D228B0C), reinterpret(0x3C870251340FA236),\n reinterpret(0x3FEDE00065BC7E16), reinterpret(0xBC75011E16A4D80C),\n reinterpret(0x3FEE200002F64791), reinterpret(0x3C89802F09EF62E0),\n reinterpret(0x3FEE600057D7A6D8), reinterpret(0xBC7E0B75580CF7FA),\n reinterpret(0x3FEEA00027EDC00C), reinterpret(0xBC8C848309459811),\n reinterpret(0x3FEEE0006CF5CB7C), reinterpret(0xBC8F8027951576F4),\n reinterpret(0x3FEF2000782B7DCC), reinterpret(0xBC8F81D97274538F),\n reinterpret(0x3FEF6000260C450A), reinterpret(0xBC4071002727FFDC),\n reinterpret(0x3FEF9FFFE88CD533), reinterpret(0xBC581BDCE1FDA8B0),\n reinterpret(0x3FEFDFFFD50F8689), reinterpret(0x3C87F91ACB918E6E),\n reinterpret(0x3FF0200004292367), reinterpret(0x3C9B7FF365324681),\n reinterpret(0x3FF05FFFE3E3D668), reinterpret(0x3C86FA08DDAE957B),\n reinterpret(0x3FF0A0000A85A757), reinterpret(0xBC57E2DE80D3FB91),\n reinterpret(0x3FF0E0001A5F3FCC), reinterpret(0xBC91823305C5F014),\n reinterpret(0x3FF11FFFF8AFBAF5), reinterpret(0xBC8BFABB6680BAC2),\n reinterpret(0x3FF15FFFE54D91AD), reinterpret(0xBC9D7F121737E7EF),\n reinterpret(0x3FF1A00011AC36E1), reinterpret(0x3C9C000A0516F5FF),\n reinterpret(0x3FF1E00019C84248), reinterpret(0xBC9082FBE4DA5DA0),\n reinterpret(0x3FF220000FFE5E6E), reinterpret(0xBC88FDD04C9CFB43),\n reinterpret(0x3FF26000269FD891), reinterpret(0x3C8CFE2A7994D182),\n reinterpret(0x3FF2A00029A6E6DA), reinterpret(0xBC700273715E8BC5),\n reinterpret(0x3FF2DFFFE0293E39), reinterpret(0x3C9B7C39DAB2A6F9),\n reinterpret(0x3FF31FFFF7DCF082), reinterpret(0x3C7DF1336EDC5254),\n reinterpret(0x3FF35FFFF05A8B60), reinterpret(0xBC9E03564CCD31EB),\n reinterpret(0x3FF3A0002E0EAECC), reinterpret(0x3C75F0E74BD3A477),\n reinterpret(0x3FF3E000043BB236), reinterpret(0x3C9C7DCB149D8833),\n reinterpret(0x3FF4200002D187FF), reinterpret(0x3C7E08AFCF2D3D28),\n reinterpret(0x3FF460000D387CB1), reinterpret(0x3C820837856599A6),\n reinterpret(0x3FF4A00004569F89), reinterpret(0xBC89FA5C904FBCD2),\n reinterpret(0x3FF4E000043543F3), reinterpret(0xBC781125ED175329),\n reinterpret(0x3FF51FFFCC027F0F), reinterpret(0x3C9883D8847754DC),\n reinterpret(0x3FF55FFFFD87B36F), reinterpret(0xBC8709E731D02807),\n reinterpret(0x3FF59FFFF21DF7BA), reinterpret(0x3C87F79F68727B02),\n reinterpret(0x3FF5DFFFEBFC3481), reinterpret(0xBC9180902E30E93E)\n]);\n\n// @ts-ignore: decorator\n@inline\nexport function log2_lut(x: f64): f64 {\n const N_MASK = (1 << LOG2_TABLE_BITS) - 1;\n\n const\n LO: u64 = 0x3FEEA4AF00000000, // reinterpret(1.0 - 0x1.5b51p-5)\n HI: u64 = 0x3FF0B55900000000; // reinterpret(1.0 + 0x1.6ab2p-5)\n\n const\n InvLn2hi = reinterpret(0x3FF7154765200000), // 0x1.7154765200000p+0\n InvLn2lo = reinterpret(0x3DE705FC2EEFA200), // 0x1.705fc2eefa200p-33\n Ox1p52 = reinterpret(0x4330000000000000); // 0x1p52\n\n const\n B0 = reinterpret(0xBFE71547652B82FE), // -0x1.71547652b82fep-1\n B1 = reinterpret(0x3FDEC709DC3A03F7), // 0x1.ec709dc3a03f7p-2\n B2 = reinterpret(0xBFD71547652B7C3F), // -0x1.71547652b7c3fp-2\n B3 = reinterpret(0x3FD2776C50F05BE4), // 0x1.2776c50f05be4p-2\n B4 = reinterpret(0xBFCEC709DD768FE5), // -0x1.ec709dd768fe5p-3\n B5 = reinterpret(0x3FCA61761EC4E736), // 0x1.a61761ec4e736p-3\n B6 = reinterpret(0xBFC7153FBC64A79B), // -0x1.7153fbc64a79bp-3\n B7 = reinterpret(0x3FC484D154F01B4A), // 0x1.484d154f01b4ap-3\n B8 = reinterpret(0xBFC289E4A72C383C), // -0x1.289e4a72c383cp-3\n B9 = reinterpret(0x3FC0B32F285AEE66); // 0x1.0b32f285aee66p-3\n\n const\n A0 = reinterpret(0xBFE71547652B8339), // -0x1.71547652b8339p-1\n A1 = reinterpret(0x3FDEC709DC3A04BE), // 0x1.ec709dc3a04bep-2\n A2 = reinterpret(0xBFD7154764702FFB), // -0x1.7154764702ffbp-2\n A3 = reinterpret(0x3FD2776C50034C48), // 0x1.2776c50034c48p-2\n A4 = reinterpret(0xBFCEC7B328EA92BC), // -0x1.ec7b328ea92bcp-3\n A5 = reinterpret(0x3FCA6225E117F92E); // 0x1.a6225e117f92ep-3\n\n var ix = reinterpret(x);\n if (ix - LO < HI - LO) {\n let r = x - 1.0;\n // #if __FP_FAST_FMA\n // hi = r * InvLn2hi;\n // lo = r * InvLn2lo + __builtin_fma(r, InvLn2hi, -hi);\n // #else\n let rhi = reinterpret(reinterpret(r) & 0xFFFFFFFF00000000);\n let rlo = r - rhi;\n let hi = rhi * InvLn2hi;\n let lo = rlo * InvLn2hi + r * InvLn2lo;\n // #endif\n let r2 = r * r; // rounding error: 0x1p-62\n let r4 = r2 * r2;\n // Worst-case error is less than 0.54 ULP (0.55 ULP without fma)\n let p = r2 * (B0 + r * B1);\n let y = hi + p;\n lo += hi - y + p;\n lo += r4 * (B2 + r * B3 + r2 * (B4 + r * B5) +\n r4 * (B6 + r * B7 + r2 * (B8 + r * B9)));\n return y + lo;\n }\n var top = u32(ix >> 48);\n if (top - 0x0010 >= 0x7ff0 - 0x0010) {\n // x < 0x1p-1022 or inf or nan.\n if ((ix << 1) == 0) return -1.0 / (x * x);\n if (ix == 0x7FF0000000000000) return x; // log(inf) == inf\n if ((top & 0x8000) || (top & 0x7FF0) == 0x7FF0) return (x - x) / (x - x);\n // x is subnormal, normalize it.\n ix = reinterpret(x * Ox1p52);\n ix -= u64(52) << 52;\n }\n\n // x = 2^k z; where z is in range [OFF,2*OFF) and exact.\n // The range is split into N subintervals.\n // The ith subinterval contains z and c is near its center.\n var tmp = ix - 0x3FE6000000000000;\n var i = ((tmp >> (52 - LOG2_TABLE_BITS)) & N_MASK);\n var k = tmp >> 52;\n var iz = ix - (tmp & 0xFFF0000000000000);\n\n var invc = load(LOG2_DATA_TAB1 + (i << (1 + alignof())), 0 << alignof()); // T[i].invc;\n var logc = load(LOG2_DATA_TAB1 + (i << (1 + alignof())), 1 << alignof()); // T[i].logc;\n var z = reinterpret(iz);\n var kd = k;\n\n // log2(x) = log2(z/c) + log2(c) + k.\n // r ~= z/c - 1, |r| < 1/(2*N).\n // #if __FP_FAST_FMA\n // \t// rounding error: 0x1p-55/N.\n // \tr = __builtin_fma(z, invc, -1.0);\n // \tt1 = r * InvLn2hi;\n // \tt2 = r * InvLn2lo + __builtin_fma(r, InvLn2hi, -t1);\n // #else\n // rounding error: 0x1p-55/N + 0x1p-65.\n var chi = load(LOG2_DATA_TAB2 + (i << (1 + alignof())), 0 << alignof()); // T[i].chi;\n var clo = load(LOG2_DATA_TAB2 + (i << (1 + alignof())), 1 << alignof()); // T[i].clo;\n\n var r = (z - chi - clo) * invc;\n var rhi = reinterpret(reinterpret(r) & 0xFFFFFFFF00000000);\n var rlo = r - rhi;\n var t1 = rhi * InvLn2hi;\n var t2 = rlo * InvLn2hi + r * InvLn2lo;\n // #endif\n\n // hi + lo = r/ln2 + log2(c) + k\n var t3 = kd + logc;\n var hi = t3 + t1;\n var lo = t3 - hi + t1 + t2;\n\n // log2(r+1) = r/ln2 + r^2*poly(r)\n // Evaluation is optimized assuming superscalar pipelined execution\n var r2 = r * r; // rounding error: 0x1p-54/N^2\n // Worst-case error if |y| > 0x1p-4: 0.547 ULP (0.550 ULP without fma).\n // ~ 0.5 + 2/N/ln2 + abs-poly-error*0x1p56 ULP (+ 0.003 ULP without fma).\n var p = A0 + r * A1 + r2 * (A2 + r * A3) + (r2 * r2) * (A4 + r * A5);\n return lo + r2 * p + hi;\n}\n\n//\n// Lookup data for log. See: https://git.musl-libc.org/cgit/musl/tree/src/math/log.c\n//\n\n// @ts-ignore: decorator\n@inline const LOG_TABLE_BITS = 7;\n\n/* Algorithm:\n\n x = 2^k z\n log(x) = k ln2 + log(c) + log(z/c)\n log(z/c) = poly(z/c - 1)\n\nwhere z is in [1.6p-1; 1.6p0] which is split into N subintervals and z falls\ninto the ith one, then table entries are computed as\n\n tab[i].invc = 1/c\n tab[i].logc = (double)log(c)\n tab2[i].chi = (double)c\n tab2[i].clo = (double)(c - (double)c)\n\nwhere c is near the center of the subinterval and is chosen by trying +-2^29\nfloating point invc candidates around 1/center and selecting one for which\n\n 1) the rounding error in 0x1.8p9 + logc is 0,\n 2) the rounding error in z - chi - clo is < 0x1p-66 and\n 3) the rounding error in (double)log(c) is minimized (< 0x1p-66).\n\nNote: 1) ensures that k*ln2hi + logc can be computed without rounding error,\n2) ensures that z/c - 1 can be computed as (z - chi - clo)*invc with close to\na single rounding error when there is no fast fma for z*invc - 1, 3) ensures\nthat logc + poly(z/c - 1) has small error, however near x == 1 when\n|log(x)| < 0x1p-4, this is not enough so that is special cased.*/\n\n// @ts-ignore: decorator\n@lazy @inline const LOG_DATA_TAB1 = memory.data([\n // invc , logc\n reinterpret(0x3FF734F0C3E0DE9F), reinterpret(0xBFD7CC7F79E69000),\n reinterpret(0x3FF713786A2CE91F), reinterpret(0xBFD76FEEC20D0000),\n reinterpret(0x3FF6F26008FAB5A0), reinterpret(0xBFD713E31351E000),\n reinterpret(0x3FF6D1A61F138C7D), reinterpret(0xBFD6B85B38287800),\n reinterpret(0x3FF6B1490BC5B4D1), reinterpret(0xBFD65D5590807800),\n reinterpret(0x3FF69147332F0CBA), reinterpret(0xBFD602D076180000),\n reinterpret(0x3FF6719F18224223), reinterpret(0xBFD5A8CA86909000),\n reinterpret(0x3FF6524F99A51ED9), reinterpret(0xBFD54F4356035000),\n reinterpret(0x3FF63356AA8F24C4), reinterpret(0xBFD4F637C36B4000),\n reinterpret(0x3FF614B36B9DDC14), reinterpret(0xBFD49DA7FDA85000),\n reinterpret(0x3FF5F66452C65C4C), reinterpret(0xBFD445923989A800),\n reinterpret(0x3FF5D867B5912C4F), reinterpret(0xBFD3EDF439B0B800),\n reinterpret(0x3FF5BABCCB5B90DE), reinterpret(0xBFD396CE448F7000),\n reinterpret(0x3FF59D61F2D91A78), reinterpret(0xBFD3401E17BDA000),\n reinterpret(0x3FF5805612465687), reinterpret(0xBFD2E9E2EF468000),\n reinterpret(0x3FF56397CEE76BD3), reinterpret(0xBFD2941B3830E000),\n reinterpret(0x3FF54725E2A77F93), reinterpret(0xBFD23EC58CDA8800),\n reinterpret(0x3FF52AFF42064583), reinterpret(0xBFD1E9E129279000),\n reinterpret(0x3FF50F22DBB2BDDF), reinterpret(0xBFD1956D2B48F800),\n reinterpret(0x3FF4F38F4734DED7), reinterpret(0xBFD141679AB9F800),\n reinterpret(0x3FF4D843CFDE2840), reinterpret(0xBFD0EDD094EF9800),\n reinterpret(0x3FF4BD3EC078A3C8), reinterpret(0xBFD09AA518DB1000),\n reinterpret(0x3FF4A27FC3E0258A), reinterpret(0xBFD047E65263B800),\n reinterpret(0x3FF4880524D48434), reinterpret(0xBFCFEB224586F000),\n reinterpret(0x3FF46DCE1B192D0B), reinterpret(0xBFCF474A7517B000),\n reinterpret(0x3FF453D9D3391854), reinterpret(0xBFCEA4443D103000),\n reinterpret(0x3FF43A2744B4845A), reinterpret(0xBFCE020D44E9B000),\n reinterpret(0x3FF420B54115F8FB), reinterpret(0xBFCD60A22977F000),\n reinterpret(0x3FF40782DA3EF4B1), reinterpret(0xBFCCC00104959000),\n reinterpret(0x3FF3EE8F5D57FE8F), reinterpret(0xBFCC202956891000),\n reinterpret(0x3FF3D5D9A00B4CE9), reinterpret(0xBFCB81178D811000),\n reinterpret(0x3FF3BD60C010C12B), reinterpret(0xBFCAE2C9CCD3D000),\n reinterpret(0x3FF3A5242B75DAB8), reinterpret(0xBFCA45402E129000),\n reinterpret(0x3FF38D22CD9FD002), reinterpret(0xBFC9A877681DF000),\n reinterpret(0x3FF3755BC5847A1C), reinterpret(0xBFC90C6D69483000),\n reinterpret(0x3FF35DCE49AD36E2), reinterpret(0xBFC87120A645C000),\n reinterpret(0x3FF34679984DD440), reinterpret(0xBFC7D68FB4143000),\n reinterpret(0x3FF32F5CCEFFCB24), reinterpret(0xBFC73CB83C627000),\n reinterpret(0x3FF3187775A10D49), reinterpret(0xBFC6A39A9B376000),\n reinterpret(0x3FF301C8373E3990), reinterpret(0xBFC60B3154B7A000),\n reinterpret(0x3FF2EB4EBB95F841), reinterpret(0xBFC5737D76243000),\n reinterpret(0x3FF2D50A0219A9D1), reinterpret(0xBFC4DC7B8FC23000),\n reinterpret(0x3FF2BEF9A8B7FD2A), reinterpret(0xBFC4462C51D20000),\n reinterpret(0x3FF2A91C7A0C1BAB), reinterpret(0xBFC3B08ABC830000),\n reinterpret(0x3FF293726014B530), reinterpret(0xBFC31B996B490000),\n reinterpret(0x3FF27DFA5757A1F5), reinterpret(0xBFC2875490A44000),\n reinterpret(0x3FF268B39B1D3BBF), reinterpret(0xBFC1F3B9F879A000),\n reinterpret(0x3FF2539D838FF5BD), reinterpret(0xBFC160C8252CA000),\n reinterpret(0x3FF23EB7AAC9083B), reinterpret(0xBFC0CE7F57F72000),\n reinterpret(0x3FF22A012BA940B6), reinterpret(0xBFC03CDC49FEA000),\n reinterpret(0x3FF2157996CC4132), reinterpret(0xBFBF57BDBC4B8000),\n reinterpret(0x3FF201201DD2FC9B), reinterpret(0xBFBE370896404000),\n reinterpret(0x3FF1ECF4494D480B), reinterpret(0xBFBD17983EF94000),\n reinterpret(0x3FF1D8F5528F6569), reinterpret(0xBFBBF9674ED8A000),\n reinterpret(0x3FF1C52311577E7C), reinterpret(0xBFBADC79202F6000),\n reinterpret(0x3FF1B17C74CB26E9), reinterpret(0xBFB9C0C3E7288000),\n reinterpret(0x3FF19E010C2C1AB6), reinterpret(0xBFB8A646B372C000),\n reinterpret(0x3FF18AB07BB670BD), reinterpret(0xBFB78D01B3AC0000),\n reinterpret(0x3FF1778A25EFBCB6), reinterpret(0xBFB674F145380000),\n reinterpret(0x3FF1648D354C31DA), reinterpret(0xBFB55E0E6D878000),\n reinterpret(0x3FF151B990275FDD), reinterpret(0xBFB4485CDEA1E000),\n reinterpret(0x3FF13F0EA432D24C), reinterpret(0xBFB333D94D6AA000),\n reinterpret(0x3FF12C8B7210F9DA), reinterpret(0xBFB22079F8C56000),\n reinterpret(0x3FF11A3028ECB531), reinterpret(0xBFB10E4698622000),\n reinterpret(0x3FF107FBDA8434AF), reinterpret(0xBFAFFA6C6AD20000),\n reinterpret(0x3FF0F5EE0F4E6BB3), reinterpret(0xBFADDA8D4A774000),\n reinterpret(0x3FF0E4065D2A9FCE), reinterpret(0xBFABBCECE4850000),\n reinterpret(0x3FF0D244632CA521), reinterpret(0xBFA9A1894012C000),\n reinterpret(0x3FF0C0A77CE2981A), reinterpret(0xBFA788583302C000),\n reinterpret(0x3FF0AF2F83C636D1), reinterpret(0xBFA5715E67D68000),\n reinterpret(0x3FF09DDB98A01339), reinterpret(0xBFA35C8A49658000),\n reinterpret(0x3FF08CABAF52E7DF), reinterpret(0xBFA149E364154000),\n reinterpret(0x3FF07B9F2F4E28FB), reinterpret(0xBF9E72C082EB8000),\n reinterpret(0x3FF06AB58C358F19), reinterpret(0xBF9A55F152528000),\n reinterpret(0x3FF059EEA5ECF92C), reinterpret(0xBF963D62CF818000),\n reinterpret(0x3FF04949CDD12C90), reinterpret(0xBF9228FB8CAA0000),\n reinterpret(0x3FF038C6C6F0ADA9), reinterpret(0xBF8C317B20F90000),\n reinterpret(0x3FF02865137932A9), reinterpret(0xBF8419355DAA0000),\n reinterpret(0x3FF0182427EA7348), reinterpret(0xBF781203C2EC0000),\n reinterpret(0x3FF008040614B195), reinterpret(0xBF60040979240000),\n reinterpret(0x3FEFE01FF726FA1A), reinterpret(0x3F6FEFF384900000),\n reinterpret(0x3FEFA11CC261EA74), reinterpret(0x3F87DC41353D0000),\n reinterpret(0x3FEF6310B081992E), reinterpret(0x3F93CEA3C4C28000),\n reinterpret(0x3FEF25F63CEEADCD), reinterpret(0x3F9B9FC114890000),\n reinterpret(0x3FEEE9C8039113E7), reinterpret(0x3FA1B0D8CE110000),\n reinterpret(0x3FEEAE8078CBB1AB), reinterpret(0x3FA58A5BD001C000),\n reinterpret(0x3FEE741AA29D0C9B), reinterpret(0x3FA95C8340D88000),\n reinterpret(0x3FEE3A91830A99B5), reinterpret(0x3FAD276AEF578000),\n reinterpret(0x3FEE01E009609A56), reinterpret(0x3FB07598E598C000),\n reinterpret(0x3FEDCA01E577BB98), reinterpret(0x3FB253F5E30D2000),\n reinterpret(0x3FED92F20B7C9103), reinterpret(0x3FB42EDD8B380000),\n reinterpret(0x3FED5CAC66FB5CCE), reinterpret(0x3FB606598757C000),\n reinterpret(0x3FED272CAA5EDE9D), reinterpret(0x3FB7DA76356A0000),\n reinterpret(0x3FECF26E3E6B2CCD), reinterpret(0x3FB9AB434E1C6000),\n reinterpret(0x3FECBE6DA2A77902), reinterpret(0x3FBB78C7BB0D6000),\n reinterpret(0x3FEC8B266D37086D), reinterpret(0x3FBD431332E72000),\n reinterpret(0x3FEC5894BD5D5804), reinterpret(0x3FBF0A3171DE6000),\n reinterpret(0x3FEC26B533BB9F8C), reinterpret(0x3FC067152B914000),\n reinterpret(0x3FEBF583EEECE73F), reinterpret(0x3FC147858292B000),\n reinterpret(0x3FEBC4FD75DB96C1), reinterpret(0x3FC2266ECDCA3000),\n reinterpret(0x3FEB951E0C864A28), reinterpret(0x3FC303D7A6C55000),\n reinterpret(0x3FEB65E2C5EF3E2C), reinterpret(0x3FC3DFC33C331000),\n reinterpret(0x3FEB374867C9888B), reinterpret(0x3FC4BA366B7A8000),\n reinterpret(0x3FEB094B211D304A), reinterpret(0x3FC5933928D1F000),\n reinterpret(0x3FEADBE885F2EF7E), reinterpret(0x3FC66ACD2418F000),\n reinterpret(0x3FEAAF1D31603DA2), reinterpret(0x3FC740F8EC669000),\n reinterpret(0x3FEA82E63FD358A7), reinterpret(0x3FC815C0F51AF000),\n reinterpret(0x3FEA5740EF09738B), reinterpret(0x3FC8E92954F68000),\n reinterpret(0x3FEA2C2A90AB4B27), reinterpret(0x3FC9BB3602F84000),\n reinterpret(0x3FEA01A01393F2D1), reinterpret(0x3FCA8BED1C2C0000),\n reinterpret(0x3FE9D79F24DB3C1B), reinterpret(0x3FCB5B515C01D000),\n reinterpret(0x3FE9AE2505C7B190), reinterpret(0x3FCC2967CCBCC000),\n reinterpret(0x3FE9852EF297CE2F), reinterpret(0x3FCCF635D5486000),\n reinterpret(0x3FE95CBAEEA44B75), reinterpret(0x3FCDC1BD3446C000),\n reinterpret(0x3FE934C69DE74838), reinterpret(0x3FCE8C01B8CFE000),\n reinterpret(0x3FE90D4F2F6752E6), reinterpret(0x3FCF5509C0179000),\n reinterpret(0x3FE8E6528EFFD79D), reinterpret(0x3FD00E6C121FB800),\n reinterpret(0x3FE8BFCE9FCC007C), reinterpret(0x3FD071B80E93D000),\n reinterpret(0x3FE899C0DABEC30E), reinterpret(0x3FD0D46B9E867000),\n reinterpret(0x3FE87427AA2317FB), reinterpret(0x3FD13687334BD000),\n reinterpret(0x3FE84F00ACB39A08), reinterpret(0x3FD1980D67234800),\n reinterpret(0x3FE82A49E8653E55), reinterpret(0x3FD1F8FFE0CC8000),\n reinterpret(0x3FE8060195F40260), reinterpret(0x3FD2595FD7636800),\n reinterpret(0x3FE7E22563E0A329), reinterpret(0x3FD2B9300914A800),\n reinterpret(0x3FE7BEB377DCB5AD), reinterpret(0x3FD3187210436000),\n reinterpret(0x3FE79BAA679725C2), reinterpret(0x3FD377266DEC1800),\n reinterpret(0x3FE77907F2170657), reinterpret(0x3FD3D54FFBAF3000),\n reinterpret(0x3FE756CADBD6130C), reinterpret(0x3FD432EEE32FE000)\n]);\n\n// @ts-ignore: decorator\n@lazy @inline const LOG_DATA_TAB2 = memory.data([\n // chi , clo\n reinterpret(0x3FE61000014FB66B), reinterpret(0x3C7E026C91425B3C),\n reinterpret(0x3FE63000034DB495), reinterpret(0x3C8DBFEA48005D41),\n reinterpret(0x3FE650000D94D478), reinterpret(0x3C8E7FA786D6A5B7),\n reinterpret(0x3FE67000074E6FAD), reinterpret(0x3C61FCEA6B54254C),\n reinterpret(0x3FE68FFFFEDF0FAE), reinterpret(0xBC7C7E274C590EFD),\n reinterpret(0x3FE6B0000763C5BC), reinterpret(0xBC8AC16848DCDA01),\n reinterpret(0x3FE6D0001E5CC1F6), reinterpret(0x3C833F1C9D499311),\n reinterpret(0x3FE6EFFFEB05F63E), reinterpret(0xBC7E80041AE22D53),\n reinterpret(0x3FE710000E869780), reinterpret(0x3C7BFF6671097952),\n reinterpret(0x3FE72FFFFC67E912), reinterpret(0x3C8C00E226BD8724),\n reinterpret(0x3FE74FFFDF81116A), reinterpret(0xBC6E02916EF101D2),\n reinterpret(0x3FE770000F679C90), reinterpret(0xBC67FC71CD549C74),\n reinterpret(0x3FE78FFFFA7EC835), reinterpret(0x3C81BEC19EF50483),\n reinterpret(0x3FE7AFFFFE20C2E6), reinterpret(0xBC707E1729CC6465),\n reinterpret(0x3FE7CFFFED3FC900), reinterpret(0xBC808072087B8B1C),\n reinterpret(0x3FE7EFFFE9261A76), reinterpret(0x3C8DC0286D9DF9AE),\n reinterpret(0x3FE81000049CA3E8), reinterpret(0x3C897FD251E54C33),\n reinterpret(0x3FE8300017932C8F), reinterpret(0xBC8AFEE9B630F381),\n reinterpret(0x3FE850000633739C), reinterpret(0x3C89BFBF6B6535BC),\n reinterpret(0x3FE87000204289C6), reinterpret(0xBC8BBF65F3117B75),\n reinterpret(0x3FE88FFFEBF57904), reinterpret(0xBC89006EA23DCB57),\n reinterpret(0x3FE8B00022BC04DF), reinterpret(0xBC7D00DF38E04B0A),\n reinterpret(0x3FE8CFFFE50C1B8A), reinterpret(0xBC88007146FF9F05),\n reinterpret(0x3FE8EFFFFC918E43), reinterpret(0x3C83817BD07A7038),\n reinterpret(0x3FE910001EFA5FC7), reinterpret(0x3C893E9176DFB403),\n reinterpret(0x3FE9300013467BB9), reinterpret(0x3C7F804E4B980276),\n reinterpret(0x3FE94FFFE6EE076F), reinterpret(0xBC8F7EF0D9FF622E),\n reinterpret(0x3FE96FFFDE3C12D1), reinterpret(0xBC7082AA962638BA),\n reinterpret(0x3FE98FFFF4458A0D), reinterpret(0xBC87801B9164A8EF),\n reinterpret(0x3FE9AFFFDD982E3E), reinterpret(0xBC8740E08A5A9337),\n reinterpret(0x3FE9CFFFED49FB66), reinterpret(0x3C3FCE08C19BE000),\n reinterpret(0x3FE9F00020F19C51), reinterpret(0xBC8A3FAA27885B0A),\n reinterpret(0x3FEA10001145B006), reinterpret(0x3C74FF489958DA56),\n reinterpret(0x3FEA300007BBF6FA), reinterpret(0x3C8CBEAB8A2B6D18),\n reinterpret(0x3FEA500010971D79), reinterpret(0x3C88FECADD787930),\n reinterpret(0x3FEA70001DF52E48), reinterpret(0xBC8F41763DD8ABDB),\n reinterpret(0x3FEA90001C593352), reinterpret(0xBC8EBF0284C27612),\n reinterpret(0x3FEAB0002A4F3E4B), reinterpret(0xBC69FD043CFF3F5F),\n reinterpret(0x3FEACFFFD7AE1ED1), reinterpret(0xBC823EE7129070B4),\n reinterpret(0x3FEAEFFFEE510478), reinterpret(0x3C6A063EE00EDEA3),\n reinterpret(0x3FEB0FFFDB650D5B), reinterpret(0x3C5A06C8381F0AB9),\n reinterpret(0x3FEB2FFFFEAACA57), reinterpret(0xBC79011E74233C1D),\n reinterpret(0x3FEB4FFFD995BADC), reinterpret(0xBC79FF1068862A9F),\n reinterpret(0x3FEB7000249E659C), reinterpret(0x3C8AFF45D0864F3E),\n reinterpret(0x3FEB8FFFF9871640), reinterpret(0x3C7CFE7796C2C3F9),\n reinterpret(0x3FEBAFFFD204CB4F), reinterpret(0xBC63FF27EEF22BC4),\n reinterpret(0x3FEBCFFFD2415C45), reinterpret(0xBC6CFFB7EE3BEA21),\n reinterpret(0x3FEBEFFFF86309DF), reinterpret(0xBC814103972E0B5C),\n reinterpret(0x3FEC0FFFE1B57653), reinterpret(0x3C8BC16494B76A19),\n reinterpret(0x3FEC2FFFF1FA57E3), reinterpret(0xBC64FEEF8D30C6ED),\n reinterpret(0x3FEC4FFFDCBFE424), reinterpret(0xBC843F68BCEC4775),\n reinterpret(0x3FEC6FFFED54B9F7), reinterpret(0x3C847EA3F053E0EC),\n reinterpret(0x3FEC8FFFEB998FD5), reinterpret(0x3C7383068DF992F1),\n reinterpret(0x3FECB0002125219A), reinterpret(0xBC68FD8E64180E04),\n reinterpret(0x3FECCFFFDD94469C), reinterpret(0x3C8E7EBE1CC7EA72),\n reinterpret(0x3FECEFFFEAFDC476), reinterpret(0x3C8EBE39AD9F88FE),\n reinterpret(0x3FED1000169AF82B), reinterpret(0x3C757D91A8B95A71),\n reinterpret(0x3FED30000D0FF71D), reinterpret(0x3C89C1906970C7DA),\n reinterpret(0x3FED4FFFEA790FC4), reinterpret(0xBC580E37C558FE0C),\n reinterpret(0x3FED70002EDC87E5), reinterpret(0xBC7F80D64DC10F44),\n reinterpret(0x3FED900021DC82AA), reinterpret(0xBC747C8F94FD5C5C),\n reinterpret(0x3FEDAFFFD86B0283), reinterpret(0x3C8C7F1DC521617E),\n reinterpret(0x3FEDD000296C4739), reinterpret(0x3C88019EB2FFB153),\n reinterpret(0x3FEDEFFFE54490F5), reinterpret(0x3C6E00D2C652CC89),\n reinterpret(0x3FEE0FFFCDABF694), reinterpret(0xBC7F8340202D69D2),\n reinterpret(0x3FEE2FFFDB52C8DD), reinterpret(0x3C7B00C1CA1B0864),\n reinterpret(0x3FEE4FFFF24216EF), reinterpret(0x3C72FFA8B094AB51),\n reinterpret(0x3FEE6FFFE88A5E11), reinterpret(0xBC57F673B1EFBE59),\n reinterpret(0x3FEE9000119EFF0D), reinterpret(0xBC84808D5E0BC801),\n reinterpret(0x3FEEAFFFDFA51744), reinterpret(0x3C780006D54320B5),\n reinterpret(0x3FEED0001A127FA1), reinterpret(0xBC5002F860565C92),\n reinterpret(0x3FEEF00007BABCC4), reinterpret(0xBC8540445D35E611),\n reinterpret(0x3FEF0FFFF57A8D02), reinterpret(0xBC4FFB3139EF9105),\n reinterpret(0x3FEF30001EE58AC7), reinterpret(0x3C8A81ACF2731155),\n reinterpret(0x3FEF4FFFF5823494), reinterpret(0x3C8A3F41D4D7C743),\n reinterpret(0x3FEF6FFFFCA94C6B), reinterpret(0xBC6202F41C987875),\n reinterpret(0x3FEF8FFFE1F9C441), reinterpret(0x3C777DD1F477E74B),\n reinterpret(0x3FEFAFFFD2E0E37E), reinterpret(0xBC6F01199A7CA331),\n reinterpret(0x3FEFD0001C77E49E), reinterpret(0x3C7181EE4BCEACB1),\n reinterpret(0x3FEFEFFFF7E0C331), reinterpret(0xBC6E05370170875A),\n reinterpret(0x3FF00FFFF465606E), reinterpret(0xBC8A7EAD491C0ADA),\n reinterpret(0x3FF02FFFF3867A58), reinterpret(0xBC977F69C3FCB2E0),\n reinterpret(0x3FF04FFFFDFC0D17), reinterpret(0x3C97BFFE34CB945B),\n reinterpret(0x3FF0700003CD4D82), reinterpret(0x3C820083C0E456CB),\n reinterpret(0x3FF08FFFF9F2CBE8), reinterpret(0xBC6DFFDFBE37751A),\n reinterpret(0x3FF0B000010CDA65), reinterpret(0xBC913F7FAEE626EB),\n reinterpret(0x3FF0D00001A4D338), reinterpret(0x3C807DFA79489FF7),\n reinterpret(0x3FF0EFFFFADAFDFD), reinterpret(0xBC77040570D66BC0),\n reinterpret(0x3FF110000BBAFD96), reinterpret(0x3C8E80D4846D0B62),\n reinterpret(0x3FF12FFFFAE5F45D), reinterpret(0x3C9DBFFA64FD36EF),\n reinterpret(0x3FF150000DD59AD9), reinterpret(0x3C9A0077701250AE),\n reinterpret(0x3FF170000F21559A), reinterpret(0x3C8DFDF9E2E3DEEE),\n reinterpret(0x3FF18FFFFC275426), reinterpret(0x3C910030DC3B7273),\n reinterpret(0x3FF1B000123D3C59), reinterpret(0x3C997F7980030188),\n reinterpret(0x3FF1CFFFF8299EB7), reinterpret(0xBC65F932AB9F8C67),\n reinterpret(0x3FF1EFFFF48AD400), reinterpret(0x3C937FBF9DA75BEB),\n reinterpret(0x3FF210000C8B86A4), reinterpret(0x3C9F806B91FD5B22),\n reinterpret(0x3FF2300003854303), reinterpret(0x3C93FFC2EB9FBF33),\n reinterpret(0x3FF24FFFFFBCF684), reinterpret(0x3C7601E77E2E2E72),\n reinterpret(0x3FF26FFFF52921D9), reinterpret(0x3C7FFCBB767F0C61),\n reinterpret(0x3FF2900014933A3C), reinterpret(0xBC7202CA3C02412B),\n reinterpret(0x3FF2B00014556313), reinterpret(0xBC92808233F21F02),\n reinterpret(0x3FF2CFFFEBFE523B), reinterpret(0xBC88FF7E384FDCF2),\n reinterpret(0x3FF2F0000BB8AD96), reinterpret(0xBC85FF51503041C5),\n reinterpret(0x3FF30FFFFB7AE2AF), reinterpret(0xBC810071885E289D),\n reinterpret(0x3FF32FFFFEAC5F7F), reinterpret(0xBC91FF5D3FB7B715),\n reinterpret(0x3FF350000CA66756), reinterpret(0x3C957F82228B82BD),\n reinterpret(0x3FF3700011FBF721), reinterpret(0x3C8000BAC40DD5CC),\n reinterpret(0x3FF38FFFF9592FB9), reinterpret(0xBC943F9D2DB2A751),\n reinterpret(0x3FF3B00004DDD242), reinterpret(0x3C857F6B707638E1),\n reinterpret(0x3FF3CFFFF5B2C957), reinterpret(0x3C7A023A10BF1231),\n reinterpret(0x3FF3EFFFEAB0B418), reinterpret(0x3C987F6D66B152B0),\n reinterpret(0x3FF410001532AFF4), reinterpret(0x3C67F8375F198524),\n reinterpret(0x3FF4300017478B29), reinterpret(0x3C8301E672DC5143),\n reinterpret(0x3FF44FFFE795B463), reinterpret(0x3C89FF69B8B2895A),\n reinterpret(0x3FF46FFFE80475E0), reinterpret(0xBC95C0B19BC2F254),\n reinterpret(0x3FF48FFFEF6FC1E7), reinterpret(0x3C9B4009F23A2A72),\n reinterpret(0x3FF4AFFFE5BEA704), reinterpret(0xBC94FFB7BF0D7D45),\n reinterpret(0x3FF4D000171027DE), reinterpret(0xBC99C06471DC6A3D),\n reinterpret(0x3FF4F0000FF03EE2), reinterpret(0x3C977F890B85531C),\n reinterpret(0x3FF5100012DC4BD1), reinterpret(0x3C6004657166A436),\n reinterpret(0x3FF530001605277A), reinterpret(0xBC96BFCECE233209),\n reinterpret(0x3FF54FFFECDB704C), reinterpret(0xBC8902720505A1D7),\n reinterpret(0x3FF56FFFEF5F54A9), reinterpret(0x3C9BBFE60EC96412),\n reinterpret(0x3FF5900017E61012), reinterpret(0x3C887EC581AFEF90),\n reinterpret(0x3FF5B00003C93E92), reinterpret(0xBC9F41080ABF0CC0),\n reinterpret(0x3FF5D0001D4919BC), reinterpret(0xBC98812AFB254729),\n reinterpret(0x3FF5EFFFE7B87A89), reinterpret(0xBC947EB780ED6904)\n]);\n\n// @ts-ignore: decorator\n@inline\nexport function log_lut(x: f64): f64 {\n const N_MASK = (1 << LOG_TABLE_BITS) - 1;\n\n const\n B0 = reinterpret(0xBFE0000000000000), // -0x1p-1\n B1 = reinterpret(0x3FD5555555555577), // 0x1.5555555555577p-2\n B2 = reinterpret(0xBFCFFFFFFFFFFDCB), // -0x1.ffffffffffdcbp-3\n B3 = reinterpret(0x3FC999999995DD0C), // 0x1.999999995dd0cp-3\n B4 = reinterpret(0xBFC55555556745A7), // -0x1.55555556745a7p-3\n B5 = reinterpret(0x3FC24924A344DE30), // 0x1.24924a344de3p-3\n B6 = reinterpret(0xBFBFFFFFA4423D65), // -0x1.fffffa4423d65p-4\n B7 = reinterpret(0x3FBC7184282AD6CA), // 0x1.c7184282ad6cap-4\n B8 = reinterpret(0xBFB999EB43B068FF), // -0x1.999eb43b068ffp-4\n B9 = reinterpret(0x3FB78182F7AFD085), // 0x1.78182f7afd085p-4\n B10 = reinterpret(0xBFB5521375D145CD); // -0x1.5521375d145cdp-4\n\n const\n A0 = reinterpret(0xBFE0000000000001), // -0x1.0000000000001p-1\n A1 = reinterpret(0x3FD555555551305B), // 0x1.555555551305bp-2\n A2 = reinterpret(0xBFCFFFFFFFEB4590), // -0x1.fffffffeb459p-3\n A3 = reinterpret(0x3FC999B324F10111), // 0x1.999b324f10111p-3\n A4 = reinterpret(0xBFC55575E506C89F); // -0x1.55575e506c89fp-3\n\n const\n LO: u64 = 0x3FEE000000000000,\n HI: u64 = 0x3FF1090000000000;\n\n const\n Ln2hi = reinterpret(0x3FE62E42FEFA3800), // 0x1.62e42fefa3800p-1\n Ln2lo = reinterpret(0x3D2EF35793C76730), // 0x1.ef35793c76730p-45\n Ox1p27 = reinterpret(0x41A0000000000000), // 0x1p27\n Ox1p52 = reinterpret(0x4330000000000000); // 0x1p52\n\n var ix = reinterpret(x);\n if (ix - LO < HI - LO) {\n let r = x - 1.0;\n let r2 = r * r;\n let r3 = r2 * r;\n let y =\n r3 * (B1 + r * B2 + r2 * B3 +\n r3 * (B4 + r * B5 + r2 * B6 +\n r3 * (B7 + r * B8 + r2 * B9 + r3 * B10)));\n // Worst-case error is around 0.507 ULP\n let w = r * Ox1p27;\n let rhi = r + w - w;\n let rlo = r - rhi;\n w = rhi * rhi * B0; // B[0] == -0.5\n let hi = r + w;\n let lo = r - hi + w;\n lo += B0 * rlo * (rhi + r);\n return y + lo + hi;\n }\n var top = u32(ix >> 48);\n if (top - 0x0010 >= 0x7FF0 - 0x0010) {\n // x < 0x1p-1022 or inf or nan\n if ((ix << 1) == 0) return -1.0 / (x * x);\n if (ix == reinterpret(Infinity)) return x; // log(inf) == inf\n if ((top & 0x8000) || (top & 0x7FF0) == 0x7FF0) return (x - x) / (x - x);\n // x is subnormal, normalize it\n ix = reinterpret(x * Ox1p52);\n ix -= u64(52) << 52;\n }\n\n // x = 2^k z; where z is in range [OFF,2*OFF) and exact.\n // The range is split into N subintervals.\n // The ith subinterval contains z and c is near its center.\n var tmp = ix - 0x3FE6000000000000;\n var i = ((tmp >> (52 - LOG_TABLE_BITS)) & N_MASK);\n var k = tmp >> 52;\n var iz = ix - (tmp & (u64(0xFFF) << 52));\n\n var invc = load(LOG_DATA_TAB1 + (i << (1 + alignof())), 0 << alignof()); // T[i].invc;\n var logc = load(LOG_DATA_TAB1 + (i << (1 + alignof())), 1 << alignof()); // T[i].logc;\n var z = reinterpret(iz);\n\n // log(x) = log1p(z/c-1) + log(c) + k*Ln2.\n // r ~= z/c - 1, |r| < 1/(2*N)\n // #if __FP_FAST_FMA\n // \t// rounding error: 0x1p-55/N\n // \tr = __builtin_fma(z, invc, -1.0);\n // #else\n // rounding error: 0x1p-55/N + 0x1p-66\n const chi = load(LOG_DATA_TAB2 + (i << (1 + alignof())), 0 << alignof()); // T2[i].chi\n const clo = load(LOG_DATA_TAB2 + (i << (1 + alignof())), 1 << alignof()); // T2[i].clo\n var r = (z - chi - clo) * invc;\n // #endif\n var kd = k;\n\n // hi + lo = r + log(c) + k*Ln2\n var w = kd * Ln2hi + logc;\n var hi = w + r;\n var lo = w - hi + r + kd * Ln2lo;\n\n // log(x) = lo + (log1p(r) - r) + hi\n var r2 = r * r; // rounding error: 0x1p-54/N^2\n // Worst case error if |y| > 0x1p-5:\n // 0.5 + 4.13/N + abs-poly-error*2^57 ULP (+ 0.002 ULP without fma)\n // Worst case error if |y| > 0x1p-4:\n // 0.5 + 2.06/N + abs-poly-error*2^56 ULP (+ 0.001 ULP without fma).\n return lo + r2 * A0 + r * r2 * (A1 + r * A2 + r2 * (A3 + r * A4)) + hi;\n}\n\n//\n// Lookup data for pow. See: https://git.musl-libc.org/cgit/musl/tree/src/math/pow.c\n//\n\n// @ts-ignore: decorator\n@inline const POW_LOG_TABLE_BITS = 7;\n\n/* Algorithm:\n\n x = 2^k z\n log(x) = k ln2 + log(c) + log(z/c)\n log(z/c) = poly(z/c - 1)\n\nwhere z is in [0x1.69555p-1; 0x1.69555p0] which is split into N subintervals\nand z falls into the ith one, then table entries are computed as\n\n tab[i].invc = 1/c\n tab[i].logc = round(0x1p43*log(c))/0x1p43\n tab[i].logctail = (double)(log(c) - logc)\n\nwhere c is chosen near the center of the subinterval such that 1/c has only a\nfew precision bits so z/c - 1 is exactly representible as double:\n\n 1/c = center < 1 ? round(N/center)/N : round(2*N/center)/N/2\n\nNote: |z/c - 1| < 1/N for the chosen c, |log(c) - logc - logctail| < 0x1p-97,\nthe last few bits of logc are rounded away so k*ln2hi + logc has no rounding\nerror and the interval for z is selected such that near x == 1, where log(x)\nis tiny, large cancellation error is avoided in logc + poly(z/c - 1). */\n\n// @ts-ignore: decorator\n@lazy @inline const POW_LOG_DATA_TAB = memory.data([\n // invc ,pad, logc , logctail\n reinterpret(0x3FF6A00000000000), 0, reinterpret(0xBFD62C82F2B9C800), reinterpret(0x3CFAB42428375680),\n reinterpret(0x3FF6800000000000), 0, reinterpret(0xBFD5D1BDBF580800), reinterpret(0xBD1CA508D8E0F720),\n reinterpret(0x3FF6600000000000), 0, reinterpret(0xBFD5767717455800), reinterpret(0xBD2362A4D5B6506D),\n reinterpret(0x3FF6400000000000), 0, reinterpret(0xBFD51AAD872DF800), reinterpret(0xBCE684E49EB067D5),\n reinterpret(0x3FF6200000000000), 0, reinterpret(0xBFD4BE5F95777800), reinterpret(0xBD041B6993293EE0),\n reinterpret(0x3FF6000000000000), 0, reinterpret(0xBFD4618BC21C6000), reinterpret(0x3D13D82F484C84CC),\n reinterpret(0x3FF5E00000000000), 0, reinterpret(0xBFD404308686A800), reinterpret(0x3CDC42F3ED820B3A),\n reinterpret(0x3FF5C00000000000), 0, reinterpret(0xBFD3A64C55694800), reinterpret(0x3D20B1C686519460),\n reinterpret(0x3FF5A00000000000), 0, reinterpret(0xBFD347DD9A988000), reinterpret(0x3D25594DD4C58092),\n reinterpret(0x3FF5800000000000), 0, reinterpret(0xBFD2E8E2BAE12000), reinterpret(0x3D267B1E99B72BD8),\n reinterpret(0x3FF5600000000000), 0, reinterpret(0xBFD2895A13DE8800), reinterpret(0x3D15CA14B6CFB03F),\n reinterpret(0x3FF5600000000000), 0, reinterpret(0xBFD2895A13DE8800), reinterpret(0x3D15CA14B6CFB03F),\n reinterpret(0x3FF5400000000000), 0, reinterpret(0xBFD22941FBCF7800), reinterpret(0xBD165A242853DA76),\n reinterpret(0x3FF5200000000000), 0, reinterpret(0xBFD1C898C1699800), reinterpret(0xBD1FAFBC68E75404),\n reinterpret(0x3FF5000000000000), 0, reinterpret(0xBFD1675CABABA800), reinterpret(0x3D1F1FC63382A8F0),\n reinterpret(0x3FF4E00000000000), 0, reinterpret(0xBFD1058BF9AE4800), reinterpret(0xBD26A8C4FD055A66),\n reinterpret(0x3FF4C00000000000), 0, reinterpret(0xBFD0A324E2739000), reinterpret(0xBD0C6BEE7EF4030E),\n reinterpret(0x3FF4A00000000000), 0, reinterpret(0xBFD0402594B4D000), reinterpret(0xBCF036B89EF42D7F),\n reinterpret(0x3FF4A00000000000), 0, reinterpret(0xBFD0402594B4D000), reinterpret(0xBCF036B89EF42D7F),\n reinterpret(0x3FF4800000000000), 0, reinterpret(0xBFCFB9186D5E4000), reinterpret(0x3D0D572AAB993C87),\n reinterpret(0x3FF4600000000000), 0, reinterpret(0xBFCEF0ADCBDC6000), reinterpret(0x3D2B26B79C86AF24),\n reinterpret(0x3FF4400000000000), 0, reinterpret(0xBFCE27076E2AF000), reinterpret(0xBD172F4F543FFF10),\n reinterpret(0x3FF4200000000000), 0, reinterpret(0xBFCD5C216B4FC000), reinterpret(0x3D21BA91BBCA681B),\n reinterpret(0x3FF4000000000000), 0, reinterpret(0xBFCC8FF7C79AA000), reinterpret(0x3D27794F689F8434),\n reinterpret(0x3FF4000000000000), 0, reinterpret(0xBFCC8FF7C79AA000), reinterpret(0x3D27794F689F8434),\n reinterpret(0x3FF3E00000000000), 0, reinterpret(0xBFCBC286742D9000), reinterpret(0x3D194EB0318BB78F),\n reinterpret(0x3FF3C00000000000), 0, reinterpret(0xBFCAF3C94E80C000), reinterpret(0x3CBA4E633FCD9066),\n reinterpret(0x3FF3A00000000000), 0, reinterpret(0xBFCA23BC1FE2B000), reinterpret(0xBD258C64DC46C1EA),\n reinterpret(0x3FF3A00000000000), 0, reinterpret(0xBFCA23BC1FE2B000), reinterpret(0xBD258C64DC46C1EA),\n reinterpret(0x3FF3800000000000), 0, reinterpret(0xBFC9525A9CF45000), reinterpret(0xBD2AD1D904C1D4E3),\n reinterpret(0x3FF3600000000000), 0, reinterpret(0xBFC87FA06520D000), reinterpret(0x3D2BBDBF7FDBFA09),\n reinterpret(0x3FF3400000000000), 0, reinterpret(0xBFC7AB890210E000), reinterpret(0x3D2BDB9072534A58),\n reinterpret(0x3FF3400000000000), 0, reinterpret(0xBFC7AB890210E000), reinterpret(0x3D2BDB9072534A58),\n reinterpret(0x3FF3200000000000), 0, reinterpret(0xBFC6D60FE719D000), reinterpret(0xBD10E46AA3B2E266),\n reinterpret(0x3FF3000000000000), 0, reinterpret(0xBFC5FF3070A79000), reinterpret(0xBD1E9E439F105039),\n reinterpret(0x3FF3000000000000), 0, reinterpret(0xBFC5FF3070A79000), reinterpret(0xBD1E9E439F105039),\n reinterpret(0x3FF2E00000000000), 0, reinterpret(0xBFC526E5E3A1B000), reinterpret(0xBD20DE8B90075B8F),\n reinterpret(0x3FF2C00000000000), 0, reinterpret(0xBFC44D2B6CCB8000), reinterpret(0x3D170CC16135783C),\n reinterpret(0x3FF2C00000000000), 0, reinterpret(0xBFC44D2B6CCB8000), reinterpret(0x3D170CC16135783C),\n reinterpret(0x3FF2A00000000000), 0, reinterpret(0xBFC371FC201E9000), reinterpret(0x3CF178864D27543A),\n reinterpret(0x3FF2800000000000), 0, reinterpret(0xBFC29552F81FF000), reinterpret(0xBD248D301771C408),\n reinterpret(0x3FF2600000000000), 0, reinterpret(0xBFC1B72AD52F6000), reinterpret(0xBD2E80A41811A396),\n reinterpret(0x3FF2600000000000), 0, reinterpret(0xBFC1B72AD52F6000), reinterpret(0xBD2E80A41811A396),\n reinterpret(0x3FF2400000000000), 0, reinterpret(0xBFC0D77E7CD09000), reinterpret(0x3D0A699688E85BF4),\n reinterpret(0x3FF2400000000000), 0, reinterpret(0xBFC0D77E7CD09000), reinterpret(0x3D0A699688E85BF4),\n reinterpret(0x3FF2200000000000), 0, reinterpret(0xBFBFEC9131DBE000), reinterpret(0xBD2575545CA333F2),\n reinterpret(0x3FF2000000000000), 0, reinterpret(0xBFBE27076E2B0000), reinterpret(0x3D2A342C2AF0003C),\n reinterpret(0x3FF2000000000000), 0, reinterpret(0xBFBE27076E2B0000), reinterpret(0x3D2A342C2AF0003C),\n reinterpret(0x3FF1E00000000000), 0, reinterpret(0xBFBC5E548F5BC000), reinterpret(0xBD1D0C57585FBE06),\n reinterpret(0x3FF1C00000000000), 0, reinterpret(0xBFBA926D3A4AE000), reinterpret(0x3D253935E85BAAC8),\n reinterpret(0x3FF1C00000000000), 0, reinterpret(0xBFBA926D3A4AE000), reinterpret(0x3D253935E85BAAC8),\n reinterpret(0x3FF1A00000000000), 0, reinterpret(0xBFB8C345D631A000), reinterpret(0x3D137C294D2F5668),\n reinterpret(0x3FF1A00000000000), 0, reinterpret(0xBFB8C345D631A000), reinterpret(0x3D137C294D2F5668),\n reinterpret(0x3FF1800000000000), 0, reinterpret(0xBFB6F0D28AE56000), reinterpret(0xBD269737C93373DA),\n reinterpret(0x3FF1600000000000), 0, reinterpret(0xBFB51B073F062000), reinterpret(0x3D1F025B61C65E57),\n reinterpret(0x3FF1600000000000), 0, reinterpret(0xBFB51B073F062000), reinterpret(0x3D1F025B61C65E57),\n reinterpret(0x3FF1400000000000), 0, reinterpret(0xBFB341D7961BE000), reinterpret(0x3D2C5EDACCF913DF),\n reinterpret(0x3FF1400000000000), 0, reinterpret(0xBFB341D7961BE000), reinterpret(0x3D2C5EDACCF913DF),\n reinterpret(0x3FF1200000000000), 0, reinterpret(0xBFB16536EEA38000), reinterpret(0x3D147C5E768FA309),\n reinterpret(0x3FF1000000000000), 0, reinterpret(0xBFAF0A30C0118000), reinterpret(0x3D2D599E83368E91),\n reinterpret(0x3FF1000000000000), 0, reinterpret(0xBFAF0A30C0118000), reinterpret(0x3D2D599E83368E91),\n reinterpret(0x3FF0E00000000000), 0, reinterpret(0xBFAB42DD71198000), reinterpret(0x3D1C827AE5D6704C),\n reinterpret(0x3FF0E00000000000), 0, reinterpret(0xBFAB42DD71198000), reinterpret(0x3D1C827AE5D6704C),\n reinterpret(0x3FF0C00000000000), 0, reinterpret(0xBFA77458F632C000), reinterpret(0xBD2CFC4634F2A1EE),\n reinterpret(0x3FF0C00000000000), 0, reinterpret(0xBFA77458F632C000), reinterpret(0xBD2CFC4634F2A1EE),\n reinterpret(0x3FF0A00000000000), 0, reinterpret(0xBFA39E87B9FEC000), reinterpret(0x3CF502B7F526FEAA),\n reinterpret(0x3FF0A00000000000), 0, reinterpret(0xBFA39E87B9FEC000), reinterpret(0x3CF502B7F526FEAA),\n reinterpret(0x3FF0800000000000), 0, reinterpret(0xBF9F829B0E780000), reinterpret(0xBD2980267C7E09E4),\n reinterpret(0x3FF0800000000000), 0, reinterpret(0xBF9F829B0E780000), reinterpret(0xBD2980267C7E09E4),\n reinterpret(0x3FF0600000000000), 0, reinterpret(0xBF97B91B07D58000), reinterpret(0xBD288D5493FAA639),\n reinterpret(0x3FF0400000000000), 0, reinterpret(0xBF8FC0A8B0FC0000), reinterpret(0xBCDF1E7CF6D3A69C),\n reinterpret(0x3FF0400000000000), 0, reinterpret(0xBF8FC0A8B0FC0000), reinterpret(0xBCDF1E7CF6D3A69C),\n reinterpret(0x3FF0200000000000), 0, reinterpret(0xBF7FE02A6B100000), reinterpret(0xBD19E23F0DDA40E4),\n reinterpret(0x3FF0200000000000), 0, reinterpret(0xBF7FE02A6B100000), reinterpret(0xBD19E23F0DDA40E4),\n reinterpret(0x3FF0000000000000), 0, 0, 0,\n reinterpret(0x3FF0000000000000), 0, 0, 0,\n reinterpret(0x3FEFC00000000000), 0, reinterpret(0x3F80101575890000), reinterpret(0xBD10C76B999D2BE8),\n reinterpret(0x3FEF800000000000), 0, reinterpret(0x3F90205658938000), reinterpret(0xBD23DC5B06E2F7D2),\n reinterpret(0x3FEF400000000000), 0, reinterpret(0x3F98492528C90000), reinterpret(0xBD2AA0BA325A0C34),\n reinterpret(0x3FEF000000000000), 0, reinterpret(0x3FA0415D89E74000), reinterpret(0x3D0111C05CF1D753),\n reinterpret(0x3FEEC00000000000), 0, reinterpret(0x3FA466AED42E0000), reinterpret(0xBD2C167375BDFD28),\n reinterpret(0x3FEE800000000000), 0, reinterpret(0x3FA894AA149FC000), reinterpret(0xBD197995D05A267D),\n reinterpret(0x3FEE400000000000), 0, reinterpret(0x3FACCB73CDDDC000), reinterpret(0xBD1A68F247D82807),\n reinterpret(0x3FEE200000000000), 0, reinterpret(0x3FAEEA31C006C000), reinterpret(0xBD0E113E4FC93B7B),\n reinterpret(0x3FEDE00000000000), 0, reinterpret(0x3FB1973BD1466000), reinterpret(0xBD25325D560D9E9B),\n reinterpret(0x3FEDA00000000000), 0, reinterpret(0x3FB3BDF5A7D1E000), reinterpret(0x3D2CC85EA5DB4ED7),\n reinterpret(0x3FED600000000000), 0, reinterpret(0x3FB5E95A4D97A000), reinterpret(0xBD2C69063C5D1D1E),\n reinterpret(0x3FED400000000000), 0, reinterpret(0x3FB700D30AEAC000), reinterpret(0x3CEC1E8DA99DED32),\n reinterpret(0x3FED000000000000), 0, reinterpret(0x3FB9335E5D594000), reinterpret(0x3D23115C3ABD47DA),\n reinterpret(0x3FECC00000000000), 0, reinterpret(0x3FBB6AC88DAD6000), reinterpret(0xBD1390802BF768E5),\n reinterpret(0x3FECA00000000000), 0, reinterpret(0x3FBC885801BC4000), reinterpret(0x3D2646D1C65AACD3),\n reinterpret(0x3FEC600000000000), 0, reinterpret(0x3FBEC739830A2000), reinterpret(0xBD2DC068AFE645E0),\n reinterpret(0x3FEC400000000000), 0, reinterpret(0x3FBFE89139DBE000), reinterpret(0xBD2534D64FA10AFD),\n reinterpret(0x3FEC000000000000), 0, reinterpret(0x3FC1178E8227E000), reinterpret(0x3D21EF78CE2D07F2),\n reinterpret(0x3FEBE00000000000), 0, reinterpret(0x3FC1AA2B7E23F000), reinterpret(0x3D2CA78E44389934),\n reinterpret(0x3FEBA00000000000), 0, reinterpret(0x3FC2D1610C868000), reinterpret(0x3D039D6CCB81B4A1),\n reinterpret(0x3FEB800000000000), 0, reinterpret(0x3FC365FCB0159000), reinterpret(0x3CC62FA8234B7289),\n reinterpret(0x3FEB400000000000), 0, reinterpret(0x3FC4913D8333B000), reinterpret(0x3D25837954FDB678),\n reinterpret(0x3FEB200000000000), 0, reinterpret(0x3FC527E5E4A1B000), reinterpret(0x3D2633E8E5697DC7),\n reinterpret(0x3FEAE00000000000), 0, reinterpret(0x3FC6574EBE8C1000), reinterpret(0x3D19CF8B2C3C2E78),\n reinterpret(0x3FEAC00000000000), 0, reinterpret(0x3FC6F0128B757000), reinterpret(0xBD25118DE59C21E1),\n reinterpret(0x3FEAA00000000000), 0, reinterpret(0x3FC7898D85445000), reinterpret(0xBD1C661070914305),\n reinterpret(0x3FEA600000000000), 0, reinterpret(0x3FC8BEAFEB390000), reinterpret(0xBD073D54AAE92CD1),\n reinterpret(0x3FEA400000000000), 0, reinterpret(0x3FC95A5ADCF70000), reinterpret(0x3D07F22858A0FF6F),\n reinterpret(0x3FEA000000000000), 0, reinterpret(0x3FCA93ED3C8AE000), reinterpret(0xBD28724350562169),\n reinterpret(0x3FE9E00000000000), 0, reinterpret(0x3FCB31D8575BD000), reinterpret(0xBD0C358D4EACE1AA),\n reinterpret(0x3FE9C00000000000), 0, reinterpret(0x3FCBD087383BE000), reinterpret(0xBD2D4BC4595412B6),\n reinterpret(0x3FE9A00000000000), 0, reinterpret(0x3FCC6FFBC6F01000), reinterpret(0xBCF1EC72C5962BD2),\n reinterpret(0x3FE9600000000000), 0, reinterpret(0x3FCDB13DB0D49000), reinterpret(0xBD2AFF2AF715B035),\n reinterpret(0x3FE9400000000000), 0, reinterpret(0x3FCE530EFFE71000), reinterpret(0x3CC212276041F430),\n reinterpret(0x3FE9200000000000), 0, reinterpret(0x3FCEF5ADE4DD0000), reinterpret(0xBCCA211565BB8E11),\n reinterpret(0x3FE9000000000000), 0, reinterpret(0x3FCF991C6CB3B000), reinterpret(0x3D1BCBECCA0CDF30),\n reinterpret(0x3FE8C00000000000), 0, reinterpret(0x3FD07138604D5800), reinterpret(0x3CF89CDB16ED4E91),\n reinterpret(0x3FE8A00000000000), 0, reinterpret(0x3FD0C42D67616000), reinterpret(0x3D27188B163CEAE9),\n reinterpret(0x3FE8800000000000), 0, reinterpret(0x3FD1178E8227E800), reinterpret(0xBD2C210E63A5F01C),\n reinterpret(0x3FE8600000000000), 0, reinterpret(0x3FD16B5CCBACF800), reinterpret(0x3D2B9ACDF7A51681),\n reinterpret(0x3FE8400000000000), 0, reinterpret(0x3FD1BF99635A6800), reinterpret(0x3D2CA6ED5147BDB7),\n reinterpret(0x3FE8200000000000), 0, reinterpret(0x3FD214456D0EB800), reinterpret(0x3D0A87DEBA46BAEA),\n reinterpret(0x3FE7E00000000000), 0, reinterpret(0x3FD2BEF07CDC9000), reinterpret(0x3D2A9CFA4A5004F4),\n reinterpret(0x3FE7C00000000000), 0, reinterpret(0x3FD314F1E1D36000), reinterpret(0xBD28E27AD3213CB8),\n reinterpret(0x3FE7A00000000000), 0, reinterpret(0x3FD36B6776BE1000), reinterpret(0x3D116ECDB0F177C8),\n reinterpret(0x3FE7800000000000), 0, reinterpret(0x3FD3C25277333000), reinterpret(0x3D183B54B606BD5C),\n reinterpret(0x3FE7600000000000), 0, reinterpret(0x3FD419B423D5E800), reinterpret(0x3D08E436EC90E09D),\n reinterpret(0x3FE7400000000000), 0, reinterpret(0x3FD4718DC271C800), reinterpret(0xBD2F27CE0967D675),\n reinterpret(0x3FE7200000000000), 0, reinterpret(0x3FD4C9E09E173000), reinterpret(0xBD2E20891B0AD8A4),\n reinterpret(0x3FE7000000000000), 0, reinterpret(0x3FD522AE0738A000), reinterpret(0x3D2EBE708164C759),\n reinterpret(0x3FE6E00000000000), 0, reinterpret(0x3FD57BF753C8D000), reinterpret(0x3D1FADEDEE5D40EF),\n reinterpret(0x3FE6C00000000000), 0, reinterpret(0x3FD5D5BDDF596000), reinterpret(0xBD0A0B2A08A465DC)\n]);\n\n// Returns 0 if not int, 1 if odd int, 2 if even int. The argument is\n// the bit representation of a non-zero finite floating-point value.\n// @ts-ignore: decorator\n@inline\nfunction checkint(iy: u64): i32 {\n var e = iy >> 52 & 0x7FF;\n if (e < 0x3FF ) return 0;\n if (e > 0x3FF + 52) return 2;\n e = u64(1) << (0x3FF + 52 - e);\n if (iy & (e - 1)) return 0;\n if (iy & e ) return 1;\n return 2;\n}\n\n// @ts-ignore: decorator\n@inline\nfunction xflow(sign: u32, y: f64): f64 {\n return select(-y, y, sign) * y;\n}\n\n// @ts-ignore: decorator\n@inline\nfunction uflow(sign: u32): f64 {\n return xflow(sign, reinterpret(0x1000000000000000)); // 0x1p-767\n}\n\n// @ts-ignore: decorator\n@inline\nfunction oflow(sign: u32): f64 {\n return xflow(sign, reinterpret(0x7000000000000000)); // 0x1p769\n}\n\n// Returns 1 if input is the bit representation of 0, infinity or nan.\n// @ts-ignore: decorator\n@inline\nfunction zeroinfnan(u: u64): bool {\n return (u << 1) - 1 >= 0xFFE0000000000000 - 1;\n}\n\n// @ts-ignore: decorator\n@lazy var log_tail: f64 = 0;\n\n// Compute y+TAIL = log(x) where the rounded result is y and TAIL has about\n// additional 15 bits precision. IX is the bit representation of x, but\n// normalized in the subnormal range using the sign bit for the exponent.\n// @ts-ignore: decorator\n@inline\nfunction log_inline(ix: u64): f64 {\n const N = 1 << POW_LOG_TABLE_BITS;\n const N_MASK = N - 1;\n\n const\n Ln2hi = reinterpret(0x3FE62E42FEFA3800),\n Ln2lo = reinterpret(0x3D2EF35793C76730);\n\n const\n A0 = reinterpret(0xBFE0000000000000),\n A1 = reinterpret(0xBFE5555555555560),\n A2 = reinterpret(0x3FE0000000000006),\n A3 = reinterpret(0x3FE999999959554E),\n A4 = reinterpret(0xBFE555555529A47A),\n A5 = reinterpret(0xBFF2495B9B4845E9),\n A6 = reinterpret(0x3FF0002B8B263FC3);\n\n // x = 2^k z; where z is in range [OFF,2*OFF) and exact.\n // The range is split into N subintervals.\n // The ith subinterval contains z and c is near its center.\n var tmp = ix - 0x3fE6955500000000;\n var i = usize((tmp >> (52 - POW_LOG_TABLE_BITS)) & N_MASK);\n var k = tmp >> 52;\n var iz = ix - (tmp & u64(0xFFF) << 52);\n var z = reinterpret(iz);\n var kd = k;\n\n // log(x) = k*Ln2 + log(c) + log1p(z/c-1).\n var invc = load(POW_LOG_DATA_TAB + (i << (2 + alignof())), 0 << alignof()); // tab[i].invc\n var logc = load(POW_LOG_DATA_TAB + (i << (2 + alignof())), 2 << alignof()); // tab[i].logc\n var logctail = load(POW_LOG_DATA_TAB + (i << (2 + alignof())), 3 << alignof()); // tab[i].logctail\n\n // Note: 1/c is j/N or j/N/2 where j is an integer in [N,2N) and\n // |z/c - 1| < 1/N, so r = z/c - 1 is exactly representible.\n // Split z such that rhi, rlo and rhi*rhi are exact and |rlo| <= |r|.\n var zhi = reinterpret((iz + u64(0x80000000)) & 0xFFFFFFFF00000000);\n var zlo = z - zhi;\n var rhi = zhi * invc - 1.0;\n var rlo = zlo * invc;\n var r = rhi + rlo;\n\n // k * Ln2 + log(c) + r.\n var t1 = kd * Ln2hi + logc;\n var t2 = t1 + r;\n var lo1 = kd * Ln2lo + logctail;\n var lo2 = t1 - t2 + r;\n\n // Evaluation is optimized assuming superscalar pipelined execution.\n var ar = A0 * r; // A[0] = -0.5\n var ar2 = r * ar;\n var ar3 = r * ar2;\n // k * Ln2 + log(c) + r + A[0] * r * r.\n var arhi = A0 * rhi;\n var arhi2 = rhi * arhi;\n var hi = t2 + arhi2;\n var lo3 = rlo * (ar + arhi);\n var lo4 = t2 - hi + arhi2;\n\n // p = log1p(r) - r - A[0] * r * r.\n var p = ar3 * (A1 + r * A2 + ar2 * (A3 + r * A4 + ar2 * (A5 + r * A6)));\n var lo = lo1 + lo2 + lo3 + lo4 + p;\n var y = hi + lo;\n log_tail = hi - y + lo;\n\n return y;\n}\n\n// @ts-ignore: decorator\n@inline const SIGN_BIAS = 0x800 << EXP_TABLE_BITS;\n\n// Computes sign*exp(x+xtail) where |xtail| < 2^-8/N and |xtail| <= |x|.\n// The sign_bias argument is SIGN_BIAS or 0 and sets the sign to -1 or 1.\n// @ts-ignore: decorator\n@inline\nfunction exp_inline(x: f64, xtail: f64, sign_bias: u32): f64 {\n const N = 1 << EXP_TABLE_BITS;\n const N_MASK = N - 1;\n\n const\n InvLn2N = reinterpret(0x3FF71547652B82FE) * N, // 0x1.71547652b82fep0\n NegLn2hiN = reinterpret(0xBF762E42FEFA0000), // -0x1.62e42fefa0000p-8\n NegLn2loN = reinterpret(0xBD0CF79ABC9E3B3A), // -0x1.cf79abc9e3b3ap-47\n shift = reinterpret(0x4338000000000000); // 0x1.8p52\n\n const\n C2 = reinterpret(0x3FDFFFFFFFFFFDBD), // __exp_data.poly[0] (0x1.ffffffffffdbdp-2)\n C3 = reinterpret(0x3FC555555555543C), // __exp_data.poly[1] (0x1.555555555543cp-3)\n C4 = reinterpret(0x3FA55555CF172B91), // __exp_data.poly[2] (0x1.55555cf172b91p-5)\n C5 = reinterpret(0x3F81111167A4D017); // __exp_data.poly[3] (0x1.1111167a4d017p-7)\n\n var abstop: u32;\n var ki: u64, top: u64, sbits: u64;\n var idx: usize;\n // double_t for better performance on targets with FLT_EVAL_METHOD==2.\n var kd: f64, z: f64, r: f64, r2: f64, scale: f64, tail: f64, tmp: f64;\n\n var ux = reinterpret(x);\n abstop = u32(ux >> 52) & 0x7FF;\n if (abstop - 0x3C9 >= 0x03F) {\n if (abstop - 0x3C9 >= 0x80000000) {\n // Avoid spurious underflow for tiny x.\n // Note: 0 is common input.\n return select(-1.0, 1.0, sign_bias);\n }\n if (abstop >= 0x409) { // top12(1024.0)\n // Note: inf and nan are already handled.\n return ux < 0\n ? uflow(sign_bias)\n : oflow(sign_bias);\n }\n // Large x is special cased below.\n abstop = 0;\n }\n\n // exp(x) = 2^(k/N) * exp(r), with exp(r) in [2^(-1/2N),2^(1/2N)].\n // x = ln2/N*k + r, with int k and r in [-ln2/2N, ln2/2N].\n z = InvLn2N * x;\n\n // #if TOINT_INTRINSICS\n // kd = roundtoint(z);\n // ki = converttoint(z);\n // #elif EXP_USE_TOINT_NARROW\n // // z - kd is in [-0.5-2^-16, 0.5] in all rounding modes.\n // kd = eval_as_double(z + shift);\n // ki = asuint64(kd) >> 16;\n // kd = (double_t)(int32_t)ki;\n // #else\n // z - kd is in [-1, 1] in non-nearest rounding modes\n kd = z + shift;\n ki = reinterpret(kd);\n kd -= shift;\n // #endif\n r = x + kd * NegLn2hiN + kd * NegLn2loN;\n // The code assumes 2^-200 < |xtail| < 2^-8/N\n r += xtail;\n // 2^(k/N) ~= scale * (1 + tail)\n idx = usize((ki & N_MASK) << 1);\n top = (ki + sign_bias) << (52 - EXP_TABLE_BITS);\n\n tail = reinterpret(load(EXP_DATA_TAB + (idx << alignof())));\n // This is only a valid scale when -1023*N < k < 1024*N\n sbits = load(EXP_DATA_TAB + (idx << alignof()), 1 << alignof()) + top;\n // exp(x) = 2^(k/N) * exp(r) ~= scale + scale * (tail + exp(r) - 1).\n // Evaluation is optimized assuming superscalar pipelined execution.\n r2 = r * r;\n // Without fma the worst case error is 0.25/N ulp larger.\n // Worst case error is less than 0.5+1.11/N+(abs poly error * 2^53) ulp\n tmp = tail + r + r2 * (C2 + r * C3) + r2 * r2 * (C4 + r * C5);\n if (abstop == 0) return specialcase(tmp, sbits, ki);\n scale = reinterpret(sbits);\n // Note: tmp == 0 or |tmp| > 2^-200 and scale > 2^-739, so there\n // is no spurious underflow here even without fma.\n return scale + scale * tmp;\n}\n\n// @ts-ignore: decorator\n@inline\nexport function pow_lut(x: f64, y: f64): f64 {\n const Ox1p52 = reinterpret(0x4330000000000000); // 0x1p52\n\n var sign_bias: u32 = 0;\n var ix = reinterpret(x);\n var iy = reinterpret(y);\n var topx = ix >> 52;\n var topy = iy >> 52;\n\n if (topx - 0x001 >= 0x7FF - 0x001 || (topy & 0x7FF) - 0x3BE >= 0x43e - 0x3BE) {\n // Note: if |y| > 1075 * ln2 * 2^53 ~= 0x1.749p62 then pow(x,y) = inf/0\n // and if |y| < 2^-54 / 1075 ~= 0x1.e7b6p-65 then pow(x,y) = +-1.\n // Special cases: (x < 0x1p-126 or inf or nan) or\n // (|y| < 0x1p-65 or |y| >= 0x1p63 or nan).\n if (zeroinfnan(iy)) {\n if ((iy << 1) == 0) return 1.0;\n if (ix == 0x3FF0000000000000) return NaN; // original: 1.0\n if ((ix << 1) > 0xFFE0000000000000 || (iy << 1) > 0xFFE0000000000000) return x + y;\n if ((ix << 1) == 0x7FE0000000000000) return NaN; // original: 1.0\n if (((ix << 1) < 0x7FE0000000000000) == !(iy >> 63)) return 0; // |x|<1 && y==inf or |x|>1 && y==-inf.\n return y * y;\n }\n if (zeroinfnan(ix)) {\n let x2 = x * x;\n if (i32(ix >> 63) && checkint(iy) == 1) x2 = -x2;\n return iy < 0 ? 1 / x2 : x2;\n }\n // Here x and y are non-zero finite\n if (ix < 0) {\n // Finite x < 0\n let yint = checkint(iy);\n if (yint == 0) return (x - x) / (x - x);\n if (yint == 1) sign_bias = SIGN_BIAS;\n ix &= 0x7FFFFFFFFFFFFFFF;\n topx &= 0x7FF;\n }\n if ((topy & 0x7FF) - 0x3BE >= 0x43E - 0x3BE) {\n // Note: sign_bias == 0 here because y is not odd.\n if (ix == 0x3FF0000000000000) return 1;\n if ((topy & 0x7FF) < 0x3BE) return 1; // |y| < 2^-65, x^y ~= 1 + y*log(x).\n return (ix > 0x3FF0000000000000) == (topy < 0x800) ? Infinity : 0;\n }\n if (topx == 0) {\n // Normalize subnormal x so exponent becomes negative.\n ix = reinterpret(x * Ox1p52);\n ix &= 0x7FFFFFFFFFFFFFFF;\n ix -= u64(52) << 52;\n }\n }\n\n var hi = log_inline(ix);\n var lo = log_tail;\n var ehi: f64, elo: f64;\n // #if __FP_FAST_FMA\n // ehi = y * hi;\n // elo = y * lo + __builtin_fma(y, hi, -ehi);\n // #else\n var yhi = reinterpret(iy & 0xFFFFFFFFF8000000);\n var ylo = y - yhi;\n var lhi = reinterpret(reinterpret(hi) & 0xFFFFFFFFF8000000);\n var llo = hi - lhi + lo;\n ehi = yhi * lhi;\n elo = ylo * lhi + y * llo; // |elo| < |ehi| * 2^-25.\n // #endif\n return exp_inline(ehi, elo, sign_bias);\n}\n","/// \n\nimport { idof } from \"../builtins\";\nimport { CharCode } from \"./string\";\n\n// @ts-ignore: decorator\n@inline\nexport const MAX_DOUBLE_LENGTH = 28;\n\n// @ts-ignore: decorator\n@lazy @inline const POWERS10 = memory.data([\n 1,\n 10,\n 100,\n 1000,\n 10000,\n 100000,\n 1000000,\n 10000000,\n 100000000,\n 1000000000\n]);\n\n/*\n Lookup table for pairwise char codes in range [0-99]\n\n \"00\", \"01\", \"02\", \"03\", \"04\", \"05\", \"06\", \"07\", \"08\", \"09\",\n \"10\", \"11\", \"12\", \"13\", \"14\", \"15\", \"16\", \"17\", \"18\", \"19\",\n \"20\", \"21\", \"22\", \"23\", \"24\", \"25\", \"26\", \"27\", \"28\", \"29\",\n \"30\", \"31\", \"32\", \"33\", \"34\", \"35\", \"36\", \"37\", \"38\", \"39\",\n \"40\", \"41\", \"42\", \"43\", \"44\", \"45\", \"46\", \"47\", \"48\", \"49\",\n \"50\", \"51\", \"52\", \"53\", \"54\", \"55\", \"56\", \"57\", \"58\", \"59\",\n \"60\", \"61\", \"62\", \"63\", \"64\", \"65\", \"66\", \"67\", \"68\", \"69\",\n \"70\", \"71\", \"72\", \"73\", \"74\", \"75\", \"76\", \"77\", \"78\", \"79\",\n \"80\", \"81\", \"82\", \"83\", \"84\", \"85\", \"86\", \"87\", \"88\", \"89\",\n \"90\", \"91\", \"92\", \"93\", \"94\", \"95\", \"96\", \"97\", \"98\", \"99\"\n*/\n// @ts-ignore: decorator\n@lazy @inline const DIGITS = memory.data([\n 0x00300030, 0x00310030, 0x00320030, 0x00330030, 0x00340030,\n 0x00350030, 0x00360030, 0x00370030, 0x00380030, 0x00390030,\n 0x00300031, 0x00310031, 0x00320031, 0x00330031, 0x00340031,\n 0x00350031, 0x00360031, 0x00370031, 0x00380031, 0x00390031,\n 0x00300032, 0x00310032, 0x00320032, 0x00330032, 0x00340032,\n 0x00350032, 0x00360032, 0x00370032, 0x00380032, 0x00390032,\n 0x00300033, 0x00310033, 0x00320033, 0x00330033, 0x00340033,\n 0x00350033, 0x00360033, 0x00370033, 0x00380033, 0x00390033,\n 0x00300034, 0x00310034, 0x00320034, 0x00330034, 0x00340034,\n 0x00350034, 0x00360034, 0x00370034, 0x00380034, 0x00390034,\n 0x00300035, 0x00310035, 0x00320035, 0x00330035, 0x00340035,\n 0x00350035, 0x00360035, 0x00370035, 0x00380035, 0x00390035,\n 0x00300036, 0x00310036, 0x00320036, 0x00330036, 0x00340036,\n 0x00350036, 0x00360036, 0x00370036, 0x00380036, 0x00390036,\n 0x00300037, 0x00310037, 0x00320037, 0x00330037, 0x00340037,\n 0x00350037, 0x00360037, 0x00370037, 0x00380037, 0x00390037,\n 0x00300038, 0x00310038, 0x00320038, 0x00330038, 0x00340038,\n 0x00350038, 0x00360038, 0x00370038, 0x00380038, 0x00390038,\n 0x00300039, 0x00310039, 0x00320039, 0x00330039, 0x00340039,\n 0x00350039, 0x00360039, 0x00370039, 0x00380039, 0x00390039\n]);\n\n// Lookup table for pairwise char codes in range [0x00-0xFF]\n// @ts-ignore: decorator\n@lazy @inline const HEX_DIGITS =\n\"000102030405060708090a0b0c0d0e0f\\\n101112131415161718191a1b1c1d1e1f\\\n202122232425262728292a2b2c2d2e2f\\\n303132333435363738393a3b3c3d3e3f\\\n404142434445464748494a4b4c4d4e4f\\\n505152535455565758595a5b5c5d5e5f\\\n606162636465666768696a6b6c6d6e6f\\\n707172737475767778797a7b7c7d7e7f\\\n808182838485868788898a8b8c8d8e8f\\\n909192939495969798999a9b9c9d9e9f\\\na0a1a2a3a4a5a6a7a8a9aaabacadaeaf\\\nb0b1b2b3b4b5b6b7b8b9babbbcbdbebf\\\nc0c1c2c3c4c5c6c7c8c9cacbcccdcecf\\\nd0d1d2d3d4d5d6d7d8d9dadbdcdddedf\\\ne0e1e2e3e4e5e6e7e8e9eaebecedeeef\\\nf0f1f2f3f4f5f6f7f8f9fafbfcfdfeff\";\n\n// @ts-ignore: decorator\n@lazy @inline const ANY_DIGITS = \"0123456789abcdefghijklmnopqrstuvwxyz\";\n\n// @ts-ignore: decorator\n@lazy @inline const EXP_POWERS = memory.data([/* eslint-disable indent */\n -1220, -1193, -1166, -1140, -1113, -1087, -1060, -1034, -1007, -980,\n -954, -927, -901, -874, -847, -821, -794, -768, -741, -715,\n -688, -661, -635, -608, -582, -555, -529, -502, -475, -449,\n -422, -396, -369, -343, -316, -289, -263, -236, -210, -183,\n -157, -130, -103, -77, -50, -24, 3, 30, 56, 83,\n 109, 136, 162, 189, 216, 242, 269, 295, 322, 348,\n 375, 402, 428, 455, 481, 508, 534, 561, 588, 614,\n 641, 667, 694, 720, 747, 774, 800, 827, 853, 880,\n 907, 933, 960, 986, 1013, 1039, 1066\n/* eslint-enable indent */]);\n\n// 1e-348, 1e-340, ..., 1e340\n// @ts-ignore: decorator\n@lazy @inline const FRC_POWERS = memory.data([\n 0xFA8FD5A0081C0288, 0xBAAEE17FA23EBF76, 0x8B16FB203055AC76, 0xCF42894A5DCE35EA,\n 0x9A6BB0AA55653B2D, 0xE61ACF033D1A45DF, 0xAB70FE17C79AC6CA, 0xFF77B1FCBEBCDC4F,\n 0xBE5691EF416BD60C, 0x8DD01FAD907FFC3C, 0xD3515C2831559A83, 0x9D71AC8FADA6C9B5,\n 0xEA9C227723EE8BCB, 0xAECC49914078536D, 0x823C12795DB6CE57, 0xC21094364DFB5637,\n 0x9096EA6F3848984F, 0xD77485CB25823AC7, 0xA086CFCD97BF97F4, 0xEF340A98172AACE5,\n 0xB23867FB2A35B28E, 0x84C8D4DFD2C63F3B, 0xC5DD44271AD3CDBA, 0x936B9FCEBB25C996,\n 0xDBAC6C247D62A584, 0xA3AB66580D5FDAF6, 0xF3E2F893DEC3F126, 0xB5B5ADA8AAFF80B8,\n 0x87625F056C7C4A8B, 0xC9BCFF6034C13053, 0x964E858C91BA2655, 0xDFF9772470297EBD,\n 0xA6DFBD9FB8E5B88F, 0xF8A95FCF88747D94, 0xB94470938FA89BCF, 0x8A08F0F8BF0F156B,\n 0xCDB02555653131B6, 0x993FE2C6D07B7FAC, 0xE45C10C42A2B3B06, 0xAA242499697392D3,\n 0xFD87B5F28300CA0E, 0xBCE5086492111AEB, 0x8CBCCC096F5088CC, 0xD1B71758E219652C,\n 0x9C40000000000000, 0xE8D4A51000000000, 0xAD78EBC5AC620000, 0x813F3978F8940984,\n 0xC097CE7BC90715B3, 0x8F7E32CE7BEA5C70, 0xD5D238A4ABE98068, 0x9F4F2726179A2245,\n 0xED63A231D4C4FB27, 0xB0DE65388CC8ADA8, 0x83C7088E1AAB65DB, 0xC45D1DF942711D9A,\n 0x924D692CA61BE758, 0xDA01EE641A708DEA, 0xA26DA3999AEF774A, 0xF209787BB47D6B85,\n 0xB454E4A179DD1877, 0x865B86925B9BC5C2, 0xC83553C5C8965D3D, 0x952AB45CFA97A0B3,\n 0xDE469FBD99A05FE3, 0xA59BC234DB398C25, 0xF6C69A72A3989F5C, 0xB7DCBF5354E9BECE,\n 0x88FCF317F22241E2, 0xCC20CE9BD35C78A5, 0x98165AF37B2153DF, 0xE2A0B5DC971F303A,\n 0xA8D9D1535CE3B396, 0xFB9B7CD9A4A7443C, 0xBB764C4CA7A44410, 0x8BAB8EEFB6409C1A,\n 0xD01FEF10A657842C, 0x9B10A4E5E9913129, 0xE7109BFBA19C0C9D, 0xAC2820D9623BF429,\n 0x80444B5E7AA7CF85, 0xBF21E44003ACDD2D, 0x8E679C2F5E44FF8F, 0xD433179D9C8CB841,\n 0x9E19DB92B4E31BA9, 0xEB96BF6EBADF77D9, 0xAF87023B9BF0EE6B\n]);\n\n// @ts-ignore: decorator\n@inline\nexport function isPowerOf2(value: T): bool {\n return popcnt(value) == 1;\n}\n\n// Count number of decimals for u32 values\n// In our case input value always non-zero so we can simplify some parts\nexport function decimalCount32(value: u32): u32 {\n if (value < 100000) {\n if (value < 100) {\n return 1 + u32(value >= 10);\n } else {\n return 3 + u32(value >= 10000) + u32(value >= 1000);\n }\n } else {\n if (value < 10000000) {\n return 6 + u32(value >= 1000000);\n } else {\n return 8 + u32(value >= 1000000000) + u32(value >= 100000000);\n }\n }\n}\n\n// Count number of decimals for u64 values\n// In our case input value always greater than 2^32-1 so we can skip some parts\nexport function decimalCount64High(value: u64): u32 {\n if (value < 1000000000000000) {\n if (value < 1000000000000) {\n return 10 + u32(value >= 100000000000) + u32(value >= 10000000000);\n } else {\n return 13 + u32(value >= 100000000000000) + u32(value >= 10000000000000);\n }\n } else {\n if (value < 100000000000000000) {\n return 16 + u32(value >= 10000000000000000);\n } else {\n return 18 + u32(value >= 10000000000000000000) + u32(value >= 1000000000000000000);\n }\n }\n}\n\nfunction ulog_base(num: u64, base: i32): u32 {\n if (isPowerOf2(base)) {\n return (63 - clz(num)) / (31 - clz(base)) + 1;\n }\n var b64 = u64(base), b = b64, e: u32 = 1;\n while (num >= b) {\n num /= b;\n b *= b;\n e <<= 1;\n }\n while (num >= 1) {\n num /= b64;\n e++;\n }\n return e - 1;\n}\n\nfunction utoa32_dec_lut(buffer: usize, num: u32, offset: usize): void {\n while (num >= 10000) {\n // in most VMs i32/u32 div and modulo by constant can be shared and simplificate\n let t = num / 10000;\n let r = num % 10000;\n num = t;\n\n let d1 = r / 100;\n let d2 = r % 100;\n\n let digits1 = load(DIGITS + (d1 << alignof()));\n let digits2 = load(DIGITS + (d2 << alignof()));\n\n offset -= 4;\n store(buffer + (offset << 1), digits1 | (digits2 << 32));\n }\n\n if (num >= 100) {\n let t = num / 100;\n let d1 = num % 100;\n num = t;\n offset -= 2;\n let digits = load(DIGITS + (d1 << alignof()));\n store(buffer + (offset << 1), digits);\n }\n\n if (num >= 10) {\n offset -= 2;\n let digits = load(DIGITS + (num << alignof()));\n store(buffer + (offset << 1), digits);\n } else {\n offset -= 1;\n let digit = CharCode._0 + num;\n store(buffer + (offset << 1), digit);\n }\n}\n\nfunction utoa64_dec_lut(buffer: usize, num: u64, offset: usize): void {\n while (num >= 100000000) {\n let t = num / 100000000;\n let r = (num - t * 100000000);\n num = t;\n\n let b = r / 10000;\n let c = r % 10000;\n\n let b1 = b / 100;\n let b2 = b % 100;\n let c1 = c / 100;\n let c2 = c % 100;\n\n let digits1 = load(DIGITS + (c1 << alignof()));\n let digits2 = load(DIGITS + (c2 << alignof()));\n\n offset -= 4;\n store(buffer + (offset << 1), digits1 | (digits2 << 32));\n\n digits1 = load(DIGITS + (b1 << alignof()));\n digits2 = load(DIGITS + (b2 << alignof()));\n\n offset -= 4;\n store(buffer + (offset << 1), digits1 | (digits2 << 32));\n }\n\n utoa32_dec_lut(buffer, num, offset);\n}\n\nfunction utoa_hex_lut(buffer: usize, num: u64, offset: usize): void {\n const lut = changetype(HEX_DIGITS);\n while (offset >= 2) {\n offset -= 2;\n store(\n buffer + (offset << 1),\n load(lut + ((num & 0xFF) << alignof()))\n );\n num >>= 8;\n }\n if (offset & 1) {\n store(buffer, load(lut + (num << 6)));\n }\n}\n\nfunction utoa_dec_simple(buffer: usize, num: T, offset: usize): void {\n do {\n let t = num / 10;\n let r = (num % 10);\n num = changetype(t);\n offset--;\n store(buffer + (offset << 1), CharCode._0 + r);\n } while (num);\n}\n\nfunction utoa_hex_simple(buffer: usize, num: T, offset: usize): void {\n do {\n let d = num & 0x0F | CharCode._0;\n d += select(0x27, 0, d > CharCode._9);\n offset--;\n store(buffer + (offset << 1), d);\n // @ts-ignore: type\n num >>= 4;\n } while (num);\n}\n\n// @ts-ignore: decorator\n@inline\nexport function utoa32_dec_core(buffer: usize, num: u32, offset: usize): void {\n if (ASC_SHRINK_LEVEL >= 1) {\n utoa_dec_simple(buffer, num, offset);\n } else {\n utoa32_dec_lut(buffer, num, offset);\n }\n}\n\n// @ts-ignore: decorator\n@inline\nfunction utoa32_hex_core(buffer: usize, num: u32, offset: usize): void {\n if (ASC_SHRINK_LEVEL >= 1) {\n utoa_hex_simple(buffer, num, offset);\n } else {\n utoa_hex_lut(buffer, num, offset);\n }\n}\n\n// @ts-ignore: decorator\n@inline\nfunction utoa64_dec_core(buffer: usize, num: u64, offset: usize): void {\n if (ASC_SHRINK_LEVEL >= 1) {\n utoa_dec_simple(buffer, num, offset);\n } else {\n utoa64_dec_lut(buffer, num, offset);\n }\n}\n\n// @ts-ignore: decorator\n@inline\nfunction utoa64_hex_core(buffer: usize, num: u64, offset: usize): void {\n if (ASC_SHRINK_LEVEL >= 1) {\n utoa_hex_simple(buffer, num, offset);\n } else {\n utoa_hex_lut(buffer, num, offset);\n }\n}\n\nfunction utoa64_any_core(buffer: usize, num: u64, offset: usize, radix: i32): void {\n const lut = changetype(ANY_DIGITS);\n var base = u64(radix);\n if ((radix & (radix - 1)) == 0) { // for radix which pow of two\n let shift = u64(ctz(radix) & 7);\n let mask = base - 1;\n do {\n offset--;\n store(buffer + (offset << 1), load(lut + (usize(num & mask) << 1)));\n num >>= shift;\n } while (num);\n } else {\n do {\n offset--;\n let q = num / base;\n store(buffer + (offset << 1), load(lut + (usize(num - q * base) << 1)));\n num = q;\n } while (num);\n }\n}\n\nexport function utoa32(value: u32, radix: i32): String {\n if (radix < 2 || radix > 36) {\n throw new RangeError(\"toString() radix argument must be between 2 and 36\");\n }\n if (!value) return \"0\";\n var out: String;\n\n if (radix == 10) {\n let decimals = decimalCount32(value);\n out = changetype(__new(decimals << 1, idof()));\n utoa32_dec_core(changetype(out), value, decimals);\n } else if (radix == 16) {\n let decimals = (31 - clz(value) >> 2) + 1;\n out = changetype(__new(decimals << 1, idof()));\n utoa32_hex_core(changetype(out), value, decimals);\n } else {\n let decimals = ulog_base(value, radix);\n out = changetype(__new(decimals << 1, idof()));\n utoa64_any_core(changetype(out), value, decimals, radix);\n }\n return out;\n}\n\nexport function itoa32(value: i32, radix: i32): String {\n if (radix < 2 || radix > 36) {\n throw new RangeError(\"toString() radix argument must be between 2 and 36\");\n }\n if (!value) return \"0\";\n\n var sign = (value >>> 31) << 1;\n if (sign) value = -value;\n var out: String;\n\n if (radix == 10) {\n let decimals = decimalCount32(value);\n out = changetype(__new((decimals << 1) + sign, idof()));\n utoa32_dec_core(changetype(out) + sign, value, decimals);\n } else if (radix == 16) {\n let decimals = (31 - clz(value) >> 2) + 1;\n out = changetype(__new((decimals << 1) + sign, idof()));\n utoa32_hex_core(changetype(out) + sign, value, decimals);\n } else {\n let val32 = u32(value);\n let decimals = ulog_base(val32, radix);\n out = changetype(__new((decimals << 1) + sign, idof()));\n utoa64_any_core(changetype(out) + sign, val32, decimals, radix);\n }\n if (sign) store(changetype(out), CharCode.MINUS);\n return out;\n}\n\nexport function utoa64(value: u64, radix: i32): String {\n if (radix < 2 || radix > 36) {\n throw new RangeError(\"toString() radix argument must be between 2 and 36\");\n }\n if (!value) return \"0\";\n var out: String;\n\n if (radix == 10) {\n if (value <= u32.MAX_VALUE) {\n let val32 = value;\n let decimals = decimalCount32(val32);\n out = changetype(__new(decimals << 1, idof()));\n utoa32_dec_core(changetype(out), val32, decimals);\n } else {\n let decimals = decimalCount64High(value);\n out = changetype(__new(decimals << 1, idof()));\n utoa64_dec_core(changetype(out), value, decimals);\n }\n } else if (radix == 16) {\n let decimals = (63 - u32(clz(value)) >> 2) + 1;\n out = changetype(__new(decimals << 1, idof()));\n utoa64_hex_core(changetype(out), value, decimals);\n } else {\n let decimals = ulog_base(value, radix);\n out = changetype(__new(decimals << 1, idof()));\n utoa64_any_core(changetype(out), value, decimals, radix);\n }\n return out;\n}\n\nexport function itoa64(value: i64, radix: i32): String {\n if (radix < 2 || radix > 36) {\n throw new RangeError(\"toString() radix argument must be between 2 and 36\");\n }\n if (!value) return \"0\";\n\n var sign = u32(value >>> 63) << 1;\n if (sign) value = -value;\n var out: String;\n\n if (radix == 10) {\n if (value <= u32.MAX_VALUE) {\n let val32 = value;\n let decimals = decimalCount32(val32);\n out = changetype(__new((decimals << 1) + sign, idof()));\n utoa32_dec_core(changetype(out) + sign, val32, decimals);\n } else {\n let decimals = decimalCount64High(value);\n out = changetype(__new((decimals << 1) + sign, idof()));\n utoa64_dec_core(changetype(out) + sign, value, decimals);\n }\n } else if (radix == 16) {\n let decimals = (63 - u32(clz(value)) >> 2) + 1;\n out = changetype(__new((decimals << 1) + sign, idof()));\n utoa64_hex_core(changetype(out) + sign, value, decimals);\n } else {\n let decimals = ulog_base(value, radix);\n out = changetype(__new((decimals << 1) + sign, idof()));\n utoa64_any_core(changetype(out) + sign, value, decimals, radix);\n }\n if (sign) store(changetype(out), CharCode.MINUS);\n return out;\n}\n\n// @ts-ignore: decorator\n@lazy var _K: i32 = 0;\n\n// // @ts-ignore: decorator\n// @lazy\n// var _frc: u64 = 0;\n\n// @ts-ignore: decorator\n@lazy var _exp: i32 = 0;\n\n// @ts-ignore: decorator\n@lazy var _frc_minus: u64 = 0;\n\n// @ts-ignore: decorator\n@lazy var _frc_plus: u64 = 0;\n\n// @ts-ignore: decorator\n@lazy var _frc_pow: u64 = 0;\n\n// @ts-ignore: decorator\n@lazy var _exp_pow: i32 = 0;\n\n// @ts-ignore: decorator\n@inline\nfunction umul64f(u: u64, v: u64): u64 {\n var u0 = u & 0xFFFFFFFF;\n var v0 = v & 0xFFFFFFFF;\n\n var u1 = u >> 32;\n var v1 = v >> 32;\n\n var l = u0 * v0;\n var t = u1 * v0 + (l >> 32);\n var w = u0 * v1 + (t & 0xFFFFFFFF);\n\n w += 0x7FFFFFFF; // rounding\n\n t >>= 32;\n w >>= 32;\n\n return u1 * v1 + t + w;\n}\n\n// @ts-ignore: decorator\n@inline\nfunction umul64e(e1: i32, e2: i32): i32 {\n return e1 + e2 + 64; // where 64 is significand size\n}\n\n// @ts-ignore: decorator\n@inline\nfunction normalizedBoundaries(f: u64, e: i32): void {\n var frc = (f << 1) + 1;\n var exp = e - 1;\n var off = clz(frc);\n frc <<= off;\n exp -= off;\n\n var m = 1 + i32(f == 0x0010000000000000);\n\n _frc_plus = frc;\n _frc_minus = ((f << m) - 1) << e - m - exp;\n _exp = exp;\n}\n\n// @ts-ignore: decorator\n@inline\nfunction grisuRound(buffer: usize, len: i32, delta: u64, rest: u64, ten_kappa: u64, wp_w: u64): void {\n var lastp = buffer + ((len - 1) << 1);\n var digit = load(lastp);\n while (\n rest < wp_w &&\n delta - rest >= ten_kappa && (\n rest + ten_kappa < wp_w ||\n wp_w - rest > rest + ten_kappa - wp_w\n )\n ) {\n --digit;\n rest += ten_kappa;\n }\n store(lastp, digit);\n}\n\n// @ts-ignore: decorator\n@inline\nfunction getCachedPower(minExp: i32): void {\n const c = reinterpret(0x3FD34413509F79FE); // 1 / lg(10) = 0.30102999566398114\n var dk = (-61 - minExp) * c + 347;\t // dk must be positive, so can do ceiling in positive\n var k = dk;\n k += i32(k != dk); // conversion with ceil\n\n var index = (k >> 3) + 1;\n _K = 348 - (index << 3);\t// decimal exponent no need lookup table\n _frc_pow = load(FRC_POWERS + (index << alignof()));\n _exp_pow = load(EXP_POWERS + (index << alignof()));\n}\n\n// @ts-ignore: decorator\n@inline\nfunction grisu2(value: f64, buffer: usize, sign: i32): i32 {\n\n // frexp routine\n var uv = reinterpret(value);\n var exp = i32((uv & 0x7FF0000000000000) >>> 52);\n var sid = uv & 0x000FFFFFFFFFFFFF;\n var frc = (u64(exp != 0) << 52) + sid;\n exp = select(exp, 1, exp) - (0x3FF + 52);\n\n normalizedBoundaries(frc, exp);\n getCachedPower(_exp);\n\n // normalize\n var off = clz(frc);\n frc <<= off;\n exp -= off;\n\n var frc_pow = _frc_pow;\n var exp_pow = _exp_pow;\n\n var w_frc = umul64f(frc, frc_pow);\n var w_exp = umul64e(exp, exp_pow);\n\n var wp_frc = umul64f(_frc_plus, frc_pow) - 1;\n var wp_exp = umul64e(_exp, exp_pow);\n\n var wm_frc = umul64f(_frc_minus, frc_pow) + 1;\n var delta = wp_frc - wm_frc;\n\n return genDigits(buffer, w_frc, w_exp, wp_frc, wp_exp, delta, sign);\n}\n\nfunction genDigits(buffer: usize, w_frc: u64, w_exp: i32, mp_frc: u64, mp_exp: i32, delta: u64, sign: i32): i32 {\n var one_exp = -mp_exp;\n var one_frc = (1) << one_exp;\n var mask = one_frc - 1;\n\n var wp_w_frc = mp_frc - w_frc;\n\n var p1 = u32(mp_frc >> one_exp);\n var p2 = mp_frc & mask;\n\n var kappa = decimalCount32(p1);\n var len = sign;\n\n while (kappa > 0) {\n let d: u32;\n switch (kappa) {\n case 10: { d = p1 / 1000000000; p1 %= 1000000000; break; }\n case 9: { d = p1 / 100000000; p1 %= 100000000; break; }\n case 8: { d = p1 / 10000000; p1 %= 10000000; break; }\n case 7: { d = p1 / 1000000; p1 %= 1000000; break; }\n case 6: { d = p1 / 100000; p1 %= 100000; break; }\n case 5: { d = p1 / 10000; p1 %= 10000; break; }\n case 4: { d = p1 / 1000; p1 %= 1000; break; }\n case 3: { d = p1 / 100; p1 %= 100; break; }\n case 2: { d = p1 / 10; p1 %= 10; break; }\n case 1: { d = p1; p1 = 0; break; }\n default: { d = 0; break; }\n }\n\n if (d | len) store(buffer + (len++ << 1), CharCode._0 + d);\n\n --kappa;\n let tmp = ((p1) << one_exp) + p2;\n if (tmp <= delta) {\n _K += kappa;\n grisuRound(buffer, len, delta, tmp, load(POWERS10 + (kappa << alignof())) << one_exp, wp_w_frc);\n return len;\n }\n }\n\n while (true) {\n p2 *= 10;\n delta *= 10;\n\n let d = p2 >> one_exp;\n if (d | len) store(buffer + (len++ << 1), CharCode._0 + d);\n\n p2 &= mask;\n --kappa;\n if (p2 < delta) {\n _K += kappa;\n wp_w_frc *= load(POWERS10 + (-kappa << alignof()));\n grisuRound(buffer, len, delta, p2, one_frc, wp_w_frc);\n return len;\n }\n }\n}\n\n// @ts-ignore: decorator\n@inline\nfunction genExponent(buffer: usize, k: i32): i32 {\n var sign = k < 0;\n if (sign) k = -k;\n var decimals = decimalCount32(k) + 1;\n utoa32_dec_core(buffer, k, decimals);\n store(buffer, select(CharCode.MINUS, CharCode.PLUS, sign));\n return decimals;\n}\n\nfunction prettify(buffer: usize, length: i32, k: i32): i32 {\n if (!k) {\n store(buffer + (length << 1), CharCode.DOT | (CharCode._0 << 16));\n return length + 2;\n }\n\n var kk = length + k;\n if (length <= kk && kk <= 21) {\n // 1234e7 -> 12340000000\n for (let i = length; i < kk; ++i) {\n store(buffer + (i << 1), CharCode._0);\n }\n store(buffer + (kk << 1), CharCode.DOT | (CharCode._0 << 16));\n return kk + 2;\n } else if (kk > 0 && kk <= 21) {\n // 1234e-2 -> 12.34\n let ptr = buffer + (kk << 1);\n memory.copy(\n ptr + 2,\n ptr,\n -k << 1\n );\n store(buffer + (kk << 1), CharCode.DOT);\n return length + 1;\n } else if (-6 < kk && kk <= 0) {\n // 1234e-6 -> 0.001234\n let offset = 2 - kk;\n memory.copy(\n buffer + (offset << 1),\n buffer,\n length << 1\n );\n store(buffer, CharCode._0 | (CharCode.DOT << 16));\n for (let i = 2; i < offset; ++i) {\n store(buffer + (i << 1), CharCode._0);\n }\n return length + offset;\n } else if (length == 1) {\n // 1e30\n store(buffer, CharCode.e, 2);\n length = genExponent(buffer + 4, kk - 1);\n return length + 2;\n } else {\n let len = length << 1;\n memory.copy(\n buffer + 4,\n buffer + 2,\n len - 2\n );\n store(buffer, CharCode.DOT, 2);\n store(buffer + len, CharCode.e, 2);\n length += genExponent(buffer + len + 4, kk - 1);\n return length + 2;\n }\n}\n\nfunction dtoa_core(buffer: usize, value: f64): i32 {\n var sign = i32(value < 0);\n if (sign) {\n value = -value;\n store(buffer, CharCode.MINUS);\n }\n // assert(value > 0 && value <= 1.7976931348623157e308);\n var len = grisu2(value, buffer, sign);\n len = prettify(buffer + (sign << 1), len - sign, _K);\n return len + sign;\n}\n\n// @ts-ignore: decorator\n@lazy @inline const dtoa_buf = memory.data(MAX_DOUBLE_LENGTH << 1);\n\nexport function dtoa(value: f64): String {\n if (value == 0) return \"0.0\";\n if (!isFinite(value)) {\n if (isNaN(value)) return \"NaN\";\n return select(\"-Infinity\", \"Infinity\", value < 0);\n }\n var size = dtoa_core(dtoa_buf, value) << 1;\n var result = changetype(__new(size, idof()));\n memory.copy(changetype(result), dtoa_buf, size);\n return result;\n}\n\nexport function itoa_buffered(buffer: usize, value: T): u32 {\n var sign: u32 = 0;\n if (isSigned()) {\n sign = u32(value < 0);\n if (sign) {\n if (sizeof() == 1) {\n if (value == -0x80) {\n // -0x80 -> -128\n store(buffer,\n CharCode.MINUS |\n (CharCode._0 + 1) << 16 |\n (CharCode._0 + 2) << 32 |\n (CharCode._0 + 8) << 48\n );\n return 4;\n }\n }\n if (sizeof() == 2) {\n if (value == -0x8000) {\n // -0x8000 -> -32768\n store(buffer,\n CharCode.MINUS |\n (CharCode._0 + 3) << 16 |\n (CharCode._0 + 2) << 32 |\n (CharCode._0 + 7) << 48\n ); // -327\n store(buffer + 8,\n (CharCode._0 + 6) << 0 |\n (CharCode._0 + 8) << 16\n ); // 68\n return 6;\n }\n }\n store(buffer, CharCode.MINUS);\n // @ts-ignore\n value = -value;\n }\n }\n var dest = buffer + (sign << 1);\n if (ASC_SHRINK_LEVEL <= 1) {\n if (isSigned()) {\n if (sizeof() <= 4) {\n if (value < 10) {\n store(dest, value | CharCode._0);\n return 1 + sign;\n }\n } else {\n if (value < 10) {\n store(dest, value | CharCode._0);\n return 1 + sign;\n }\n }\n } else {\n if (value < 10) {\n store(buffer, value | CharCode._0);\n return 1;\n }\n }\n }\n var decimals: u32 = 0;\n if (sizeof() <= 4) {\n let val32 = value;\n decimals = decimalCount32(val32);\n utoa32_dec_core(dest, val32, decimals);\n } else {\n if (value <= u32.MAX_VALUE) {\n let val32 = value;\n decimals = decimalCount32(val32);\n utoa32_dec_core(dest, val32, decimals);\n } else {\n let val64 = value;\n decimals = decimalCount64High(val64);\n utoa64_dec_core(dest, val64, decimals);\n }\n }\n return sign + decimals;\n}\n\nexport function dtoa_buffered(buffer: usize, value: f64): u32 {\n if (value == 0) {\n store(buffer, CharCode._0);\n store(buffer, CharCode.DOT, 2);\n store(buffer, CharCode._0, 4);\n return 3;\n }\n if (!isFinite(value)) {\n if (isNaN(value)) {\n store(buffer, CharCode.N);\n store(buffer, CharCode.a, 2);\n store(buffer, CharCode.N, 4);\n return 3;\n } else {\n let sign = value < 0;\n if (sign) {\n store(buffer, CharCode.MINUS); // -\n buffer += 2;\n }\n store(buffer, 0x690066006E0049, 0); // ifnI\n store(buffer, 0x7900740069006E, 8); // ytin\n return 8 + u32(sign);\n }\n }\n return dtoa_core(buffer, value);\n}\n","import {\n itoa32,\n utoa32,\n itoa64,\n utoa64,\n dtoa,\n itoa_buffered,\n dtoa_buffered,\n MAX_DOUBLE_LENGTH\n} from \"./number\";\n\nimport {\n ipow32\n} from \"../math\";\n\n// All tables are stored as two staged lookup tables (static tries)\n// because the full range of Unicode symbols can't be efficiently\n// represented as-is in memory (see Unicode spec ch 5, p.196):\n// https://www.unicode.org/versions/Unicode12.0.0/ch05.pdf\n// Tables have been generated using these forked musl tools:\n// https://github.com/MaxGraey/musl-chartable-tools/tree/case-ignorable\n\n// Lookup table to check if a character is alphanumeric or not\n// See: https://git.musl-libc.org/cgit/musl/tree/src/ctype/alpha.h\n// size: 3904 bytes\n// @ts-ignore\n@inline @lazy const ALPHA_TABLE = memory.data([\n 18,17,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,17,34,35,36,17,37,38,39,40,\n 41,42,43,44,17,45,46,47,16,16,48,16,16,16,16,16,16,16,49,50,51,16,52,53,16,16,\n 17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,54,\n 17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,\n 17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,\n 17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,\n 17,17,17,55,17,17,17,17,56,17,57,58,59,60,61,62,17,17,17,17,17,17,17,17,17,17,\n 17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,\n 17,17,17,17,17,17,17,63,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,17,64,65,17,66,67,\n 68,69,70,71,72,73,74,17,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,\n 93,94,16,95,96,97,98,17,17,17,99,100,101,16,16,16,16,16,16,16,16,16,16,17,17,\n 17,17,102,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,17,17,103,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,17,17,104,105,16,16,106,107,17,17,17,17,17,17,17,17,17,17,17,17,17,\n 17,17,17,17,17,17,17,17,17,17,108,17,17,17,17,109,110,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 17,111,112,16,16,16,16,16,16,16,16,16,113,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,114,115,116,117,16,16,16,16,16,16,16,16,118,\n 119,120,16,16,16,16,16,121,122,16,16,16,16,123,16,16,124,16,16,16,16,16,16,16,\n 16,16,125,16,16,16,\n 16,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,255,255,\n 255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,\n 255,255,255,255,255,255,255,255,255,255,255,0,0,0,0,0,0,0,0,254,255,255,7,254,\n 255,255,7,0,0,0,0,0,4,32,4,255,255,127,255,255,255,127,255,255,255,255,255,\n 255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,\n 255,195,255,3,0,31,80,0,0,0,0,0,0,0,0,0,0,32,0,0,0,0,0,223,188,64,215,255,255,\n 251,255,255,255,255,255,255,255,255,255,191,255,255,255,255,255,255,255,255,\n 255,255,255,255,255,255,255,255,255,3,252,255,255,255,255,255,255,255,255,255,\n 255,255,255,255,255,255,255,255,255,255,255,254,255,255,255,127,2,255,255,255,\n 255,255,1,0,0,0,0,255,191,182,0,255,255,255,135,7,0,0,0,255,7,255,255,255,255,\n 255,255,255,254,255,195,255,255,255,255,255,255,255,255,255,255,255,255,239,\n 31,254,225,255,\n 159,0,0,255,255,255,255,255,255,0,224,255,255,255,255,255,255,255,255,255,255,\n 255,255,3,0,255,255,255,255,255,7,48,4,255,255,255,252,255,31,0,0,255,255,255,\n 1,255,7,0,0,0,0,0,0,255,255,223,255,255,0,240,255,248,3,255,255,255,255,255,\n 255,255,255,255,239,255,223,225,255,207,255,254,255,239,159,249,255,255,253,\n 197,227,159,89,128,176,207,255,3,16,238,135,249,255,255,253,109,195,135,25,2,\n 94,192,255,63,0,238,191,251,255,255,253,237,227,191,27,1,0,207,255,0,30,238,\n 159,249,255,255,253,237,227,159,25,192,176,207,255,2,0,236,199,61,214,24,199,\n 255,195,199,29,129,0,192,255,0,0,239,223,253,255,255,253,255,227,223,29,96,7,\n 207,255,0,0,239,223,253,255,255,253,239,227,223,29,96,64,207,255,6,0,255,223,\n 253,255,255,255,255,231,223,93,240,128,207,255,0,252,238,255,127,252,255,255,\n 251,47,127,128,95,255,192,255,12,0,254,255,255,255,255,127,255,7,63,32,255,3,\n 0,0,0,0,214,247,255,255,175,255,255,59,95,32,255,243,0,0,0,\n 0,1,0,0,0,255,3,0,0,255,254,255,255,255,31,254,255,3,255,255,254,255,255,255,\n 31,0,0,0,0,0,0,0,0,255,255,255,255,255,255,127,249,255,3,255,255,255,255,255,\n 255,255,255,255,63,255,255,255,255,191,32,255,255,255,255,255,247,255,255,255,\n 255,255,255,255,255,255,61,127,61,255,255,255,255,255,61,255,255,255,255,61,\n 127,61,255,127,255,255,255,255,255,255,255,61,255,255,255,255,255,255,255,255,\n 7,0,0,0,0,255,255,0,0,255,255,255,255,255,255,255,255,255,255,63,63,254,255,\n 255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,\n 255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,\n 255,255,255,255,255,159,255,255,254,255,255,7,255,255,255,255,255,255,255,255,\n 255,199,255,1,255,223,15,0,255,255,15,0,255,255,15,0,255,223,13,0,255,255,255,\n 255,255,255,207,255,255,1,128,16,255,3,0,0,0,0,255,3,255,255,255,255,255,255,\n 255,255,255,255,255,1,255,255,255,255,255,7,255,255,255,255,255,255,255,255,\n 63,\n 0,255,255,255,127,255,15,255,1,192,255,255,255,255,63,31,0,255,255,255,255,\n 255,15,255,255,255,3,255,3,0,0,0,0,255,255,255,15,255,255,255,255,255,255,255,\n 127,254,255,31,0,255,3,255,3,128,0,0,128,1,0,0,0,0,0,0,0,255,255,255,255,255,\n 255,239,255,239,15,255,3,0,0,0,0,255,255,255,255,255,243,255,255,255,255,255,\n 255,191,255,3,0,255,255,255,255,255,255,127,0,255,227,255,255,255,255,255,63,\n 255,1,255,255,255,255,255,231,0,0,0,0,0,222,111,4,255,255,255,255,255,255,255,\n 255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,0,0,0,0,\n 128,255,31,0,255,255,63,63,255,255,255,255,63,63,255,170,255,255,255,63,255,\n 255,255,255,255,255,223,95,220,31,207,15,255,31,220,31,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,2,128,0,0,255,31,0,0,0,0,0,0,0,0,0,0,0,0,132,252,47,62,80,189,255,243,\n 224,67,0,0,255,255,255,255,255,1,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,192,255,255,255,255,255,255,3,0,\n 0,255,255,255,255,255,127,255,255,255,255,255,127,255,255,255,255,255,255,255,\n 255,255,255,255,255,255,255,255,255,31,120,12,0,255,255,255,255,191,32,255,\n 255,255,255,255,255,255,128,0,0,255,255,127,0,127,127,127,127,127,127,127,127,\n 255,255,255,255,0,0,0,0,0,128,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,224,0,0,0,254,3,62,31,254,255,255,255,255,255,255,255,255,255,127,224,254,\n 255,255,255,255,255,255,255,255,255,255,247,224,255,255,255,255,255,254,255,\n 255,255,255,255,255,255,255,255,255,127,0,0,255,255,255,255,0,0,0,0,0,0,255,\n 255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,\n 255,255,255,255,255,255,0,0,0,0,0,0,0,0,255,255,255,255,255,255,255,255,255,\n 255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,\n 255,255,255,\n 31,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,31,0,0,\n 0,0,0,0,0,0,255,255,255,255,255,63,255,31,255,255,255,15,0,0,255,255,255,255,\n 255,127,240,143,255,255,255,255,255,255,255,255,255,255,255,255,255,255,0,0,0,\n 0,128,255,252,255,255,255,255,255,255,255,255,255,255,255,255,249,255,255,255,\n 255,255,255,252,7,0,0,0,0,224,255,191,255,255,255,255,0,0,0,255,255,255,255,\n 255,255,15,0,255,255,255,255,255,255,255,255,47,0,255,3,0,0,252,232,255,255,\n 255,255,255,7,255,255,255,255,7,0,255,255,255,31,255,255,255,255,255,255,247,\n 255,0,128,255,3,255,255,255,127,255,255,255,255,255,255,127,0,255,63,255,3,\n 255,255,127,252,255,255,255,255,255,255,255,127,5,0,0,56,255,255,60,0,126,126,\n 126,0,127,127,255,255,255,255,255,247,255,3,255,255,255,255,255,255,255,255,\n 255,255,255,255,255,255,255,7,255,3,255,255,255,255,255,255,255,255,255,255,\n 255,255,255,255,255,255,255,255,255,255,15,0,255,255,127,248,255,255,255,255,\n 255,\n 15,255,255,255,255,255,255,255,255,255,255,255,255,255,63,255,255,255,255,255,\n 255,255,255,255,255,255,255,255,3,0,0,0,0,127,0,248,224,255,253,127,95,219,\n 255,255,255,255,255,255,255,255,255,255,255,255,255,3,0,0,0,248,255,255,255,\n 255,255,255,255,255,255,255,255,255,63,0,0,255,255,255,255,255,255,255,255,\n 252,255,255,255,255,255,255,0,0,0,0,0,255,15,0,0,0,0,0,0,0,0,0,0,0,0,0,0,223,\n 255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,31,0,0,255,3,\n 254,255,255,7,254,255,255,7,192,255,255,255,255,255,255,255,255,255,255,127,\n 252,252,252,28,0,0,0,0,255,239,255,255,127,255,255,183,255,63,255,63,0,0,0,0,\n 255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,7,0,0,0,0,0,0,0,0,\n 255,255,255,255,255,255,31,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,255,255,255,31,255,255,255,255,255,255,1,0,0,0,0,\n 0,255,255,255,255,0,224,255,255,255,7,255,255,255,255,255,7,255,255,255,63,\n 255,255,255,255,15,255,62,0,0,0,0,0,255,255,255,255,255,255,255,255,255,255,\n 255,255,255,255,255,255,255,255,255,63,255,3,255,255,255,255,15,255,255,255,\n 255,15,255,255,255,255,255,0,255,255,255,255,255,255,15,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,255,255,255,255,255,255,127,0,255,255,63,0,255,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,63,253,255,255,255,255,191,145,255,255,63,0,255,255,\n 127,0,255,255,255,127,0,0,0,0,0,0,0,0,255,255,55,0,255,255,63,0,255,255,255,3,\n 0,0,0,0,0,0,0,0,255,255,255,255,255,255,255,192,0,0,0,0,0,0,0,0,111,240,239,\n 254,255,255,63,0,0,0,0,0,255,255,255,31,255,255,255,31,0,0,0,0,255,254,255,\n 255,31,0,0,0,255,255,255,255,255,255,63,0,255,255,63,0,255,255,7,0,255,255,3,\n 0,0,0,0,0,0,0,0,0,0,0,0,\n 0,255,255,255,255,255,255,255,255,255,1,0,0,0,0,0,0,255,255,255,255,255,255,7,\n 0,255,255,255,255,255,255,7,0,255,255,255,255,255,0,255,3,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,255,255,255,255,\n 255,27,3,0,0,0,0,0,0,0,0,0,255,255,255,31,128,0,255,255,63,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,255,255,31,0,0,0,255,255,127,0,255,255,255,255,255,255,255,255,63,0,0,\n 0,192,255,0,0,252,255,255,255,255,255,255,1,0,0,255,255,255,1,255,3,255,255,\n 255,255,255,255,199,255,240,0,255,255,255,255,71,0,255,255,255,255,255,255,\n 255,255,30,192,255,23,0,0,0,0,255,255,251,255,255,255,159,64,0,0,0,0,0,0,0,0,\n 127,189,255,191,255,1,255,255,255,255,255,255,255,1,255,3,239,159,249,255,255,\n 253,237,227,159,25,129,224,15,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,255,255,255,255,255,255,255,255,187,7,255,131,3,0,0,0,255,255,255,255,255,\n 255,255,255,179,0,255,3,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,255,255,255,\n 255,255,255,63,127,0,0,0,63,0,0,0,0,255,255,255,255,255,255,255,127,17,0,255,\n 3,0,0,0,0,255,255,255,255,255,255,63,1,255,3,0,0,0,0,0,0,255,255,255,231,255,\n 7,255,3,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,255,255,255,255,255,\n 255,255,1,0,0,0,0,0,0,0,0,0,0,0,0,255,255,255,255,255,255,255,255,255,3,0,128,\n 127,242,111,255,255,255,191,153,7,0,255,3,0,0,0,0,0,0,0,0,255,252,255,255,255,\n 255,255,252,26,0,0,0,255,255,255,255,255,255,231,127,0,0,255,255,255,255,255,\n 255,255,255,255,32,0,0,0,0,255,255,255,255,255,255,255,1,255,253,255,255,255,\n 255,127,127,1,0,255,3,0,0,252,255,255,255,252,255,255,254,127,0,0,0,0,0,0,0,0,\n 0,127,251,255,255,255,255,127,180,203,0,255,3,191,253,255,255,255,127,123,1,\n 255,3,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,255,255,127,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,\n 0,0,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,\n 255,3,0,0,0,0,0,0,0,0,0,0,0,0,255,255,255,255,255,255,255,255,255,255,255,255,\n 255,127,0,0,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,\n 255,255,255,255,255,255,255,255,15,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,255,255,255,255,255,127,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,255,255,255,255,255,255,255,255,127,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,\n 0,255,255,255,255,255,255,255,1,255,255,255,127,255,3,0,0,0,0,0,0,0,0,0,0,0,0,\n 255,255,255,63,0,0,255,255,255,255,255,255,0,0,15,0,255,3,248,255,255,224,255,\n 255,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,255,255,255,255,255,255,255,\n 255,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,255,255,255,255,255,255,255,255,255,135,\n 255,255,255,255,255,255,255,128,255,255,0,0,0,0,0,0,0,0,11,0,3,0,255,255,255,\n 255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,\n 255,255,255,255,255,255,255,255,255,0,255,255,255,255,255,255,255,255,255,255,\n 255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,63,0,0,0,0,0,\n 255,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,255,255,255,\n 127,0,0,0,0,0,0,7,0,240,0,255,255,255,255,255,255,255,255,255,255,255,255,255,\n 255,255,255,255,\n 255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,\n 255,255,255,255,255,255,255,255,255,255,255,255,255,15,255,255,255,255,255,\n 255,255,255,255,255,255,255,255,7,255,31,255,1,255,67,0,0,0,0,0,0,0,0,0,0,0,0,\n 255,255,255,255,255,255,255,255,255,255,223,255,255,255,255,255,255,255,255,\n 223,100,222,255,235,239,255,255,255,255,255,255,255,191,231,223,223,255,255,\n 255,123,95,252,253,255,255,255,255,255,255,255,255,255,255,255,255,255,255,\n 255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,\n 255,255,255,255,255,255,255,255,63,255,255,255,253,255,255,247,255,255,255,\n 247,255,255,223,255,255,255,223,255,255,127,255,255,255,127,255,255,255,253,\n 255,255,255,253,255,255,247,207,255,255,255,255,255,255,127,255,255,249,219,7,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,255,255,255,255,255,31,\n 128,63,255,67,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,255,255,255,255,255,15,255,\n 3,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,\n 255,255,255,255,255,31,0,0,0,0,0,0,0,255,255,255,255,255,255,255,255,143,8,\n 255,3,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,239,255,255,255,150,254,247,10,\n 132,234,150,170,150,247,247,94,255,251,255,15,238,251,255,15,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,255,255,255,3,255,255,255,3,255,255,255,3,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,255,3\n]);\n\n// size: 1568 bytes (compressed to ~1380 bytes after binaryen)\n// @ts-ignore: decorator\n@lazy @inline const CASED = memory.data([\n 18,19,20,21,22,23,16,16,16,16,16,16,16,16,16,16,\n 24,16,16,25,16,16,16,16,16,16,16,16,26,27,17,28,\n 29,30,16,16,31,16,16,16,16,16,16,16,32,33,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,34,35,16,16,16,36,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,37,16,16,16,38,\n 16,16,16,16,39,16,16,16,16,16,16,16,40,16,16,16,\n 16,16,16,16,16,16,16,16,41,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,42,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,43,44,45,46,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,47,16,16,16,16,16,16,\n 16,48,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,\n 255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,\n 0,0,0,0,0,0,0,0,254,255,255,7,254,255,255,7,0,0,0,0,0,4,32,4,\n 255,255,127,255,255,255,127,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,\n 255,255,255,255,255,255,255,247,240,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,\n 255,255,255,255,255,255,255,255,255,255,239,255,255,255,255,1,3,0,0,0,31,0,0,0,\n 0,0,0,0,0,0,0,0,32,0,0,0,0,0,207,188,64,215,255,255,251,255,255,255,\n 255,255,255,255,255,255,191,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,\n 3,252,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,254,255,\n 255,255,127,0,255,255,255,255,255,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,255,255,255,255,\n 191,32,255,255,255,255,255,231,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,255,255,255,255,255,255,255,255,255,255,63,63,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,255,1,255,255,255,255,255,231,0,0,0,0,0,0,0,0,\n 255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,\n 0,0,0,0,0,0,0,0,255,255,63,63,255,255,255,255,63,63,255,170,255,255,255,63,\n 255,255,255,255,255,255,223,95,220,31,207,15,255,31,220,31,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,2,128,0,0,255,31,0,0,0,0,0,0,0,0,0,0,0,0,\n 132,252,47,62,80,189,31,242,224,67,0,0,255,255,255,255,24,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,192,255,255,255,255,255,255,3,0,0,255,255,255,255,255,127,255,255,\n 255,255,255,127,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,31,120,12,0,\n 255,255,255,255,191,32,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,255,255,255,255,255,63,0,0,\n 255,255,255,63,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,252,255,255,255,\n 255,255,255,255,255,255,255,255,255,120,255,255,255,255,255,255,252,7,0,0,0,0,96,7,\n 0,0,0,0,0,0,255,255,255,255,255,247,255,1,255,255,255,255,255,255,255,255,255,255,\n 0,0,0,0,0,0,0,0,127,0,248,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,254,255,255,7,\n 254,255,255,7,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 255,255,255,255,255,255,255,255,255,255,0,0,0,0,0,0,0,0,0,0,0,0,255,255,\n 255,255,15,255,255,255,255,15,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 255,255,255,255,255,255,7,0,255,255,255,255,255,255,7,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,255,255,255,255,255,255,255,255,0,0,0,0,\n 0,0,0,0,0,0,0,0,255,255,255,255,255,255,255,255,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,255,255,255,255,255,255,255,255,255,255,223,255,255,255,255,255,\n 255,255,255,223,100,222,255,235,239,255,255,255,255,255,255,255,191,231,223,223,255,255,255,123,\n 95,252,253,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,\n 255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,63,255,255,255,\n 253,255,255,247,255,255,255,247,255,255,223,255,255,255,223,255,255,127,255,255,255,127,255,255,\n 255,253,255,255,255,253,255,255,247,15,0,0,0,0,0,0,255,255,255,255,255,255,255,255,\n 15,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,255,255,255,3,255,255,255,3,255,255,255,3,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0\n]);\n\n// size: 2976 bytes (compressed to ~2050 bytes after binaryen)\n// @ts-ignore: decorator\n@lazy @inline const CASE_IGNORABLES = memory.data([\n 18,16,19,20,21,22,23,24,25,26,27,28,29,30,31,32,\n 33,16,16,34,16,16,16,35,36,37,38,39,40,41,16,42,\n 43,16,16,16,16,16,16,16,16,16,16,16,44,45,46,16,\n 47,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 48,16,16,16,49,16,50,51,52,53,54,55,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,56,16,16,57,58,\n 16,59,60,61,16,16,16,16,16,16,62,16,16,63,64,65,\n 66,67,68,69,70,71,72,73,74,75,76,16,77,78,79,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,80,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,81,82,16,16,16,83,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,84,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,85,86,16,16,16,16,16,16,16,87,16,16,16,16,16,\n 88,89,90,16,16,16,16,16,91,92,16,16,16,16,16,16,\n 16,16,16,93,16,16,16,16,16,16,16,16,16,16,16,16,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,\n 255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,\n 0,0,0,0,128,64,0,4,0,0,0,64,1,0,0,0,0,0,0,0,0,161,144,1,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,\n 255,255,255,255,255,255,48,4,176,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,248,3,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,130,0,0,0,0,\n 0,0,254,255,255,255,255,191,182,0,0,0,0,0,16,0,63,0,255,23,0,0,0,0,\n 1,248,255,255,0,0,1,0,0,0,0,0,0,0,0,0,0,0,192,191,255,61,0,0,\n 0,128,2,0,0,0,255,255,255,7,0,0,0,0,0,0,0,0,0,0,192,255,1,0,\n 0,0,0,0,0,248,63,36,0,0,192,255,255,63,0,0,0,0,0,14,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,248,255,255,255,255,255,7,0,0,0,0,0,0,20,\n 254,33,254,0,12,0,2,0,2,0,0,0,0,0,0,16,30,32,0,0,12,0,0,64,\n 6,0,0,0,0,0,0,16,134,57,2,0,0,0,35,0,6,0,0,0,0,0,0,16,\n 190,33,0,0,12,0,0,252,2,0,0,0,0,0,0,144,30,32,96,0,12,0,0,0,\n 4,0,0,0,0,0,0,0,1,32,0,0,0,0,0,0,17,0,0,0,0,0,0,192,\n 193,61,96,0,12,0,0,0,2,0,0,0,0,0,0,144,64,48,0,0,12,0,0,0,\n 3,0,0,0,0,0,0,24,30,32,0,0,12,0,0,0,2,0,0,0,0,0,0,0,\n 0,4,92,0,0,0,0,0,0,0,0,0,0,0,242,7,192,127,0,0,0,0,0,0,\n 0,0,0,0,0,0,242,31,64,63,0,0,0,0,0,0,0,0,0,3,0,0,160,2,\n 0,0,0,0,0,0,254,127,223,224,255,254,255,255,255,31,64,0,0,0,0,0,0,0,\n 0,0,0,0,0,224,253,102,0,0,0,195,1,0,30,0,100,32,0,32,0,0,0,0,\n 0,0,0,0,0,0,0,16,0,0,0,0,0,0,0,0,0,0,0,224,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,28,0,0,0,28,0,\n 0,0,12,0,0,0,12,0,0,0,0,0,0,0,176,63,64,254,143,32,0,0,0,0,\n 0,120,0,0,0,0,0,0,8,0,0,0,0,0,0,0,96,0,0,0,0,2,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,135,1,4,14,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,128,9,0,0,0,0,\n 0,0,64,127,229,31,248,159,0,0,0,0,128,0,255,255,1,0,0,0,0,0,0,0,\n 15,0,0,0,0,0,208,23,4,0,0,0,0,248,15,0,3,0,0,0,60,59,0,0,\n 0,0,0,0,64,163,3,0,0,0,0,0,0,240,207,0,0,0,0,0,0,0,0,63,\n 0,0,0,0,0,0,0,0,0,0,247,255,253,33,16,3,0,0,0,0,0,240,255,255,\n 255,255,255,255,255,7,0,1,0,0,0,248,255,255,255,255,255,255,255,255,255,255,255,251,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,160,\n 3,224,0,224,0,224,0,96,0,248,0,3,144,124,0,0,0,0,0,0,223,255,2,128,\n 0,0,255,31,0,0,0,0,0,0,255,255,255,255,1,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,48,0,0,0,0,0,0,0,0,0,0,0,0,0,128,3,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,128,0,128,0,0,0,0,0,0,0,0,\n 0,0,0,0,255,255,255,255,0,0,0,0,0,128,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,32,0,0,0,0,60,62,8,\n 0,0,0,0,0,0,0,0,0,0,0,126,0,0,0,0,0,0,0,0,0,0,0,112,\n 0,0,32,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,63,0,16,0,0,0,0,0,0,\n 0,0,0,0,0,128,247,191,0,0,0,240,0,0,0,0,0,0,0,0,0,0,3,0,\n 255,255,255,255,3,0,0,0,0,0,0,0,0,0,1,0,0,7,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,3,68,8,0,0,96,16,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,48,0,0,0,255,255,3,128,0,0,0,0,192,63,0,0,\n 128,255,3,0,0,0,0,0,7,0,0,0,0,0,200,51,0,128,0,0,96,0,0,0,\n 0,0,0,0,0,126,102,0,8,16,0,0,0,0,1,16,0,0,0,0,0,0,157,193,\n 2,0,0,32,0,48,88,0,0,0,0,0,0,0,0,0,0,0,0,248,0,14,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,32,33,0,0,0,0,0,64,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,252,255,3,0,0,0,0,0,0,0,\n 255,255,8,0,255,255,0,0,0,0,36,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,128,128,64,0,4,0,0,0,64,1,0,0,0,0,0,1,0,\n 0,0,0,192,0,0,0,0,0,0,0,0,8,0,0,14,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,32,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,192,7,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,110,240,0,0,0,0,0,135,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,96,0,0,0,\n 0,0,0,0,240,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,24,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 192,255,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 2,0,0,0,0,0,0,255,127,0,0,0,0,0,0,128,3,0,0,0,0,0,120,38,\n 0,32,0,0,0,0,0,0,7,0,0,0,128,239,31,0,0,0,0,0,0,0,8,0,\n 3,0,0,0,0,0,192,127,0,158,0,0,0,0,0,0,0,0,0,0,0,128,211,64,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,128,248,7,0,0,\n 3,0,0,0,0,0,0,24,1,0,0,0,192,31,31,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,255,92,0,0,64,0,0,0,0,\n 0,0,0,0,0,0,248,133,13,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,60,176,1,0,0,48,0,0,0,0,\n 0,0,0,0,0,0,248,167,1,0,0,0,0,0,0,0,0,0,0,0,0,40,191,0,\n 0,0,0,0,0,0,0,0,0,0,0,224,188,15,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,128,255,6,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,88,8,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,240,12,1,0,0,0,254,7,0,0,0,0,248,121,128,0,126,14,0,0,0,0,\n 0,252,127,3,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,127,191,\n 0,0,0,0,0,0,0,0,0,0,252,255,255,252,109,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,126,180,191,0,0,0,0,0,0,0,0,0,163,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,24,0,0,0,0,0,0,0,255,1,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,31,0,0,0,0,0,0,0,127,0,15,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,128,0,0,0,0,0,0,0,128,255,255,0,0,0,0,0,0,0,0,27,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,96,15,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,128,3,248,255,\n 231,15,0,0,0,60,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 28,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 255,255,255,255,255,255,127,248,255,255,255,255,255,31,32,0,16,0,0,248,254,255,0,0,\n 0,0,0,0,0,0,0,0,127,255,255,249,219,7,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,255,63,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,240,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,127,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 240,15,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,248\n]);\n\n// @ts-ignore: decorator\n@lazy @inline const LOWER127 = memory.data([\n 0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,\n 16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,\n 32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,\n 48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,\n 64,\n 97,98,99,100,101,102,103,104,105,106,107,108,109,\n 110,111,112,113,114,115,116,117,118,119,120,121,122,\n 91,92,93,94,95,96,\n 97,98,99,100,101,102,103,104,105,106,107,108,109,\n 110,111,112,113,114,115,116,117,118,119,120,121,122,\n 123,124,125,126,127\n]);\n\n// @ts-ignore: decorator\n@lazy @inline const UPPER127 = memory.data([\n 0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,\n 16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,\n 32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,\n 48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,\n 64,\n 65,66,67,68,69,70,71,72,73,74,75,76,77,\n 78,79,80,81,82,83,84,85,86,87,88,89,90,\n 91,92,93,94,95,96,\n 65,66,67,68,69,70,71,72,73,74,75,76,77,\n 78,79,80,81,82,83,84,85,86,87,88,89,90,\n 123,124,125,126,127\n]);\n\n// 23 * 8 = 184 bytes\n// @ts-ignore: decorator\n@lazy @inline const POWERS10 = memory.data([\n 1e00, 1e01, 1e02, 1e03, 1e04, 1e05, 1e06, 1e07, 1e08, 1e09,\n 1e10, 1e11, 1e12, 1e13, 1e14, 1e15, 1e16, 1e17, 1e18, 1e19,\n 1e20, 1e21, 1e22\n]);\n\n// @ts-ignore: decorator\n@inline\nexport const enum CharCode {\n PERCENT = 0x25,\n PLUS = 0x2B,\n MINUS = 0x2D,\n DOT = 0x2E,\n _0 = 0x30,\n _1 = 0x31,\n _2 = 0x32,\n _3 = 0x33,\n _4 = 0x34,\n _5 = 0x35,\n _6 = 0x36,\n _7 = 0x37,\n _8 = 0x38,\n _9 = 0x39,\n A = 0x41,\n B = 0x42,\n E = 0x45,\n I = 0x49,\n N = 0x4E,\n O = 0x4F,\n X = 0x58,\n Z = 0x5A,\n a = 0x61,\n b = 0x62,\n e = 0x65,\n n = 0x6E,\n o = 0x6F,\n u = 0x75,\n x = 0x78,\n z = 0x7A\n}\n\n// @ts-ignore: decorator\n@inline\nexport function isAscii(c: u32): bool {\n return !(c >> 7);\n}\n\n// @ts-ignore: decorator\n@inline\nexport function isLower8(c: u32): bool {\n return c - CharCode.a < 26;\n}\n\n// @ts-ignore: decorator\n@inline\nexport function isUpper8(c: u32): bool {\n return c - CharCode.A < 26;\n}\n\nexport function isSpace(c: u32): bool {\n if (c < 0x1680) { // < (1)\n // , , , , , and \n // (c == 0x20 || c == 0xA0) was optimized to (c | 0x80) == 0xA0\n return ((c | 0x80) == 0xA0) || (c - 0x09 <= 0x0D - 0x09);\n }\n if (c - 0x2000 <= 0x200A - 0x2000) return true;\n switch (c) {\n case 0x1680: // (1)\n case 0x2028: // (2)\n case 0x2029: // \n case 0x202F: // \n case 0x205F: // \n case 0x3000: // \n case 0xFEFF: return true; // \n }\n return false;\n}\n\nexport function isAlpha(c: u32): bool {\n if (isAscii(c)) return (c | 32) - CharCode.a < 26;\n if (c < 0x20000) {\n // @ts-ignore: cast\n return stagedBinaryLookup(ALPHA_TABLE, c);\n }\n return c < 0x2FFFE;\n}\n\n// @ts-ignore: decorator\n@inline\nexport function isCased(c: u32): bool {\n // @ts-ignore: cast\n return c < 0x1F18A && stagedBinaryLookup(CASED, c);\n}\n\n// @ts-ignore: decorator\n@inline\nexport function isCaseIgnorable(c: u32): bool {\n // @ts-ignore: cast\n return c < 0xE01F0 && stagedBinaryLookup(CASE_IGNORABLES, c);\n}\n\n// @ts-ignore: decorator\n@inline\nexport function isFinalSigma(buffer: usize, index: isize, len: isize): bool {\n const lookaheadLimit = 30; // max lookahead limit\n var found = false;\n var pos = index;\n var minPos = max(0, pos - lookaheadLimit);\n while (pos > minPos) {\n let c = codePointBefore(buffer, pos);\n if (!isCaseIgnorable(c)) {\n if (isCased(c)) {\n found = true;\n } else {\n return false;\n }\n }\n pos -= isize(c >= 0x10000) + 1;\n }\n if (!found) return false;\n pos = index + 1;\n var maxPos = min(pos + lookaheadLimit, len);\n while (pos < maxPos) {\n let c = load(buffer + (pos << 1));\n if (u32((c & 0xFC00) == 0xD800) & u32(pos + 1 != len)) {\n let c1 = load(buffer + (pos << 1), 2);\n if ((c1 & 0xFC00) == 0xDC00) {\n c = (c - 0xD800 << 10) + (c1 - 0xDC00) + 0x10000;\n }\n }\n if (!isCaseIgnorable(c)) {\n return !isCased(c);\n }\n pos += isize(c >= 0x10000) + 1;\n }\n return true;\n}\n\n// @ts-ignore: decorator\n@inline\nfunction codePointBefore(buffer: usize, index: isize): i32 {\n if (index <= 0) return -1;\n var c = load(buffer + (index - 1 << 1));\n if (u32((c & 0xFC00) == 0xDC00) & u32(index - 2 >= 0)) {\n let c1 = load(buffer + (index - 2 << 1));\n if ((c1 & 0xFC00) == 0xD800) {\n return ((c1 & 0x3FF) << 10) + (c & 0x3FF) + 0x10000;\n }\n }\n return (c & 0xF800) == 0xD800 ? 0xFFFD : c;\n}\n\n// Search routine for two-staged lookup tables\nfunction stagedBinaryLookup(table: usize, c: u32): bool {\n return ((load(table + (load(table + (c >>> 8)) << 5) + ((c & 255) >> 3)) >>> (c & 7)) & 1);\n}\n\nexport function compareImpl(str1: string, index1: usize, str2: string, index2: usize, len: usize): i32 {\n var ptr1 = changetype(str1) + (index1 << 1);\n var ptr2 = changetype(str2) + (index2 << 1);\n if (ASC_SHRINK_LEVEL < 2) {\n if (len >= 4 && !((ptr1 & 7) | (ptr2 & 7))) {\n do {\n if (load(ptr1) != load(ptr2)) break;\n ptr1 += 8;\n ptr2 += 8;\n len -= 4;\n } while (len >= 4);\n }\n }\n while (len--) {\n let a = load(ptr1);\n let b = load(ptr2);\n if (a != b) return a - b;\n ptr1 += 2;\n ptr2 += 2;\n }\n return 0;\n}\n\n// @ts-ignore: decorator\n@inline\nexport function toLower8(c: u32): u32 {\n if (ASC_SHRINK_LEVEL > 0) {\n return c | u32(isUpper8(c)) << 5;\n } else {\n return load(LOWER127 + c);\n }\n}\n\n// @ts-ignore: decorator\n@inline\nexport function toUpper8(c: u32): u32 {\n if (ASC_SHRINK_LEVEL > 0) {\n return c & ~(u32(isLower8(c)) << 5);\n } else {\n return load(UPPER127 + c);\n }\n}\n\n/** Parses a string to an integer (usually), using the specified radix. */\nexport function strtol(str: string, radix: i32 = 0): T {\n var len = str.length;\n if (!len) {\n if (isFloat()) {\n // @ts-ignore: cast\n return NaN;\n } else {\n // @ts-ignore: cast\n return 0;\n }\n }\n\n var ptr = changetype(str) /* + HEAD -> offset */;\n var code = load(ptr);\n\n // trim white spaces\n while (isSpace(code)) {\n code = load(ptr += 2);\n --len;\n }\n // determine sign\n // @ts-ignore\n var sign: T = 1;\n if (code == CharCode.MINUS || code == CharCode.PLUS) {\n if (!--len) {\n if (isFloat()) {\n // @ts-ignore: cast\n return NaN;\n } else {\n // @ts-ignore: cast\n return 0;\n }\n }\n if (code == CharCode.MINUS) {\n // @ts-ignore: type\n sign = -1;\n }\n code = load(ptr += 2);\n }\n\n // See https://tc39.es/ecma262/#sec-parseint-string-radix\n if (radix) {\n if (radix < 2 || radix > 36) {\n if (isFloat()) {\n // @ts-ignore: cast\n return NaN;\n } else {\n // @ts-ignore: cast\n return 0;\n }\n }\n // handle case as parseInt(\"0xFF\", 16) by spec\n if (radix == 16) {\n if (\n len > 2 &&\n code == CharCode._0 &&\n (load(ptr, 2) | 32) == CharCode.x\n ) {\n ptr += 4; len -= 2;\n }\n }\n } else {\n // determine radix by literal prefix\n if (code == CharCode._0 && len > 2) {\n switch (load(ptr, 2) | 32) {\n case CharCode.b: {\n ptr += 4; len -= 2;\n radix = 2;\n break;\n }\n case CharCode.o: {\n ptr += 4; len -= 2;\n radix = 8;\n break;\n }\n case CharCode.x: {\n ptr += 4; len -= 2;\n radix = 16;\n break;\n }\n }\n }\n if (!radix) radix = 10;\n }\n\n // calculate value\n // @ts-ignore: type\n var num: T = 0;\n var initial = len - 1;\n while (len--) {\n code = load(ptr);\n if (code - CharCode._0 < 10) {\n code -= CharCode._0;\n } else if (code - CharCode.A <= (CharCode.Z - CharCode.A)) {\n code -= CharCode.A - 10;\n } else if (code - CharCode.a <= (CharCode.z - CharCode.a)) {\n code -= CharCode.a - 10;\n }\n if (code >= radix) {\n if (initial == len) {\n if (isFloat()) {\n // @ts-ignore: cast\n return NaN;\n } else {\n // @ts-ignore: cast\n return 0;\n }\n }\n break;\n }\n // @ts-ignore: type\n num = num * radix + code;\n ptr += 2;\n }\n // @ts-ignore: type\n return sign * num;\n}\n\nexport function strtod(str: string): f64 {\n var len = str.length;\n if (!len) return NaN;\n\n var ptr = changetype(str);\n var code = load(ptr);\n\n var sign = 1.0;\n // skip white spaces\n while (len && isSpace(code)) {\n code = load(ptr += 2);\n --len;\n }\n if (!len) return NaN;\n\n // try parse '-' or '+'\n if (code == CharCode.MINUS) {\n if (!--len) return NaN;\n code = load(ptr += 2);\n sign = -1;\n } else if (code == CharCode.PLUS) {\n if (!--len) return NaN;\n code = load(ptr += 2);\n }\n\n // try parse Infinity\n if (len >= 8 && code == CharCode.I) {\n if (\n load(ptr, 0) == 0x690066006E0049 && // ifnI\n load(ptr, 8) == 0x7900740069006E // ytin\n ) {\n return Infinity * sign;\n }\n return NaN;\n }\n // validate next symbol\n if (code != CharCode.DOT && (code - CharCode._0) >= 10) {\n return NaN;\n }\n var savedPtr = ptr;\n // skip zeros\n while (code == CharCode._0) {\n code = load(ptr += 2);\n --len;\n }\n if (len <= 0) return 0;\n const capacity = 19; // int(64 * 0.3010)\n var pointed = false;\n var consumed = 0;\n var position = 0;\n var x: u64 = 0;\n if (code == CharCode.DOT) {\n let noDigits = !(savedPtr - ptr);\n ptr += 2; --len;\n if (!len && noDigits) return NaN;\n for (pointed = true; (code = load(ptr)) == CharCode._0; --position, ptr += 2) --len;\n if (len <= 0) return 0;\n if (!position && noDigits && code - CharCode._0 >= 10) return NaN;\n }\n for (let digit = code - CharCode._0; digit < 10 || (code == CharCode.DOT && !pointed); digit = code - CharCode._0) {\n if (digit < 10) {\n x = consumed < capacity ? 10 * x + digit : x | u64(!!digit);\n ++consumed;\n } else {\n position = consumed;\n pointed = true;\n }\n if (!--len) break;\n code = load(ptr += 2);\n }\n\n if (!pointed) position = consumed;\n return copysign(scientific(x, position - min(capacity, consumed) + parseExp(ptr, len)), sign);\n}\n\nexport function strtob(str: string): bool {\n var size: usize = str.length << 1;\n var offset: usize = 0;\n if (size > 8) {\n // try trim end whitespaces first\n while (size && isSpace(load(changetype(str) + size - 2))) size -= 2;\n if (size > 8) {\n // trim start whitespaces\n while (offset < size && isSpace(load(changetype(str) + offset))) offset += 2;\n size -= offset;\n }\n }\n if (size != 8) return false;\n // \"true\" represents as \\00\\e\\00\\u\\00\\e\\00\\t (00 65 00 75 00 72 00 74)\n return load(changetype(str) + offset) == 0x0065_0075_0072_0074;\n}\n\nexport function joinBooleanArray(dataStart: usize, length: i32, separator: string): string {\n var lastIndex = length - 1;\n if (lastIndex < 0) return \"\";\n if (!lastIndex) return select(\"true\", \"false\", load(dataStart));\n\n var sepLen = separator.length;\n var valueLen = 5; // max possible length of element len(\"false\")\n var estLen = (valueLen + sepLen) * lastIndex + valueLen;\n var result = changetype(__new(estLen << 1, idof()));\n var offset = 0;\n var value: bool;\n for (let i = 0; i < lastIndex; ++i) {\n value = load(dataStart + i);\n valueLen = 4 + i32(!value);\n memory.copy(\n changetype(result) + (offset << 1),\n changetype(select(\"true\", \"false\", value)),\n valueLen << 1\n );\n offset += valueLen;\n if (sepLen) {\n memory.copy(\n changetype(result) + (offset << 1),\n changetype(separator),\n sepLen << 1\n );\n offset += sepLen;\n }\n }\n value = load(dataStart + lastIndex);\n valueLen = 4 + i32(!value);\n memory.copy(\n changetype(result) + (offset << 1),\n changetype(select(\"true\", \"false\", value)),\n valueLen << 1\n );\n offset += valueLen;\n\n if (estLen > offset) return result.substring(0, offset);\n return result;\n}\n\nexport function joinIntegerArray(dataStart: usize, length: i32, separator: string): string {\n var lastIndex = length - 1;\n if (lastIndex < 0) return \"\";\n if (!lastIndex) {\n let value = load(dataStart);\n if (isSigned()) {\n if (sizeof() <= 4) {\n // @ts-ignore: type\n return changetype(itoa32(value, 10));\n } else {\n // @ts-ignore: type\n return changetype(itoa64(value, 10));\n }\n } else {\n if (sizeof() <= 4) {\n // @ts-ignore: type\n return changetype(utoa32(value, 10));\n } else {\n // @ts-ignore: type\n return changetype(utoa64(value, 10));\n }\n }\n }\n\n var sepLen = separator.length;\n const valueLen = (sizeof() <= 4 ? 10 : 20) + i32(isSigned());\n var estLen = (valueLen + sepLen) * lastIndex + valueLen;\n var result = changetype(__new(estLen << 1, idof()));\n var offset = 0;\n var value: T;\n for (let i = 0; i < lastIndex; ++i) {\n value = load(dataStart + (i << alignof()));\n // @ts-ignore: type\n offset += itoa_buffered(changetype(result) + (offset << 1), value);\n if (sepLen) {\n memory.copy(\n changetype(result) + (offset << 1),\n changetype(separator),\n sepLen << 1\n );\n offset += sepLen;\n }\n }\n value = load(dataStart + (lastIndex << alignof()));\n // @ts-ignore: type\n offset += itoa_buffered(changetype(result) + (offset << 1), value);\n if (estLen > offset) return result.substring(0, offset);\n return result;\n}\n\nexport function joinFloatArray(dataStart: usize, length: i32, separator: string): string {\n var lastIndex = length - 1;\n if (lastIndex < 0) return \"\";\n if (!lastIndex) {\n return changetype(dtoa(\n // @ts-ignore: type\n load(dataStart))\n );\n }\n\n const valueLen = MAX_DOUBLE_LENGTH;\n var sepLen = separator.length;\n var estLen = (valueLen + sepLen) * lastIndex + valueLen;\n var result = changetype(__new(estLen << 1, idof()));\n var offset = 0;\n var value: T;\n for (let i = 0; i < lastIndex; ++i) {\n value = load(dataStart + (i << alignof()));\n // @ts-ignore: type\n offset += dtoa_buffered(changetype(result) + (offset << 1), value);\n if (sepLen) {\n memory.copy(\n changetype(result) + (offset << 1),\n changetype(separator),\n sepLen << 1\n );\n offset += sepLen;\n }\n }\n value = load(dataStart + (lastIndex << alignof()));\n // @ts-ignore: type\n offset += dtoa_buffered(changetype(result) + (offset << 1), value);\n if (estLen > offset) return result.substring(0, offset);\n return result;\n}\n\nexport function joinStringArray(dataStart: usize, length: i32, separator: string): string {\n var lastIndex = length - 1;\n if (lastIndex < 0) return \"\";\n if (!lastIndex) {\n // @ts-ignore: type\n return load(dataStart) || \"\";\n }\n var estLen = 0;\n var value: string;\n for (let i = 0; i < length; ++i) {\n value = load(dataStart + (i << alignof()));\n if (changetype(value) != 0) estLen += value.length;\n }\n var offset = 0;\n var sepLen = separator.length;\n var result = changetype(__new((estLen + sepLen * lastIndex) << 1, idof()));\n for (let i = 0; i < lastIndex; ++i) {\n value = load(dataStart + (i << alignof()));\n if (changetype(value) != 0) {\n let valueLen = value.length;\n memory.copy(\n changetype(result) + (offset << 1),\n changetype(value),\n valueLen << 1\n );\n offset += valueLen;\n }\n if (sepLen) {\n memory.copy(\n changetype(result) + (offset << 1),\n changetype(separator),\n sepLen << 1\n );\n offset += sepLen;\n }\n }\n value = load(dataStart + (lastIndex << alignof()));\n if (changetype(value) != 0) {\n memory.copy(\n changetype(result) + (offset << 1),\n changetype(value),\n value.length << 1\n );\n }\n return result;\n}\n\nexport function joinReferenceArray(dataStart: usize, length: i32, separator: string): string {\n var lastIndex = length - 1;\n if (lastIndex < 0) return \"\";\n var value: T;\n if (!lastIndex) {\n value = load(dataStart);\n // @ts-ignore: type\n return value != null ? value.toString() : \"\";\n }\n var result = \"\";\n var sepLen = separator.length;\n for (let i = 0; i < lastIndex; ++i) {\n value = load(dataStart + (i << alignof()));\n // @ts-ignore: type\n if (value != null) result += value.toString();\n if (sepLen) result += separator;\n }\n value = load(dataStart + (lastIndex << alignof()));\n // @ts-ignore: type\n if (value != null) result += value.toString();\n return result;\n}\n\n// @ts-ignore: decorator\n@inline\nfunction scientific(significand: u64, exp: i32): f64 {\n if (!significand || exp < -342) return 0;\n if (exp > 308) return Infinity;\n // Try use fast path\n // Use fast path for string-to-double conversion if possible\n // see http://www.exploringbinary.com/fast-path-decimal-to-floating-point-conversion\n // Simple integer\n var significandf = significand;\n if (!exp) return significandf;\n if (exp > 22 && exp <= 22 + 15) {\n significandf *= pow10(exp - 22);\n exp = 22;\n }\n if (significand <= 9007199254740991 && abs(exp) <= 22) {\n if (exp > 0) return significandf * pow10(exp);\n return significandf / pow10(-exp);\n } else if (exp < 0) {\n return scaledown(significand, exp);\n } else {\n return scaleup(significand, exp);\n }\n}\n\n// Adopted from metallic lib:\n// https://github.com/jdh8/metallic/blob/master/src/stdlib/parse/scientific.h\n// @ts-ignore: decorator\n@inline\nfunction scaledown(significand: u64, exp: i32): f64 {\n const denom: u64 = 6103515625; // 1e14 * 0x1p-14\n const scale = reinterpret(0x3F06849B86A12B9B); // 1e-14 * 0x1p32\n\n var shift = clz(significand);\n significand <<= shift;\n shift = exp - shift;\n\n for (; exp <= -14; exp += 14) {\n let q = significand / denom;\n let r = significand % denom;\n let s = clz(q);\n significand = (q << s) + nearest(scale * (r << (s - 18)));\n shift -= s;\n }\n var b = ipow32(5, -exp);\n var q = significand / b;\n var r = significand % b;\n var s = clz(q);\n significand = (q << s) + (reinterpret(reinterpret(r) + (s << 52)) / b);\n shift -= s;\n\n return NativeMath.scalbn(significand, shift);\n}\n\n// Adopted from metallic lib:\n// https://github.com/jdh8/metallic/blob/master/src/stdlib/parse/scientific.h\n// @ts-ignore: decorator\n@inline\nfunction scaleup(significand: u64, exp: i32): f64 {\n const coeff: u32 = 1220703125; // 1e13 * 0x1p-13;\n var shift = ctz(significand);\n significand >>= shift;\n shift += exp;\n\n __fixmulShift = shift;\n for (; exp >= 13; exp -= 13) {\n significand = fixmul(significand, coeff);\n }\n significand = fixmul(significand, ipow32(5, exp));\n shift = __fixmulShift;\n return NativeMath.scalbn(significand, shift);\n}\n\n// Adopted from metallic lib:\n// https://github.com/jdh8/metallic/blob/master/src/stdlib/parse/scientific.h\n// @ts-ignore: decorator\n@inline\nfunction parseExp(ptr: usize, len: i32): i32 {\n var sign = 1, magnitude = 0;\n var code = load(ptr);\n // check code is 'e' or 'E'\n if ((code | 32) != CharCode.e) return 0;\n\n if (!--len) return 0;\n code = load(ptr += 2);\n if (code == CharCode.MINUS) {\n if (!--len) return 0;\n code = load(ptr += 2);\n sign = -1;\n } else if (code == CharCode.PLUS) {\n if (!--len) return 0;\n code = load(ptr += 2);\n }\n // skip zeros\n while (code == CharCode._0) {\n if (!--len) return 0;\n code = load(ptr += 2);\n }\n for (let digit: u32 = code - CharCode._0; len && digit < 10; digit = code - CharCode._0) {\n if (magnitude >= 3200) return sign * 3200;\n magnitude = 10 * magnitude + digit;\n code = load(ptr += 2);\n --len;\n }\n return sign * magnitude;\n}\n\n// @ts-ignore: decorator\n@lazy var __fixmulShift: u64 = 0;\n\n// Adopted from metallic lib:\n// https://github.com/jdh8/metallic/blob/master/src/stdlib/parse/scientific.h\n// @ts-ignore: decorator\n@inline\nfunction fixmul(a: u64, b: u32): u64 {\n var low = (a & 0xFFFFFFFF) * b;\n var high = (a >> 32) * b + (low >> 32);\n var overflow = (high >> 32);\n var space = clz(overflow);\n var revspace: u64 = 32 - space;\n __fixmulShift += revspace;\n return (high << space | (low & 0xFFFFFFFF) >> revspace) + (low << space >> 31 & 1);\n}\n\n// @ts-ignore: decorator\n@inline\nfunction pow10(n: i32): f64 {\n // argument `n` should bounds in [0, 22] range\n return load(POWERS10 + (n << alignof()));\n}\n","import { Math as JSMath } from \"./bindings/dom\";\nexport { JSMath };\n\nimport {\n pow_lut, exp_lut, exp2_lut, log_lut, log2_lut,\n powf_lut, expf_lut, exp2f_lut, logf_lut, log2f_lut\n} from \"./util/math\";\n\nimport {\n abs as builtin_abs,\n ceil as builtin_ceil,\n clz as builtin_clz,\n copysign as builtin_copysign,\n floor as builtin_floor,\n max as builtin_max,\n min as builtin_min,\n sqrt as builtin_sqrt,\n trunc as builtin_trunc\n} from \"./builtins\";\n\n// SUN COPYRIGHT NOTICE\n//\n// Copyright (C) 1993 by Sun Microsystems, Inc. All rights reserved.\n// Developed at SunPro, a Sun Microsystems, Inc. business.\n// Permission to use, copy, modify, and distribute this software\n// is freely granted, provided that this notice is preserved.\n//\n// Applies to all functions marked with a comment referring here.\n\n/** @internal */\n// @ts-ignore: decorator\n@lazy var rempio2_y0: f64, rempio2_y1: f64, res128_hi: u64;\n\n/** @internal */\n// @ts-ignore: decorator\n@lazy @inline const PIO2_TABLE = memory.data([\n 0x00000000A2F9836E, 0x4E441529FC2757D1, 0xF534DDC0DB629599, 0x3C439041FE5163AB,\n 0xDEBBC561B7246E3A, 0x424DD2E006492EEA, 0x09D1921CFE1DEB1C, 0xB129A73EE88235F5,\n 0x2EBB4484E99C7026, 0xB45F7E413991D639, 0x835339F49C845F8B, 0xBDF9283B1FF897FF,\n 0xDE05980FEF2F118B, 0x5A0A6D1F6D367ECF, 0x27CB09B74F463F66, 0x9E5FEA2D7527BAC7,\n 0xEBE5F17B3D0739F7, 0x8A5292EA6BFB5FB1, 0x1F8D5D0856033046, 0xFC7B6BABF0CFBC20,\n 0x9AF4361DA9E39161, 0x5EE61B086599855F, 0x14A068408DFFD880, 0x4D73273106061557\n]);\n\n/** @internal */\nfunction R(z: f64): f64 { // Rational approximation of (asin(x)-x)/x^3\n const // see: musl/src/math/asin.c and SUN COPYRIGHT NOTICE above\n pS0 = reinterpret(0x3FC5555555555555), // 1.66666666666666657415e-01\n pS1 = reinterpret(0xBFD4D61203EB6F7D), // -3.25565818622400915405e-01\n pS2 = reinterpret(0x3FC9C1550E884455), // 2.01212532134862925881e-01\n pS3 = reinterpret(0xBFA48228B5688F3B), // -4.00555345006794114027e-02\n pS4 = reinterpret(0x3F49EFE07501B288), // 7.91534994289814532176e-04\n pS5 = reinterpret(0x3F023DE10DFDF709), // 3.47933107596021167570e-05\n qS1 = reinterpret(0xC0033A271C8A2D4B), // -2.40339491173441421878e+00\n qS2 = reinterpret(0x40002AE59C598AC8), // 2.02094576023350569471e+00\n qS3 = reinterpret(0xBFE6066C1B8D0159), // -6.88283971605453293030e-01\n qS4 = reinterpret(0x3FB3B8C5B12E9282); // 7.70381505559019352791e-02\n\n var p = z * (pS0 + z * (pS1 + z * (pS2 + z * (pS3 + z * (pS4 + z * pS5)))));\n var q = 1.0 + z * (qS1 + z * (qS2 + z * (qS3 + z * qS4)));\n return p / q;\n}\n\n/** @internal */\n// @ts-ignore: decorator\n@inline\nfunction expo2(x: f64, sign: f64): f64 { // exp(x)/2 for x >= log(DBL_MAX)\n const // see: musl/src/math/__expo2.c\n k = 2043,\n kln2 = reinterpret(0x40962066151ADD8B); // 0x1.62066151add8bp+10\n var scale = reinterpret(((0x3FF + k / 2) << 20) << 32);\n // in directed rounding correct sign before rounding or overflow is important\n return NativeMath.exp(x - kln2) * (sign * scale) * scale;\n}\n\n/** @internal */\n/* Helper function to eventually get bits of π/2 * |x|\n *\n * y = π/4 * (frac << clz(frac) >> 11)\n * return clz(frac)\n *\n * Right shift 11 bits to make upper half fit in `double`\n */\n// @ts-ignore: decorator\n@inline\nfunction pio2_right(q0: u64, q1: u64): u64 { // see: jdh8/metallic/blob/master/src/math/double/rem_pio2.c\n // Bits of π/4\n const p0: u64 = 0xC4C6628B80DC1CD1;\n const p1: u64 = 0xC90FDAA22168C234;\n\n const Ox1p_64 = reinterpret(0x3BF0000000000000); // 0x1p-64\n const Ox1p_75 = reinterpret(0x3B40000000000000); // 0x1p-75\n\n var shift = clz(q1);\n\n q1 = q1 << shift | q0 >> (64 - shift);\n q0 <<= shift;\n\n var lo = umuldi(p1, q1);\n var hi = res128_hi;\n\n var ahi = hi >> 11;\n var alo = lo >> 11 | hi << 53;\n var blo = (Ox1p_75 * p0 * q1 + Ox1p_75 * p1 * q0);\n\n rempio2_y0 = (ahi + u64(lo < blo));\n rempio2_y1 = Ox1p_64 * (alo + blo);\n\n return shift;\n}\n\n/** @internal */\n// @ts-ignore: decorator\n@inline\nfunction umuldi(u: u64, v: u64): u64 {\n var u1: u64 , v1: u64, w0: u64, w1: u64, t: u64;\n\n u1 = u & 0xFFFFFFFF;\n v1 = v & 0xFFFFFFFF;\n\n u >>= 32;\n v >>= 32;\n\n t = u1 * v1;\n w0 = t & 0xFFFFFFFF;\n t = u * v1 + (t >> 32);\n w1 = t >> 32;\n t = u1 * v + (t & 0xFFFFFFFF);\n\n res128_hi = u * v + w1 + (t >> 32);\n return (t << 32) + w0;\n}\n\n/** @internal */\nfunction pio2_large_quot(x: f64, u: i64): i32 { // see: jdh8/metallic/blob/master/src/math/double/rem_pio2.c\n var magnitude = u & 0x7FFFFFFFFFFFFFFF;\n var offset = (magnitude >> 52) - 1045;\n var shift = offset & 63;\n var tblPtr = PIO2_TABLE + ((offset >> 6) << 3);\n var s0: u64, s1: u64, s2: u64;\n\n var b0 = load(tblPtr, 0 << 3);\n var b1 = load(tblPtr, 1 << 3);\n var b2 = load(tblPtr, 2 << 3);\n\n // Get 192 bits of 0x1p-31 / π with `offset` bits skipped\n if (shift) {\n let rshift = 64 - shift;\n let b3 = load(tblPtr, 3 << 3);\n s0 = b1 >> rshift | b0 << shift;\n s1 = b2 >> rshift | b1 << shift;\n s2 = b3 >> rshift | b2 << shift;\n } else {\n s0 = b0;\n s1 = b1;\n s2 = b2;\n }\n\n var significand = (u & 0x000FFFFFFFFFFFFF) | 0x0010000000000000;\n\n // First 128 bits of fractional part of x/(2π)\n var blo = umuldi(s1, significand);\n var bhi = res128_hi;\n\n var ahi = s0 * significand;\n var clo = (s2 >> 32) * (significand >> 32);\n var plo = blo + clo;\n var phi = ahi + bhi + u64(plo < clo);\n\n // r: u128 = p << 2\n var rlo = plo << 2;\n var rhi = phi << 2 | plo >> 62;\n\n // s: i128 = r >> 127\n var slo = rhi >> 63;\n var shi = slo >> 1;\n var q = (phi >> 62) - slo;\n\n var shifter = 0x3CB0000000000000 - (pio2_right(rlo ^ slo, rhi ^ shi) << 52);\n var signbit = (u ^ rhi) & 0x8000000000000000;\n var coeff = reinterpret(shifter | signbit);\n\n rempio2_y0 *= coeff;\n rempio2_y1 *= coeff;\n\n return q;\n}\n\n/** @internal */\n// @ts-ignore: decorator\n@inline\nfunction rempio2(x: f64, u: u64, sign: i32): i32 {\n const\n pio2_1 = reinterpret(0x3FF921FB54400000), // 1.57079632673412561417e+00\n pio2_1t = reinterpret(0x3DD0B4611A626331), // 6.07710050650619224932e-11\n pio2_2 = reinterpret(0x3DD0B4611A600000), // 6.07710050630396597660e-11\n pio2_2t = reinterpret(0x3BA3198A2E037073), // 2.02226624879595063154e-21\n pio2_3 = reinterpret(0x3BA3198A2E000000), // 2.02226624871116645580e-21\n pio2_3t = reinterpret(0x397B839A252049C1), // 8.47842766036889956997e-32\n invpio2 = reinterpret(0x3FE45F306DC9C883); // 0.63661977236758134308\n\n var ix = (u >> 32) & 0x7FFFFFFF;\n\n if (ASC_SHRINK_LEVEL < 1) {\n if (ix < 0x4002D97C) { // |x| < 3pi/4, special case with n=+-1\n let q = 1, z: f64, y0: f64, y1: f64;\n if (!sign) {\n z = x - pio2_1;\n if (ix != 0x3FF921FB) { // 33+53 bit pi is good enough\n y0 = z - pio2_1t;\n y1 = (z - y0) - pio2_1t;\n } else { // near pi/2, use 33+33+53 bit pi\n z -= pio2_2;\n y0 = z - pio2_2t;\n y1 = (z - y0) - pio2_2t;\n }\n } else { // negative x\n z = x + pio2_1;\n if (ix != 0x3FF921FB) { // 33+53 bit pi is good enough\n y0 = z + pio2_1t;\n y1 = (z - y0) + pio2_1t;\n } else { // near pi/2, use 33+33+53 bit pi\n z += pio2_2;\n y0 = z + pio2_2t;\n y1 = (z - y0) + pio2_2t;\n }\n q = -1;\n }\n rempio2_y0 = y0;\n rempio2_y1 = y1;\n return q;\n }\n }\n\n if (ix < 0x413921FB) { // |x| ~< 2^20*pi/2 (1647099)\n // Use precise Cody Waite scheme\n let q = nearest(x * invpio2);\n let r = x - q * pio2_1;\n let w = q * pio2_1t; // 1st round good to 85 bit\n let j = ix >> 20;\n let y0 = r - w;\n let hi = (reinterpret(y0) >> 32);\n let i = j - ((hi >> 20) & 0x7FF);\n\n if (i > 16) { // 2nd iteration needed, good to 118\n let t = r;\n w = q * pio2_2;\n r = t - w;\n w = q * pio2_2t - ((t - r) - w);\n y0 = r - w;\n hi = (reinterpret(y0) >> 32);\n i = j - ((hi >> 20) & 0x7FF);\n if (i > 49) { // 3rd iteration need, 151 bits acc\n let t = r;\n w = q * pio2_3;\n r = t - w;\n w = q * pio2_3t - ((t - r) - w);\n y0 = r - w;\n }\n }\n let y1 = (r - y0) - w;\n rempio2_y0 = y0;\n rempio2_y1 = y1;\n return q;\n }\n var q = pio2_large_quot(x, u);\n return select(-q, q, sign);\n}\n\n/** @internal */\n// @ts-ignore: decorator\n@inline\nfunction sin_kern(x: f64, y: f64, iy: i32): f64 { // see: musl/tree/src/math/__sin.c\n const\n S1 = reinterpret(0xBFC5555555555549), // -1.66666666666666324348e-01\n S2 = reinterpret(0x3F8111111110F8A6), // 8.33333333332248946124e-03\n S3 = reinterpret(0xBF2A01A019C161D5), // -1.98412698298579493134e-04\n S4 = reinterpret(0x3EC71DE357B1FE7D), // 2.75573137070700676789e-06\n S5 = reinterpret(0xBE5AE5E68A2B9CEB), // -2.50507602534068634195e-08\n S6 = reinterpret(0x3DE5D93A5ACFD57C); // 1.58969099521155010221e-10\n\n var z = x * x;\n var w = z * z;\n var r = S2 + z * (S3 + z * S4) + z * w * (S5 + z * S6);\n var v = z * x;\n if (!iy) {\n return x + v * (S1 + z * r);\n } else {\n return x - ((z * (0.5 * y - v * r) - y) - v * S1);\n }\n}\n\n/** @internal */\n// @ts-ignore: decorator\n@inline\nfunction cos_kern(x: f64, y: f64): f64 { // see: musl/tree/src/math/__cos.c\n const\n C1 = reinterpret(0x3FA555555555554C), // 4.16666666666666019037e-02\n C2 = reinterpret(0xBF56C16C16C15177), // -1.38888888888741095749e-03\n C3 = reinterpret(0x3EFA01A019CB1590), // 2.48015872894767294178e-05\n C4 = reinterpret(0xBE927E4F809C52AD), // -2.75573143513906633035e-07\n C5 = reinterpret(0x3E21EE9EBDB4B1C4), // 2.08757232129817482790e-09\n C6 = reinterpret(0xBDA8FAE9BE8838D4); // -1.13596475577881948265e-11\n\n var z = x * x;\n var w = z * z;\n var r = z * (C1 + z * (C2 + z * C3)) + w * w * (C4 + z * (C5 + z * C6));\n var hz = 0.5 * z;\n w = 1.0 - hz;\n return w + (((1.0 - w) - hz) + (z * r - x * y));\n}\n\n/** @internal */\nfunction tan_kern(x: f64, y: f64, iy: i32): f64 { // see: src/lib/msun/src/k_tan.c\n const\n T0 = reinterpret(0x3FD5555555555563), // 3.33333333333334091986e-01\n T1 = reinterpret(0x3FC111111110FE7A), // 1.33333333333201242699e-01\n T2 = reinterpret(0x3FABA1BA1BB341FE), // 5.39682539762260521377e-02\n T3 = reinterpret(0x3F9664F48406D637), // 2.18694882948595424599e-02\n T4 = reinterpret(0x3F8226E3E96E8493), // 8.86323982359930005737e-03\n T5 = reinterpret(0x3F6D6D22C9560328), // 3.59207910759131235356e-03\n T6 = reinterpret(0x3F57DBC8FEE08315), // 1.45620945432529025516e-03\n T7 = reinterpret(0x3F4344D8F2F26501), // 5.88041240820264096874e-04\n T8 = reinterpret(0x3F3026F71A8D1068), // 2.46463134818469906812e-04\n T9 = reinterpret(0x3F147E88A03792A6), // 7.81794442939557092300e-05\n T10 = reinterpret(0x3F12B80F32F0A7E9), // 7.14072491382608190305e-05\n T11 = reinterpret(0xBEF375CBDB605373), // -1.85586374855275456654e-05\n T12 = reinterpret(0x3EFB2A7074BF7AD4); // 2.59073051863633712884e-05\n\n const\n one = reinterpret(0x3FF0000000000000), // 1.00000000000000000000e+00\n pio4 = reinterpret(0x3FE921FB54442D18), // 7.85398163397448278999e-01\n pio4lo = reinterpret(0x3C81A62633145C07); // 3.06161699786838301793e-17\n\n var z: f64, r: f64, v: f64, w: f64, s: f64;\n var hx = (reinterpret(x) >> 32); // high word of x\n var ix = hx & 0x7FFFFFFF; // high word of |x|\n var big = ix >= 0x3FE59428;\n if (big) { // |x| >= 0.6744\n if (hx < 0) { x = -x, y = -y; }\n z = pio4 - x;\n w = pio4lo - y;\n x = z + w;\n y = 0.0;\n }\n z = x * x;\n w = z * z;\n r = T1 + w * (T3 + w * (T5 + w * (T7 + w * (T9 + w * T11))));\n v = z * (T2 + w * (T4 + w * (T6 + w * (T8 + w * (T10 + w * T12)))));\n s = z * x;\n r = y + z * (s * (r + v) + y);\n r += T0 * s;\n w = x + r;\n if (big) {\n v = iy;\n return (1 - ((hx >> 30) & 2)) * (v - 2.0 * (x - (w * w / (w + v) - r)));\n }\n if (iy == 1) return w;\n var a: f64, t: f64;\n z = w;\n z = reinterpret(reinterpret(z) & 0xFFFFFFFF00000000);\n v = r - (z - x); // z + v = r + x\n t = a = -one / w; // a = -1.0 / w\n t = reinterpret(reinterpret(t) & 0xFFFFFFFF00000000);\n s = one + t * z;\n return t + a * (s + t * v);\n}\n\n/** @internal */\nfunction dtoi32(x: f64): i32 {\n if (ASC_SHRINK_LEVEL > 0) {\n const inv32 = 1.0 / 4294967296;\n return (x - 4294967296 * floor(x * inv32));\n } else {\n let result = 0;\n let u = reinterpret(x);\n let e = (u >> 52) & 0x7FF;\n if (e <= 1023 + 30) {\n result = x;\n } else if (e <= 1023 + 30 + 53) {\n let v = (u & ((1 << 52) - 1)) | (1 << 52);\n v = v << e - 1023 - 52 + 32;\n result = (v >> 32);\n result = select(-result, result, u < 0);\n }\n return result;\n }\n}\n\n// @ts-ignore: decorator\n@lazy var random_seeded = false;\n\n// @ts-ignore: decorator\n@lazy var random_state0_64: u64, random_state1_64: u64;\n\n// @ts-ignore: decorator\n@lazy var random_state0_32: u32, random_state1_32: u32;\n\nfunction murmurHash3(h: u64): u64 { // Force all bits of a hash block to avalanche\n h ^= h >> 33; // see: https://github.com/aappleby/smhasher\n h *= 0xFF51AFD7ED558CCD;\n h ^= h >> 33;\n h *= 0xC4CEB9FE1A85EC53;\n h ^= h >> 33;\n return h;\n}\n\nfunction splitMix32(h: u32): u32 {\n h += 0x6D2B79F5;\n h = (h ^ (h >> 15)) * (h | 1);\n h ^= h + (h ^ (h >> 7)) * (h | 61);\n return h ^ (h >> 14);\n}\n\nexport namespace NativeMath {\n\n // @ts-ignore: decorator\n @lazy\n export const E = reinterpret(0x4005BF0A8B145769); // 2.7182818284590452354\n\n // @ts-ignore: decorator\n @lazy\n export const LN2 = reinterpret(0x3FE62E42FEFA39EF); // 0.69314718055994530942\n\n // @ts-ignore: decorator\n @lazy\n export const LN10 = reinterpret(0x40026BB1BBB55516); // 2.30258509299404568402\n\n // @ts-ignore: decorator\n @lazy\n export const LOG2E = reinterpret(0x3FF71547652B82FE); // 1.4426950408889634074\n\n // @ts-ignore: decorator\n @lazy\n export const LOG10E = reinterpret(0x3FDBCB7B1526E50E); // 0.43429448190325182765\n\n // @ts-ignore: decorator\n @lazy\n export const PI = reinterpret(0x400921FB54442D18); // 3.14159265358979323846\n\n // @ts-ignore: decorator\n @lazy\n export const SQRT1_2 = reinterpret(0x3FE6A09E667F3BCD); // 0.70710678118654752440\n\n // @ts-ignore: decorator\n @lazy\n export const SQRT2 = reinterpret(0x3FF6A09E667F3BCD); // 1.41421356237309504880\n\n // @ts-ignore: decorator\n @lazy\n export var sincos_sin: f64 = 0;\n\n // @ts-ignore: decorator\n @lazy\n export var sincos_cos: f64 = 0;\n\n // @ts-ignore: decorator\n @inline export function abs(x: f64): f64 {\n return builtin_abs(x);\n }\n\n export function acos(x: f64): f64 { // see: musl/src/math/acos.c and SUN COPYRIGHT NOTICE above\n const\n pio2_hi = reinterpret(0x3FF921FB54442D18), // 1.57079632679489655800e+00\n pio2_lo = reinterpret(0x3C91A62633145C07), // 6.12323399573676603587e-17\n Ox1p_120f = reinterpret(0x03800000);\n\n var hx = (reinterpret(x) >> 32);\n var ix = hx & 0x7FFFFFFF;\n if (ix >= 0x3FF00000) {\n let lx = reinterpret(x);\n if ((ix - 0x3FF00000 | lx) == 0) {\n if (hx < 0) return 2 * pio2_hi + Ox1p_120f;\n return 0;\n }\n return 0 / (x - x);\n }\n if (ix < 0x3FE00000) {\n if (ix <= 0x3C600000) return pio2_hi + Ox1p_120f;\n return pio2_hi - (x - (pio2_lo - x * R(x * x)));\n }\n var s: f64, w: f64, z: f64;\n if (hx < 0) {\n // z = (1.0 + x) * 0.5;\n z = 0.5 + x * 0.5;\n s = builtin_sqrt(z);\n w = R(z) * s - pio2_lo;\n return 2 * (pio2_hi - (s + w));\n }\n // z = (1.0 - x) * 0.5;\n z = 0.5 - x * 0.5;\n s = builtin_sqrt(z);\n var df = reinterpret(reinterpret(s) & 0xFFFFFFFF00000000);\n var c = (z - df * df) / (s + df);\n w = R(z) * s + c;\n return 2 * (df + w);\n }\n\n export function acosh(x: f64): f64 { // see: musl/src/math/acosh.c\n const s = reinterpret(0x3FE62E42FEFA39EF);\n var u = reinterpret(x);\n // Prevent propagation for all input values less than 1.0.\n // Note musl lib didn't fix this yet.\n if (u < 0x3FF0000000000000) return (x - x) / 0.0;\n var e = u >> 52 & 0x7FF;\n if (e < 0x3FF + 1) return log1p(x - 1 + builtin_sqrt((x - 1) * (x - 1) + 2 * (x - 1)));\n if (e < 0x3FF + 26) return log(2 * x - 1 / (x + builtin_sqrt(x * x - 1)));\n return log(x) + s;\n }\n\n export function asin(x: f64): f64 { // see: musl/src/math/asin.c and SUN COPYRIGHT NOTICE above\n const\n pio2_hi = reinterpret(0x3FF921FB54442D18), // 1.57079632679489655800e+00\n pio2_lo = reinterpret(0x3C91A62633145C07), // 6.12323399573676603587e-17\n Ox1p_120f = reinterpret(0x03800000);\n\n var hx = (reinterpret(x) >> 32);\n var ix = hx & 0x7FFFFFFF;\n if (ix >= 0x3FF00000) {\n let lx = reinterpret(x);\n if ((ix - 0x3FF00000 | lx) == 0) return x * pio2_hi + Ox1p_120f;\n return 0 / (x - x);\n }\n if (ix < 0x3FE00000) {\n if (ix < 0x3E500000 && ix >= 0x00100000) return x;\n return x + x * R(x * x);\n }\n // var z = (1.0 - builtin_abs(x)) * 0.5;\n var z = 0.5 - builtin_abs(x) * 0.5;\n var s = builtin_sqrt(z);\n var r = R(z);\n if (ix >= 0x3FEF3333) x = pio2_hi - (2 * (s + s * r) - pio2_lo);\n else {\n let f = reinterpret(reinterpret(s) & 0xFFFFFFFF00000000);\n let c = (z - f * f) / (s + f);\n x = 0.5 * pio2_hi - (2 * s * r - (pio2_lo - 2 * c) - (0.5 * pio2_hi - 2 * f));\n }\n return select(-x, x, hx < 0);\n }\n\n export function asinh(x: f64): f64 { // see: musl/src/math/asinh.c\n const c = reinterpret(0x3FE62E42FEFA39EF); // 0.693147180559945309417232121458176568\n var u = reinterpret(x);\n var e = u >> 52 & 0x7FF;\n var y = reinterpret(u & 0x7FFFFFFFFFFFFFFF);\n if (e >= 0x3FF + 26) y = log(y) + c;\n else if (e >= 0x3FF + 1) y = log(2 * y + 1 / (builtin_sqrt(y * y + 1) + y));\n else if (e >= 0x3FF - 26) y = log1p(y + y * y / (builtin_sqrt(y * y + 1) + 1));\n return builtin_copysign(y, x);\n }\n\n export function atan(x: f64): f64 { // see musl/src/math/atan.c and SUN COPYRIGHT NOTICE above\n const\n atanhi0 = reinterpret(0x3FDDAC670561BB4F), // 4.63647609000806093515e-01\n atanhi1 = reinterpret(0x3FE921FB54442D18), // 7.85398163397448278999e-01\n atanhi2 = reinterpret(0x3FEF730BD281F69B), // 9.82793723247329054082e-01\n atanhi3 = reinterpret(0x3FF921FB54442D18), // 1.57079632679489655800e+00\n atanlo0 = reinterpret(0x3C7A2B7F222F65E2), // 2.26987774529616870924e-17\n atanlo1 = reinterpret(0x3C81A62633145C07), // 3.06161699786838301793e-17\n atanlo2 = reinterpret(0x3C7007887AF0CBBD), // 1.39033110312309984516e-17\n atanlo3 = reinterpret(0x3C91A62633145C07), // 6.12323399573676603587e-17\n aT0 = reinterpret(0x3FD555555555550D), // 3.33333333333329318027e-01\n aT1 = reinterpret(0xBFC999999998EBC4), // -1.99999999998764832476e-01\n aT2 = reinterpret(0x3FC24924920083FF), // 1.42857142725034663711e-01\n aT3 = reinterpret(0xBFBC71C6FE231671), // -1.11111104054623557880e-01,\n aT4 = reinterpret(0x3FB745CDC54C206E), // 9.09088713343650656196e-02\n aT5 = reinterpret(0xBFB3B0F2AF749A6D), // -7.69187620504482999495e-02\n aT6 = reinterpret(0x3FB10D66A0D03D51), // 6.66107313738753120669e-02\n aT7 = reinterpret(0xBFADDE2D52DEFD9A), // -5.83357013379057348645e-02\n aT8 = reinterpret(0x3FA97B4B24760DEB), // 4.97687799461593236017e-02\n aT9 = reinterpret(0xBFA2B4442C6A6C2F), // -3.65315727442169155270e-02\n aT10 = reinterpret(0x3F90AD3AE322DA11), // 1.62858201153657823623e-02\n Ox1p_120f = reinterpret(0x03800000);\n\n var ix = (reinterpret(x) >> 32);\n var sx = x;\n ix &= 0x7FFFFFFF;\n var z: f64;\n if (ix >= 0x44100000) {\n if (isNaN(x)) return x;\n z = atanhi3 + Ox1p_120f;\n return builtin_copysign(z, sx);\n }\n var id: i32;\n if (ix < 0x3FDC0000) {\n if (ix < 0x3E400000) return x;\n id = -1;\n } else {\n x = builtin_abs(x);\n if (ix < 0x3FF30000) {\n if (ix < 0x3FE60000) {\n id = 0;\n x = (2.0 * x - 1.0) / (2.0 + x);\n } else {\n id = 1;\n x = (x - 1.0) / (x + 1.0);\n }\n } else {\n if (ix < 0x40038000) {\n id = 2;\n x = (x - 1.5) / (1.0 + 1.5 * x);\n } else {\n id = 3;\n x = -1.0 / x;\n }\n }\n }\n z = x * x;\n var w = z * z;\n var s1 = z * (aT0 + w * (aT2 + w * (aT4 + w * (aT6 + w * (aT8 + w * aT10)))));\n var s2 = w * (aT1 + w * (aT3 + w * (aT5 + w * (aT7 + w * aT9))));\n var s3 = x * (s1 + s2);\n if (id < 0) return x - s3;\n switch (id) {\n case 0: { z = atanhi0 - ((s3 - atanlo0) - x); break; }\n case 1: { z = atanhi1 - ((s3 - atanlo1) - x); break; }\n case 2: { z = atanhi2 - ((s3 - atanlo2) - x); break; }\n case 3: { z = atanhi3 - ((s3 - atanlo3) - x); break; }\n default: unreachable();\n }\n return builtin_copysign(z, sx);\n }\n\n export function atanh(x: f64): f64 { // see: musl/src/math/atanh.c\n var u = reinterpret(x);\n var e = u >> 52 & 0x7FF;\n var y = builtin_abs(x);\n if (e < 0x3FF - 1) {\n if (e >= 0x3FF - 32) y = 0.5 * log1p(2 * y + 2 * y * y / (1 - y));\n } else {\n y = 0.5 * log1p(2 * (y / (1 - y)));\n }\n return builtin_copysign(y, x);\n }\n\n export function atan2(y: f64, x: f64): f64 { // see: musl/src/math/atan2.c and SUN COPYRIGHT NOTICE above\n const pi_lo = reinterpret(0x3CA1A62633145C07); // 1.2246467991473531772E-16\n if (isNaN(x) || isNaN(y)) return x + y;\n var u = reinterpret(x);\n var ix = (u >> 32);\n var lx = u;\n u = reinterpret(y);\n var iy = (u >> 32);\n var ly = u;\n if ((ix - 0x3FF00000 | lx) == 0) return atan(y);\n var m = ((iy >> 31) & 1) | ((ix >> 30) & 2);\n ix = ix & 0x7FFFFFFF;\n iy = iy & 0x7FFFFFFF;\n if ((iy | ly) == 0) {\n switch (m) {\n case 0:\n case 1: return y;\n case 2: return PI;\n case 3: return -PI;\n }\n }\n if ((ix | lx) == 0) return m & 1 ? -PI / 2 : PI / 2;\n if (ix == 0x7FF00000) {\n if (iy == 0x7FF00000) {\n let t = m & 2 ? 3 * PI / 4 : PI / 4;\n return m & 1 ? -t : t;\n } else {\n let t = m & 2 ? PI : 0;\n return m & 1 ? -t : t;\n }\n }\n var z: f64;\n if (ix + (64 << 20) < iy || iy == 0x7FF00000) return m & 1 ? -PI / 2 : PI / 2;\n if ((m & 2) && iy + (64 << 20) < ix) z = 0;\n else z = atan(builtin_abs(y / x));\n switch (m) {\n case 0: return z;\n case 1: return -z;\n case 2: return PI - (z - pi_lo);\n case 3: return (z - pi_lo) - PI;\n }\n unreachable();\n return 0;\n }\n\n export function cbrt(x: f64): f64 { // see: musl/src/math/cbrt.c and SUN COPYRIGHT NOTICE above\n const\n B1 = 715094163,\n B2 = 696219795,\n P0 = reinterpret(0x3FFE03E60F61E692), // 1.87595182427177009643\n P1 = reinterpret(0xBFFE28E092F02420), // -1.88497979543377169875\n P2 = reinterpret(0x3FF9F1604A49D6C2), // 1.621429720105354466140\n P3 = reinterpret(0xBFE844CBBEE751D9), // -0.758397934778766047437\n P4 = reinterpret(0x3FC2B000D4E4EDD7), // 0.145996192886612446982\n Ox1p54 = reinterpret(0x4350000000000000); // 0x1p54\n\n var u = reinterpret(x);\n var hx = (u >> 32) & 0x7FFFFFFF;\n if (hx >= 0x7FF00000) return x + x;\n if (hx < 0x00100000) {\n u = reinterpret(x * Ox1p54);\n hx = (u >> 32) & 0x7FFFFFFF;\n if (hx == 0) return x;\n hx = hx / 3 + B2;\n } else {\n hx = hx / 3 + B1;\n }\n u &= 1 << 63;\n u |= hx << 32;\n var t = reinterpret(u);\n var r = (t * t) * (t / x);\n t = t * ((P0 + r * (P1 + r * P2)) + ((r * r) * r) * (P3 + r * P4));\n t = reinterpret((reinterpret(t) + 0x80000000) & 0xFFFFFFFFC0000000);\n var s = t * t;\n r = x / s;\n r = (r - t) / (2 * t + r);\n t = t + t * r;\n return t;\n }\n\n // @ts-ignore: decorator\n @inline\n export function ceil(x: f64): f64 {\n return builtin_ceil(x);\n }\n\n export function clz32(x: f64): f64 {\n if (!isFinite(x)) return 32;\n /*\n * Wasm (MVP) and JS have different approaches for double->int conversions.\n *\n * For emulate JS conversion behavior and avoid trapping from wasm we should modulate by MAX_INT\n * our float-point arguments before actual convertion to integers.\n */\n return builtin_clz(dtoi32(x));\n }\n\n export function cos(x: f64): f64 { // see: musl/src/math/cos.c\n var u = reinterpret(x);\n var ux = u32(u >> 32);\n var sign = ux >> 31;\n\n ux &= 0x7FFFFFFF;\n\n // |x| ~< pi/4\n if (ux <= 0x3FE921FB) {\n if (ux < 0x3E46A09E) { // |x| < 2**-27 * sqrt(2)\n return 1.0;\n }\n return cos_kern(x, 0);\n }\n\n // sin(Inf or NaN) is NaN\n if (ux >= 0x7FF00000) return x - x;\n\n // argument reduction needed\n var n = rempio2(x, u, sign);\n var y0 = rempio2_y0;\n var y1 = rempio2_y1;\n\n x = n & 1 ? sin_kern(y0, y1, 1) : cos_kern(y0, y1);\n return (n + 1) & 2 ? -x : x;\n }\n\n export function cosh(x: f64): f64 { // see: musl/src/math/cosh.c\n var u = reinterpret(x);\n u &= 0x7FFFFFFFFFFFFFFF;\n x = reinterpret(u);\n var w = (u >> 32);\n var t: f64;\n if (w < 0x3FE62E42) {\n if (w < 0x3FF00000 - (26 << 20)) return 1;\n t = expm1(x);\n // return 1 + t * t / (2 * (1 + t));\n return 1 + t * t / (2 + 2 * t);\n }\n if (w < 0x40862E42) {\n t = exp(x);\n return 0.5 * (t + 1 / t);\n }\n t = expo2(x, 1);\n return t;\n }\n\n export function exp(x: f64): f64 { // see: musl/src/math/exp.c and SUN COPYRIGHT NOTICE above\n if (ASC_SHRINK_LEVEL < 1) {\n return exp_lut(x);\n } else {\n const\n ln2hi = reinterpret(0x3FE62E42FEE00000), // 6.93147180369123816490e-01\n ln2lo = reinterpret(0x3DEA39EF35793C76), // 1.90821492927058770002e-10\n invln2 = reinterpret(0x3FF71547652B82FE), // 1.44269504088896338700e+00\n P1 = reinterpret(0x3FC555555555553E), // 1.66666666666666019037e-01\n P2 = reinterpret(0xBF66C16C16BEBD93), // -2.77777777770155933842e-03\n P3 = reinterpret(0x3F11566AAF25DE2C), // 6.61375632143793436117e-05\n P4 = reinterpret(0xBEBBBD41C5D26BF1), // -1.65339022054652515390e-06\n P5 = reinterpret(0x3E66376972BEA4D0), // 4.13813679705723846039e-08\n overflow = reinterpret(0x40862E42FEFA39EF), // 709.782712893383973096\n underflow = reinterpret(0xC0874910D52D3051), // -745.13321910194110842\n Ox1p1023 = reinterpret(0x7FE0000000000000); // 0x1p1023\n\n let hx = u32(reinterpret(x) >> 32);\n let sign = hx >> 31;\n hx &= 0x7FFFFFFF;\n if (hx >= 0x4086232B) {\n if (isNaN(x)) return x;\n if (x > overflow) return x * Ox1p1023;\n if (x < underflow) return 0;\n }\n let hi: f64, lo: f64 = 0;\n let k = 0;\n if (hx > 0x3FD62E42) {\n if (hx >= 0x3FF0A2B2) {\n k = i32(invln2 * x + builtin_copysign(0.5, x));\n } else {\n k = 1 - (sign << 1);\n }\n hi = x - k * ln2hi;\n lo = k * ln2lo;\n x = hi - lo;\n } else if (hx > 0x3E300000) {\n hi = x;\n } else return 1.0 + x;\n let xs = x * x;\n // var c = x - xp2 * (P1 + xp2 * (P2 + xp2 * (P3 + xp2 * (P4 + xp2 * P5))));\n let xq = xs * xs;\n let c = x - (xs * P1 + xq * ((P2 + xs * P3) + xq * (P4 + xs * P5)));\n let y = 1.0 + (x * c / (2 - c) - lo + hi);\n return k == 0 ? y : scalbn(y, k);\n }\n }\n\n export function exp2(x: f64): f64 {\n return exp2_lut(x);\n }\n\n export function expm1(x: f64): f64 { // see: musl/src/math/expm1.c and SUN COPYRIGHT NOTICE above\n const\n o_threshold = reinterpret(0x40862E42FEFA39EF), // 7.09782712893383973096e+02\n ln2_hi = reinterpret(0x3FE62E42FEE00000), // 6.93147180369123816490e-01\n ln2_lo = reinterpret(0x3DEA39EF35793C76), // 1.90821492927058770002e-10\n invln2 = reinterpret(0x3FF71547652B82FE), // 1.44269504088896338700e+00\n Q1 = reinterpret(0xBFA11111111110F4), // -3.33333333333331316428e-02\n Q2 = reinterpret(0x3F5A01A019FE5585), // 1.58730158725481460165e-03\n Q3 = reinterpret(0xBF14CE199EAADBB7), // -7.93650757867487942473e-05\n Q4 = reinterpret(0x3ED0CFCA86E65239), // 4.00821782732936239552e-06\n Q5 = reinterpret(0xBE8AFDB76E09C32D), // -2.01099218183624371326e-07\n Ox1p1023 = reinterpret(0x7FE0000000000000); // 0x1p1023\n\n var u = reinterpret(x);\n var hx = u32(u >> 32) & 0x7FFFFFFF;\n var sign = u32(u >> 63);\n var k = 0;\n if (hx >= 0x4043687A) {\n if (isNaN(x)) return x;\n if (sign) return -1;\n if (x > o_threshold) return x * Ox1p1023;\n }\n var c = 0.0, t: f64;\n if (hx > 0x3FD62E42) {\n k = select(\n 1 - (sign << 1),\n i32(invln2 * x + builtin_copysign(0.5, x)),\n hx < 0x3FF0A2B2\n );\n t = k;\n let hi = x - t * ln2_hi;\n let lo = t * ln2_lo;\n x = hi - lo;\n c = (hi - x) - lo;\n } else if (hx < 0x3C900000) return x;\n var hfx = 0.5 * x;\n var hxs = x * hfx;\n // var r1 = 1.0 + hxs * (Q1 + hxs * (Q2 + hxs * (Q3 + hxs * (Q4 + hxs * Q5))));\n var hxq = hxs * hxs;\n var r1 = (1.0 + hxs * Q1) + hxq * ((Q2 + hxs * Q3) + hxq * (Q4 + hxs * Q5));\n t = 3.0 - r1 * hfx;\n var e = hxs * ((r1 - t) / (6.0 - x * t));\n if (k == 0) return x - (x * e - hxs);\n e = x * (e - c) - c;\n e -= hxs;\n if (k == -1) return 0.5 * (x - e) - 0.5;\n if (k == 1) {\n if (x < -0.25) return -2.0 * (e - (x + 0.5));\n return 1.0 + 2.0 * (x - e);\n }\n u = (0x3FF + k) << 52;\n var twopk = reinterpret(u);\n var y: f64;\n if (k < 0 || k > 56) {\n y = x - e + 1.0;\n if (k == 1024) y = y * 2.0 * Ox1p1023;\n else y = y * twopk;\n return y - 1.0;\n }\n u = (0x3FF - k) << 52;\n y = reinterpret(u);\n if (k < 20) y = (1 - y) - e;\n else y = 1 - (e + y);\n return (x + y) * twopk;\n }\n\n // @ts-ignore: decorator\n @inline\n export function floor(x: f64): f64 {\n return builtin_floor(x);\n }\n\n // @ts-ignore: decorator\n @inline\n export function fround(x: f64): f64 {\n return x;\n }\n\n export function hypot(x: f64, y: f64): f64 { // see: musl/src/math/hypot.c\n const\n SPLIT = reinterpret(0x41A0000000000000) + 1, // 0x1p27 + 1\n Ox1p700 = reinterpret(0x6BB0000000000000),\n Ox1p_700 = reinterpret(0x1430000000000000);\n\n var ux = reinterpret(x);\n var uy = reinterpret(y);\n ux &= 0x7FFFFFFFFFFFFFFF;\n uy &= 0x7FFFFFFFFFFFFFFF;\n if (ux < uy) {\n let ut = ux;\n ux = uy;\n uy = ut;\n }\n var ex = i32(ux >> 52);\n var ey = i32(uy >> 52);\n y = reinterpret(uy);\n if (ey == 0x7FF) return y;\n x = reinterpret(ux);\n if (ex == 0x7FF || uy == 0) return x;\n if (ex - ey > 64) return x + y;\n var z = 1.0;\n if (ex > 0x3FF + 510) {\n z = Ox1p700;\n x *= Ox1p_700;\n y *= Ox1p_700;\n } else if (ey < 0x3FF - 450) {\n z = Ox1p_700;\n x *= Ox1p700;\n y *= Ox1p700;\n }\n var c = x * SPLIT;\n var h = x - c + c;\n var l = x - h;\n var hx = x * x;\n var lx = h * h - hx + (2 * h + l) * l;\n c = y * SPLIT;\n h = y - c + c;\n l = y - h;\n var hy = y * y;\n var ly = h * h - hy + (2 * h + l) * l;\n return z * builtin_sqrt(ly + lx + hy + hx);\n }\n\n export function imul(x: f64, y: f64): f64 {\n /*\n * Wasm (MVP) and JS have different approaches for double->int conversions.\n *\n * For emulate JS conversion behavior and avoid trapping from wasm we should modulate by MAX_INT\n * our float-point arguments before actual convertion to integers.\n */\n if (!isFinite(x + y)) return 0;\n return dtoi32(x) * dtoi32(y);\n }\n\n export function log(x: f64): f64 { // see: musl/src/math/log.c and SUN COPYRIGHT NOTICE above\n if (ASC_SHRINK_LEVEL < 1) {\n return log_lut(x);\n } else {\n const\n ln2_hi = reinterpret(0x3FE62E42FEE00000), // 6.93147180369123816490e-01\n ln2_lo = reinterpret(0x3DEA39EF35793C76), // 1.90821492927058770002e-10\n Lg1 = reinterpret(0x3FE5555555555593), // 6.666666666666735130e-01\n Lg2 = reinterpret(0x3FD999999997FA04), // 3.999999999940941908e-01\n Lg3 = reinterpret(0x3FD2492494229359), // 2.857142874366239149e-01\n Lg4 = reinterpret(0x3FCC71C51D8E78AF), // 2.222219843214978396e-01\n Lg5 = reinterpret(0x3FC7466496CB03DE), // 1.818357216161805012e-01\n Lg6 = reinterpret(0x3FC39A09D078C69F), // 1.531383769920937332e-01\n Lg7 = reinterpret(0x3FC2F112DF3E5244), // 1.479819860511658591e-01\n Ox1p54 = reinterpret(0x4350000000000000); // 0x1p54\n\n let u = reinterpret(x);\n let hx = u32(u >> 32);\n let k = 0;\n let sign = hx >> 31;\n if (sign || hx < 0x00100000) {\n if (u << 1 == 0) return -1 / (x * x);\n if (sign) return (x - x) / 0.0;\n k -= 54;\n x *= Ox1p54;\n u = reinterpret(x);\n hx = u32(u >> 32);\n } else if (hx >= 0x7FF00000) {\n return x;\n } else if (hx == 0x3FF00000 && u << 32 == 0) {\n return 0;\n }\n hx += 0x3FF00000 - 0x3FE6A09E;\n k += (hx >> 20) - 0x3FF;\n hx = (hx & 0x000FFFFF) + 0x3FE6A09E;\n u = hx << 32 | (u & 0xFFFFFFFF);\n x = reinterpret(u);\n let f = x - 1.0;\n let hfsq = 0.5 * f * f;\n let s = f / (2.0 + f);\n let z = s * s;\n let w = z * z;\n let t1 = w * (Lg2 + w * (Lg4 + w * Lg6));\n let t2 = z * (Lg1 + w * (Lg3 + w * (Lg5 + w * Lg7)));\n let r = t2 + t1;\n let dk = k;\n return s * (hfsq + r) + dk * ln2_lo - hfsq + f + dk * ln2_hi;\n }\n }\n\n export function log10(x: f64): f64 { // see: musl/src/math/log10.c and SUN COPYRIGHT NOTICE above\n const\n ivln10hi = reinterpret(0x3FDBCB7B15200000), // 4.34294481878168880939e-01\n ivln10lo = reinterpret(0x3DBB9438CA9AADD5), // 2.50829467116452752298e-11\n log10_2hi = reinterpret(0x3FD34413509F6000), // 3.01029995663611771306e-01\n log10_2lo = reinterpret(0x3D59FEF311F12B36), // 3.69423907715893078616e-13\n Lg1 = reinterpret(0x3FE5555555555593), // 6.666666666666735130e-01\n Lg2 = reinterpret(0x3FD999999997FA04), // 3.999999999940941908e-01\n Lg3 = reinterpret(0x3FD2492494229359), // 2.857142874366239149e-01\n Lg4 = reinterpret(0x3FCC71C51D8E78AF), // 2.222219843214978396e-01\n Lg5 = reinterpret(0x3FC7466496CB03DE), // 1.818357216161805012e-01\n Lg6 = reinterpret(0x3FC39A09D078C69F), // 1.531383769920937332e-01\n Lg7 = reinterpret(0x3FC2F112DF3E5244), // 1.479819860511658591e-01\n Ox1p54 = reinterpret(0x4350000000000000); // 0x1p54\n\n var u = reinterpret(x);\n var hx = u32(u >> 32);\n var k = 0;\n var sign = hx >> 31;\n if (sign || hx < 0x00100000) {\n if (u << 1 == 0) return -1 / (x * x);\n if (sign) return (x - x) / 0.0;\n k -= 54;\n x *= Ox1p54;\n u = reinterpret(x);\n hx = u32(u >> 32);\n } else if (hx >= 0x7FF00000) {\n return x;\n } else if (hx == 0x3FF00000 && u << 32 == 0) {\n return 0;\n }\n hx += 0x3FF00000 - 0x3FE6A09E;\n k += i32(hx >> 20) - 0x3FF;\n hx = (hx & 0x000FFFFF) + 0x3FE6A09E;\n u = hx << 32 | (u & 0xFFFFFFFF);\n x = reinterpret(u);\n var f = x - 1.0;\n var hfsq = 0.5 * f * f;\n var s = f / (2.0 + f);\n var z = s * s;\n var w = z * z;\n var t1 = w * (Lg2 + w * (Lg4 + w * Lg6));\n var t2 = z * (Lg1 + w * (Lg3 + w * (Lg5 + w * Lg7)));\n var r = t2 + t1;\n var hi = f - hfsq;\n u = reinterpret(hi);\n u &= 0xFFFFFFFF00000000;\n hi = reinterpret(u);\n var lo = f - hi - hfsq + s * (hfsq + r);\n var val_hi = hi * ivln10hi;\n var dk = k;\n var y = dk * log10_2hi;\n var val_lo = dk * log10_2lo + (lo + hi) * ivln10lo + lo * ivln10hi;\n w = y + val_hi;\n val_lo += (y - w) + val_hi;\n return val_lo + w;\n }\n\n export function log1p(x: f64): f64 { // see: musl/src/math/log1p.c and SUN COPYRIGHT NOTICE above\n const\n ln2_hi = reinterpret(0x3FE62E42FEE00000), // 6.93147180369123816490e-01\n ln2_lo = reinterpret(0x3DEA39EF35793C76), // 1.90821492927058770002e-10\n Lg1 = reinterpret(0x3FE5555555555593), // 6.666666666666735130e-01\n Lg2 = reinterpret(0x3FD999999997FA04), // 3.999999999940941908e-01\n Lg3 = reinterpret(0x3FD2492494229359), // 2.857142874366239149e-01\n Lg4 = reinterpret(0x3FCC71C51D8E78AF), // 2.222219843214978396e-01\n Lg5 = reinterpret(0x3FC7466496CB03DE), // 1.818357216161805012e-01\n Lg6 = reinterpret(0x3FC39A09D078C69F), // 1.531383769920937332e-01\n Lg7 = reinterpret(0x3FC2F112DF3E5244); // 1.479819860511658591e-01\n\n var u = reinterpret(x);\n var hx = u32(u >> 32);\n var k = 1;\n var c = 0.0, f = 0.0;\n if (hx < 0x3FDA827A || bool(hx >> 31)) {\n if (hx >= 0xBFF00000) {\n if (x == -1) return x / 0.0;\n return (x - x) / 0.0;\n }\n if (hx << 1 < 0x3CA00000 << 1) return x;\n if (hx <= 0xBFD2BEC4) {\n k = 0;\n c = 0;\n f = x;\n }\n } else if (hx >= 0x7FF00000) return x;\n if (k) {\n u = reinterpret(1 + x);\n let hu = u32(u >> 32);\n hu += 0x3FF00000 - 0x3FE6A09E;\n k = i32(hu >> 20) - 0x3FF;\n if (k < 54) {\n let uf = reinterpret(u);\n c = k >= 2 ? 1 - (uf - x) : x - (uf - 1);\n c /= uf;\n } else c = 0;\n hu = (hu & 0x000FFFFF) + 0x3FE6A09E;\n u = hu << 32 | (u & 0xFFFFFFFF);\n f = reinterpret(u) - 1;\n }\n var hfsq = 0.5 * f * f;\n var s = f / (2.0 + f);\n var z = s * s;\n var w = z * z;\n var t1 = w * (Lg2 + w * (Lg4 + w * Lg6));\n var t2 = z * (Lg1 + w * (Lg3 + w * (Lg5 + w * Lg7)));\n var r = t2 + t1;\n var dk = k;\n return s * (hfsq + r) + (dk * ln2_lo + c) - hfsq + f + dk * ln2_hi;\n }\n\n export function log2(x: f64): f64 { // see: musl/src/math/log2.c and SUN COPYRIGHT NOTICE above\n if (ASC_SHRINK_LEVEL < 1) {\n return log2_lut(x);\n } else {\n const\n ivln2hi = reinterpret(0x3FF7154765200000), // 1.44269504072144627571e+00\n ivln2lo = reinterpret(0x3DE705FC2EEFA200), // 1.67517131648865118353e-10\n Lg1 = reinterpret(0x3FE5555555555593), // 6.666666666666735130e-01\n Lg2 = reinterpret(0x3FD999999997FA04), // 3.999999999940941908e-01\n Lg3 = reinterpret(0x3FD2492494229359), // 2.857142874366239149e-01\n Lg4 = reinterpret(0x3FCC71C51D8E78AF), // 2.222219843214978396e-01\n Lg5 = reinterpret(0x3FC7466496CB03DE), // 1.818357216161805012e-01\n Lg6 = reinterpret(0x3FC39A09D078C69F), // 1.531383769920937332e-01\n Lg7 = reinterpret(0x3FC2F112DF3E5244), // 1.479819860511658591e-01\n Ox1p54 = reinterpret(0x4350000000000000); // 1p54\n\n let u = reinterpret(x);\n let hx = u32(u >> 32);\n let k = 0;\n let sign = hx >> 31;\n if (sign || hx < 0x00100000) {\n if (u << 1 == 0) return -1 / (x * x);\n if (sign) return (x - x) / 0.0;\n k -= 54;\n x *= Ox1p54;\n u = reinterpret(x);\n hx = u32(u >> 32);\n } else if (hx >= 0x7FF00000) {\n return x;\n } else if (hx == 0x3FF00000 && u << 32 == 0) {\n return 0;\n }\n hx += 0x3FF00000 - 0x3FE6A09E;\n k += i32(hx >> 20) - 0x3FF;\n hx = (hx & 0x000FFFFF) + 0x3FE6A09E;\n u = hx << 32 | (u & 0xFFFFFFFF);\n x = reinterpret(u);\n let f = x - 1.0;\n let hfsq = 0.5 * f * f;\n let s = f / (2.0 + f);\n let z = s * s;\n let w = z * z;\n let t1 = w * (Lg2 + w * (Lg4 + w * Lg6));\n let t2 = z * (Lg1 + w * (Lg3 + w * (Lg5 + w * Lg7)));\n let r = t2 + t1;\n let hi = f - hfsq;\n u = reinterpret(hi);\n u &= 0xFFFFFFFF00000000;\n hi = reinterpret(u);\n let lo = f - hi - hfsq + s * (hfsq + r);\n let val_hi = hi * ivln2hi;\n let val_lo = (lo + hi) * ivln2lo + lo * ivln2hi;\n let y = k;\n w = y + val_hi;\n val_lo += (y - w) + val_hi;\n val_hi = w;\n return val_lo + val_hi;\n }\n }\n\n // @ts-ignore: decorator\n @inline\n export function max(value1: f64, value2: f64): f64 {\n return builtin_max(value1, value2);\n }\n\n // @ts-ignore: decorator\n @inline\n export function min(value1: f64, value2: f64): f64 {\n return builtin_min(value1, value2);\n }\n\n export function pow(x: f64, y: f64): f64 { // see: musl/src/math/pow.c and SUN COPYRIGHT NOTICE above\n // TODO: remove this fast pathes after introduced own mid-end IR with \"stdlib call simplify\" transforms\n if (builtin_abs(y) <= 2) {\n if (y == 2.0) return x * x;\n if (y == 0.5) {\n return select(\n builtin_abs(builtin_sqrt(x)),\n Infinity,\n x != -Infinity\n );\n }\n if (y == -1.0) return 1 / x;\n if (y == 1.0) return x;\n if (y == 0.0) return 1.0;\n }\n if (ASC_SHRINK_LEVEL < 1) {\n return pow_lut(x, y);\n } else {\n const\n dp_h1 = reinterpret(0x3FE2B80340000000), // 5.84962487220764160156e-01\n dp_l1 = reinterpret(0x3E4CFDEB43CFD006), // 1.35003920212974897128e-08\n two53 = reinterpret(0x4340000000000000), // 9007199254740992.0\n huge = reinterpret(0x7E37E43C8800759C), // 1e+300\n tiny = reinterpret(0x01A56E1FC2F8F359), // 1e-300\n L1 = reinterpret(0x3FE3333333333303), // 5.99999999999994648725e-01\n L2 = reinterpret(0x3FDB6DB6DB6FABFF), // 4.28571428578550184252e-01\n L3 = reinterpret(0x3FD55555518F264D), // 3.33333329818377432918e-01\n L4 = reinterpret(0x3FD17460A91D4101), // 2.72728123808534006489e-01\n L5 = reinterpret(0x3FCD864A93C9DB65), // 2.30660745775561754067e-01\n L6 = reinterpret(0x3FCA7E284A454EEF), // 2.06975017800338417784e-01\n P1 = reinterpret(0x3FC555555555553E), // 1.66666666666666019037e-01\n P2 = reinterpret(0xBF66C16C16BEBD93), // -2.77777777770155933842e-03\n P3 = reinterpret(0x3F11566AAF25DE2C), // 6.61375632143793436117e-05\n P4 = reinterpret(0xBEBBBD41C5D26BF1), // -1.65339022054652515390e-06\n P5 = reinterpret(0x3E66376972BEA4D0), // 4.13813679705723846039e-08\n lg2 = reinterpret(0x3FE62E42FEFA39EF), // 6.93147180559945286227e-01\n lg2_h = reinterpret(0x3FE62E4300000000), // 6.93147182464599609375e-01\n lg2_l = reinterpret(0xBE205C610CA86C39), // -1.90465429995776804525e-09\n ovt = reinterpret(0x3C971547652B82FE), // 8.0085662595372944372e-017\n cp = reinterpret(0x3FEEC709DC3A03FD), // 9.61796693925975554329e-01\n cp_h = reinterpret(0x3FEEC709E0000000), // 9.61796700954437255859e-01\n cp_l = reinterpret(0xBE3E2FE0145B01F5), // -7.02846165095275826516e-09\n ivln2 = reinterpret(0x3FF71547652B82FE), // 1.44269504088896338700e+00\n ivln2_h = reinterpret(0x3FF7154760000000), // 1.44269502162933349609e+00\n ivln2_l = reinterpret(0x3E54AE0BF85DDF44), // 1.92596299112661746887e-08\n inv3 = reinterpret(0x3FD5555555555555); // 0.3333333333333333333333\n\n let u_ = reinterpret(x);\n let hx = i32(u_ >> 32);\n let lx = u_;\n u_ = reinterpret(y);\n let hy = i32(u_ >> 32);\n let ly = u_;\n let ix = hx & 0x7FFFFFFF;\n let iy = hy & 0x7FFFFFFF;\n if ((iy | ly) == 0) return 1.0; // x**0 = 1, even if x is NaN\n // if (hx == 0x3FF00000 && lx == 0) return 1.0; // C: 1**y = 1, even if y is NaN, JS: NaN\n if ( // NaN if either arg is NaN\n ix > 0x7FF00000 || (ix == 0x7FF00000 && lx != 0) ||\n iy > 0x7FF00000 || (iy == 0x7FF00000 && ly != 0)\n ) return x + y;\n let yisint = 0, k: i32;\n if (hx < 0) {\n if (iy >= 0x43400000) yisint = 2;\n else if (iy >= 0x3FF00000) {\n k = (iy >> 20) - 0x3FF;\n let offset = select(52, 20, k > 20) - k;\n let Ly = select(ly, iy, k > 20);\n let jj = Ly >> offset;\n if ((jj << offset) == Ly) yisint = 2 - (jj & 1);\n }\n }\n if (ly == 0) {\n if (iy == 0x7FF00000) { // y is +-inf\n if (((ix - 0x3FF00000) | lx) == 0) return NaN; // C: (-1)**+-inf is 1, JS: NaN\n else if (ix >= 0x3FF00000) return hy >= 0 ? y : 0.0; // (|x|>1)**+-inf = inf,0\n else return hy >= 0 ? 0.0 : -y; // (|x|<1)**+-inf = 0,inf\n }\n if (iy == 0x3FF00000) {\n if (hy >= 0) return x;\n return 1 / x;\n }\n if (hy == 0x40000000) return x * x;\n if (hy == 0x3FE00000) {\n if (hx >= 0) return builtin_sqrt(x);\n }\n }\n let ax = builtin_abs(x), z: f64;\n if (lx == 0) {\n if (ix == 0 || ix == 0x7FF00000 || ix == 0x3FF00000) {\n z = ax;\n if (hy < 0) z = 1.0 / z;\n if (hx < 0) {\n if (((ix - 0x3FF00000) | yisint) == 0) {\n let d = z - z;\n z = d / d;\n } else if (yisint == 1) z = -z;\n }\n return z;\n }\n }\n let s = 1.0;\n if (hx < 0) {\n if (yisint == 0) {\n let d = x - x;\n return d / d;\n }\n if (yisint == 1) s = -1.0;\n }\n let t1: f64, t2: f64, p_h: f64, p_l: f64, r: f64, t: f64, u: f64, v: f64, w: f64;\n let j: i32, n: i32;\n if (iy > 0x41E00000) {\n if (iy > 0x43F00000) {\n if (ix <= 0x3FEFFFFF) return hy < 0 ? huge * huge : tiny * tiny;\n if (ix >= 0x3FF00000) return hy > 0 ? huge * huge : tiny * tiny;\n }\n if (ix < 0x3FEFFFFF) return hy < 0 ? s * huge * huge : s * tiny * tiny;\n if (ix > 0x3FF00000) return hy > 0 ? s * huge * huge : s * tiny * tiny;\n t = ax - 1.0;\n w = (t * t) * (0.5 - t * (inv3 - t * 0.25));\n u = ivln2_h * t;\n v = t * ivln2_l - w * ivln2;\n t1 = u + v;\n t1 = reinterpret(reinterpret(t1) & 0xFFFFFFFF00000000);\n t2 = v - (t1 - u);\n } else {\n let ss: f64, s2: f64, s_h: f64, s_l: f64, t_h: f64, t_l: f64;\n n = 0;\n if (ix < 0x00100000) {\n ax *= two53;\n n -= 53;\n ix = (reinterpret(ax) >> 32);\n }\n n += (ix >> 20) - 0x3FF;\n j = ix & 0x000FFFFF;\n ix = j | 0x3FF00000;\n if (j <= 0x3988E) k = 0;\n else if (j < 0xBB67A) k = 1;\n else {\n k = 0;\n n += 1;\n ix -= 0x00100000;\n }\n ax = reinterpret(reinterpret(ax) & 0xFFFFFFFF | (ix << 32));\n let bp = select(1.5, 1.0, k); // k ? 1.5 : 1.0\n u = ax - bp;\n v = 1.0 / (ax + bp);\n ss = u * v;\n s_h = ss;\n s_h = reinterpret(reinterpret(s_h) & 0xFFFFFFFF00000000);\n t_h = reinterpret(u64(((ix >> 1) | 0x20000000) + 0x00080000 + (k << 18)) << 32);\n t_l = ax - (t_h - bp);\n s_l = v * ((u - s_h * t_h) - s_h * t_l);\n s2 = ss * ss;\n r = s2 * s2 * (L1 + s2 * (L2 + s2 * (L3 + s2 * (L4 + s2 * (L5 + s2 * L6)))));\n r += s_l * (s_h + ss);\n s2 = s_h * s_h;\n t_h = 3.0 + s2 + r;\n t_h = reinterpret(reinterpret(t_h) & 0xFFFFFFFF00000000);\n t_l = r - ((t_h - 3.0) - s2);\n u = s_h * t_h;\n v = s_l * t_h + t_l * ss;\n p_h = u + v;\n p_h = reinterpret(reinterpret(p_h) & 0xFFFFFFFF00000000);\n p_l = v - (p_h - u);\n let z_h = cp_h * p_h;\n let dp_l = select(dp_l1, 0.0, k);\n let z_l = cp_l * p_h + p_l * cp + dp_l;\n t = n;\n let dp_h = select(dp_h1, 0.0, k);\n t1 = ((z_h + z_l) + dp_h) + t;\n t1 = reinterpret(reinterpret(t1) & 0xFFFFFFFF00000000);\n t2 = z_l - (((t1 - t) - dp_h) - z_h);\n }\n let y1 = y;\n y1 = reinterpret(reinterpret(y1) & 0xFFFFFFFF00000000);\n p_l = (y - y1) * t1 + y * t2;\n p_h = y1 * t1;\n z = p_l + p_h;\n u_ = reinterpret(z);\n j = u32(u_ >> 32);\n let i = u_;\n if (j >= 0x40900000) {\n if (((j - 0x40900000) | i) != 0) return s * huge * huge;\n if (p_l + ovt > z - p_h) return s * huge * huge;\n } else if ((j & 0x7FFFFFFF) >= 0x4090CC00) {\n if (((j - 0xC090CC00) | i) != 0) return s * tiny * tiny;\n if (p_l <= z - p_h) return s * tiny * tiny;\n }\n i = j & 0x7FFFFFFF;\n k = (i >> 20) - 0x3FF;\n n = 0;\n if (i > 0x3FE00000) {\n n = j + (0x00100000 >> (k + 1));\n k = ((n & 0x7FFFFFFF) >> 20) - 0x3FF;\n t = 0.0;\n t = reinterpret(u64(n & ~(0x000FFFFF >> k)) << 32);\n n = ((n & 0x000FFFFF) | 0x00100000) >> (20 - k);\n if (j < 0) n = -n;\n p_h -= t;\n }\n t = p_l + p_h;\n t = reinterpret(reinterpret(t) & 0xFFFFFFFF00000000);\n u = t * lg2_h;\n v = (p_l - (t - p_h)) * lg2 + t * lg2_l;\n z = u + v;\n w = v - (z - u);\n t = z * z;\n t1 = z - t * (P1 + t * (P2 + t * (P3 + t * (P4 + t * P5))));\n r = (z * t1) / (t1 - 2.0) - (w + z * w);\n z = 1.0 - (r - z);\n j = u32(reinterpret(z) >> 32);\n j += n << 20;\n if ((j >> 20) <= 0) z = scalbn(z, n);\n else z = reinterpret(reinterpret(z) & 0xFFFFFFFF | (j << 32));\n return s * z;\n }\n }\n\n export function seedRandom(value: i64): void {\n // Instead zero seed use golden ratio:\n // phi = (1 + sqrt(5)) / 2\n // trunc(2^64 / phi) = 0x9e3779b97f4a7c15\n if (value == 0) value = 0x9e3779b97f4a7c15;\n random_state0_64 = murmurHash3(value);\n random_state1_64 = murmurHash3(~random_state0_64);\n random_state0_32 = splitMix32(value);\n random_state1_32 = splitMix32(random_state0_32);\n random_seeded = true;\n }\n\n export function random(): f64 { // see: v8/src/base/utils/random-number-generator.cc\n if (!random_seeded) seedRandom(reinterpret(seed()));\n var s1 = random_state0_64;\n var s0 = random_state1_64;\n random_state0_64 = s0;\n s1 ^= s1 << 23;\n s1 ^= s1 >> 17;\n s1 ^= s0;\n s1 ^= s0 >> 26;\n random_state1_64 = s1;\n var r = (s0 >> 12) | 0x3FF0000000000000;\n return reinterpret(r) - 1;\n }\n\n // @ts-ignore: decorator\n @inline\n export function round(x: f64): f64 {\n let roundUp = builtin_ceil(x);\n return select(roundUp, roundUp - 1.0, roundUp - 0.5 <= x);\n }\n\n // @ts-ignore: decorator\n @inline\n export function sign(x: f64): f64 {\n if (ASC_SHRINK_LEVEL > 0) {\n return builtin_abs(x) > 0 ? builtin_copysign(1, x) : x;\n } else {\n return x > 0 ? 1 : x < 0 ? -1 : x;\n }\n }\n\n // @ts-ignore: decorator\n @inline\n export function signbit(x: f64): bool {\n return bool(reinterpret(x) >>> 63);\n }\n\n export function sin(x: f64): f64 { // see: musl/src/math/sin.c\n var u = reinterpret(x);\n var ux = u32(u >> 32);\n var sign = ux >> 31;\n\n ux &= 0x7FFFFFFF;\n\n // |x| ~< pi/4\n if (ux <= 0x3FE921FB) {\n if (ux < 0x3E500000) { // |x| < 2**-26\n return x;\n }\n return sin_kern(x, 0.0, 0);\n }\n\n // sin(Inf or NaN) is NaN\n if (ux >= 0x7FF00000) return x - x;\n\n // argument reduction needed\n var n = rempio2(x, u, sign);\n var y0 = rempio2_y0;\n var y1 = rempio2_y1;\n\n x = n & 1 ? cos_kern(y0, y1) : sin_kern(y0, y1, 1);\n return n & 2 ? -x : x;\n }\n\n export function sinh(x: f64): f64 { // see: musl/src/math/sinh.c\n var u = reinterpret(x) & 0x7FFFFFFFFFFFFFFF;\n var a = reinterpret(u);\n var w = u32(u >> 32);\n var h = builtin_copysign(0.5, x);\n if (w < 0x40862E42) {\n let t = expm1(a);\n if (w < 0x3FF00000) {\n if (w < 0x3FF00000 - (26 << 20)) return x;\n return h * (2 * t - t * t / (t + 1));\n }\n return h * (t + t / (t + 1));\n }\n return expo2(a, 2 * h);\n }\n\n // @ts-ignore: decorator\n @inline\n export function sqrt(x: f64): f64 {\n return builtin_sqrt(x);\n }\n\n export function tan(x: f64): f64 { // see: musl/src/math/tan.c\n var u = reinterpret(x);\n var ux = u32(u >> 32);\n var sign = ux >>> 31;\n\n ux &= 0x7FFFFFFF;\n\n // |x| ~< pi/4\n if (ux <= 0x3FE921FB) {\n if (ux < 0x3E400000) { // |x| < 2**-27\n return x;\n }\n return tan_kern(x, 0.0, 1);\n }\n\n // tan(Inf or NaN) is NaN\n if (ux >= 0x7FF00000) return x - x;\n\n var n = rempio2(x, u, sign);\n return tan_kern(rempio2_y0, rempio2_y1, 1 - ((n & 1) << 1));\n }\n\n export function tanh(x: f64): f64 { // see: musl/src/math/tanh.c\n var u = reinterpret(x);\n u &= 0x7FFFFFFFFFFFFFFF;\n var y = reinterpret(u);\n var w = u32(u >> 32);\n var t: f64;\n if (w > 0x3FE193EA) {\n if (w > 0x40340000) {\n t = 1 - 0 / y;\n } else {\n t = expm1(2 * y);\n t = 1 - 2 / (t + 2);\n }\n } else if (w > 0x3FD058AE) {\n t = expm1(2 * y);\n t = t / (t + 2);\n } else if (w >= 0x00100000) {\n t = expm1(-2 * y);\n t = -t / (t + 2);\n } else t = y;\n return builtin_copysign(t, x);\n }\n\n // @ts-ignore: decorator\n @inline\n export function trunc(x: f64): f64 {\n return builtin_trunc(x);\n }\n\n export function scalbn(x: f64, n: i32): f64 { // see: https://git.musl-libc.org/cgit/musl/tree/src/math/scalbn.c\n const\n Ox1p53 = reinterpret(0x4340000000000000),\n Ox1p1023 = reinterpret(0x7FE0000000000000),\n Ox1p_1022 = reinterpret(0x0010000000000000);\n\n var y = x;\n if (n > 1023) {\n y *= Ox1p1023;\n n -= 1023;\n if (n > 1023) {\n y *= Ox1p1023;\n n = builtin_min(n - 1023, 1023);\n }\n } else if (n < -1022) {\n // make sure final n < -53 to avoid double\n // rounding in the subnormal range\n y *= Ox1p_1022 * Ox1p53;\n n += 1022 - 53;\n if (n < -1022) {\n y *= Ox1p_1022 * Ox1p53;\n n = builtin_max(n + 1022 - 53, -1022);\n }\n }\n return y * reinterpret((0x3FF + n) << 52);\n }\n\n export function mod(x: f64, y: f64): f64 { // see: musl/src/math/fmod.c\n if (builtin_abs(y) == 1.0) {\n // x % 1, x % -1 ==> sign(x) * abs(x - 1.0 * trunc(x / 1.0))\n // TODO: move this rule to compiler's optimization pass.\n // It could be apply for any x % C_pot, where \"C_pot\" is pow of two const.\n return builtin_copysign(x - builtin_trunc(x), x);\n }\n var ux = reinterpret(x);\n var uy = reinterpret(y);\n var ex = i64(ux >> 52 & 0x7FF);\n var ey = i64(uy >> 52 & 0x7FF);\n var sx = ux >> 63;\n var uy1 = uy << 1;\n if (uy1 == 0 || ex == 0x7FF || isNaN(y)) {\n let m = x * y;\n return m / m;\n }\n var ux1 = ux << 1;\n if (ux1 <= uy1) {\n return x * f64(ux1 != uy1);\n }\n if (!ex) {\n ex -= builtin_clz(ux << 12);\n ux <<= 1 - ex;\n } else {\n ux &= u64(-1) >> 12;\n ux |= 1 << 52;\n }\n if (!ey) {\n ey -= builtin_clz(uy << 12);\n uy <<= 1 - ey;\n } else {\n uy &= u64(-1) >> 12;\n uy |= 1 << 52;\n }\n while (ex > ey) {\n if (ux >= uy) {\n if (ux == uy) return 0 * x;\n ux -= uy;\n }\n ux <<= 1;\n --ex;\n }\n if (ux >= uy) {\n if (ux == uy) return 0 * x;\n ux -= uy;\n }\n // for (; !(ux >> 52); ux <<= 1) --ex;\n var shift = builtin_clz(ux << 11);\n ex -= shift;\n ux <<= shift;\n if (ex > 0) {\n ux -= 1 << 52;\n ux |= ex << 52;\n } else {\n ux >>= -ex + 1;\n }\n return reinterpret(ux | (sx << 63));\n }\n\n export function rem(x: f64, y: f64): f64 { // see: musl/src/math/remquo.c\n var ux = reinterpret(x);\n var uy = reinterpret(y);\n var ex = i64(ux >> 52 & 0x7FF);\n var ey = i64(uy >> 52 & 0x7FF);\n if (uy << 1 == 0 || ex == 0x7FF || isNaN(y)) {\n let m = x * y;\n return m / m;\n }\n if (ux << 1 == 0) return x;\n var uxi = ux;\n if (!ex) {\n ex -= builtin_clz(uxi << 12);\n uxi <<= 1 - ex;\n } else {\n uxi &= u64(-1) >> 12;\n uxi |= 1 << 52;\n }\n if (!ey) {\n ey -= builtin_clz(uy << 12);\n uy <<= 1 - ey;\n } else {\n uy &= u64(-1) >> 12;\n uy |= 1 << 52;\n }\n var q: u32 = 0;\n do {\n if (ex < ey) {\n if (ex + 1 == ey) break; // goto end\n return x;\n }\n while (ex > ey) {\n if (uxi >= uy) {\n uxi -= uy;\n ++q;\n }\n uxi <<= 1;\n q <<= 1;\n --ex;\n }\n if (uxi >= uy) {\n uxi -= uy;\n ++q;\n }\n if (uxi == 0) ex = -60;\n else {\n let shift = builtin_clz(uxi << 11);\n ex -= shift;\n uxi <<= shift;\n }\n break;\n } while (false);\n // end:\n if (ex > 0) {\n uxi -= 1 << 52;\n uxi |= ex << 52;\n } else {\n uxi >>= -ex + 1;\n }\n x = reinterpret(uxi);\n y = builtin_abs(y);\n var x2 = x + x;\n if (ex == ey || (ex + 1 == ey && (x2 > y || (x2 == y && (q & 1))))) {\n x -= y;\n // ++q;\n }\n return ux < 0 ? -x : x;\n }\n\n export function sincos(x: f64): void { // see: musl/tree/src/math/sincos.c\n var u = reinterpret(x);\n var ux = u32(u >> 32);\n var sign = ux >> 31;\n ux &= 0x7FFFFFFF;\n\n if (ux <= 0x3FE921FB) { // |x| ~<= π/4\n if (ux < 0x3E46A09E) { // if |x| < 2**-27 * sqrt(2)\n sincos_sin = x;\n sincos_cos = 1;\n return;\n }\n sincos_sin = sin_kern(x, 0, 0);\n sincos_cos = cos_kern(x, 0);\n return;\n }\n // sin(Inf or NaN) is NaN\n if (ux >= 0x7F800000) {\n let xx = x - x;\n sincos_sin = xx;\n sincos_cos = xx;\n return;\n }\n // general argument reduction needed\n var n = rempio2(x, u, sign);\n var y0 = rempio2_y0;\n var y1 = rempio2_y1;\n var s = sin_kern(y0, y1, 1);\n var c = cos_kern(y0, y1);\n var sin = s, cos = c;\n if (n & 1) {\n sin = c;\n cos = -s;\n }\n if (n & 2) {\n sin = -sin;\n cos = -cos;\n }\n sincos_sin = sin;\n sincos_cos = cos;\n }\n}\n\n// @ts-ignore: decorator\n@lazy var rempio2f_y: f64;\n\n// @ts-ignore: decorator\n@lazy @inline const PIO2F_TABLE = memory.data([\n 0xA2F9836E4E441529,\n 0xFC2757D1F534DDC0,\n 0xDB6295993C439041,\n 0xFE5163ABDEBBC561\n]);\n\nfunction Rf(z: f32): f32 { // Rational approximation of (asin(x)-x)/x^3\n const // see: musl/src/math/asinf.c and SUN COPYRIGHT NOTICE above\n pS0 = reinterpret(0x3E2AAA75), // 1.6666586697e-01f\n pS1 = reinterpret(0xBD2F13BA), // -4.2743422091e-02f\n pS2 = reinterpret(0xBC0DD36B), // -8.6563630030e-03f\n qS1 = reinterpret(0xBF34E5AE); // -7.0662963390e-01f\n\n var p = z * (pS0 + z * (pS1 + z * pS2));\n var q: f32 = 1 + z * qS1;\n return p / q;\n}\n\n// @ts-ignore: decorator\n@inline\nfunction expo2f(x: f32, sign: f32): f32 { // exp(x)/2 for x >= log(DBL_MAX)\n const // see: musl/src/math/__expo2f.c\n k = 235,\n kln2 = reinterpret(0x4322E3BC); // 0x1.45c778p+7f\n var scale = reinterpret(u32(0x7F + (k >> 1)) << 23);\n // in directed rounding correct sign before rounding or overflow is important\n return NativeMathf.exp(x - kln2) * (sign * scale) * scale;\n}\n\n// @ts-ignore: decorator\n@inline\nfunction pio2f_large_quot(x: f32, u: i32): i32 { // see: jdh8/metallic/blob/master/src/math/float/rem_pio2f.c\n const coeff = reinterpret(0x3BF921FB54442D18); // π * 0x1p-65 = 8.51530395021638647334e-20\n\n var offset = (u >> 23) - 152;\n var shift = u64(offset & 63);\n var tblPtr = PIO2F_TABLE + (offset >> 6 << 3);\n\n var b0 = load(tblPtr, 0 << 3);\n var b1 = load(tblPtr, 1 << 3);\n var lo: u64;\n\n if (shift > 32) {\n let b2 = load(tblPtr, 2 << 3);\n lo = b2 >> (96 - shift);\n lo |= b1 << (shift - 32);\n } else {\n lo = b1 >> (32 - shift);\n }\n\n var hi = (b1 >> (64 - shift)) | (b0 << shift);\n var mantissa: u64 = (u & 0x007FFFFF) | 0x00800000;\n var product = mantissa * hi + (mantissa * lo >> 32);\n var r: i64 = product << 2;\n var q = i32((product >> 62) + (r >>> 63));\n rempio2f_y = copysign(coeff, x) * r;\n return q;\n}\n\n// @ts-ignore: decorator\n@inline\nfunction rempio2f(x: f32, u: u32, sign: i32): i32 { // see: jdh8/metallic/blob/master/src/math/float/rem_pio2f.c\n const\n pi2hi = reinterpret(0x3FF921FB50000000), // 1.57079631090164184570\n pi2lo = reinterpret(0x3E5110B4611A6263), // 1.58932547735281966916e-8\n _2_pi = reinterpret(0x3FE45F306DC9C883); // 0.63661977236758134308\n\n if (u < 0x4DC90FDB) { // π * 0x1p28\n let q = nearest(x * _2_pi);\n rempio2f_y = x - q * pi2hi - q * pi2lo;\n return q;\n }\n\n var q = pio2f_large_quot(x, u);\n return select(-q, q, sign);\n}\n\n// |sin(x)/x - s(x)| < 2**-37.5 (~[-4.89e-12, 4.824e-12]).\n// @ts-ignore: decorator\n@inline\nfunction sin_kernf(x: f64): f32 { // see: musl/tree/src/math/__sindf.c\n const\n S1 = reinterpret(0xBFC5555554CBAC77), // -0x15555554cbac77.0p-55\n S2 = reinterpret(0x3F811110896EFBB2), // 0x111110896efbb2.0p-59\n S3 = reinterpret(0xBF2A00F9E2CAE774), // -0x1a00f9e2cae774.0p-65\n S4 = reinterpret(0x3EC6CD878C3B46A7); // 0x16cd878c3b46a7.0p-71\n\n var z = x * x;\n var w = z * z;\n var r = S3 + z * S4;\n var s = z * x;\n return f32((x + s * (S1 + z * S2)) + s * w * r);\n}\n\n// |cos(x) - c(x)| < 2**-34.1 (~[-5.37e-11, 5.295e-11]).\n// @ts-ignore: decorator\n@inline\nfunction cos_kernf(x: f64): f32 { // see: musl/tree/src/math/__cosdf.c\n const\n C0 = reinterpret(0xBFDFFFFFFD0C5E81), // -0x1ffffffd0c5e81.0p-54\n C1 = reinterpret(0x3FA55553E1053A42), // 0x155553e1053a42.0p-57\n C2 = reinterpret(0xBF56C087E80F1E27), // -0x16c087e80f1e27.0p-62\n C3 = reinterpret(0x3EF99342E0EE5069); // 0x199342e0ee5069.0p-68\n\n var z = x * x;\n var w = z * z;\n var r = C2 + z * C3;\n return f32(((1 + z * C0) + w * C1) + (w * z) * r);\n}\n\n// |tan(x)/x - t(x)| < 2**-25.5 (~[-2e-08, 2e-08]).\n// @ts-ignore: decorator\n@inline\nfunction tan_kernf(x: f64, odd: i32): f32 { // see: musl/tree/src/math/__tandf.c\n const\n T0 = reinterpret(0x3FD5554D3418C99F), // 0x15554d3418c99f.0p-54\n T1 = reinterpret(0x3FC112FD38999F72), // 0x1112fd38999f72.0p-55\n T2 = reinterpret(0x3FAB54C91D865AFE), // 0x1b54c91d865afe.0p-57\n T3 = reinterpret(0x3F991DF3908C33CE), // 0x191df3908c33ce.0p-58\n T4 = reinterpret(0x3F685DADFCECF44E), // 0x185dadfcecf44e.0p-61\n T5 = reinterpret(0x3F8362B9BF971BCD); // 0x1362b9bf971bcd.0p-59\n\n var z = x * x;\n var r = T4 + z * T5;\n var t = T2 + z * T3;\n var w = z * z;\n var s = z * x;\n var u = T0 + z * T1;\n\n r = (x + s * u) + (s * w) * (t + w * r);\n return f32(odd ? -1 / r : r);\n}\n\n// See: jdh8/metallic/src/math/float/log2f.c and jdh8/metallic/src/math/float/kernel/atanh.h\n// @ts-ignore: decorator\n@inline\nfunction log2f(x: f64): f64 {\n const\n log2e = reinterpret(0x3FF71547652B82FE), // 1.44269504088896340736\n c0 = reinterpret(0x3FD555554FD9CAEF), // 0.33333332822728226129\n c1 = reinterpret(0x3FC999A7A8AF4132), // 0.20000167595436263505\n c2 = reinterpret(0x3FC2438D79437030), // 0.14268654271188685375\n c3 = reinterpret(0x3FBE2F663B001C97); // 0.11791075649681414150\n\n var i = reinterpret(x);\n var exponent = (i - 0x3FE6A09E667F3BCD) >> 52;\n x = reinterpret(i - (exponent << 52));\n x = (x - 1) / (x + 1);\n var xx = x * x;\n var y = x + x * xx * (c0 + c1 * xx + (c2 + c3 * xx) * (xx * xx));\n return (2 * log2e) * y + exponent;\n}\n\n// See: jdh8/metallic/src/math/float/exp2f.h and jdh8/metallic/blob/master/src/math/float/kernel/exp2f.h\n// @ts-ignore: decorator\n@inline\nfunction exp2f(x: f64): f64 {\n const\n c0 = reinterpret(0x3FE62E4302FCC24A), // 6.931471880289532425e-1\n c1 = reinterpret(0x3FCEBFBE07D97B91), // 2.402265108421173406e-1\n c2 = reinterpret(0x3FAC6AF6CCFC1A65), // 5.550357105498874537e-2\n c3 = reinterpret(0x3F83B29E3CE9AEF6), // 9.618030771171497658e-3\n c4 = reinterpret(0x3F55F0896145A89F), // 1.339086685300950937e-3\n c5 = reinterpret(0x3F2446C81E384864); // 1.546973499989028719e-4\n\n if (x < -1022) return 0;\n if (x >= 1024) return Infinity;\n\n var n = nearest(x);\n x -= n;\n var xx = x * x;\n var y = 1 + x * (c0 + c1 * x + (c2 + c3 * x) * xx + (c4 + c5 * x) * (xx * xx));\n return reinterpret(reinterpret(y) + (n << 52));\n}\n\nexport namespace NativeMathf {\n\n // @ts-ignore: decorator\n @lazy\n export const E = NativeMath.E;\n\n // @ts-ignore: decorator\n @lazy\n export const LN2 = NativeMath.LN2;\n\n // @ts-ignore: decorator\n @lazy\n export const LN10 = NativeMath.LN10;\n\n // @ts-ignore: decorator\n @lazy\n export const LOG2E = NativeMath.LOG2E;\n\n // @ts-ignore: decorator\n @lazy\n export const LOG10E = NativeMath.LOG10E;\n\n // @ts-ignore: decorator\n @lazy\n export const PI = NativeMath.PI;\n\n // @ts-ignore: decorator\n @lazy\n export const SQRT1_2 = NativeMath.SQRT1_2;\n\n // @ts-ignore: decorator\n @lazy\n export const SQRT2 = NativeMath.SQRT2;\n\n // @ts-ignore: decorator\n @lazy\n export var sincos_sin: f32 = 0;\n\n // @ts-ignore: decorator\n @lazy\n export var sincos_cos: f32 = 0;\n\n // @ts-ignore: decorator\n @inline\n export function abs(x: f32): f32 {\n return builtin_abs(x);\n }\n\n export function acos(x: f32): f32 { // see: musl/src/math/acosf.c and SUN COPYRIGHT NOTICE above\n const\n pio2_hi = reinterpret(0x3FC90FDA), // 1.5707962513e+00f\n pio2_lo = reinterpret(0x33A22168), // 7.5497894159e-08f\n Ox1p_120f = reinterpret(0x03800000); // 0x1p-120f\n\n var hx = reinterpret(x);\n var ix = hx & 0x7FFFFFFF;\n if (ix >= 0x3F800000) {\n if (ix == 0x3F800000) {\n return select(2 * pio2_hi + Ox1p_120f, 0, hx < 0);\n }\n return 0 / (x - x);\n }\n if (ix < 0x3F000000) {\n if (ix <= 0x32800000) return pio2_hi + Ox1p_120f;\n return pio2_hi - (x - (pio2_lo - x * Rf(x * x)));\n }\n var z: f32, w: f32, s: f32;\n if (hx < 0) {\n // z = (1 + x) * 0.5;\n z = 0.5 + x * 0.5;\n s = builtin_sqrt(z);\n w = Rf(z) * s - pio2_lo;\n return 2 * (pio2_hi - (s + w));\n }\n // z = (1 - x) * 0.5;\n z = 0.5 - x * 0.5;\n s = builtin_sqrt(z);\n hx = reinterpret(s);\n var df = reinterpret(hx & 0xFFFFF000);\n var c = (z - df * df) / (s + df);\n w = Rf(z) * s + c;\n return 2 * (df + w);\n }\n\n export function acosh(x: f32): f32 { // see: musl/src/math/acoshf.c\n const s = reinterpret(0x3F317218); // 0.693147180559945309417232121458176568f\n var u = reinterpret(x);\n var a = u & 0x7FFFFFFF;\n if (a < 0x3F800000 + (1 << 23)) { // |x| < 2, invalid if x < 1\n let xm1 = x - 1;\n return log1p(xm1 + builtin_sqrt(xm1 * (xm1 + 2)));\n }\n if (u < 0x3F800000 + (12 << 23)) { // 2 <= x < 0x1p12\n return log(2 * x - 1 / (x + builtin_sqrt(x * x - 1)));\n }\n // x >= 0x1p12 or x <= -2 or NaN\n return log(x) + s;\n }\n\n export function asin(x: f32): f32 { // see: musl/src/math/asinf.c and SUN COPYRIGHT NOTICE above\n const\n pio2 = reinterpret(0x3FC90FDB), // 1.570796326794896558e+00f\n Ox1p_120f = reinterpret(0x03800000); // 0x1p-120f\n\n var sx = x;\n var hx = reinterpret(x) & 0x7FFFFFFF;\n if (hx >= 0x3F800000) {\n if (hx == 0x3F800000) return x * pio2 + Ox1p_120f;\n return 0 / (x - x);\n }\n if (hx < 0x3F000000) {\n if (hx < 0x39800000 && hx >= 0x00800000) return x;\n return x + x * Rf(x * x);\n }\n // var z: f32 = (1 - builtin_abs(x)) * 0.5;\n var z: f32 = 0.5 - builtin_abs(x) * 0.5;\n var s = builtin_sqrt(z); // sic\n x = f32(pio2 - 2 * (s + s * Rf(z)));\n return builtin_copysign(x, sx);\n }\n\n export function asinh(x: f32): f32 { // see: musl/src/math/asinhf.c\n const c = reinterpret(0x3F317218); // 0.693147180559945309417232121458176568f\n var u = reinterpret(x) & 0x7FFFFFFF;\n var y = reinterpret(u);\n if (u >= 0x3F800000 + (12 << 23)) y = log(y) + c;\n else if (u >= 0x3F800000 + (1 << 23)) y = log(2 * y + 1 / (builtin_sqrt(y * y + 1) + y));\n else if (u >= 0x3F800000 - (12 << 23)) y = log1p(y + y * y / (builtin_sqrt(y * y + 1) + 1));\n return builtin_copysign(y, x);\n }\n\n export function atan(x: f32): f32 { // see: musl/src/math/atanf.c and SUN COPYRIGHT NOTICE above\n const\n atanhi0 = reinterpret(0x3EED6338), // 4.6364760399e-01f\n atanhi1 = reinterpret(0x3F490FDA), // 7.8539812565e-01f\n atanhi2 = reinterpret(0x3F7B985E), // 9.8279368877e-01f\n atanhi3 = reinterpret(0x3FC90FDA), // 1.5707962513e+00f\n atanlo0 = reinterpret(0x31AC3769), // 5.0121582440e-09f\n atanlo1 = reinterpret(0x33222168), // 3.7748947079e-08f\n atanlo2 = reinterpret(0x33140FB4), // 3.4473217170e-08f\n atanlo3 = reinterpret(0x33A22168), // 7.5497894159e-08f\n aT0 = reinterpret(0x3EAAAAA9), // 3.3333328366e-01f\n aT1 = reinterpret(0xBE4CCA98), // -1.9999158382e-01f\n aT2 = reinterpret(0x3E11F50D), // 1.4253635705e-01f\n aT3 = reinterpret(0xBDDA1247), // -1.0648017377e-01f\n aT4 = reinterpret(0x3D7CAC25), // 6.1687607318e-02f\n Ox1p_120f = reinterpret(0x03800000); // 0x1p-120f\n\n var ix = reinterpret(x);\n var sx = x;\n ix &= 0x7FFFFFFF;\n var z: f32;\n if (ix >= 0x4C800000) {\n if (isNaN(x)) return x;\n z = atanhi3 + Ox1p_120f;\n return builtin_copysign(z, sx);\n }\n var id: i32;\n if (ix < 0x3EE00000) {\n if (ix < 0x39800000) return x;\n id = -1;\n } else {\n x = builtin_abs(x);\n if (ix < 0x3F980000) {\n if (ix < 0x3F300000) {\n id = 0;\n x = (2.0 * x - 1.0) / (2.0 + x);\n } else {\n id = 1;\n x = (x - 1.0) / (x + 1.0);\n }\n } else {\n if (ix < 0x401C0000) {\n id = 2;\n x = (x - 1.5) / (1.0 + 1.5 * x);\n } else {\n id = 3;\n x = -1.0 / x;\n }\n }\n }\n z = x * x;\n var w = z * z;\n var s1 = z * (aT0 + w * (aT2 + w * aT4));\n var s2 = w * (aT1 + w * aT3);\n var s3 = x * (s1 + s2);\n if (id < 0) return x - s3;\n switch (id) {\n case 0: { z = atanhi0 - ((s3 - atanlo0) - x); break; }\n case 1: { z = atanhi1 - ((s3 - atanlo1) - x); break; }\n case 2: { z = atanhi2 - ((s3 - atanlo2) - x); break; }\n case 3: { z = atanhi3 - ((s3 - atanlo3) - x); break; }\n default: unreachable();\n }\n return builtin_copysign(z, sx);\n }\n\n export function atanh(x: f32): f32 { // see: musl/src/math/atanhf.c\n var u = reinterpret(x);\n var y = builtin_abs(x);\n if (u < 0x3F800000 - (1 << 23)) {\n if (u >= 0x3F800000 - (32 << 23)) y = 0.5 * log1p(2 * y * (1.0 + y / (1 - y)));\n } else y = 0.5 * log1p(2 * (y / (1 - y)));\n return builtin_copysign(y, x);\n }\n\n export function atan2(y: f32, x: f32): f32 { // see: musl/src/math/atan2f.c and SUN COPYRIGHT NOTICE above\n const\n pi = reinterpret(0x40490FDB), // 3.1415927410e+00f\n pi_lo = reinterpret(0xB3BBBD2E); // -8.7422776573e-08f\n\n if (isNaN(x) || isNaN(y)) return x + y;\n var ix = reinterpret(x);\n var iy = reinterpret(y);\n if (ix == 0x3F800000) return atan(y);\n var m = u32(((iy >> 31) & 1) | ((ix >> 30) & 2));\n ix &= 0x7FFFFFFF;\n iy &= 0x7FFFFFFF;\n if (iy == 0) {\n switch (m) {\n case 0:\n case 1: return y;\n case 2: return pi;\n case 3: return -pi;\n }\n }\n if (ix == 0) return m & 1 ? -pi / 2 : pi / 2;\n if (ix == 0x7F800000) {\n if (iy == 0x7F800000) {\n let t: f32 = m & 2 ? 3 * pi / 4 : pi / 4;\n return m & 1 ? -t : t;\n } else {\n let t: f32 = m & 2 ? pi : 0.0;\n return m & 1 ? -t : t;\n }\n }\n if (ix + (26 << 23) < iy || iy == 0x7F800000) return m & 1 ? -pi / 2 : pi / 2;\n var z: f32;\n if ((m & 2) && iy + (26 << 23) < ix) z = 0.0;\n else z = atan(builtin_abs(y / x));\n switch (m) {\n case 0: return z;\n case 1: return -z;\n case 2: return pi - (z - pi_lo);\n case 3: return (z - pi_lo) - pi;\n }\n unreachable();\n return 0;\n }\n\n export function cbrt(x: f32): f32 { // see: musl/src/math/cbrtf.c and SUN COPYRIGHT NOTICE above\n const\n B1 = 709958130,\n B2 = 642849266,\n Ox1p24f = reinterpret(0x4B800000);\n\n var u = reinterpret(x);\n var hx = u & 0x7FFFFFFF;\n if (hx >= 0x7F800000) return x + x;\n if (hx < 0x00800000) {\n if (hx == 0) return x;\n u = reinterpret(x * Ox1p24f);\n hx = u & 0x7FFFFFFF;\n hx = hx / 3 + B2;\n } else {\n hx = hx / 3 + B1;\n }\n u &= 0x80000000;\n u |= hx;\n var t = reinterpret(u);\n var r = t * t * t;\n t = t * (x + x + r) / (x + r + r);\n r = t * t * t;\n t = t * (x + x + r) / (x + r + r);\n return t;\n }\n\n // @ts-ignore: decorator\n @inline\n export function ceil(x: f32): f32 {\n return builtin_ceil(x);\n }\n\n export function clz32(x: f32): f32 {\n if (!isFinite(x)) return 32;\n return builtin_clz(dtoi32(x));\n }\n\n export function cos(x: f32): f32 { // see: musl/src/math/cosf.c\n const\n c1pio2 = reinterpret(0x3FF921FB54442D18), // M_PI_2 * 1\n c2pio2 = reinterpret(0x400921FB54442D18), // M_PI_2 * 2\n c3pio2 = reinterpret(0x4012D97C7F3321D2), // M_PI_2 * 3\n c4pio2 = reinterpret(0x401921FB54442D18); // M_PI_2 * 4\n\n var ux = reinterpret(x);\n var sign = ux >> 31;\n ux &= 0x7FFFFFFF;\n\n if (ux <= 0x3F490FDA) { // |x| ~<= π/4\n if (ux < 0x39800000) { // |x| < 2**-12\n // raise inexact if x != 0\n return 1;\n }\n return cos_kernf(x);\n }\n\n if (ASC_SHRINK_LEVEL < 1) {\n if (ux <= 0x407B53D1) { // |x| ~<= 5π/4\n if (ux > 0x4016CBE3) { // |x| ~> 3π/4\n return -cos_kernf(sign ? x + c2pio2 : x - c2pio2);\n } else {\n return sign ? sin_kernf(x + c1pio2) : sin_kernf(c1pio2 - x);\n }\n }\n if (ux <= 0x40E231D5) { // |x| ~<= 9π/4\n if (ux > 0x40AFEDDF) { // |x| ~> 7π/4\n return cos_kernf(sign ? x + c4pio2 : x - c4pio2);\n } else {\n return sign ? sin_kernf(-x - c3pio2) : sin_kernf(x - c3pio2);\n }\n }\n }\n\n // cos(Inf or NaN) is NaN\n if (ux >= 0x7F800000) return x - x;\n\n // general argument reduction needed\n var n = rempio2f(x, ux, sign);\n var y = rempio2f_y;\n\n var t = n & 1 ? sin_kernf(y) : cos_kernf(y);\n return (n + 1) & 2 ? -t : t;\n }\n\n export function cosh(x: f32): f32 { // see: musl/src/math/coshf.c\n var u = reinterpret(x);\n u &= 0x7FFFFFFF;\n x = reinterpret(u);\n if (u < 0x3F317217) {\n if (u < 0x3F800000 - (12 << 23)) return 1;\n let t = expm1(x);\n // return 1 + t * t / (2 * (1 + t));\n return 1 + t * t / (2 + 2 * t);\n }\n if (u < 0x42B17217) {\n let t = exp(x);\n // return 0.5 * (t + 1 / t);\n return 0.5 * t + 0.5 / t;\n }\n return expo2f(x, 1);\n }\n\n // @ts-ignore: decorator\n @inline\n export function floor(x: f32): f32 {\n return builtin_floor(x);\n }\n\n export function exp(x: f32): f32 { // see: musl/src/math/expf.c and SUN COPYRIGHT NOTICE above\n if (ASC_SHRINK_LEVEL < 1) {\n return expf_lut(x);\n } else {\n const\n ln2hi = reinterpret(0x3F317200), // 6.9314575195e-1f\n ln2lo = reinterpret(0x35BFBE8E), // 1.4286067653e-6f\n invln2 = reinterpret(0x3FB8AA3B), // 1.4426950216e+0f\n P1 = reinterpret(0x3E2AAA8F), // 1.6666625440e-1f\n P2 = reinterpret(0xBB355215), // -2.7667332906e-3f\n Ox1p127f = reinterpret(0x7F000000); // 0x1p+127f\n\n let hx = reinterpret(x);\n let sign = hx >> 31;\n hx &= 0x7FFFFFFF;\n if (hx >= 0x42AEAC50) {\n if (hx > 0x7F800000) return x; // NaN\n if (hx >= 0x42B17218) {\n if (!sign) return x * Ox1p127f;\n else if (hx >= 0x42CFF1B5) return 0;\n }\n }\n let hi: f32, lo: f32;\n let k: i32;\n if (hx > 0x3EB17218) {\n if (hx > 0x3F851592) {\n k = i32(invln2 * x + builtin_copysign(0.5, x));\n } else {\n k = 1 - (sign << 1);\n }\n hi = x - k * ln2hi;\n lo = k * ln2lo;\n x = hi - lo;\n } else if (hx > 0x39000000) {\n k = 0;\n hi = x;\n lo = 0;\n } else {\n return 1 + x;\n }\n let xx = x * x;\n let c = x - xx * (P1 + xx * P2);\n let y: f32 = 1 + (x * c / (2 - c) - lo + hi);\n return k == 0 ? y : scalbn(y, k);\n }\n }\n\n export function exp2(x: f32): f32 {\n return exp2f_lut(x);\n }\n\n export function expm1(x: f32): f32 { // see: musl/src/math/expm1f.c and SUN COPYRIGHT NOTICE above\n const\n ln2_hi = reinterpret(0x3F317180), // 6.9313812256e-01f\n ln2_lo = reinterpret(0x3717F7D1), // 9.0580006145e-06f\n invln2 = reinterpret(0x3FB8AA3B), // 1.4426950216e+00f\n Q1 = reinterpret(0xBD088868), // -3.3333212137e-02f\n Q2 = reinterpret(0x3ACF3010), // 1.5807170421e-03f\n Ox1p127f = reinterpret(0x7F000000); // 0x1p+127f\n\n var u = reinterpret(x);\n var hx = u & 0x7FFFFFFF;\n var sign = u >> 31;\n if (hx >= 0x4195B844) {\n if (hx > 0x7F800000) return x;\n if (sign) return -1;\n if (hx > 0x42B17217) { // x > log(FLT_MAX)\n x *= Ox1p127f;\n return x;\n }\n }\n var c: f32 = 0.0, t: f32, k: i32;\n if (hx > 0x3EB17218) {\n k = select(\n 1 - (sign << 1),\n i32(invln2 * x + builtin_copysign(0.5, x)),\n hx < 0x3F851592\n );\n t = k;\n let hi = x - t * ln2_hi;\n let lo = t * ln2_lo;\n x = hi - lo;\n c = (hi - x) - lo;\n } else if (hx < 0x33000000) {\n return x;\n } else k = 0;\n var hfx: f32 = 0.5 * x;\n var hxs: f32 = x * hfx;\n var r1: f32 = 1.0 + hxs * (Q1 + hxs * Q2);\n t = 3.0 - r1 * hfx;\n var e = hxs * ((r1 - t) / (6.0 - x * t));\n if (k == 0) return x - (x * e - hxs);\n e = x * (e - c) - c;\n e -= hxs;\n if (k == -1) return 0.5 * (x - e) - 0.5;\n if (k == 1) {\n if (x < -0.25) return -2.0 * (e - (x + 0.5));\n return 1.0 + 2.0 * (x - e);\n }\n u = (0x7F + k) << 23;\n var twopk = reinterpret(u);\n var y: f32;\n if (k < 0 || k > 56) {\n y = x - e + 1.0;\n if (k == 128) y = y * 2.0 * Ox1p127f;\n else y = y * twopk;\n return y - 1.0;\n }\n u = (0x7F - k) << 23;\n y = reinterpret(u);\n if (k < 20) y = (1 - y) - e;\n else y = 1 - (e + y);\n return (x + y) * twopk;\n }\n\n // @ts-ignore: decorator\n @inline\n export function fround(x: f32): f32 {\n return x;\n }\n\n export function hypot(x: f32, y: f32): f32 { // see: musl/src/math/hypotf.c\n const\n Ox1p90f = reinterpret(0x6C800000),\n Ox1p_90f = reinterpret(0x12800000);\n\n var ux = reinterpret(x);\n var uy = reinterpret(y);\n ux &= 0x7FFFFFFF;\n uy &= 0x7FFFFFFF;\n if (ux < uy) {\n let ut = ux;\n ux = uy;\n uy = ut;\n }\n x = reinterpret(ux);\n y = reinterpret(uy);\n if (uy == 0xFF << 23) return y;\n if (ux >= 0xFF << 23 || uy == 0 || ux - uy >= 25 << 23) return x + y;\n var z: f32 = 1;\n if (ux >= (0x7F + 60) << 23) {\n z = Ox1p90f;\n x *= Ox1p_90f;\n y *= Ox1p_90f;\n } else if (uy < (0x7F - 60) << 23) {\n z = Ox1p_90f;\n x *= Ox1p90f;\n y *= Ox1p90f;\n }\n return z * builtin_sqrt(f32(x * x + y * y));\n }\n\n // @ts-ignore: decorator\n @inline\n export function imul(x: f32, y: f32): f32 {\n /*\n * Wasm (MVP) and JS have different approaches for double->int conversions.\n *\n * For emulate JS conversion behavior and avoid trapping from wasm we should modulate by MAX_INT\n * our float-point arguments before actual convertion to integers.\n */\n if (!isFinite(x + y)) return 0;\n return (dtoi32(x) * dtoi32(y));\n }\n\n export function log(x: f32): f32 { // see: musl/src/math/logf.c and SUN COPYRIGHT NOTICE above\n if (ASC_SHRINK_LEVEL < 1) {\n return logf_lut(x);\n } else {\n const\n ln2_hi = reinterpret(0x3F317180), // 6.9313812256e-01f\n ln2_lo = reinterpret(0x3717F7D1), // 9.0580006145e-06f\n Lg1 = reinterpret(0x3F2AAAAA), // 0xaaaaaa.0p-24f\n Lg2 = reinterpret(0x3ECCCE13), // 0xccce13.0p-25f\n Lg3 = reinterpret(0x3E91E9EE), // 0x91e9ee.0p-25f\n Lg4 = reinterpret(0x3E789E26), // 0xf89e26.0p-26f\n Ox1p25f = reinterpret(0x4C000000);\n\n let u = reinterpret(x);\n let k = 0;\n let sign = u >> 31;\n if (sign || u < 0x00800000) {\n if (u << 1 == 0) return -1 / (x * x);\n if (sign) return (x - x) / 0;\n k -= 25;\n x *= Ox1p25f;\n u = reinterpret(x);\n } else if (u >= 0x7F800000) {\n return x;\n } else if (u == 0x3F800000) {\n return 0;\n }\n u += 0x3F800000 - 0x3F3504F3;\n k += i32(u >> 23) - 0x7F;\n u = (u & 0x007FFFFF) + 0x3F3504F3;\n x = reinterpret(u);\n let f = x - 1.0;\n let s = f / (2.0 + f);\n let z = s * s;\n let w = z * z;\n let t1 = w * (Lg2 + w * Lg4);\n let t2 = z * (Lg1 + w * Lg3);\n let r = t2 + t1;\n let hfsq = 0.5 * f * f;\n let dk = k;\n return s * (hfsq + r) + dk * ln2_lo - hfsq + f + dk * ln2_hi;\n }\n }\n\n export function log10(x: f32): f32 { // see: musl/src/math/log10f.c and SUN COPYRIGHT NOTICE above\n const\n ivln10hi = reinterpret(0x3EDE6000), // 4.3432617188e-01f\n ivln10lo = reinterpret(0xB804EAD9), // -3.1689971365e-05f\n log10_2hi = reinterpret(0x3E9A2080), // 3.0102920532e-01f\n log10_2lo = reinterpret(0x355427DB), // 7.9034151668e-07f\n Lg1 = reinterpret(0x3F2AAAAA), // 0xaaaaaa.0p-24f, 0.66666662693f\n Lg2 = reinterpret(0x3ECCCE13), // 0xccce13.0p-25f, 0.40000972152f\n Lg3 = reinterpret(0x3E91E9EE), // 0x91e9ee.0p-25f, 0.28498786688f\n Lg4 = reinterpret(0x3E789E26), // 0xf89e26.0p-26f, 0.24279078841f\n Ox1p25f = reinterpret(0x4C000000); // 0x1p25f\n\n var ux = reinterpret(x);\n var k = 0;\n var sign = ux >> 31;\n if (sign || ux < 0x00800000) {\n if (ux << 1 == 0) return -1 / (x * x);\n if (sign) return (x - x) / 0.0;\n k -= 25;\n x *= Ox1p25f;\n ux = reinterpret(x);\n } else if (ux >= 0x7F800000) {\n return x;\n } else if (ux == 0x3F800000) {\n return 0;\n }\n ux += 0x3F800000 - 0x3F3504F3;\n k += i32(ux >> 23) - 0x7F;\n ux = (ux & 0x007FFFFF) + 0x3F3504F3;\n x = reinterpret(ux);\n var f = x - 1.0;\n var s = f / (2.0 + f);\n var z = s * s;\n var w = z * z;\n var t1 = w * (Lg2 + w * Lg4);\n var t2 = z * (Lg1 + w * Lg3);\n var r = t2 + t1;\n var hfsq: f32 = 0.5 * f * f;\n var hi = f - hfsq;\n ux = reinterpret(hi);\n ux &= 0xFFFFF000;\n hi = reinterpret(ux);\n var lo = f - hi - hfsq + s * (hfsq + r);\n var dk = k;\n return dk * log10_2lo + (lo + hi) * ivln10lo + lo * ivln10hi + hi * ivln10hi + dk * log10_2hi;\n }\n\n export function log1p(x: f32): f32 { // see: musl/src/math/log1pf.c and SUN COPYRIGHT NOTICE above\n const\n ln2_hi = reinterpret(0x3F317180), // 6.9313812256e-01\n ln2_lo = reinterpret(0x3717F7D1), // 9.0580006145e-06\n Lg1 = reinterpret(0x3F2AAAAA), // 0xaaaaaa.0p-24f, 0.66666662693f\n Lg2 = reinterpret(0x3ECCCE13), // 0xccce13.0p-25f, 0.40000972152f\n Lg3 = reinterpret(0x3E91E9EE), // 0x91e9ee.0p-25f, 0.28498786688f\n Lg4 = reinterpret(0x3E789E26); // 0xf89e26.0p-26f, 0.24279078841f\n\n var ix = reinterpret(x);\n var c: f32 = 0;\n var f: f32 = 0;\n var k = 1;\n if (ix < 0x3ED413D0 || bool(ix >> 31)) {\n if (ix >= 0xBF800000) {\n if (x == -1) return x / 0.0;\n return (x - x) / 0.0;\n }\n if (ix << 1 < 0x33800000 << 1) return x;\n if (ix <= 0xBE95F619) {\n k = 0;\n c = 0;\n f = x;\n }\n } else if (ix >= 0x7F800000) return x;\n if (k) {\n let uf: f32 = 1 + x;\n let iu = reinterpret(uf);\n iu += 0x3F800000 - 0x3F3504F3;\n k = i32(iu >> 23) - 0x7F;\n if (k < 25) {\n c = k >= 2 ? 1 - (uf - x) : x - (uf - 1);\n c /= uf;\n } else c = 0;\n iu = (iu & 0x007FFFFF) + 0x3F3504F3;\n f = reinterpret(iu) - 1;\n }\n var s = f / (2.0 + f);\n var z = s * s;\n var w = z * z;\n var t1 = w * (Lg2 + w * Lg4);\n var t2 = z * (Lg1 + w * Lg3);\n var r = t2 + t1;\n var hfsq: f32 = 0.5 * f * f;\n var dk = k;\n return s * (hfsq + r) + (dk * ln2_lo + c) - hfsq + f + dk * ln2_hi;\n }\n\n export function log2(x: f32): f32 { // see: musl/src/math/log2f.c and SUN COPYRIGHT NOTICE above\n if (ASC_SHRINK_LEVEL < 1) {\n return log2f_lut(x);\n } else {\n const\n ivln2hi = reinterpret(0x3FB8B000), // 1.4428710938e+00f\n ivln2lo = reinterpret(0xB9389AD4), // -1.7605285393e-04\n Lg1 = reinterpret(0x3F2AAAAA), // 0xaaaaaa.0p-24f, 0.66666662693f\n Lg2 = reinterpret(0x3ECCCE13), // 0xccce13.0p-25f, 0.40000972152f\n Lg3 = reinterpret(0x3E91E9EE), // 0x91e9ee.0p-25f, 0.28498786688f\n Lg4 = reinterpret(0x3E789E26), // 0xf89e26.0p-26f, 0.24279078841f\n Ox1p25f = reinterpret(0x4C000000); // 0x1p25f\n\n let ux = reinterpret(x);\n let k = 0;\n let sign = ux >> 31;\n if (sign || ux < 0x00800000) {\n if (ux << 1 == 0) return -1 / (x * x);\n if (sign) return (x - x) / 0.0;\n k -= 25;\n x *= Ox1p25f;\n ux = reinterpret(x);\n } else if (ux >= 0x7F800000) {\n return x;\n } else if (ux == 0x3F800000) {\n return 0;\n }\n ux += 0x3F800000 - 0x3F3504F3;\n k += i32(ux >> 23) - 0x7F;\n ux = (ux & 0x007FFFFF) + 0x3F3504F3;\n x = reinterpret(ux);\n let f = x - 1.0;\n let s = f / (2.0 + f);\n let z = s * s;\n let w = z * z;\n let t1 = w * (Lg2 + w * Lg4);\n let t2 = z * (Lg1 + w * Lg3);\n let r = t2 + t1;\n let hfsq: f32 = 0.5 * f * f;\n let hi = f - hfsq;\n let u = reinterpret(hi);\n u &= 0xFFFFF000;\n hi = reinterpret(u);\n let lo: f32 = f - hi - hfsq + s * (hfsq + r);\n let dk = k;\n return (lo + hi) * ivln2lo + lo * ivln2hi + hi * ivln2hi + dk;\n }\n }\n\n // @ts-ignore: decorator\n @inline\n export function max(value1: f32, value2: f32): f32 {\n return builtin_max(value1, value2);\n }\n\n // @ts-ignore: decorator\n @inline\n export function min(value1: f32, value2: f32): f32 {\n return builtin_min(value1, value2);\n }\n\n export function pow(x: f32, y: f32): f32 {\n // TODO: remove this fast pathes after introduced own mid-end IR with \"stdlib call simplify\" transforms\n if (builtin_abs(y) <= 2) {\n if (y == 2.0) return x * x;\n if (y == 0.5) {\n return select(\n builtin_abs(builtin_sqrt(x)),\n Infinity,\n x != -Infinity\n );\n }\n if (y == -1.0) return 1 / x;\n if (y == 1.0) return x;\n if (y == 0.0) return 1.0;\n }\n if (ASC_SHRINK_LEVEL < 1) {\n // see: musl/src/math/powf.c\n return powf_lut(x, y);\n } else {\n // based on: jdh8/metallic/src/math/float/powf.c\n if (y == 0) return 1;\n // @ts-ignore: cast\n if (isNaN(x) | isNaN(y)) {\n return NaN;\n }\n let sign: u32 = 0;\n let uy = reinterpret(y);\n let ux = reinterpret(x);\n let sx = ux >> 31;\n ux &= 0x7FFFFFFF;\n if (sx && nearest(y) == y) {\n x = -x;\n sx = 0;\n sign = u32(nearest(y * 0.5) != y * 0.5) << 31;\n }\n let m: u32;\n if (ux == 0x3F800000) { // x == 1\n m = sx | u32((uy & 0x7FFFFFFF) == 0x7F800000) ? 0x7FC00000 : 0x3F800000;\n } else if (ux == 0) {\n m = uy < 0 ? 0x7F800000 : 0;\n } else if (ux == 0x7F800000) {\n m = uy < 0 ? 0 : 0x7F800000;\n } else if (sx) {\n m = 0x7FC00000;\n } else {\n m = reinterpret(exp2f(y * log2f(x)));\n }\n return reinterpret(m | sign);\n }\n }\n\n // @ts-ignore: decorator\n @inline\n export function seedRandom(value: i64): void {\n NativeMath.seedRandom(value);\n }\n\n // Using xoroshiro64starstar from http://xoshiro.di.unimi.it/xoroshiro64starstar.c\n export function random(): f32 {\n if (!random_seeded) seedRandom(reinterpret(seed()));\n\n var s0 = random_state0_32;\n var s1 = random_state1_32;\n var r = rotl(s0 * 0x9E3779BB, 5) * 5;\n\n s1 ^= s0;\n random_state0_32 = rotl(s0, 26) ^ s1 ^ (s1 << 9);\n random_state1_32 = rotl(s1, 13);\n\n return reinterpret((r >> 9) | (127 << 23)) - 1.0;\n }\n\n // @ts-ignore: decorator\n @inline\n export function round(x: f32): f32 {\n let roundUp = builtin_ceil(x);\n return select(roundUp, roundUp - 1.0, roundUp - 0.5 <= x);\n }\n\n // @ts-ignore: decorator\n @inline\n export function sign(x: f32): f32 {\n if (ASC_SHRINK_LEVEL > 0) {\n return builtin_abs(x) > 0 ? builtin_copysign(1, x) : x;\n } else {\n return x > 0 ? 1 : x < 0 ? -1 : x;\n }\n }\n\n // @ts-ignore: decorator\n @inline\n export function signbit(x: f32): bool {\n return (reinterpret(x) >>> 31);\n }\n\n export function sin(x: f32): f32 { // see: musl/src/math/sinf.c\n const\n s1pio2 = reinterpret(0x3FF921FB54442D18), // M_PI_2 * 1\n s2pio2 = reinterpret(0x400921FB54442D18), // M_PI_2 * 2\n s3pio2 = reinterpret(0x4012D97C7F3321D2), // M_PI_2 * 3\n s4pio2 = reinterpret(0x401921FB54442D18); // M_PI_2 * 4\n\n var ux = reinterpret(x);\n var sign = ux >> 31;\n ux &= 0x7FFFFFFF;\n\n if (ux <= 0x3F490FDA) { // |x| ~<= π/4\n if (ux < 0x39800000) { // |x| < 2**-12\n return x;\n }\n return sin_kernf(x);\n }\n\n if (ASC_SHRINK_LEVEL < 1) {\n if (ux <= 0x407B53D1) { // |x| ~<= 5π/4\n if (ux <= 0x4016CBE3) { // |x| ~<= 3π/4\n return sign ? -cos_kernf(x + s1pio2) : cos_kernf(x - s1pio2);\n }\n return sin_kernf(-(sign ? x + s2pio2 : x - s2pio2));\n }\n\n if (ux <= 0x40E231D5) { // |x| ~<= 9π/4\n if (ux <= 0x40AFEDDF) { // |x| ~<= 7π/4\n return sign ? cos_kernf(x + s3pio2) : -cos_kernf(x - s3pio2);\n }\n return sin_kernf(sign ? x + s4pio2 : x - s4pio2);\n }\n }\n\n // sin(Inf or NaN) is NaN\n if (ux >= 0x7F800000) return x - x;\n\n var n = rempio2f(x, ux, sign);\n var y = rempio2f_y;\n\n var t = n & 1 ? cos_kernf(y) : sin_kernf(y);\n return n & 2 ? -t : t;\n }\n\n export function sinh(x: f32): f32 { // see: musl/src/math/sinhf.c\n var u = reinterpret(x) & 0x7FFFFFFF;\n var a = reinterpret(u);\n var h = builtin_copysign(0.5, x);\n if (u < 0x42B17217) {\n let t = expm1(a);\n if (u < 0x3F800000) {\n if (u < 0x3F800000 - (12 << 23)) return x;\n return h * (2 * t - t * t / (t + 1));\n }\n return h * (t + t / (t + 1));\n }\n return expo2f(a, 2 * h);\n }\n\n // @ts-ignore: decorator\n @inline\n export function sqrt(x: f32): f32 {\n return builtin_sqrt(x);\n }\n\n export function tan(x: f32): f32 { // see: musl/src/math/tanf.c\n const\n t1pio2 = reinterpret(0x3FF921FB54442D18), // 1 * M_PI_2\n t2pio2 = reinterpret(0x400921FB54442D18), // 2 * M_PI_2\n t3pio2 = reinterpret(0x4012D97C7F3321D2), // 3 * M_PI_2\n t4pio2 = reinterpret(0x401921FB54442D18); // 4 * M_PI_2\n\n var ux = reinterpret(x);\n var sign = ux >> 31;\n ux &= 0x7FFFFFFF;\n\n if (ux <= 0x3F490FDA) { // |x| ~<= π/4\n if (ux < 0x39800000) { // |x| < 2**-12\n return x;\n }\n return tan_kernf(x, 0);\n }\n\n if (ASC_SHRINK_LEVEL < 1) {\n if (ux <= 0x407B53D1) { // |x| ~<= 5π/4\n if (ux <= 0x4016CBE3) { // |x| ~<= 3π/4\n return tan_kernf((sign ? x + t1pio2 : x - t1pio2), 1);\n } else {\n return tan_kernf((sign ? x + t2pio2 : x - t2pio2), 0);\n }\n }\n if (ux <= 0x40E231D5) { // |x| ~<= 9π/4\n if (ux <= 0x40AFEDDF) { // |x| ~<= 7π/4\n return tan_kernf((sign ? x + t3pio2 : x - t3pio2), 1);\n } else {\n return tan_kernf((sign ? x + t4pio2 : x - t4pio2), 0);\n }\n }\n }\n\n // tan(Inf or NaN) is NaN\n if (ux >= 0x7F800000) return x - x;\n\n // argument reduction\n var n = rempio2f(x, ux, sign);\n var y = rempio2f_y;\n return tan_kernf(y, n & 1);\n }\n\n export function tanh(x: f32): f32 { // see: musl/src/math/tanhf.c\n var u = reinterpret(x);\n u &= 0x7FFFFFFF;\n var y = reinterpret(u);\n var t: f32;\n if (u > 0x3F0C9F54) {\n if (u > 0x41200000) t = 1 + 0 / y;\n else {\n t = expm1(2 * y);\n t = 1 - 2 / (t + 2);\n }\n } else if (u > 0x3E82C578) {\n t = expm1(2 * y);\n t = t / (t + 2);\n } else if (u >= 0x00800000) {\n t = expm1(-2 * y);\n t = -t / (t + 2);\n } else t = y;\n return builtin_copysign(t, x);\n }\n\n // @ts-ignore: decorator\n @inline\n export function trunc(x: f32): f32 {\n return builtin_trunc(x);\n }\n\n export function scalbn(x: f32, n: i32): f32 { // see: https://git.musl-libc.org/cgit/musl/tree/src/math/scalbnf.c\n const\n Ox1p24f = reinterpret(0x4B800000),\n Ox1p127f = reinterpret(0x7F000000),\n Ox1p_126f = reinterpret(0x00800000);\n\n var y = x;\n if (n > 127) {\n y *= Ox1p127f;\n n -= 127;\n if (n > 127) {\n y *= Ox1p127f;\n n = builtin_min(n - 127, 127);\n }\n } else if (n < -126) {\n y *= Ox1p_126f * Ox1p24f;\n n += 126 - 24;\n if (n < -126) {\n y *= Ox1p_126f * Ox1p24f;\n n = builtin_max(n + 126 - 24, -126);\n }\n }\n return y * reinterpret((0x7F + n) << 23);\n }\n\n export function mod(x: f32, y: f32): f32 { // see: musl/src/math/fmodf.c\n if (builtin_abs(y) == 1.0) {\n // x % 1, x % -1 ==> sign(x) * abs(x - 1.0 * trunc(x / 1.0))\n // TODO: move this rule to compiler's optimization pass.\n // It could be apply for any x % C_pot, where \"C_pot\" is pow of two const.\n return builtin_copysign(x - builtin_trunc(x), x);\n }\n var ux = reinterpret(x);\n var uy = reinterpret(y);\n var ex = i32(ux >> 23 & 0xFF);\n var ey = i32(uy >> 23 & 0xFF);\n var sm = ux & 0x80000000;\n var uy1 = uy << 1;\n if (uy1 == 0 || ex == 0xFF || isNaN(y)) {\n let m = x * y;\n return m / m;\n }\n var ux1 = ux << 1;\n if (ux1 <= uy1) {\n return x * f32(ux1 != uy1);\n }\n if (!ex) {\n ex -= builtin_clz(ux << 9);\n ux <<= 1 - ex;\n } else {\n ux &= -1 >> 9;\n ux |= 1 << 23;\n }\n if (!ey) {\n ey -= builtin_clz(uy << 9);\n uy <<= 1 - ey;\n } else {\n uy &= u32(-1) >> 9;\n uy |= 1 << 23;\n }\n while (ex > ey) {\n if (ux >= uy) {\n if (ux == uy) return 0 * x;\n ux -= uy;\n }\n ux <<= 1;\n --ex;\n }\n if (ux >= uy) {\n if (ux == uy) return 0 * x;\n ux -= uy;\n }\n // for (; !(ux >> 23); ux <<= 1) --ex;\n var shift = builtin_clz(ux << 8);\n ex -= shift;\n ux <<= shift;\n if (ex > 0) {\n ux -= 1 << 23;\n ux |= ex << 23;\n } else {\n ux >>= -ex + 1;\n }\n return reinterpret(ux | sm);\n }\n\n export function rem(x: f32, y: f32): f32 { // see: musl/src/math/remquof.c\n var ux = reinterpret(x);\n var uy = reinterpret(y);\n var ex = i32(ux >> 23 & 0xFF);\n var ey = i32(uy >> 23 & 0xFF);\n var uxi = ux;\n if (uy << 1 == 0 || ex == 0xFF || isNaN(y)) return (x * y) / (x * y);\n if (ux << 1 == 0) return x;\n if (!ex) {\n ex -= builtin_clz(uxi << 9);\n uxi <<= 1 - ex;\n } else {\n uxi &= u32(-1) >> 9;\n uxi |= 1 << 23;\n }\n if (!ey) {\n ey -= builtin_clz(uy << 9);\n uy <<= 1 - ey;\n } else {\n uy &= u32(-1) >> 9;\n uy |= 1 << 23;\n }\n var q = 0;\n do {\n if (ex < ey) {\n if (ex + 1 == ey) break; // goto end\n return x;\n }\n while (ex > ey) {\n if (uxi >= uy) {\n uxi -= uy;\n ++q;\n }\n uxi <<= 1;\n q <<= 1;\n --ex;\n }\n if (uxi >= uy) {\n uxi -= uy;\n ++q;\n }\n if (uxi == 0) ex = -30;\n else {\n let shift = builtin_clz(uxi << 8);\n ex -= shift;\n uxi <<= shift;\n }\n break;\n } while (false);\n // end:\n if (ex > 0) {\n uxi -= 1 << 23;\n uxi |= ex << 23;\n } else {\n uxi >>= -ex + 1;\n }\n x = reinterpret(uxi);\n y = builtin_abs(y);\n var x2 = x + x;\n if (ex == ey || (ex + 1 == ey && (x2 > y || (x2 == y && bool(q & 1))))) {\n x -= y;\n // q++;\n }\n return ux < 0 ? -x : x;\n }\n\n export function sincos(x: f32): void { // see: musl/tree/src/math/sincosf.c\n const\n s1pio2 = reinterpret(0x3FF921FB54442D18), // 1 * M_PI_2\n s2pio2 = reinterpret(0x400921FB54442D18), // 2 * M_PI_2\n s3pio2 = reinterpret(0x4012D97C7F3321D2), // 3 * M_PI_2\n s4pio2 = reinterpret(0x401921FB54442D18); // 4 * M_PI_2\n\n var ux = reinterpret(x);\n var sign = ux >> 31;\n ux &= 0x7FFFFFFF;\n\n if (ux <= 0x3F490FDA) { // |x| ~<= π/4\n if (ux < 0x39800000) { // |x| < 2**-12\n sincos_sin = x;\n sincos_cos = 1;\n return;\n }\n sincos_sin = sin_kernf(x);\n sincos_cos = cos_kernf(x);\n return;\n }\n if (ASC_SHRINK_LEVEL < 1) {\n if (ux <= 0x407B53D1) { // |x| ~<= 5π/4\n if (ux <= 0x4016CBE3) { // |x| ~<= 3π/4\n if (sign) {\n sincos_sin = -cos_kernf(x + s1pio2);\n sincos_cos = sin_kernf(x + s1pio2);\n } else {\n sincos_sin = cos_kernf(s1pio2 - x);\n sincos_cos = sin_kernf(s1pio2 - x);\n }\n return;\n }\n // -sin(x + c) is not correct if x+c could be 0: -0 vs +0\n sincos_sin = -sin_kernf(sign ? x + s2pio2 : x - s2pio2);\n sincos_cos = -cos_kernf(sign ? x + s2pio2 : x - s2pio2);\n return;\n }\n if (ux <= 0x40E231D5) { // |x| ~<= 9π/4\n if (ux <= 0x40AFEDDF) { // |x| ~<= 7π/4\n if (sign) {\n sincos_sin = cos_kernf(x + s3pio2);\n sincos_cos = -sin_kernf(x + s3pio2);\n } else {\n sincos_sin = -cos_kernf(x - s3pio2);\n sincos_cos = sin_kernf(x - s3pio2);\n }\n return;\n }\n sincos_sin = sin_kernf(sign ? x + s4pio2 : x - s4pio2);\n sincos_cos = cos_kernf(sign ? x + s4pio2 : x - s4pio2);\n return;\n }\n }\n // sin(Inf or NaN) is NaN\n if (ux >= 0x7F800000) {\n let xx = x - x;\n sincos_sin = xx;\n sincos_cos = xx;\n return;\n }\n // general argument reduction needed\n var n = rempio2f(x, ux, sign);\n var y = rempio2f_y;\n var s = sin_kernf(y);\n var c = cos_kernf(y);\n var sin = s, cos = c;\n if (n & 1) {\n sin = c;\n cos = -s;\n }\n if (n & 2) {\n sin = -sin;\n cos = -cos;\n }\n sincos_sin = sin;\n sincos_cos = cos;\n }\n}\n\nexport function ipow32(x: i32, e: i32): i32 {\n var out = 1;\n if (ASC_SHRINK_LEVEL < 1) {\n if (x == 2) {\n return select(1 << e, 0, e < 32);\n }\n if (e <= 0) {\n if (x == -1) return select(-1, 1, e & 1);\n return i32(e == 0) | i32(x == 1);\n }\n else if (e == 1) return x;\n else if (e == 2) return x * x;\n else if (e < 32) {\n let log = 32 - clz(e);\n // 32 = 2 ^ 5, so need only five cases.\n // But some extra cases needs for properly overflowing\n switch (log) {\n case 5: {\n if (e & 1) out *= x;\n e >>>= 1;\n x *= x;\n }\n case 4: {\n if (e & 1) out *= x;\n e >>>= 1;\n x *= x;\n }\n case 3: {\n if (e & 1) out *= x;\n e >>>= 1;\n x *= x;\n }\n case 2: {\n if (e & 1) out *= x;\n e >>>= 1;\n x *= x;\n }\n case 1: {\n if (e & 1) out *= x;\n }\n }\n return out;\n }\n }\n while (e) {\n if (e & 1) out *= x;\n e >>>= 1;\n x *= x;\n }\n return out;\n}\n\nexport function ipow64(x: i64, e: i64): i64 {\n var out: i64 = 1;\n if (ASC_SHRINK_LEVEL < 1) {\n if (x == 2) {\n return select(1 << e, 0, e < 64);\n }\n if (e <= 0) {\n if (x == -1) return select(-1, 1, e & 1);\n return i64(e == 0) | i64(x == 1);\n }\n else if (e == 1) return x;\n else if (e == 2) return x * x;\n else if (e < 64) {\n let log = 64 - clz(e);\n // 64 = 2 ^ 6, so need only six cases.\n // But some extra cases needs for properly overflowing\n switch (log) {\n case 6: {\n if (e & 1) out *= x;\n e >>>= 1;\n x *= x;\n }\n case 5: {\n if (e & 1) out *= x;\n e >>>= 1;\n x *= x;\n }\n case 4: {\n if (e & 1) out *= x;\n e >>>= 1;\n x *= x;\n }\n case 3: {\n if (e & 1) out *= x;\n e >>>= 1;\n x *= x;\n }\n case 2: {\n if (e & 1) out *= x;\n e >>>= 1;\n x *= x;\n }\n case 1: {\n if (e & 1) out *= x;\n }\n }\n return out;\n }\n }\n while (e) {\n if (e & 1) out *= x;\n e >>>= 1;\n x *= x;\n }\n return out;\n}\n\n/*\nTODO:\nIn compile time if only exponent is constant we could replace ipow32/ipow64 by shortest addition chains\nwhich usually faster than exponentiation by squaring\n\nfor ipow32 and e < 32:\n\nlet b: i32, c: i32, d: i32, h: i32, k: i32, g: i32;\nswitch (e) {\n case 1: return x;\n case 2: return x * x;\n case 3: return x * x * x;\n case 4: return (b = x * x) * b;\n case 5: return (b = x * x) * b * x;\n case 6: return (b = x * x) * b * b;\n case 7: return (b = x * x) * b * b * x;\n case 8: return (d = (b = x * x) * b) * d;\n case 9: return (c = x * x * x) * c * c;\n case 10: return (d = (b = x * x) * b) * d * b;\n case 11: return (d = (b = x * x) * b) * d * b * x;\n case 12: return (d = (b = x * x) * b) * d * d;\n case 13: return (d = (b = x * x) * b) * d * d * x;\n case 14: return (d = (b = x * x) * b) * d * d * b;\n case 15: return (k = (b = x * x) * b * x) * k * k;\n case 16: return (h = (d = (b = x * x) * b) * d) * h;\n case 17: return (h = (d = (b = x * x) * b) * d) * h * x;\n case 18: return (h = (d = (b = x * x) * b) * d * x) * h;\n case 19: return (h = (d = (b = x * x) * b) * d * x) * h * x;\n case 20: return (h = (k = (b = x * x) * b * x) * k) * h;\n case 21: return (h = (k = (b = x * x) * b * x) * k) * h * x;\n case 22: return (g = (h = (k = (b = x * x) * b * x) * k) * x) * g;\n case 23: return (h = (d = (c = (b = x * x) * x) * b) * d) * h * c;\n case 24: return (h = (d = (c = x * x * x) * c) * d) * h;\n case 25: return (h = (d = (c = x * x * x) * c) * d) * h * x;\n case 26: return (g = (h = (d = (c = x * x * x) * c) * d) * x) * g;\n case 27: return (h = (d = (c = x * x * x) * c) * d) * h * c;\n case 28: return (h = (d = (c = x * x * x) * c * x) * d) * h;\n case 29: return (h = (d = (c = x * x * x) * c * x) * d) * h * x;\n case 30: return (h = (d = (c = x * x * x) * c) * d * c) * h;\n case 31: return (h = (d = (c = x * x * x) * c) * d * c) * h * x;\n}\n\nfor ipow64: TODO\nswitch (e) {\n case 32:\n ...\n case 63:\n}\n*/\n","// This file is shared with the compiler and must remain portable\n\n/** Runtime types. */\nexport enum Runtime {\n /** Simple bump allocator without GC. */\n Stub = 0,\n /** Stop the world semi-automatic GC. */\n Minimal = 1,\n /** incremental GC. */\n Incremental = 2,\n}\n","import { compareImpl } from \"./string\";\n\ntype Comparator = (a: T, b: T) => i32;\n\n// @ts-ignore: decorator\n@lazy @inline const EMPTY = u32.MAX_VALUE;\n// @ts-ignore: decorator\n@inline const INSERTION_SORT_THRESHOLD = 48;\n// @ts-ignore: decorator\n@inline const MIN_RUN_LENGTH = 32;\n\n// @ts-ignore: decorator\n@inline\nfunction log2u(n: u32): u32 {\n return 31 - clz(n);\n}\n\n// @ts-ignore: decorator\n@inline\nexport function COMPARATOR(): Comparator {\n if (isInteger()) {\n if (isSigned() && sizeof() <= 4) {\n return (a, b) => i32(a) - i32(b);\n } else {\n return (a, b) => i32(a > b) - i32(a < b);\n }\n } else if (isFloat()) {\n if (sizeof() == 4) {\n return (a, b) => {\n var ia = reinterpret(f32(a));\n var ib = reinterpret(f32(b));\n ia ^= ia >> 31 >>> 1;\n ib ^= ib >> 31 >>> 1;\n return i32(ia > ib) - i32(ia < ib);\n };\n } else {\n return (a, b) => {\n var ia = reinterpret(f64(a));\n var ib = reinterpret(f64(b));\n ia ^= ia >> 63 >>> 1;\n ib ^= ib >> 63 >>> 1;\n return i32(ia > ib) - i32(ia < ib);\n };\n }\n } else if (isString()) {\n return (a, b) => {\n if (\n changetype(a) == changetype(b) ||\n changetype(a) == 0 ||\n changetype(b) == 0\n ) return 0;\n var alen = changetype(a).length;\n var blen = changetype(b).length;\n if (!(alen | blen)) return 0;\n if (!alen) return -1;\n if (!blen) return 1;\n let res = compareImpl(\n changetype(a), 0,\n changetype(b), 0,\n min(alen, blen)\n );\n return res ? res : alen - blen;\n };\n } else {\n return (a, b) => i32(a > b) - i32(a < b);\n }\n}\n\n// Power Sort implementation (stable) from paper \"Nearly-Optimal Mergesorts\"\n// https://arxiv.org/pdf/1805.04154.pdf\n// This method usually outperform TimSort.\n// TODO: refactor c >>> 31 to c < 0 when binaryen will support this opt\nexport function SORT(\n ptr: usize,\n len: i32,\n comparator: Comparator\n): void {\n if (len <= INSERTION_SORT_THRESHOLD) {\n if (len <= 1) return;\n if (ASC_SHRINK_LEVEL < 1) {\n switch (len) {\n case 3: {\n let a = load(ptr, 0);\n let b = load(ptr, 1 << alignof());\n let c = comparator(a, b) > 0;\n store(ptr, select(b, a, c), 0);\n a = select(a, b, c);\n b = load(ptr, 2 << alignof());\n c = comparator(a, b) > 0;\n store(ptr, select(b, a, c), 1 << alignof());\n store(ptr, select(a, b, c), 2 << alignof());\n }\n case 2: {\n let a = load(ptr, 0);\n let b = load(ptr, 1 << alignof());\n let c = comparator(a, b) > 0;\n store(ptr, select(b, a, c), 0);\n store(ptr, select(a, b, c), 1 << alignof());\n return;\n }\n }\n }\n insertionSort(ptr, 0, len - 1, 0, comparator);\n return;\n }\n\n var lgPlus2 = log2u(len) + 2;\n var lgPlus2Size = lgPlus2 << alignof();\n var leftRunStartBuf = __alloc(lgPlus2Size << 1);\n var leftRunEndBuf = leftRunStartBuf + lgPlus2Size;\n\n for (let i: u32 = 0; i < lgPlus2; ++i) {\n store(leftRunStartBuf + (i << alignof()), EMPTY);\n }\n\n var buffer = __alloc(len << alignof());\n\n var hi = len - 1;\n var endA = extendRunRight(ptr, 0, hi, comparator);\n var lenA = endA + 1;\n\n if (lenA < MIN_RUN_LENGTH) {\n endA = min(hi, MIN_RUN_LENGTH - 1);\n insertionSort(ptr, 0, endA, lenA, comparator);\n }\n\n var top: u32 = 0, startA = 0;\n while (endA < hi) {\n let startB = endA + 1;\n let endB = extendRunRight(ptr, startB, hi, comparator);\n let lenB = endB - startB + 1;\n\n if (lenB < MIN_RUN_LENGTH) {\n endB = min(hi, startB + MIN_RUN_LENGTH - 1);\n insertionSort(ptr, startB, endB, lenB, comparator);\n }\n\n let k = nodePower(0, hi, startA, startB, endB);\n\n for (let i = top; i > k; --i) {\n let start = load(leftRunStartBuf + (i << alignof()));\n if (start != EMPTY) {\n mergeRuns(\n ptr,\n start,\n load(leftRunEndBuf + (i << alignof())) + 1,\n endA,\n buffer,\n comparator\n );\n startA = start;\n store(leftRunStartBuf + (i << alignof()), EMPTY);\n }\n }\n\n store(leftRunStartBuf + (k << alignof()), startA);\n store(leftRunEndBuf + (k << alignof()), endA);\n startA = startB;\n endA = endB;\n top = k;\n }\n\n for (let i = top; i != 0; --i) {\n let start = load(leftRunStartBuf + (i << alignof()));\n if (start != EMPTY) {\n mergeRuns(\n ptr,\n start,\n load(leftRunEndBuf + (i << alignof())) + 1,\n hi,\n buffer,\n comparator\n );\n }\n }\n // dealloc aux buffers\n __free(buffer);\n __free(leftRunStartBuf);\n}\n\nfunction insertionSort(\n ptr: usize,\n left: i32,\n right: i32,\n presorted: i32,\n comparator: Comparator\n): void {\n if (ASC_SHRINK_LEVEL >= 1) {\n // slightly improved original insertion sort\n for (let i = left + presorted; i <= right; ++i) {\n let j = i - 1;\n let a = load(ptr + (i << alignof()));\n while (j >= left) {\n let b = load(ptr + (j << alignof()));\n if (comparator(a, b) < 0) {\n store(ptr + (j << alignof()), b, 1 << alignof()); --j;\n } else break;\n }\n store(ptr + (j << alignof()), a, 1 << alignof());\n }\n } else {\n // even-odd two-way insertion sort which allow increase minRunLen\n let range = right - left + 1;\n let i = left + select(range & 1, presorted - ((range - presorted) & 1), presorted == 0);\n for (; i <= right; i += 2) {\n let a = load(ptr + (i << alignof()), 0);\n let b = load(ptr + (i << alignof()), 1 << alignof());\n let min = b, max = a;\n if (comparator(a, b) <= 0) {\n min = a, max = b;\n }\n let j = i - 1;\n while (j >= left) {\n a = load(ptr + (j << alignof()));\n if (comparator(a, max) > 0) {\n store(ptr + (j << alignof()), a, 2 << alignof()); --j;\n } else break;\n }\n store(ptr + (j << alignof()), max, 2 << alignof());\n while (j >= left) {\n a = load(ptr + (j << alignof()));\n if (comparator(a, min) > 0) {\n store(ptr + (j << alignof()), a, 1 << alignof()); --j;\n } else break;\n }\n store(ptr + (j << alignof()), min, 1 << alignof());\n }\n }\n}\n\nfunction nodePower(left: u32, right: u32, startA: u32, startB: u32, endB: u32): u32 {\n var n: u64 = right - left + 1;\n var s = startB - (left << 1);\n var l = startA + s;\n var r = endB + s + 1;\n var a = (l << 30) / n;\n var b = (r << 30) / n;\n return clz((a ^ b));\n}\n\nfunction extendRunRight(\n ptr: usize,\n i: i32,\n right: i32,\n comparator: Comparator\n): i32 {\n if (i == right) return i;\n var j = i;\n if (comparator(\n load(ptr + ( j << alignof())),\n load(ptr + (++j << alignof()))\n ) > 0) {\n while (\n j < right &&\n (comparator(\n load(ptr + (j << alignof()), 1 << alignof()),\n load(ptr + (j << alignof()))\n ) >>> 31) // < 0\n ) ++j;\n // reverse\n let k = j;\n while (i < k) {\n let tmp = load(ptr + (i << alignof()));\n store(ptr + (i << alignof()), load(ptr + (k << alignof()))); ++i;\n store(ptr + (k << alignof()), tmp); --k;\n }\n } else {\n while (\n j < right &&\n comparator(\n load(ptr + (j << alignof()), 1 << alignof()),\n load(ptr + (j << alignof()))\n ) >= 0\n ) ++j;\n }\n return j;\n}\n\n// Merges arr[l..m - 1] and arr[m..r]\nfunction mergeRuns(\n ptr: usize,\n l: i32,\n m: i32,\n r: i32,\n buffer: usize,\n comparator: Comparator\n): void {\n --m;\n var i: i32, j: i32, t = r + m;\n for (i = m + 1; i > l; --i) {\n store(\n buffer + ((i - 1) << alignof()),\n load(ptr + ((i - 1) << alignof()))\n );\n }\n for (j = m; j < r; ++j) {\n store(\n buffer + ((t - j) << alignof()),\n load(ptr + (j << alignof()), 1 << alignof())\n );\n }\n for (let k = l; k <= r; ++k) {\n let a = load(buffer + (j << alignof()));\n let b = load(buffer + (i << alignof()));\n if (comparator(a, b) < 0) {\n store(ptr + (k << alignof()), a);\n --j;\n } else {\n store(ptr + (k << alignof()), b);\n ++i;\n }\n }\n}\n","/// \n\nimport { BLOCK_MAXSIZE } from \"./rt/common\";\nimport { Runtime } from \"shared/runtime\";\nimport { COMPARATOR, SORT } from \"./util/sort\";\nimport { REVERSE, FILL } from \"./util/bytes\";\nimport { joinBooleanArray, joinIntegerArray, joinFloatArray, joinStringArray, joinReferenceArray } from \"./util/string\";\nimport { idof, isArray as builtin_isArray } from \"./builtins\";\nimport { E_INDEXOUTOFRANGE, E_INVALIDLENGTH, E_EMPTYARRAY, E_HOLEYARRAY } from \"./util/error\";\n\n// @ts-ignore: decorator\n@inline @lazy const MIN_SIZE: usize = 8;\n\n/** Ensures that the given array has _at least_ the specified backing size. */\nfunction ensureCapacity(array: usize, newSize: usize, alignLog2: u32, canGrow: bool = true): void {\n // Depends on the fact that Arrays mimic ArrayBufferView\n var oldCapacity = changetype(array).byteLength;\n if (newSize > oldCapacity >>> alignLog2) {\n if (newSize > BLOCK_MAXSIZE >>> alignLog2) throw new RangeError(E_INVALIDLENGTH);\n let oldData = changetype(changetype(array).buffer);\n // Grows old capacity by factor of two.\n // Make sure we don't reach BLOCK_MAXSIZE for new growed capacity.\n let newCapacity = max(newSize, MIN_SIZE) << alignLog2;\n if (canGrow) newCapacity = max(min(oldCapacity << 1, BLOCK_MAXSIZE), newCapacity);\n let newData = __renew(oldData, newCapacity);\n // __new / __renew already init memory range as zeros in Incremental runtime.\n // So try to avoid this.\n if (ASC_RUNTIME != Runtime.Incremental) {\n memory.fill(newData + oldCapacity, 0, newCapacity - oldCapacity);\n }\n if (newData != oldData) { // oldData has been free'd\n store(array, newData, offsetof(\"buffer\"));\n store(array, newData, offsetof(\"dataStart\"));\n __link(array, changetype(newData), false);\n }\n store(array, newCapacity, offsetof(\"byteLength\"));\n }\n}\n\nexport class Array {\n [key: number]: T;\n\n // Mimicking ArrayBufferView isn't strictly necessary here but is done to allow glue code\n // to work with typed and normal arrays interchangeably. Technically, normal arrays do not need\n // `dataStart` (equals `buffer`) and `byteLength` (equals computed `buffer.byteLength`), but the\n // block is 16 bytes anyway so it's fine to have a couple extra fields in there.\n\n private buffer: ArrayBuffer;\n @unsafe readonly dataStart: usize;\n private byteLength: i32; // Uses here as capacity\n\n // Also note that Array with non-nullable T must guard against uninitialized null values\n // whenever an element is accessed. Otherwise, the compiler wouldn't be able to guarantee\n // type-safety anymore. For lack of a better word, such an array is \"holey\".\n\n private length_: i32;\n\n static isArray(value: U): bool {\n return isReference() ? changetype(value) != 0 && builtin_isArray(value) : false;\n }\n\n static create(capacity: i32 = 0): Array {\n WARNING(\"'Array.create' is deprecated. Use 'new Array' instead, making sure initial elements are initialized.\");\n var array = new Array(capacity);\n array.length = 0;\n return array;\n }\n\n constructor(length: i32 = 0) {\n if (length > BLOCK_MAXSIZE >>> alignof()) throw new RangeError(E_INVALIDLENGTH);\n // reserve capacity for at least MIN_SIZE elements\n var bufferSize = max(length, MIN_SIZE) << alignof();\n var buffer = changetype(__new(bufferSize, idof()));\n if (ASC_RUNTIME != Runtime.Incremental) {\n memory.fill(changetype(buffer), 0, bufferSize);\n }\n this.buffer = buffer; // links\n this.dataStart = changetype(buffer);\n this.byteLength = bufferSize;\n this.length_ = length;\n }\n\n get length(): i32 {\n return this.length_;\n }\n\n set length(newLength: i32) {\n ensureCapacity(changetype(this), newLength, alignof(), false);\n this.length_ = newLength;\n }\n\n every(fn: (value: T, index: i32, array: Array) => bool): bool {\n for (let i = 0, len = this.length_; i < min(len, this.length_); ++i) {\n if (!fn(load(this.dataStart + (i << alignof())), i, this)) return false;\n }\n return true;\n }\n\n findIndex(fn: (value: T, index: i32, array: Array) => bool): i32 {\n for (let i = 0, len = this.length_; i < min(len, this.length_); ++i) {\n if (fn(load(this.dataStart + (i << alignof())), i, this)) return i;\n }\n return -1;\n }\n\n findLastIndex(fn: (value: T, index: i32, array: Array) => bool): i32 {\n for (let i = this.length_ - 1; i >= 0; --i) {\n if (fn(load(this.dataStart + (i << alignof())), i, this)) return i;\n }\n return -1;\n }\n\n @operator(\"[]\") private __get(index: i32): T {\n if (index >= this.length_) throw new RangeError(E_INDEXOUTOFRANGE);\n var value = load(this.dataStart + (index << alignof()));\n if (isReference()) {\n if (!isNullable()) {\n if (!changetype(value)) throw new Error(E_HOLEYARRAY);\n }\n }\n return value;\n }\n\n @unsafe @operator(\"{}\") private __uget(index: i32): T {\n return load(this.dataStart + (index << alignof()));\n }\n\n @operator(\"[]=\") private __set(index: i32, value: T): void {\n if (index >= this.length_) {\n if (index < 0) throw new RangeError(E_INDEXOUTOFRANGE);\n ensureCapacity(changetype(this), index + 1, alignof());\n this.length_ = index + 1;\n }\n this.__uset(index, value);\n }\n\n @unsafe @operator(\"{}=\") private __uset(index: i32, value: T): void {\n store(this.dataStart + (index << alignof()), value);\n if (isManaged()) {\n __link(changetype(this), changetype(value), true);\n }\n }\n\n at(index: i32): T {\n var len = this.length_;\n index += select(0, len, index >= 0);\n if (index >= len) throw new RangeError(E_INDEXOUTOFRANGE);\n var value = load(this.dataStart + (index << alignof()));\n if (isReference()) {\n if (!isNullable()) {\n if (!changetype(value)) throw new Error(E_HOLEYARRAY);\n }\n }\n return value;\n }\n\n fill(value: T, start: i32 = 0, end: i32 = i32.MAX_VALUE): Array {\n if (isManaged()) {\n FILL(this.dataStart, this.length_, changetype(value), start, end);\n __link(changetype(this), changetype(value), false);\n } else {\n FILL(this.dataStart, this.length_, value, start, end);\n }\n return this;\n }\n\n includes(value: T, fromIndex: i32 = 0): bool {\n if (isFloat()) {\n let len = this.length_;\n if (len == 0 || fromIndex >= len) return false;\n if (fromIndex < 0) fromIndex = max(len + fromIndex, 0);\n let ptr = this.dataStart;\n while (fromIndex < len) {\n let elem = load(ptr + (fromIndex << alignof()));\n // @ts-ignore\n if (elem == value || isNaN(elem) & isNaN(value)) return true;\n ++fromIndex;\n }\n return false;\n } else {\n return this.indexOf(value, fromIndex) >= 0;\n }\n }\n\n indexOf(value: T, fromIndex: i32 = 0): i32 {\n var len = this.length_;\n if (len == 0 || fromIndex >= len) return -1;\n if (fromIndex < 0) fromIndex = max(len + fromIndex, 0);\n var ptr = this.dataStart;\n while (fromIndex < len) {\n if (load(ptr + (fromIndex << alignof())) == value) return fromIndex;\n ++fromIndex;\n }\n return -1;\n }\n\n lastIndexOf(value: T, fromIndex: i32 = this.length_): i32 {\n var len = this.length_;\n if (len == 0) return -1;\n if (fromIndex < 0) fromIndex = len + fromIndex;\n else if (fromIndex >= len) fromIndex = len - 1;\n var ptr = this.dataStart;\n while (fromIndex >= 0) {\n if (load(ptr + (fromIndex << alignof())) == value) return fromIndex;\n --fromIndex;\n }\n return -1;\n }\n\n push(value: T): i32 {\n var oldLen = this.length_;\n var len = oldLen + 1;\n ensureCapacity(changetype(this), len, alignof());\n if (isManaged()) {\n store(this.dataStart + (oldLen << alignof()), changetype(value));\n __link(changetype(this), changetype(value), true);\n } else {\n store(this.dataStart + (oldLen << alignof()), value);\n }\n this.length_ = len;\n return len;\n }\n\n concat(other: Array): Array {\n var thisLen = this.length_;\n var otherLen = other.length_;\n var outLen = thisLen + otherLen;\n if (outLen > BLOCK_MAXSIZE >>> alignof()) throw new Error(E_INVALIDLENGTH);\n var out = changetype>(__newArray(outLen, alignof(), idof>()));\n var outStart = out.dataStart;\n var thisSize = thisLen << alignof();\n if (isManaged()) {\n let thisStart = this.dataStart;\n for (let offset: usize = 0; offset < thisSize; offset += sizeof()) {\n let ref = load(thisStart + offset);\n store(outStart + offset, ref);\n __link(changetype(out), ref, true);\n }\n outStart += thisSize;\n let otherStart = other.dataStart;\n let otherSize = otherLen << alignof();\n for (let offset: usize = 0; offset < otherSize; offset += sizeof()) {\n let ref = load(otherStart + offset);\n store(outStart + offset, ref);\n __link(changetype(out), ref, true);\n }\n } else {\n memory.copy(outStart, this.dataStart, thisSize);\n memory.copy(outStart + thisSize, other.dataStart, otherLen << alignof());\n }\n return out;\n }\n\n copyWithin(target: i32, start: i32, end: i32 = i32.MAX_VALUE): Array {\n var ptr = this.dataStart;\n var len = this.length_;\n\n end = min(end, len);\n\n var to = target < 0 ? max(len + target, 0) : min(target, len);\n var from = start < 0 ? max(len + start, 0) : min(start, len);\n var last = end < 0 ? max(len + end, 0) : min(end, len);\n var count = min(last - from, len - to);\n\n memory.copy( // is memmove\n ptr + (to << alignof()),\n ptr + (from << alignof()),\n count << alignof()\n );\n return this;\n }\n\n pop(): T {\n var len = this.length_;\n if (len < 1) throw new RangeError(E_EMPTYARRAY);\n var val = load(this.dataStart + ((--len) << alignof()));\n this.length_ = len;\n return val;\n }\n\n forEach(fn: (value: T, index: i32, array: Array) => void): void {\n for (let i = 0, len = this.length_; i < min(len, this.length_); ++i) {\n fn(load(this.dataStart + (i << alignof())), i, this);\n }\n }\n\n map(fn: (value: T, index: i32, array: Array) => U): Array {\n var len = this.length_;\n var out = changetype>(__newArray(len, alignof(), idof>()));\n var outStart = out.dataStart;\n for (let i = 0; i < min(len, this.length_); ++i) {\n let result = fn(load(this.dataStart + (i << alignof())), i, this);\n store(outStart + (i << alignof()), result);\n if (isManaged()) {\n __link(changetype(out), changetype(result), true);\n }\n }\n return out;\n }\n\n filter(fn: (value: T, index: i32, array: Array) => bool): Array {\n var result = changetype>(__newArray(0, alignof(), idof>()));\n for (let i = 0, len = this.length_; i < min(len, this.length_); ++i) {\n let value = load(this.dataStart + (i << alignof()));\n if (fn(value, i, this)) result.push(value);\n }\n return result;\n }\n\n reduce(\n fn: (previousValue: U, currentValue: T, currentIndex: i32, array: Array) => U,\n initialValue: U\n ): U {\n var acc = initialValue;\n for (let i = 0, len = this.length_; i < min(len, this.length_); ++i) {\n acc = fn(acc, load(this.dataStart + (i << alignof())), i, this);\n }\n return acc;\n }\n\n reduceRight(\n fn: (previousValue: U, currentValue: T, currentIndex: i32, array: Array) => U,\n initialValue: U\n ): U {\n var acc = initialValue;\n for (let i = this.length_ - 1; i >= 0; --i) {\n acc = fn(acc, load(this.dataStart + (i << alignof())), i, this);\n }\n return acc;\n }\n\n shift(): T {\n var len = this.length_;\n if (len < 1) throw new RangeError(E_EMPTYARRAY);\n var base = this.dataStart;\n var element = load(base);\n var lastIndex = len - 1;\n memory.copy(\n base,\n base + sizeof(),\n lastIndex << alignof()\n );\n if (isReference()) {\n store(base + (lastIndex << alignof()), 0);\n } else {\n // @ts-ignore\n store(base + (lastIndex << alignof()), 0);\n }\n this.length_ = lastIndex;\n return element;\n }\n\n some(fn: (value: T, index: i32, array: Array) => bool): bool {\n for (let i = 0, len = this.length_; i < min(len, this.length_); ++i) {\n if (fn(load(this.dataStart + (i << alignof())), i, this)) return true;\n }\n return false;\n }\n\n unshift(value: T): i32 {\n var len = this.length_ + 1;\n ensureCapacity(changetype(this), len, alignof());\n var ptr = this.dataStart;\n memory.copy(\n ptr + sizeof(),\n ptr,\n (len - 1) << alignof()\n );\n store(ptr, value);\n if (isManaged()) {\n __link(changetype(this), changetype(value), true);\n }\n this.length_ = len;\n return len;\n }\n\n slice(start: i32 = 0, end: i32 = i32.MAX_VALUE): Array {\n var len = this.length_;\n start = start < 0 ? max(start + len, 0) : min(start, len);\n end = end < 0 ? max(end + len, 0) : min(end , len);\n len = max(end - start, 0);\n var slice = changetype>(__newArray(len, alignof(), idof>()));\n var sliceBase = slice.dataStart;\n var thisBase = this.dataStart + (start << alignof());\n if (isManaged()) {\n let off = 0;\n let end = len << alignof();\n while (off < end) {\n let ref = load(thisBase + off);\n store(sliceBase + off, ref);\n __link(changetype(slice), ref, true);\n off += sizeof();\n }\n } else {\n memory.copy(sliceBase, thisBase, len << alignof());\n }\n return slice;\n }\n\n splice(start: i32, deleteCount: i32 = i32.MAX_VALUE): Array {\n var len = this.length_;\n start = start < 0 ? max(len + start, 0) : min(start, len);\n deleteCount = max(min(deleteCount, len - start), 0);\n var result = changetype>(__newArray(deleteCount, alignof(), idof>()));\n var resultStart = result.dataStart;\n var thisStart = this.dataStart;\n var thisBase = thisStart + (start << alignof());\n memory.copy(\n resultStart,\n thisBase,\n deleteCount << alignof()\n );\n var offset = start + deleteCount;\n if (len != offset) {\n memory.copy(\n thisBase,\n thisStart + (offset << alignof()),\n (len - offset) << alignof()\n );\n }\n this.length_ = len - deleteCount;\n return result;\n }\n\n reverse(): Array {\n REVERSE(this.dataStart, this.length_);\n return this;\n }\n\n sort(comparator: (a: T, b: T) => i32 = COMPARATOR()): Array {\n SORT(this.dataStart, this.length_, comparator);\n return this;\n }\n\n join(separator: string = \",\"): string {\n var ptr = this.dataStart;\n var len = this.length_;\n if (isBoolean()) return joinBooleanArray(ptr, len, separator);\n if (isInteger()) return joinIntegerArray(ptr, len, separator);\n if (isFloat()) return joinFloatArray(ptr, len, separator);\n\n if (ASC_SHRINK_LEVEL < 1) {\n if (isString()) return joinStringArray(ptr, len, separator);\n }\n // For rest objects and arrays use general join routine\n if (isReference()) return joinReferenceArray(ptr, len, separator);\n ERROR(\"unspported element type\");\n return unreachable();\n }\n\n flat(): T {\n if (!isArray()) {\n ERROR(\"Cannot call flat() on Array where T is not an Array.\");\n }\n // Get the length and data start values\n var ptr = this.dataStart;\n var len = this.length_;\n\n // calculate the end size with an initial pass\n var size = 0;\n for (let i = 0; i < len; ++i) {\n let child = load(ptr + (i << alignof()));\n size += child == 0 ? 0 : load(child, offsetof(\"length_\"));\n }\n\n // calculate the byteLength of the resulting backing ArrayBuffer\n const align = alignof>();\n var byteLength = size << align;\n var outBuffer = changetype(__new(byteLength, idof()));\n\n // create the return value and initialize it\n var outArray = changetype(__new(offsetof(), idof()));\n store(changetype(outArray), size, offsetof(\"length_\"));\n\n // byteLength, dataStart, and buffer are all readonly\n store(changetype(outArray), byteLength, offsetof(\"byteLength\"));\n store(changetype(outArray), changetype(outBuffer), offsetof(\"dataStart\"));\n store(changetype(outArray), changetype(outBuffer), offsetof(\"buffer\"));\n __link(changetype(outArray), changetype(outBuffer), false);\n\n // set the elements\n var resultOffset: usize = 0;\n for (let i = 0; i < len; ++i) { // for each child\n let child = load(ptr + (i << alignof()));\n\n // ignore null arrays\n if (!child) continue;\n\n // copy the underlying buffer data to the result buffer\n let childDataLength = load(child, offsetof(\"length_\")) << align;\n memory.copy(\n changetype(outBuffer) + resultOffset,\n load(child, offsetof(\"dataStart\")),\n childDataLength\n );\n\n // advance the result length\n resultOffset += childDataLength;\n }\n\n // if the `valueof` type is managed, we must link each reference\n if (isManaged>()) {\n for (let i = 0; i < size; ++i) {\n let ref = load(changetype(outBuffer) + (i << usize(alignof>())));\n __link(changetype(outBuffer), ref, true);\n }\n }\n\n return outArray;\n }\n\n toString(): string {\n return this.join();\n }\n\n // RT integration\n\n @unsafe private __visit(cookie: u32): void {\n if (isManaged()) {\n let cur = this.dataStart;\n let end = cur + (this.length_ << alignof());\n while (cur < end) {\n let val = load(cur);\n if (val) __visit(val, cookie);\n cur += sizeof();\n }\n }\n __visit(changetype(this.buffer), cookie);\n }\n}\n","// Common error messages for use across the standard library. Keeping error messages compact\n// and reusing them where possible ensures minimal static data in binaries.\n\n// @ts-ignore: decorator\n@lazy @inline\nexport const E_INDEXOUTOFRANGE: string = \"Index out of range\";\n\n// @ts-ignore: decorator\n@lazy @inline\nexport const E_VALUEOUTOFRANGE: string = \"Value out of range\";\n\n// @ts-ignore: decorator\n@lazy @inline\nexport const E_INVALIDLENGTH: string = \"Invalid length\";\n\n// @ts-ignore: decorator\n@lazy @inline\nexport const E_EMPTYARRAY: string = \"Array is empty\";\n\n// @ts-ignore: decorator\n@lazy @inline\nexport const E_HOLEYARRAY: string = \"Element type must be nullable if array is holey\";\n\n// @ts-ignore: decorator\n@lazy @inline\nexport const E_NOTIMPLEMENTED: string = \"Not implemented\";\n\n// @ts-ignore: decorator\n@lazy @inline\nexport const E_KEYNOTFOUND: string = \"Key does not exist\";\n\n// @ts-ignore: decorator\n@lazy @inline\nexport const E_ALLOCATION_TOO_LARGE: string = \"Allocation too large\";\n\n// @ts-ignore: decorator\n@lazy @inline\nexport const E_ALREADY_PINNED: string = \"Object already pinned\";\n\n// @ts-ignore: decorator\n@lazy @inline\nexport const E_NOT_PINNED: string = \"Object is not pinned\";\n\n// @ts-ignore: decorator\n@lazy @inline\nexport const E_URI_MALFORMED: string = \"URI malformed\";\n\n// @ts-ignore: decorator\n@lazy @inline\nexport const E_INVALIDDATE: string = \"Invalid Date\";\n\n// @ts-ignore: decorator\n@lazy @inline\nexport const E_UNPAIRED_SURROGATE: string = \"Unpaired surrogate\";\n"]} \ No newline at end of file +{"version":3,"sources":["~lib/rt/common.ts","~lib/rt/tlsf.ts","~lib/shared/typeinfo.ts","~lib/rt/itcms.ts","assembly/perlin.ts","~lib/util/math.ts","~lib/util/number.ts","~lib/util/string.ts","~lib/math.ts","~lib/shared/runtime.ts","~lib/util/sort.ts","~lib/array.ts","~lib/util/error.ts"],"names":[],"mappings":"yGWiHI,AAAI,EAAc,AAAK,SAAmC,eAO1D,AANoB,MAAkB,EAAgB,6CPvDhD,EAAO,uBAEJ,EAAI,KAEJ,AAAK,EAAJ,KAED,EAAI,KAEJ,AAAC,GAAI,KAEL,EAAI,KAEJ,AAAK,EAAJ,KAED,EAAI,KAEJ,AAAC,GAAI,KAEL,EAAI,KAEJ,AAAK,EAAJ,KAED,EAAI,KAEJ,AAAC,GAAI,KAEL,EAAI,KAEJ,AAAK,EAAJ,KAED,EAAI,KAEJ,AAAC,GAAI,KAhChB,iEAnCiB,AAfF,AAAe,AALjB,GAAU,aAKa,QAed,AAdP,AAAe,AALjB,GAAU,UAKa,WAepB,MAAE,IAAK,AAdR,AAAe,AALjB,GAAU,UAKa,WAepB,MAAE,EAAI,KAAK,OACZ,MAAE,EAAI,KAAK,OACV,MAAE,IAAK,OACP,MAAE,EAAI,KAAK,OAOV,MAAE,IAAK,AAtBxB,EAAK,KAsBsB,AArB3B,EAAK,KAqByB,AApB9B,EAAK,WAoBkC,QAmB5B,AApCI,AAgCR,AAhCa,EAgCT,GAAI,GAAK,EAAK,EAAI,UAAI,WAAM,aAfE,IAAK,EAAI,YAAG,EAAG,IAmBpC,SAlBH,MAAE,IAAK,EAAG,EAAI,YAAG,QAAS,QAkBhC,AAnCI,AA+BR,AA/Ba,EA+BT,GAAI,GAAK,EAAK,EAAI,UAAI,WAAM,eAI5B,EAlBkC,IAAK,EAAO,EAAO,IAkB5C,cAdH,MAAE,EAAK,KAAI,EAAG,EAAG,EAAI,kBAAS,QAcpC,EAdsC,EAAK,KAAI,EAAO,EAAG,IAchD,SAbH,MAAE,EAAK,KAAI,EAAG,EAAO,QAAa,QAaxC,AAJJ,AA9Ba,EA8BT,GAAI,GAAK,EAAK,EAAI,UAAI,WAAM,aAI5B,MAb0C,EAAK,KAAI,EAAO,EAAO,IAaxD,eARR,UAAK","sourceRoot":"./release","sourcesContent":["// Alignment guarantees\n\n// @ts-ignore: decorator\n@inline export const AL_BITS: u32 = 4; // 16 bytes to fit up to v128\n// @ts-ignore: decorator\n@inline export const AL_SIZE: usize = 1 << AL_BITS;\n// @ts-ignore: decorator\n@inline export const AL_MASK: usize = AL_SIZE - 1;\n\n// Extra debugging\n\n// @ts-ignore: decorator\n@inline export const DEBUG = true;\n// @ts-ignore: decorator\n@inline export const TRACE = false;\n// @ts-ignore: decorator\n@inline export const RTRACE = isDefined(ASC_RTRACE);\n// @ts-ignore: decorator\n@inline export const PROFILE = isDefined(ASC_PROFILE);\n\n// Memory manager\n\n// ╒════════════ Memory manager block layout (32-bit) ═════════════╕\n// 3 2 1\n// 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 bits\n// ├─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┤\n// │ MM info │ -4\n// ╞>ptr═══════════════════════════════════════════════════════════╡\n// │ ... │\n@unmanaged export class BLOCK {\n /** Memory manager info. */\n mmInfo: usize;\n}\n\n/** Overhead of a memory manager block. */\n// @ts-ignore: decorator\n@inline export const BLOCK_OVERHEAD: usize = offsetof();\n\n/** Maximum size of a memory manager block's payload. */\n// @ts-ignore: decorator\n@inline export const BLOCK_MAXSIZE: usize = (1 << 30) - BLOCK_OVERHEAD;\n\n// Garbage collector\n\n// ╒══════════ Garbage collector object layout (32-bit) ═══════════╕\n// 3 2 1\n// 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 bits\n// ├─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┤\n// │ Memory manager block │ -20\n// ╞═══════════════════════════════════════════════════════════════╡\n// │ GC info │ -16\n// ├───────────────────────────────────────────────────────────────┤\n// │ GC info │ -12\n// ├───────────────────────────────────────────────────────────────┤\n// │ RT id │ -8\n// ├───────────────────────────────────────────────────────────────┤\n// │ RT size │ -4\n// ╞>ptr═══════════════════════════════════════════════════════════╡\n// │ ... │\n@unmanaged export class OBJECT extends BLOCK {\n /** Garbage collector info. */\n gcInfo: u32;\n /** Garbage collector info. */\n gcInfo2: u32;\n /** Runtime class id. */\n rtId: u32;\n /** Runtime object size. */\n rtSize: u32;\n}\n\n/** Overhead of a garbage collector object. Excludes memory manager block overhead. */\n// @ts-ignore: decorator\n@inline export const OBJECT_OVERHEAD: usize = (offsetof() - BLOCK_OVERHEAD + AL_MASK) & ~AL_MASK;\n\n/** Maximum size of a garbage collector object's payload. */\n// @ts-ignore: decorator\n@inline export const OBJECT_MAXSIZE: usize = BLOCK_MAXSIZE - OBJECT_OVERHEAD;\n\n/** Total of memory manager and garbage collector overhead. */\n// @ts-ignore: decorator\n@inline export const TOTAL_OVERHEAD: usize = BLOCK_OVERHEAD + OBJECT_OVERHEAD;\n","import { AL_BITS, AL_SIZE, AL_MASK, DEBUG, BLOCK, BLOCK_OVERHEAD, BLOCK_MAXSIZE } from \"./common\";\nimport { oninit, onalloc, onresize, onmove, onfree } from \"./rtrace\";\nimport { E_ALLOCATION_TOO_LARGE } from \"../util/error\";\n\n// === The TLSF (Two-Level Segregate Fit) memory allocator ===\n// see: http://www.gii.upv.es/tlsf/\n\n// - `ffs(x)` is equivalent to `ctz(x)` with x != 0\n// - `fls(x)` is equivalent to `sizeof(x) * 8 - clz(x) - 1`\n\n// ╒══════════════ Block size interpretation (32-bit) ═════════════╕\n// 3 2 1\n// 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 bits\n// ├─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┼─┴─┴─┴─╫─┴─┴─┴─┤\n// │ | FL │ SB = SL + AL │ ◄─ usize\n// └───────────────────────────────────────────────┴───────╨───────┘\n// FL: first level, SL: second level, AL: alignment, SB: small block\n\n// @ts-ignore: decorator\n@inline const SL_BITS: u32 = 4;\n// @ts-ignore: decorator\n@inline const SL_SIZE: u32 = 1 << SL_BITS;\n\n// @ts-ignore: decorator\n@inline const SB_BITS: u32 = SL_BITS + AL_BITS;\n// @ts-ignore: decorator\n@inline const SB_SIZE: u32 = 1 << SB_BITS;\n\n// @ts-ignore: decorator\n@inline const FL_BITS: u32 = 31 - SB_BITS;\n\n// [00]: < 256B (SB) [12]: < 1M\n// [01]: < 512B [13]: < 2M\n// [02]: < 1K [14]: < 4M\n// [03]: < 2K [15]: < 8M\n// [04]: < 4K [16]: < 16M\n// [05]: < 8K [17]: < 32M\n// [06]: < 16K [18]: < 64M\n// [07]: < 32K [19]: < 128M\n// [08]: < 64K [20]: < 256M\n// [09]: < 128K [21]: < 512M\n// [10]: < 256K [22]: <= 1G - OVERHEAD\n// [11]: < 512K\n// VMs limit to 2GB total (currently), making one 1G block max (or three 512M etc.) due to block overhead\n\n// Tags stored in otherwise unused alignment bits\n\n// @ts-ignore: decorator\n@inline const FREE: usize = 1 << 0;\n// @ts-ignore: decorator\n@inline const LEFTFREE: usize = 1 << 1;\n// @ts-ignore: decorator\n@inline const TAGS_MASK: usize = FREE | LEFTFREE; // <= AL_MASK\n\n// ╒════════════════════ Block layout (32-bit) ════════════════════╕\n// 3 2 1\n// 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 bits\n// ├─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┼─┼─┤ ┐\n// │ size │L│F│ ◄─┐ info overhead\n// ╞>ptr═══════════════════════════════════════════════════════╧═╧═╡ │ ┘\n// │ if free: ◄ prev │ ◄─┤ usize\n// ├───────────────────────────────────────────────────────────────┤ │\n// │ if free: next ► │ ◄─┤\n// ├───────────────────────────────────────────────────────────────┤ │\n// │ ... │ │ >= 0\n// ├───────────────────────────────────────────────────────────────┤ │\n// │ if free: back ▲ │ ◄─┘\n// └───────────────────────────────────────────────────────────────┘ >= MIN SIZE\n// F: FREE, L: LEFTFREE\n@unmanaged export class Block extends BLOCK {\n\n /** Previous free block, if any. Only valid if free, otherwise part of payload. */\n prev: Block | null;\n /** Next free block, if any. Only valid if free, otherwise part of payload. */\n next: Block | null;\n\n // If the block is free, there is a 'back'reference at its end pointing at its start.\n}\n\n// Block constants. A block must have a minimum size of three pointers so it can hold `prev`,\n// `next` and `back` if free.\n\n// @ts-ignore: decorator\n@inline const BLOCK_MINSIZE: usize = ((3 * sizeof() + BLOCK_OVERHEAD + AL_MASK) & ~AL_MASK) - BLOCK_OVERHEAD; // prev + next + back\n// @ts-ignore: decorator\n// @inline const BLOCK_MAXSIZE: usize = 1 << (FL_BITS + SB_BITS - 1); // exclusive, lives in common.ts\n\n/** Gets the left block of a block. Only valid if the left block is free. */\n// @ts-ignore: decorator\n@inline function GETFREELEFT(block: Block): Block {\n return load(changetype(block) - sizeof());\n}\n\n/** Gets the right block of a block by advancing to the right by its size. */\n// @ts-ignore: decorator\n@inline function GETRIGHT(block: Block): Block {\n return changetype(changetype(block) + BLOCK_OVERHEAD + (block.mmInfo & ~TAGS_MASK));\n}\n\n// ╒═════════════════════ Root layout (32-bit) ════════════════════╕\n// 3 2 1\n// 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 bits\n// ├─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┤ ┐\n// │ 0 | flMap S│ ◄────┐\n// ╞═══════════════════════════════════════════════════════════════╡ │\n// │ slMap[0] S │ ◄─┐ │\n// ├───────────────────────────────────────────────────────────────┤ │ │\n// │ slMap[1] │ ◄─┤ │\n// ├───────────────────────────────────────────────────────────────┤ u32 │\n// │ slMap[22] │ ◄─┘ │\n// ╞═══════════════════════════════════════════════════════════════╡ usize\n// │ head[0] │ ◄────┤\n// ├───────────────────────────────────────────────────────────────┤ │\n// │ ... │ ◄────┤\n// ├───────────────────────────────────────────────────────────────┤ │\n// │ head[367] │ ◄────┤\n// ╞═══════════════════════════════════════════════════════════════╡ │\n// │ tail │ ◄────┘\n// └───────────────────────────────────────────────────────────────┘ SIZE ┘\n// S: Small blocks map\n@unmanaged class Root {\n /** First level bitmap. */\n flMap: usize;\n}\n\n// Root constants. Where stuff is stored inside of the root structure.\n\n// @ts-ignore: decorator\n@inline const SL_START: usize = sizeof();\n// @ts-ignore: decorator\n@inline const SL_END: usize = SL_START + (FL_BITS << alignof());\n// @ts-ignore: decorator\n@inline const HL_START: usize = (SL_END + AL_MASK) & ~AL_MASK;\n// @ts-ignore: decorator\n@inline const HL_END: usize = HL_START + FL_BITS * SL_SIZE * sizeof();\n// @ts-ignore: decorator\n@inline const ROOT_SIZE: usize = HL_END + sizeof();\n\n// @ts-ignore: decorator\n@lazy export var ROOT: Root;\n\n/** Gets the second level map of the specified first level. */\n// @ts-ignore: decorator\n@inline function GETSL(root: Root, fl: usize): u32 {\n return load(\n changetype(root) + (fl << alignof()),\n SL_START\n );\n}\n\n/** Sets the second level map of the specified first level. */\n// @ts-ignore: decorator\n@inline function SETSL(root: Root, fl: usize, slMap: u32): void {\n store(\n changetype(root) + (fl << alignof()),\n slMap,\n SL_START\n );\n}\n\n/** Gets the head of the free list for the specified combination of first and second level. */\n// @ts-ignore: decorator\n@inline function GETHEAD(root: Root, fl: usize, sl: u32): Block | null {\n return load(\n changetype(root) + (((fl << SL_BITS) + sl) << alignof()),\n HL_START\n );\n}\n\n/** Sets the head of the free list for the specified combination of first and second level. */\n// @ts-ignore: decorator\n@inline function SETHEAD(root: Root, fl: usize, sl: u32, head: Block | null): void {\n store(\n changetype(root) + (((fl << SL_BITS) + sl) << alignof()),\n head,\n HL_START\n );\n}\n\n/** Gets the tail block.. */\n// @ts-ignore: decorator\n@inline function GETTAIL(root: Root): Block {\n return load(\n changetype(root),\n HL_END\n );\n}\n\n/** Sets the tail block. */\n// @ts-ignore: decorator\n@inline function SETTAIL(root: Root, tail: Block): void {\n store(\n changetype(root),\n tail,\n HL_END\n );\n}\n\n/** Inserts a previously used block back into the free list. */\nfunction insertBlock(root: Root, block: Block): void {\n if (DEBUG) assert(block); // cannot be null\n var blockInfo = block.mmInfo;\n if (DEBUG) assert(blockInfo & FREE); // must be free\n\n var right = GETRIGHT(block);\n var rightInfo = right.mmInfo;\n\n // merge with right block if also free\n if (rightInfo & FREE) {\n removeBlock(root, right);\n block.mmInfo = blockInfo = blockInfo + BLOCK_OVERHEAD + (rightInfo & ~TAGS_MASK); // keep block tags\n right = GETRIGHT(block);\n rightInfo = right.mmInfo;\n // 'back' is set below\n }\n\n // merge with left block if also free\n if (blockInfo & LEFTFREE) {\n let left = GETFREELEFT(block);\n let leftInfo = left.mmInfo;\n if (DEBUG) assert(leftInfo & FREE); // must be free according to right tags\n removeBlock(root, left);\n block = left;\n block.mmInfo = blockInfo = leftInfo + BLOCK_OVERHEAD + (blockInfo & ~TAGS_MASK); // keep left tags\n // 'back' is set below\n }\n\n right.mmInfo = rightInfo | LEFTFREE;\n // reference to right is no longer used now, hence rightInfo is not synced\n\n // we now know the size of the block\n var size = blockInfo & ~TAGS_MASK;\n if (DEBUG) assert(size >= BLOCK_MINSIZE); // must be a valid size\n if (DEBUG) assert(changetype(block) + BLOCK_OVERHEAD + size == changetype(right)); // must match\n\n // set 'back' to itself at the end of block\n store(changetype(right) - sizeof(), block);\n\n // mapping_insert\n var fl: usize, sl: u32;\n if (size < SB_SIZE) {\n fl = 0;\n sl = (size >> AL_BITS);\n } else {\n const inv: usize = sizeof() * 8 - 1;\n let boundedSize = min(size, BLOCK_MAXSIZE);\n fl = inv - clz(boundedSize);\n sl = ((boundedSize >> (fl - SL_BITS)) ^ (1 << SL_BITS));\n fl -= SB_BITS - 1;\n }\n if (DEBUG) assert(fl < FL_BITS && sl < SL_SIZE); // fl/sl out of range\n\n // perform insertion\n var head = GETHEAD(root, fl, sl);\n block.prev = null;\n block.next = head;\n if (head) head.prev = block;\n SETHEAD(root, fl, sl, block);\n\n // update first and second level maps\n root.flMap |= (1 << fl);\n SETSL(root, fl, GETSL(root, fl) | (1 << sl));\n}\n\n/** Removes a free block from internal lists. */\nfunction removeBlock(root: Root, block: Block): void {\n var blockInfo = block.mmInfo;\n if (DEBUG) assert(blockInfo & FREE); // must be free\n var size = blockInfo & ~TAGS_MASK;\n if (DEBUG) assert(size >= BLOCK_MINSIZE); // must be valid\n\n // mapping_insert\n var fl: usize, sl: u32;\n if (size < SB_SIZE) {\n fl = 0;\n sl = (size >> AL_BITS);\n } else {\n const inv: usize = sizeof() * 8 - 1;\n let boundedSize = min(size, BLOCK_MAXSIZE);\n fl = inv - clz(boundedSize);\n sl = ((boundedSize >> (fl - SL_BITS)) ^ (1 << SL_BITS));\n fl -= SB_BITS - 1;\n }\n if (DEBUG) assert(fl < FL_BITS && sl < SL_SIZE); // fl/sl out of range\n\n // link previous and next free block\n var prev = block.prev;\n var next = block.next;\n if (prev) prev.next = next;\n if (next) next.prev = prev;\n\n // update head if we are removing it\n if (block == GETHEAD(root, fl, sl)) {\n SETHEAD(root, fl, sl, next);\n\n // clear second level map if head is empty now\n if (!next) {\n let slMap = GETSL(root, fl);\n SETSL(root, fl, slMap &= ~(1 << sl));\n\n // clear first level map if second level is empty now\n if (!slMap) root.flMap &= ~(1 << fl);\n }\n }\n // note: does not alter left/back because it is likely that splitting\n // is performed afterwards, invalidating those changes. so, the caller\n // must perform those updates.\n}\n\n/** Searches for a free block of at least the specified size. */\nfunction searchBlock(root: Root, size: usize): Block | null {\n // size was already asserted by caller\n\n // mapping_search\n var fl: usize, sl: u32;\n if (size < SB_SIZE) {\n fl = 0;\n sl = (size >> AL_BITS);\n } else {\n const halfMaxSize = BLOCK_MAXSIZE >> 1; // don't round last fl\n const inv: usize = sizeof() * 8 - 1;\n const invRound = inv - SL_BITS;\n let requestSize = size < halfMaxSize\n ? size + (1 << (invRound - clz(size))) - 1\n : size;\n fl = inv - clz(requestSize);\n sl = ((requestSize >> (fl - SL_BITS)) ^ (1 << SL_BITS));\n fl -= SB_BITS - 1;\n }\n if (DEBUG) assert(fl < FL_BITS && sl < SL_SIZE); // fl/sl out of range\n\n // search second level\n var slMap = GETSL(root, fl) & (~0 << sl);\n var head: Block | null = null;\n if (!slMap) {\n // search next larger first level\n let flMap = root.flMap & (~0 << (fl + 1));\n if (!flMap) {\n head = null;\n } else {\n fl = ctz(flMap);\n slMap = GETSL(root, fl);\n if (DEBUG) assert(slMap); // can't be zero if fl points here\n head = GETHEAD(root, fl, ctz(slMap));\n }\n } else {\n head = GETHEAD(root, fl, ctz(slMap));\n }\n return head;\n}\n\n/** Prepares the specified block before (re-)use, possibly splitting it. */\nfunction prepareBlock(root: Root, block: Block, size: usize): void {\n // size was already asserted by caller\n\n var blockInfo = block.mmInfo;\n if (DEBUG) assert(!((size + BLOCK_OVERHEAD) & AL_MASK)); // size must be aligned so the new block is\n\n // split if the block can hold another MINSIZE block incl. overhead\n var remaining = (blockInfo & ~TAGS_MASK) - size;\n if (remaining >= BLOCK_OVERHEAD + BLOCK_MINSIZE) {\n block.mmInfo = size | (blockInfo & LEFTFREE); // also discards FREE\n\n let spare = changetype(changetype(block) + BLOCK_OVERHEAD + size);\n spare.mmInfo = (remaining - BLOCK_OVERHEAD) | FREE; // not LEFTFREE\n insertBlock(root, spare); // also sets 'back'\n\n // otherwise tag block as no longer FREE and right as no longer LEFTFREE\n } else {\n block.mmInfo = blockInfo & ~FREE;\n GETRIGHT(block).mmInfo &= ~LEFTFREE;\n }\n}\n\n/** Adds more memory to the pool. */\nfunction addMemory(root: Root, start: usize, end: usize): bool {\n if (DEBUG) assert(start <= end); // must be valid\n start = ((start + BLOCK_OVERHEAD + AL_MASK) & ~AL_MASK) - BLOCK_OVERHEAD;\n end &= ~AL_MASK;\n\n var tail = GETTAIL(root);\n var tailInfo: usize = 0;\n if (tail) { // more memory\n if (DEBUG) assert(start >= changetype(tail) + BLOCK_OVERHEAD);\n\n // merge with current tail if adjacent\n const offsetToTail = AL_SIZE;\n if (start - offsetToTail == changetype(tail)) {\n start -= offsetToTail;\n tailInfo = tail.mmInfo;\n } else {\n // We don't do this, but a user might `memory.grow` manually\n // leading to non-adjacent pages managed by TLSF.\n }\n\n } else if (DEBUG) { // first memory\n assert(start >= changetype(root) + ROOT_SIZE); // starts after root\n }\n\n // check if size is large enough for a free block and the tail block\n var size = end - start;\n if (size < BLOCK_OVERHEAD + BLOCK_MINSIZE + BLOCK_OVERHEAD) {\n return false;\n }\n\n // left size is total minus its own and the zero-length tail's header\n var leftSize = size - 2 * BLOCK_OVERHEAD;\n var left = changetype(start);\n left.mmInfo = leftSize | FREE | (tailInfo & LEFTFREE);\n left.prev = null;\n left.next = null;\n\n // tail is a zero-length used block\n tail = changetype(start + BLOCK_OVERHEAD + leftSize);\n tail.mmInfo = 0 | LEFTFREE;\n SETTAIL(root, tail);\n\n insertBlock(root, left); // also merges with free left before tail / sets 'back'\n\n return true;\n}\n\n/** Grows memory to fit at least another block of the specified size. */\nfunction growMemory(root: Root, size: usize): void {\n if (ASC_LOW_MEMORY_LIMIT) {\n unreachable();\n return;\n }\n // Here, both rounding performed in searchBlock ...\n const halfMaxSize = BLOCK_MAXSIZE >> 1;\n if (size < halfMaxSize) { // don't round last fl\n const invRound = (sizeof() * 8 - 1) - SL_BITS;\n size += (1 << (invRound - clz(size))) - 1;\n }\n // and additional BLOCK_OVERHEAD must be taken into account. If we are going\n // to merge with the tail block, that's one time, otherwise it's two times.\n var pagesBefore = memory.size();\n size += BLOCK_OVERHEAD << usize((pagesBefore << 16) - BLOCK_OVERHEAD != changetype(GETTAIL(root)));\n var pagesNeeded = (((size + 0xffff) & ~0xffff) >>> 16);\n var pagesWanted = max(pagesBefore, pagesNeeded); // double memory\n if (memory.grow(pagesWanted) < 0) {\n if (memory.grow(pagesNeeded) < 0) unreachable();\n }\n var pagesAfter = memory.size();\n addMemory(root, pagesBefore << 16, pagesAfter << 16);\n}\n\n/** Computes the size (excl. header) of a block. */\nfunction computeSize(size: usize): usize {\n // Size must be large enough and aligned minus preceeding overhead\n return size <= BLOCK_MINSIZE\n ? BLOCK_MINSIZE\n : ((size + BLOCK_OVERHEAD + AL_MASK) & ~AL_MASK) - BLOCK_OVERHEAD;\n}\n\n/** Prepares and checks an allocation size. */\nfunction prepareSize(size: usize): usize {\n if (size > BLOCK_MAXSIZE) throw new Error(E_ALLOCATION_TOO_LARGE);\n return computeSize(size);\n}\n\n/** Initializes the root structure. */\nfunction initialize(): void {\n if (isDefined(ASC_RTRACE)) oninit(__heap_base);\n var rootOffset = (__heap_base + AL_MASK) & ~AL_MASK;\n var pagesBefore = memory.size();\n var pagesNeeded = ((((rootOffset + ROOT_SIZE) + 0xffff) & ~0xffff) >>> 16);\n if (pagesNeeded > pagesBefore && memory.grow(pagesNeeded - pagesBefore) < 0) unreachable();\n var root = changetype(rootOffset);\n root.flMap = 0;\n SETTAIL(root, changetype(0));\n for (let fl: usize = 0; fl < FL_BITS; ++fl) {\n SETSL(root, fl, 0);\n for (let sl: u32 = 0; sl < SL_SIZE; ++sl) {\n SETHEAD(root, fl, sl, null);\n }\n }\n var memStart = rootOffset + ROOT_SIZE;\n if (ASC_LOW_MEMORY_LIMIT) {\n const memEnd = ASC_LOW_MEMORY_LIMIT & ~AL_MASK;\n if (memStart <= memEnd) addMemory(root, memStart, memEnd);\n else unreachable(); // low memory limit already exceeded\n } else {\n addMemory(root, memStart, memory.size() << 16);\n }\n ROOT = root;\n}\n\n/** Allocates a block of the specified size. */\nexport function allocateBlock(root: Root, size: usize): Block {\n var payloadSize = prepareSize(size);\n var block = searchBlock(root, payloadSize);\n if (!block) {\n growMemory(root, payloadSize);\n block = changetype(searchBlock(root, payloadSize));\n if (DEBUG) assert(block); // must be found now\n }\n if (DEBUG) assert((block.mmInfo & ~TAGS_MASK) >= payloadSize); // must fit\n removeBlock(root, block);\n prepareBlock(root, block, payloadSize);\n if (isDefined(ASC_RTRACE)) onalloc(block);\n return block;\n}\n\n/** Reallocates a block to the specified size. */\nexport function reallocateBlock(root: Root, block: Block, size: usize): Block {\n var payloadSize = prepareSize(size);\n var blockInfo = block.mmInfo;\n var blockSize = blockInfo & ~TAGS_MASK;\n\n // possibly split and update runtime size if it still fits\n if (payloadSize <= blockSize) {\n prepareBlock(root, block, payloadSize);\n if (isDefined(ASC_RTRACE)) {\n if (payloadSize != blockSize) onresize(block, BLOCK_OVERHEAD + blockSize);\n }\n return block;\n }\n\n // merge with right free block if merger is large enough\n var right = GETRIGHT(block);\n var rightInfo = right.mmInfo;\n if (rightInfo & FREE) {\n let mergeSize = blockSize + BLOCK_OVERHEAD + (rightInfo & ~TAGS_MASK);\n if (mergeSize >= payloadSize) {\n removeBlock(root, right);\n block.mmInfo = (blockInfo & TAGS_MASK) | mergeSize;\n prepareBlock(root, block, payloadSize);\n if (isDefined(ASC_RTRACE)) onresize(block, BLOCK_OVERHEAD + blockSize);\n return block;\n }\n }\n\n // otherwise move the block\n return moveBlock(root, block, size);\n}\n\n/** Moves a block to a new one of the specified size. */\nfunction moveBlock(root: Root, block: Block, newSize: usize): Block {\n var newBlock = allocateBlock(root, newSize);\n memory.copy(changetype(newBlock) + BLOCK_OVERHEAD, changetype(block) + BLOCK_OVERHEAD, block.mmInfo & ~TAGS_MASK);\n if (changetype(block) >= __heap_base) {\n if (isDefined(ASC_RTRACE)) onmove(block, newBlock);\n freeBlock(root, block);\n }\n return newBlock;\n}\n\n/** Frees a block. */\nexport function freeBlock(root: Root, block: Block): void {\n if (isDefined(ASC_RTRACE)) onfree(block);\n block.mmInfo = block.mmInfo | FREE;\n insertBlock(root, block);\n}\n\n/** Checks that a used block is valid to be freed or reallocated. */\nfunction checkUsedBlock(ptr: usize): Block {\n var block = changetype(ptr - BLOCK_OVERHEAD);\n assert(\n ptr != 0 && !(ptr & AL_MASK) && // must exist and be aligned\n !(block.mmInfo & FREE) // must be used\n );\n return block;\n}\n\n// @ts-ignore: decorator\n@global @unsafe\nexport function __alloc(size: usize): usize {\n if (!ROOT) initialize();\n return changetype(allocateBlock(ROOT, size)) + BLOCK_OVERHEAD;\n}\n\n// @ts-ignore: decorator\n@global @unsafe\nexport function __realloc(ptr: usize, size: usize): usize {\n if (!ROOT) initialize();\n return (ptr < __heap_base\n ? changetype(moveBlock(ROOT, checkUsedBlock(ptr), size))\n : changetype(reallocateBlock(ROOT, checkUsedBlock(ptr), size))\n ) + BLOCK_OVERHEAD;\n}\n\n// @ts-ignore: decorator\n@global @unsafe\nexport function __free(ptr: usize): void {\n if (ptr < __heap_base) return;\n if (!ROOT) initialize();\n freeBlock(ROOT, checkUsedBlock(ptr));\n}\n","// This file is shared with the compiler and must remain portable\n\n// ╒═══════════════════ Typeinfo interpretation ═══════════════════╕\n// 3 2 1\n// 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 bits\n// ├─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┤ ◄─ __rtti_base\n// │ count │\n// ╞═══════════════════════════════════════════════════════════════╡ ┐\n// │ Typeinfo#flags [id=0] │ id < count\n// ├ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ┤\n// │ Typeinfo#base [id=0] │\n// ├───────────────────────────────────────────────────────────────┤\n// │ ... │\n\n/** Runtime type information data structure. */\n@unmanaged\nexport class Typeinfo {\n /** Flags describing the shape of this class type. */\n flags: TypeinfoFlags = TypeinfoFlags.NONE;\n /** Base class id or `0` if none. */\n base: u32 = 0;\n}\n\n/** Runtime type information flags. */\nexport const enum TypeinfoFlags {\n /** No specific flags. */\n NONE = 0,\n /** Type is an `ArrayBufferView`. */\n ARRAYBUFFERVIEW = 1 << 0,\n /** Type is an `Array`. */\n ARRAY = 1 << 1,\n /** Type is a `StaticArray`. */\n STATICARRAY = 1 << 2,\n /** Type is a `Set`. */\n SET = 1 << 3,\n /** Type is a `Map`. */\n MAP = 1 << 4,\n /** Type has no outgoing pointers. */\n POINTERFREE = 1 << 5,\n /** Value alignment of 1 byte. */\n VALUE_ALIGN_0 = 1 << 6,\n /** Value alignment of 2 bytes. */\n VALUE_ALIGN_1 = 1 << 7,\n /** Value alignment of 4 bytes. */\n VALUE_ALIGN_2 = 1 << 8,\n /** Value alignment of 8 bytes. */\n VALUE_ALIGN_3 = 1 << 9,\n /** Value alignment of 16 bytes. */\n VALUE_ALIGN_4 = 1 << 10,\n /** Value is a signed type. */\n VALUE_SIGNED = 1 << 11,\n /** Value is a float type. */\n VALUE_FLOAT = 1 << 12,\n /** Value type is nullable. */\n VALUE_NULLABLE = 1 << 13,\n /** Value type is managed. */\n VALUE_MANAGED = 1 << 14,\n /** Key alignment of 1 byte. */\n KEY_ALIGN_0 = 1 << 15,\n /** Key alignment of 2 bytes. */\n KEY_ALIGN_1 = 1 << 16,\n /** Key alignment of 4 bytes. */\n KEY_ALIGN_2 = 1 << 17,\n /** Key alignment of 8 bytes. */\n KEY_ALIGN_3 = 1 << 18,\n /** Key alignment of 16 bytes. */\n KEY_ALIGN_4 = 1 << 19,\n /** Key is a signed type. */\n KEY_SIGNED = 1 << 20,\n /** Key is a float type. */\n KEY_FLOAT = 1 << 21,\n /** Key type is nullable. */\n KEY_NULLABLE = 1 << 22,\n /** Key type is managed. */\n KEY_MANAGED = 1 << 23\n}\n","import { BLOCK, BLOCK_OVERHEAD, OBJECT_OVERHEAD, OBJECT_MAXSIZE, TOTAL_OVERHEAD, DEBUG, TRACE, RTRACE, PROFILE } from \"./common\";\nimport { onvisit, oncollect, oninterrupt, onyield } from \"./rtrace\";\nimport { TypeinfoFlags } from \"../shared/typeinfo\";\nimport { E_ALLOCATION_TOO_LARGE, E_ALREADY_PINNED, E_NOT_PINNED } from \"../util/error\";\n\n// === ITCMS: An incremental Tri-Color Mark & Sweep garbage collector ===\n// Adapted from Bach Le's μgc, see: https://github.com/bullno1/ugc\n\n// ╒═════════════╤══════════════ Colors ═══════════════════════════╕\n// │ Color │ Meaning │\n// ├─────────────┼─────────────────────────────────────────────────┤\n// │ WHITE* │ Unprocessed │\n// │ BLACK* │ Processed │\n// │ GRAY │ Processed with unprocessed children │\n// │ TRANSPARENT │ Manually pinned (always reachable) │\n// └─────────────┴─────────────────────────────────────────────────┘\n// * flipped between cycles\n\n// @ts-ignore: decorator\n@lazy var white = 0;\n// @ts-ignore: decorator\n@inline const gray = 2;\n// @ts-ignore: decorator\n@inline const transparent = 3;\n// @ts-ignore: decorator\n@inline const COLOR_MASK = 3;\n\n/** Size in memory of all objects currently managed by the GC. */\n// @ts-ignore: decorator\n@lazy var total: usize = 0;\n\n/** Currently transitioning from SWEEP to MARK state. */\n// @ts-ignore: decorator\n@inline const STATE_IDLE = 0;\n/** Currently marking reachable objects. */\n// @ts-ignore: decorator\n@inline const STATE_MARK = 1;\n/** Currently sweeping unreachable objects. */\n// @ts-ignore: decorator\n@inline const STATE_SWEEP = 2;\n/** Current collector state. */\n// @ts-ignore: decorator\n@lazy var state = STATE_IDLE;\n\n// @ts-ignore: decorator\n@lazy var fromSpace = initLazy(changetype(memory.data(offsetof())));\n// @ts-ignore: decorator\n@lazy var toSpace = initLazy(changetype(memory.data(offsetof())));\n// @ts-ignore: decorator\n@lazy var pinSpace = initLazy(changetype(memory.data(offsetof())));\n// @ts-ignore: decorator\n@lazy var iter: Object; // null\n\nfunction initLazy(space: Object): Object {\n space.nextWithColor = changetype(space);\n space.prev = space;\n return space;\n}\n\n/** Visit cookie indicating scanning of an object. */\n// @ts-ignore: decorator\n@inline const VISIT_SCAN = 0;\n\n// ╒═══════════════ Managed object layout (32-bit) ════════════════╕\n// 3 2 1\n// 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 bits\n// ├─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┤\n// │ Memory manager block │\n// ╞═══════════════════════════════════════════════════════════╤═══╡\n// │ next │ C │ = nextWithColor\n// ├───────────────────────────────────────────────────────────┴───┤\n// │ prev │\n// ├───────────────────────────────────────────────────────────────┤\n// │ rtId │\n// ├───────────────────────────────────────────────────────────────┤\n// │ rtSize │\n// ╞>ptr═══════════════════════════════════════════════════════════╡\n// │ ... │\n// C: color\n\n/** Represents a managed object in memory, consisting of a header followed by the object's data. */\n@unmanaged class Object extends BLOCK {\n /** Pointer to the next object with color flags stored in the alignment bits. */\n nextWithColor: usize; // *u32\n /** Pointer to the previous object. */\n prev: Object; // *u32\n /** Runtime id. */\n rtId: u32;\n /** Runtime size. */\n rtSize: u32;\n\n /** Gets the pointer to the next object. */\n get next(): Object {\n return changetype(this.nextWithColor & ~COLOR_MASK);\n }\n\n /** Sets the pointer to the next object. */\n set next(obj: Object) {\n this.nextWithColor = changetype(obj) | (this.nextWithColor & COLOR_MASK);\n }\n\n /** Gets this object's color. */\n get color(): i32 {\n return i32(this.nextWithColor & COLOR_MASK);\n }\n\n /** Sets this object's color. */\n set color(color: i32) {\n this.nextWithColor = (this.nextWithColor & ~COLOR_MASK) | color;\n }\n\n /** Gets the size of this object in memory. */\n get size(): usize {\n return BLOCK_OVERHEAD + (this.mmInfo & ~3);\n }\n\n /** Tests if this object is pointerfree. */\n get isPointerfree(): bool {\n var rtId = this.rtId;\n return rtId <= idof() || (__typeinfo(rtId) & TypeinfoFlags.POINTERFREE) != 0;\n }\n\n /** Unlinks this object from its list. */\n unlink(): void {\n var next = this.next;\n if (next == null) {\n if (DEBUG) assert(this.prev == null && changetype(this) < __heap_base);\n return; // static data not yet linked\n }\n var prev = this.prev;\n if (DEBUG) assert(prev);\n next.prev = prev;\n prev.next = next;\n }\n\n /** Links this object to the specified list, with the given color. */\n linkTo(list: Object, withColor: i32): void {\n let prev = list.prev;\n this.nextWithColor = changetype(list) | withColor;\n this.prev = prev;\n prev.next = this;\n list.prev = this;\n }\n\n /** Marks this object as gray, that is reachable with unscanned children. */\n makeGray(): void {\n if (this == iter) iter = assert(this.prev);\n this.unlink();\n this.linkTo(toSpace, this.isPointerfree ? i32(!white) : gray);\n }\n}\n\n/** Visits all objects considered to be program roots. */\nfunction visitRoots(cookie: u32): void {\n __visit_globals(cookie);\n var pn = pinSpace;\n var iter = pn.next;\n while (iter != pn) {\n if (DEBUG) assert(iter.color == transparent);\n __visit_members(changetype(iter) + TOTAL_OVERHEAD, cookie);\n iter = iter.next;\n }\n}\n\n/** Visits all objects on the stack. */\nfunction visitStack(cookie: u32): void {\n var ptr = __stack_pointer;\n while (ptr < __heap_base) {\n __visit(load(ptr), cookie);\n ptr += sizeof();\n }\n}\n\n/** Performs a single step according to the current state. */\nfunction step(): usize {\n // Magic constants responsible for pause times. Obtained experimentally\n // using the compiler compiling itself. 2048 budget pro run by default.\n const MARKCOST = isDefined(ASC_GC_MARKCOST) ? ASC_GC_MARKCOST : 1;\n const SWEEPCOST = isDefined(ASC_GC_SWEEPCOST) ? ASC_GC_SWEEPCOST : 10;\n var obj: Object;\n switch (state) {\n case STATE_IDLE: {\n state = STATE_MARK;\n visitCount = 0;\n visitRoots(VISIT_SCAN);\n iter = toSpace;\n return visitCount * MARKCOST;\n }\n case STATE_MARK: {\n let black = i32(!white);\n obj = iter.next;\n while (obj != toSpace) {\n iter = obj;\n if (obj.color != black) { // skip already-blacks (pointerfree)\n obj.color = black;\n visitCount = 0;\n __visit_members(changetype(obj) + TOTAL_OVERHEAD, VISIT_SCAN);\n return visitCount * MARKCOST;\n }\n obj = obj.next;\n }\n visitCount = 0;\n visitRoots(VISIT_SCAN);\n obj = iter.next;\n if (obj == toSpace) {\n visitStack(VISIT_SCAN);\n obj = iter.next;\n while (obj != toSpace) {\n if (obj.color != black) {\n obj.color = black;\n __visit_members(changetype(obj) + TOTAL_OVERHEAD, VISIT_SCAN);\n }\n obj = obj.next;\n }\n let from = fromSpace;\n fromSpace = toSpace;\n toSpace = from;\n white = black;\n iter = from.next;\n state = STATE_SWEEP;\n }\n return visitCount * MARKCOST;\n }\n case STATE_SWEEP: {\n obj = iter;\n if (obj != toSpace) {\n iter = obj.next;\n if (DEBUG) assert(obj.color == i32(!white)); // old white\n free(obj);\n return SWEEPCOST;\n }\n toSpace.nextWithColor = changetype(toSpace);\n toSpace.prev = toSpace;\n state = STATE_IDLE;\n break;\n }\n }\n return 0;\n}\n\n/** Frees an object. */\nfunction free(obj: Object): void {\n if (changetype(obj) < __heap_base) {\n obj.nextWithColor = 0; // may become linked again\n obj.prev = changetype(0);\n } else {\n total -= obj.size;\n if (isDefined(__finalize)) {\n __finalize(changetype(obj) + TOTAL_OVERHEAD);\n }\n __free(changetype(obj) + BLOCK_OVERHEAD);\n }\n}\n\n// Garbage collector interface\n\n// @ts-ignore: decorator\n@global @unsafe\nexport function __new(size: usize, id: i32): usize {\n if (size >= OBJECT_MAXSIZE) throw new Error(E_ALLOCATION_TOO_LARGE);\n if (total >= threshold) interrupt();\n var obj = changetype(__alloc(OBJECT_OVERHEAD + size) - BLOCK_OVERHEAD);\n obj.rtId = id;\n obj.rtSize = size;\n obj.linkTo(fromSpace, white); // inits next/prev\n total += obj.size;\n var ptr = changetype(obj) + TOTAL_OVERHEAD;\n // may be visited before being fully initialized, so must fill\n memory.fill(ptr, 0, size);\n return ptr;\n}\n\n// @ts-ignore: decorator\n@global @unsafe\nexport function __renew(oldPtr: usize, size: usize): usize {\n var oldObj = changetype(oldPtr - TOTAL_OVERHEAD);\n // Update object size if its block is large enough\n if (size <= (oldObj.mmInfo & ~3) - OBJECT_OVERHEAD) {\n oldObj.rtSize = size;\n return oldPtr;\n }\n // If not the same object anymore, we have to move it move it due to the\n // shadow stack potentially still referencing the old object\n var newPtr = __new(size, oldObj.rtId);\n memory.copy(newPtr, oldPtr, min(size, oldObj.rtSize));\n return newPtr;\n}\n\n// @ts-ignore: decorator\n@global @unsafe\nexport function __link(parentPtr: usize, childPtr: usize, expectMultiple: bool): void {\n // Write barrier is unnecessary if non-incremental\n if (!childPtr) return;\n if (DEBUG) assert(parentPtr);\n var child = changetype(childPtr - TOTAL_OVERHEAD);\n if (child.color == white) {\n let parent = changetype(parentPtr - TOTAL_OVERHEAD);\n let parentColor = parent.color;\n if (parentColor == i32(!white)) {\n // Maintain the invariant that no black object may point to a white object.\n if (expectMultiple) {\n // Move the barrier \"backward\". Suitable for containers receiving multiple stores.\n // Avoids a barrier for subsequent objects stored into the same container.\n parent.makeGray();\n } else {\n // Move the barrier \"forward\". Suitable for objects receiving isolated stores.\n child.makeGray();\n }\n } else if (parentColor == transparent && state == STATE_MARK) {\n // Pinned objects are considered 'black' during the mark phase.\n child.makeGray();\n }\n }\n}\n\n// @ts-ignore: decorator\n@lazy var visitCount = 0;\n\n// @ts-ignore: decorator\n@global @unsafe\nexport function __visit(ptr: usize, cookie: i32): void {\n if (!ptr) return;\n let obj = changetype(ptr - TOTAL_OVERHEAD);\n if (RTRACE) if (!onvisit(obj)) return;\n if (obj.color == white) {\n obj.makeGray();\n ++visitCount;\n }\n}\n\n// @ts-ignore: decorator\n@global @unsafe\nexport function __pin(ptr: usize): usize {\n if (ptr) {\n let obj = changetype(ptr - TOTAL_OVERHEAD);\n if (obj.color == transparent) {\n throw new Error(E_ALREADY_PINNED);\n }\n obj.unlink(); // from fromSpace\n obj.linkTo(pinSpace, transparent);\n }\n return ptr;\n}\n\n// @ts-ignore: decorator\n@global @unsafe\nexport function __unpin(ptr: usize): void {\n if (!ptr) return;\n var obj = changetype(ptr - TOTAL_OVERHEAD);\n if (obj.color != transparent) {\n throw new Error(E_NOT_PINNED);\n }\n if (state == STATE_MARK) {\n // We may be right at the point after marking roots for the second time and\n // entering the sweep phase, in which case the object would be missed if it\n // is not only pinned but also a root. Make sure it isn't missed.\n obj.makeGray();\n } else {\n obj.unlink();\n obj.linkTo(fromSpace, white);\n }\n}\n\n// @ts-ignore: decorator\n@global @unsafe\nexport function __collect(): void {\n if (TRACE) trace(\"GC (full) at\", 1, total);\n if (state > STATE_IDLE) {\n // finish current cycle\n while (state != STATE_IDLE) step();\n }\n // perform a full cycle\n step();\n while (state != STATE_IDLE) step();\n threshold = (total * IDLEFACTOR / 100) + GRANULARITY;\n if (TRACE) trace(\"GC (full) done at cur/max\", 2, total, memory.size() << 16);\n if (RTRACE || PROFILE) oncollect(total);\n}\n\n// Garbage collector automation\n\n/** How often to interrupt. The default of 1024 means \"interrupt each 1024 bytes allocated\". */\n// @ts-ignore: decorator\n@inline const GRANULARITY: usize = isDefined(ASC_GC_GRANULARITY) ? ASC_GC_GRANULARITY : 1024;\n/** How long to interrupt. The default of 200% means \"run at double the speed of allocations\". */\n// @ts-ignore: decorator\n@inline const STEPFACTOR: usize = isDefined(ASC_GC_SWEEPFACTOR) ? ASC_GC_SWEEPFACTOR : 200;\n/** How long to idle. The default of 200% means \"wait for memory to double before kicking in again\". */\n// @ts-ignore: decorator\n@inline const IDLEFACTOR: usize = isDefined(ASC_GC_IDLEFACTOR) ? ASC_GC_IDLEFACTOR : 200;\n\n/** Threshold of memory used by objects to exceed before interrupting again. */\n// @ts-ignore: decorator\n@lazy var threshold: usize = ((memory.size() << 16) - __heap_base) >> 1;\n\n/** Performs a reasonable amount of incremental GC steps. */\nfunction interrupt(): void {\n if (PROFILE) oninterrupt(total);\n if (TRACE) trace(\"GC (auto) at\", 1, total);\n var budget: isize = GRANULARITY * STEPFACTOR / 100;\n do {\n budget -= step();\n if (state == STATE_IDLE) {\n if (TRACE) trace(\"└ GC (auto) done at cur/max\", 2, total, memory.size() << 16);\n threshold = (total * IDLEFACTOR / 100) + GRANULARITY;\n if (PROFILE) onyield(total);\n return;\n }\n } while (budget > 0);\n if (TRACE) trace(\"└ GC (auto) ongoing at\", 1, total);\n threshold = total + GRANULARITY * usize(total - threshold < GRANULARITY);\n if (PROFILE) onyield(total);\n}\n","// Ported from perlin reference implementation (https://cs.nyu.edu/~perlin/noise/)\n\nexport function perlin(_x: i32, _y: i32, _z: i32, denom: i32): f64 {\n // Convert fraction into f64\n let x: f64 = f64(_x) / f64(denom);\n let y: f64 = f64(_y) / f64(denom);\n let z: f64 = f64(_z) / f64(denom);\n\n // Find unit cube that contains point\n const X: i32 = i32(Math.floor(x)) & 255;\n const Y: i32 = i32(Math.floor(y)) & 255;\n const Z: i32 = i32(Math.floor(z)) & 255;\n\n // Find relative x,y,z of point in cube\n x -= Math.floor(x);\n y -= Math.floor(y);\n z -= Math.floor(z);\n\n // Compute fade curves for each x,y,z\n const u: f64 = fade(x);\n const v: f64 = fade(y);\n const w: f64 = fade(z);\n\n // Hash coordinates of the 8 cube corners\n const A: i32 = p[X] + Y;\n const AA: i32 = p[A] + Z;\n const AB: i32 = p[A + 1] + Z;\n const B: i32 = p[X + 1] + Y;\n const BA: i32 = p[B] + Z;\n const BB: i32 = p[B + 1] + Z;\n\n // Add blended results from 8 corners of cube\n const r: f64 = lerp(\n w,\n lerp(\n v,\n lerp(u, grad(p[AA], x, y, z), grad(p[BA], x - 1, y, z)),\n lerp(u, grad(p[AB], x, y - 1, z), grad(p[BB], x - 1, y - 1, z))\n ),\n lerp(\n v,\n lerp(u, grad(p[AA + 1], x, y, z - 1), grad(p[BA + 1], x - 1, y, z - 1)),\n lerp(u, grad(p[AB + 1], x, y - 1, z - 1), grad(p[BB + 1], x - 1, y - 1, z - 1))\n )\n );\n\n // Shift to range from 0 to 1\n return (r + 1) / 2;\n}\n\nfunction fade(t: f64): f64 {\n return t * t * t * (t * (t * 6 - 15) + 10);\n}\n\nfunction lerp(t: f64, a: f64, b: f64): f64 {\n return a + t * (b - a);\n}\n\nfunction grad(hash: i32, x: f64, y: f64, z: f64): f64 {\n switch (hash & 0xf) {\n case 0x0:\n return x + y;\n case 0x1:\n return -x + y;\n case 0x2:\n return x - y;\n case 0x3:\n return -x - y;\n case 0x4:\n return x + z;\n case 0x5:\n return -x + z;\n case 0x6:\n return x - z;\n case 0x7:\n return -x - z;\n case 0x8:\n return y + z;\n case 0x9:\n return -y + z;\n case 0xa:\n return y - z;\n case 0xb:\n return -y - z;\n case 0xc:\n return y + x;\n case 0xd:\n return -y + z;\n case 0xe:\n return y - x;\n case 0xf:\n return -y - z;\n default:\n return 0; // never happens\n }\n}\n\nconst p: i32[] = [\n 151, 160, 137, 91, 90, 15, 131, 13, 201, 95, 96, 53, 194, 233, 7, 225, 140, 36, 103, 30, 69, 142, 8, 99, 37, 240, 21,\n 10, 23, 190, 6, 148, 247, 120, 234, 75, 0, 26, 197, 62, 94, 252, 219, 203, 117, 35, 11, 32, 57, 177, 33, 88, 237, 149,\n 56, 87, 174, 20, 125, 136, 171, 168, 68, 175, 74, 165, 71, 134, 139, 48, 27, 166, 77, 146, 158, 231, 83, 111, 229,\n 122, 60, 211, 133, 230, 220, 105, 92, 41, 55, 46, 245, 40, 244, 102, 143, 54, 65, 25, 63, 161, 1, 216, 80, 73, 209,\n 76, 132, 187, 208, 89, 18, 169, 200, 196, 135, 130, 116, 188, 159, 86, 164, 100, 109, 198, 173, 186, 3, 64, 52, 217,\n 226, 250, 124, 123, 5, 202, 38, 147, 118, 126, 255, 82, 85, 212, 207, 206, 59, 227, 47, 16, 58, 17, 182, 189, 28, 42,\n 223, 183, 170, 213, 119, 248, 152, 2, 44, 154, 163, 70, 221, 153, 101, 155, 167, 43, 172, 9, 129, 22, 39, 253, 19, 98,\n 108, 110, 79, 113, 224, 232, 178, 185, 112, 104, 218, 246, 97, 228, 251, 34, 242, 193, 238, 210, 144, 12, 191, 179,\n 162, 241, 81, 51, 145, 235, 249, 14, 239, 107, 49, 192, 214, 31, 181, 199, 106, 157, 184, 84, 204, 176, 115, 121, 50,\n 45, 127, 4, 150, 254, 138, 236, 205, 93, 222, 114, 67, 29, 24, 72, 243, 141, 128, 195, 78, 66, 215, 61, 156, 180, 151,\n 160, 137, 91, 90, 15, 131, 13, 201, 95, 96, 53, 194, 233, 7, 225, 140, 36, 103, 30, 69, 142, 8, 99, 37, 240, 21, 10,\n 23, 190, 6, 148, 247, 120, 234, 75, 0, 26, 197, 62, 94, 252, 219, 203, 117, 35, 11, 32, 57, 177, 33, 88, 237, 149, 56,\n 87, 174, 20, 125, 136, 171, 168, 68, 175, 74, 165, 71, 134, 139, 48, 27, 166, 77, 146, 158, 231, 83, 111, 229, 122,\n 60, 211, 133, 230, 220, 105, 92, 41, 55, 46, 245, 40, 244, 102, 143, 54, 65, 25, 63, 161, 1, 216, 80, 73, 209, 76,\n 132, 187, 208, 89, 18, 169, 200, 196, 135, 130, 116, 188, 159, 86, 164, 100, 109, 198, 173, 186, 3, 64, 52, 217, 226,\n 250, 124, 123, 5, 202, 38, 147, 118, 126, 255, 82, 85, 212, 207, 206, 59, 227, 47, 16, 58, 17, 182, 189, 28, 42, 223,\n 183, 170, 213, 119, 248, 152, 2, 44, 154, 163, 70, 221, 153, 101, 155, 167, 43, 172, 9, 129, 22, 39, 253, 19, 98, 108,\n 110, 79, 113, 224, 232, 178, 185, 112, 104, 218, 246, 97, 228, 251, 34, 242, 193, 238, 210, 144, 12, 191, 179, 162,\n 241, 81, 51, 145, 235, 249, 14, 239, 107, 49, 192, 214, 31, 181, 199, 106, 157, 184, 84, 204, 176, 115, 121, 50, 45,\n 127, 4, 150, 254, 138, 236, 205, 93, 222, 114, 67, 29, 24, 72, 243, 141, 128, 195, 78, 66, 215, 61, 156, 180,\n];\n","//\n// Lookup data for exp2f\n//\n\n// @ts-ignore: decorator\n@inline const EXP2F_TABLE_BITS = 5;\n\n// @ts-ignore: decorator\n@lazy @inline const EXP2F_DATA_TAB = memory.data([\n // exp2f_data_tab[i] = uint(2^(i/N)) - (i << 52-BITS)\n // used for computing 2^(k/N) for an int |k| < 150 N as\n // double(tab[k%N] + (k << 52-BITS))\n 0x3FF0000000000000, 0x3FEFD9B0D3158574, 0x3FEFB5586CF9890F, 0x3FEF9301D0125B51,\n 0x3FEF72B83C7D517B, 0x3FEF54873168B9AA, 0x3FEF387A6E756238, 0x3FEF1E9DF51FDEE1,\n 0x3FEF06FE0A31B715, 0x3FEEF1A7373AA9CB, 0x3FEEDEA64C123422, 0x3FEECE086061892D,\n 0x3FEEBFDAD5362A27, 0x3FEEB42B569D4F82, 0x3FEEAB07DD485429, 0x3FEEA47EB03A5585,\n 0x3FEEA09E667F3BCD, 0x3FEE9F75E8EC5F74, 0x3FEEA11473EB0187, 0x3FEEA589994CCE13,\n 0x3FEEACE5422AA0DB, 0x3FEEB737B0CDC5E5, 0x3FEEC49182A3F090, 0x3FEED503B23E255D,\n 0x3FEEE89F995AD3AD, 0x3FEEFF76F2FB5E47, 0x3FEF199BDD85529C, 0x3FEF3720DCEF9069,\n 0x3FEF5818DCFBA487, 0x3FEF7C97337B9B5F, 0x3FEFA4AFA2A490DA, 0x3FEFD0765B6E4540\n]);\n\n// ULP error: 0.502 (nearest rounding.)\n// Relative error: 1.69 * 2^-34 in [-1/64, 1/64] (before rounding.)\n// Wrong count: 168353 (all nearest rounding wrong results with fma.)\n// @ts-ignore: decorator\n@inline\nexport function exp2f_lut(x: f32): f32 {\n const\n N = 1 << EXP2F_TABLE_BITS,\n N_MASK = N - 1,\n shift = reinterpret(0x4338000000000000) / N, // 0x1.8p+52\n Ox127f = reinterpret(0x7F000000);\n\n const\n C0 = reinterpret(0x3FAC6AF84B912394), // 0x1.c6af84b912394p-5\n C1 = reinterpret(0x3FCEBFCE50FAC4F3), // 0x1.ebfce50fac4f3p-3\n C2 = reinterpret(0x3FE62E42FF0C52D6); // 0x1.62e42ff0c52d6p-1\n\n var xd = x;\n var ix = reinterpret(x);\n var ux = ix >> 20 & 0x7FF;\n if (ux >= 0x430) {\n // |x| >= 128 or x is nan.\n if (ix == 0xFF800000) return 0; // x == -Inf -> 0\n if (ux >= 0x7F8) return x + x; // x == Inf/NaN -> Inf/NaN\n if (x > 0) return x * Ox127f; // x > 0 -> HugeVal (Owerflow)\n if (x <= -150) return 0; // x <= -150 -> 0 (Underflow)\n }\n\n // x = k/N + r with r in [-1/(2N), 1/(2N)] and int k.\n var kd = xd + shift;\n var ki = reinterpret(kd);\n var r = xd - (kd - shift);\n var t: u64, y: f64, s: f64;\n\n // exp2(x) = 2^(k/N) * 2^r ~= s * (C0*r^3 + C1*r^2 + C2*r + 1)\n t = load(EXP2F_DATA_TAB + ((ki & N_MASK) << alignof()));\n t += ki << (52 - EXP2F_TABLE_BITS);\n s = reinterpret(t);\n y = C2 * r + 1;\n y += (C0 * r + C1) * (r * r);\n y *= s;\n\n return y;\n}\n\n// ULP error: 0.502 (nearest rounding.)\n// Relative error: 1.69 * 2^-34 in [-ln2/64, ln2/64] (before rounding.)\n// Wrong count: 170635 (all nearest rounding wrong results with fma.)\n// @ts-ignore: decorator\n@inline\nexport function expf_lut(x: f32): f32 {\n const\n N = 1 << EXP2F_TABLE_BITS,\n N_MASK = N - 1,\n shift = reinterpret(0x4338000000000000), // 0x1.8p+52\n InvLn2N = reinterpret(0x3FF71547652B82FE) * N, // 0x1.71547652b82fep+0\n Ox1p127f = reinterpret(0x7F000000);\n\n const\n C0 = reinterpret(0x3FAC6AF84B912394) / N / N / N, // 0x1.c6af84b912394p-5\n C1 = reinterpret(0x3FCEBFCE50FAC4F3) / N / N, // 0x1.ebfce50fac4f3p-3\n C2 = reinterpret(0x3FE62E42FF0C52D6) / N; // 0x1.62e42ff0c52d6p-1\n\n var xd = x;\n var ix = reinterpret(x);\n var ux = ix >> 20 & 0x7FF;\n if (ux >= 0x42B) {\n // |x| >= 88 or x is nan.\n if (ix == 0xFF800000) return 0; // x == -Inf -> 0\n if (ux >= 0x7F8) return x + x; // x == Inf/NaN -> Inf/NaN\n if (x > reinterpret(0x42B17217)) return x * Ox1p127f; // x > log(0x1p128) ~= 88.72 -> HugeVal (Owerflow)\n if (x < reinterpret(0xC2CFF1B4)) return 0; // x < log(0x1p-150) ~= -103.97 -> 0 (Underflow)\n }\n\n // x*N/Ln2 = k + r with r in [-1/2, 1/2] and int k.\n var z = InvLn2N * xd;\n\n // Round and convert z to int, the result is in [-150*N, 128*N] and\n // ideally ties-to-even rule is used, otherwise the magnitude of r\n // can be bigger which gives larger approximation error.\n var kd = (z + shift);\n var ki = reinterpret(kd);\n var r = z - (kd - shift);\n var s: f64, y: f64, t: u64;\n\n // exp(x) = 2^(k/N) * 2^(r/N) ~= s * (C0*r^3 + C1*r^2 + C2*r + 1)\n t = load(EXP2F_DATA_TAB + ((ki & N_MASK) << alignof()));\n t += ki << (52 - EXP2F_TABLE_BITS);\n s = reinterpret(t);\n z = C0 * r + C1;\n y = C2 * r + 1;\n y += z * (r * r);\n y *= s;\n\n return y;\n}\n\n//\n// Lookup data for log2f\n//\n\n// @ts-ignore: decorator\n@inline const LOG2F_TABLE_BITS = 4;\n\n// @ts-ignore: decorator\n@lazy @inline const LOG2F_DATA_TAB = memory.data([\n reinterpret(0x3FF661EC79F8F3BE), reinterpret(0xBFDEFEC65B963019), // 0x1.661ec79f8f3bep+0, -0x1.efec65b963019p-2,\n reinterpret(0x3FF571ED4AAF883D), reinterpret(0xBFDB0B6832D4FCA4), // 0x1.571ed4aaf883dp+0, -0x1.b0b6832d4fca4p-2,\n reinterpret(0x3FF49539F0F010B0), reinterpret(0xBFD7418B0A1FB77B), // 0x1.49539f0f010bp+0 , -0x1.7418b0a1fb77bp-2,\n reinterpret(0x3FF3C995B0B80385), reinterpret(0xBFD39DE91A6DCF7B), // 0x1.3c995b0b80385p+0, -0x1.39de91a6dcf7bp-2,\n reinterpret(0x3FF30D190C8864A5), reinterpret(0xBFD01D9BF3F2B631), // 0x1.30d190c8864a5p+0, -0x1.01d9bf3f2b631p-2,\n reinterpret(0x3FF25E227B0B8EA0), reinterpret(0xBFC97C1D1B3B7AF0), // 0x1.25e227b0b8eap+0 , -0x1.97c1d1b3b7afp-3 ,\n reinterpret(0x3FF1BB4A4A1A343F), reinterpret(0xBFC2F9E393AF3C9F), // 0x1.1bb4a4a1a343fp+0, -0x1.2f9e393af3c9fp-3,\n reinterpret(0x3FF12358F08AE5BA), reinterpret(0xBFB960CBBF788D5C), // 0x1.12358f08ae5bap+0, -0x1.960cbbf788d5cp-4,\n reinterpret(0x3FF0953F419900A7), reinterpret(0xBFAA6F9DB6475FCE), // 0x1.0953f419900a7p+0, -0x1.a6f9db6475fcep-5,\n reinterpret(0x3FF0000000000000), 0, // 0x1p+0, 0x0,\n reinterpret(0x3FEE608CFD9A47AC), reinterpret(0x3FB338CA9F24F53D), // 0x1.e608cfd9a47acp-1, 0x1.338ca9f24f53dp-4,\n reinterpret(0x3FECA4B31F026AA0), reinterpret(0x3FC476A9543891BA), // 0x1.ca4b31f026aap-1 , 0x1.476a9543891bap-3,\n reinterpret(0x3FEB2036576AFCE6), reinterpret(0x3FCE840B4AC4E4D2), // 0x1.b2036576afce6p-1, 0x1.e840b4ac4e4d2p-3,\n reinterpret(0x3FE9C2D163A1AA2D), reinterpret(0x3FD40645F0C6651C), // 0x1.9c2d163a1aa2dp-1, 0x1.40645f0c6651cp-2,\n reinterpret(0x3FE886E6037841ED), reinterpret(0x3FD88E9C2C1B9FF8), // 0x1.886e6037841edp-1, 0x1.88e9c2c1b9ff8p-2,\n reinterpret(0x3FE767DCF5534862), reinterpret(0x3FDCE0A44EB17BCC) // 0x1.767dcf5534862p-1, 0x1.ce0a44eb17bccp-2\n]);\n\n// ULP error: 0.752 (nearest rounding.)\n// Relative error: 1.9 * 2^-26 (before rounding.)\n// @ts-ignore: decorator\n@inline\nexport function log2f_lut(x: f32): f32 {\n const\n N_MASK = (1 << LOG2F_TABLE_BITS) - 1,\n Ox1p23f = reinterpret(0x4B000000); // 0x1p23f\n\n const\n A0 = reinterpret(0xBFD712B6F70A7E4D), // -0x1.712b6f70a7e4dp-2\n A1 = reinterpret(0x3FDECABF496832E0), // 0x1.ecabf496832ep-2\n A2 = reinterpret(0xBFE715479FFAE3DE), // -0x1.715479ffae3dep-1\n A3 = reinterpret(0x3FF715475F35C8B8); // 0x1.715475f35c8b8p0\n\n var ux = reinterpret(x);\n // Fix sign of zero with downward rounding when x==1.\n // if (WANT_ROUNDING && predict_false(ix == 0x3f800000)) return 0;\n if (ux - 0x00800000 >= 0x7F800000 - 0x00800000) {\n // x < 0x1p-126 or inf or nan.\n if (ux * 2 == 0) return -Infinity;\n if (ux == 0x7F800000) return x; // log2(inf) == inf.\n if ((ux >> 31) || ux * 2 >= 0xFF000000) return (x - x) / (x - x);\n // x is subnormal, normalize it.\n ux = reinterpret(x * Ox1p23f);\n ux -= 23 << 23;\n }\n // x = 2^k z; where z is in range [OFF,2*OFF] and exact.\n // The range is split into N subintervals.\n // The ith subinterval contains z and c is near its center.\n var tmp = ux - 0x3F330000;\n var i = (tmp >> (23 - LOG2F_TABLE_BITS)) & N_MASK;\n var top = tmp & 0xFF800000;\n var iz = ux - top;\n var k = tmp >> 23;\n\n var invc = load(LOG2F_DATA_TAB + (i << (1 + alignof())), 0 << alignof());\n var logc = load(LOG2F_DATA_TAB + (i << (1 + alignof())), 1 << alignof());\n var z = reinterpret(iz);\n\n // log2(x) = log1p(z/c-1)/ln2 + log2(c) + k\n var r = z * invc - 1;\n var y0 = logc + k;\n\n // Pipelined polynomial evaluation to approximate log1p(r)/ln2.\n var y = A1 * r + A2;\n var p = A3 * r + y0;\n var r2 = r * r;\n y += A0 * r2;\n y = y * r2 + p;\n\n return y;\n}\n\n//\n// Lookup data for logf. See: https://git.musl-libc.org/cgit/musl/tree/src/math/logf.c\n//\n\n// @ts-ignore: decorator\n@inline const LOGF_TABLE_BITS = 4;\n\n// @ts-ignore: decorator\n@lazy @inline const LOGF_DATA_TAB = memory.data([\n reinterpret(0x3FF661EC79F8F3BE), reinterpret(0xBFD57BF7808CAADE), // 0x1.661ec79f8f3bep+0, -0x1.57bf7808caadep-2,\n reinterpret(0x3FF571ED4AAF883D), reinterpret(0xBFD2BEF0A7C06DDB), // 0x1.571ed4aaf883dp+0, -0x1.2bef0a7c06ddbp-2,\n reinterpret(0x3FF49539F0F010B0), reinterpret(0xBFD01EAE7F513A67), // 0x1.49539f0f010bp+0 , -0x1.01eae7f513a67p-2,\n reinterpret(0x3FF3C995B0B80385), reinterpret(0xBFCB31D8A68224E9), // 0x1.3c995b0b80385p+0, -0x1.b31d8a68224e9p-3,\n reinterpret(0x3FF30D190C8864A5), reinterpret(0xBFC6574F0AC07758), // 0x1.30d190c8864a5p+0, -0x1.6574f0ac07758p-3,\n reinterpret(0x3FF25E227B0B8EA0), reinterpret(0xBFC1AA2BC79C8100), // 0x1.25e227b0b8eap+0 , -0x1.1aa2bc79c81p-3 ,\n reinterpret(0x3FF1BB4A4A1A343F), reinterpret(0xBFBA4E76CE8C0E5E), // 0x1.1bb4a4a1a343fp+0, -0x1.a4e76ce8c0e5ep-4,\n reinterpret(0x3FF12358F08AE5BA), reinterpret(0xBFB1973C5A611CCC), // 0x1.12358f08ae5bap+0, -0x1.1973c5a611cccp-4,\n reinterpret(0x3FF0953F419900A7), reinterpret(0xBFA252F438E10C1E), // 0x1.0953f419900a7p+0, -0x1.252f438e10c1ep-5,\n reinterpret(0x3FF0000000000000), 0, // 0x1p+0, 0,\n reinterpret(0x3FEE608CFD9A47AC), reinterpret(0x3FAAA5AA5DF25984), // 0x1.e608cfd9a47acp-1, 0x1.aa5aa5df25984p-5,\n reinterpret(0x3FECA4B31F026AA0), reinterpret(0x3FBC5E53AA362EB4), // 0x1.ca4b31f026aap-1 , 0x1.c5e53aa362eb4p-4,\n reinterpret(0x3FEB2036576AFCE6), reinterpret(0x3FC526E57720DB08), // 0x1.b2036576afce6p-1, 0x1.526e57720db08p-3,\n reinterpret(0x3FE9C2D163A1AA2D), reinterpret(0x3FCBC2860D224770), // 0x1.9c2d163a1aa2dp-1, 0x1.bc2860d22477p-3 ,\n reinterpret(0x3FE886E6037841ED), reinterpret(0x3FD1058BC8A07EE1), // 0x1.886e6037841edp-1, 0x1.1058bc8a07ee1p-2,\n reinterpret(0x3FE767DCF5534862), reinterpret(0x3FD4043057B6EE09) // 0x1.767dcf5534862p-1, 0x1.4043057b6ee09p-2\n]);\n\n// ULP error: 0.818 (nearest rounding.)\n// Relative error: 1.957 * 2^-26 (before rounding.)\n// @ts-ignore: decorator\n@inline\nexport function logf_lut(x: f32): f32 {\n const\n N_MASK = (1 << LOGF_TABLE_BITS) - 1,\n Ox1p23f = reinterpret(0x4B000000); // 0x1p23f\n\n const\n Ln2 = reinterpret(0x3FE62E42FEFA39EF), // 0x1.62e42fefa39efp-1;\n A0 = reinterpret(0xBFD00EA348B88334), // -0x1.00ea348b88334p-2\n A1 = reinterpret(0x3FD5575B0BE00B6A), // 0x1.5575b0be00b6ap-2\n A2 = reinterpret(0xBFDFFFFEF20A4123); // -0x1.ffffef20a4123p-2\n\n var ux = reinterpret(x);\n // Fix sign of zero with downward rounding when x==1.\n // if (WANT_ROUNDING && ux == 0x3f800000) return 0;\n if (ux - 0x00800000 >= 0x7F800000 - 0x00800000) {\n // x < 0x1p-126 or inf or nan.\n if ((ux << 1) == 0) return -Infinity;\n if (ux == 0x7F800000) return x; // log(inf) == inf.\n if ((ux >> 31) || (ux << 1) >= 0xFF000000) return (x - x) / (x - x);\n // x is subnormal, normalize it.\n ux = reinterpret(x * Ox1p23f);\n ux -= 23 << 23;\n }\n // x = 2^k z; where z is in range [OFF,2*OFF] and exact.\n // The range is split into N subintervals.\n // The ith subinterval contains z and c is near its center.\n var tmp = ux - 0x3F330000;\n var i = (tmp >> (23 - LOGF_TABLE_BITS)) & N_MASK;\n var k = tmp >> 23;\n var iz = ux - (tmp & 0x1FF << 23);\n\n var invc = load(LOGF_DATA_TAB + (i << (1 + alignof())), 0 << alignof());\n var logc = load(LOGF_DATA_TAB + (i << (1 + alignof())), 1 << alignof());\n\n var z = reinterpret(iz);\n\n // log(x) = log1p(z/c-1) + log(c) + k*Ln2\n var r = z * invc - 1;\n var y0 = logc + k * Ln2;\n\n // Pipelined polynomial evaluation to approximate log1p(r).\n var r2 = r * r;\n var y = A1 * r + A2;\n y += A0 * r2;\n y = y * r2 + (y0 + r);\n\n return y;\n}\n\n//\n// Lookup data for powf. See: https://git.musl-libc.org/cgit/musl/tree/src/math/powf.c\n//\n\n// @ts-ignore: decorator\n@inline\nfunction zeroinfnanf(ux: u32): bool {\n return (ux << 1) - 1 >= (0x7f800000 << 1) - 1;\n}\n\n// Returns 0 if not int, 1 if odd int, 2 if even int. The argument is\n// the bit representation of a non-zero finite floating-point value.\n// @ts-ignore: decorator\n@inline\nfunction checkintf(iy: u32): i32 {\n var e = iy >> 23 & 0xFF;\n if (e < 0x7F ) return 0;\n if (e > 0x7F + 23) return 2;\n e = 1 << (0x7F + 23 - e);\n if (iy & (e - 1)) return 0;\n if (iy & e ) return 1;\n return 2;\n}\n\n// Subnormal input is normalized so ix has negative biased exponent.\n// Output is multiplied by N (POWF_SCALE) if TOINT_INTRINICS is set.\n// @ts-ignore: decorator\n@inline\nfunction log2f_inline(ux: u32): f64 {\n const N_MASK = (1 << LOG2F_TABLE_BITS) - 1;\n\n const\n A0 = reinterpret(0x3FD27616C9496E0B), // 0x1.27616c9496e0bp-2\n A1 = reinterpret(0xBFD71969A075C67A), // -0x1.71969a075c67ap-2\n A2 = reinterpret(0x3FDEC70A6CA7BADD), // 0x1.ec70a6ca7baddp-2\n A3 = reinterpret(0xBFE7154748BEF6C8), // -0x1.7154748bef6c8p-1\n A4 = reinterpret(0x3FF71547652AB82B); // 0x1.71547652ab82bp+0\n\n // x = 2^k z; where z is in range [OFF,2*OFF] and exact.\n // The range is split into N subintervals.\n // The ith subinterval contains z and c is near its center.\n var tmp = ux - 0x3F330000;\n var i = usize((tmp >> (23 - LOG2F_TABLE_BITS)) & N_MASK);\n var top = tmp & 0xFF800000;\n var uz = ux - top;\n var k = top >> 23;\n\n var invc = load(LOG2F_DATA_TAB + (i << (1 + alignof())), 0 << alignof());\n var logc = load(LOG2F_DATA_TAB + (i << (1 + alignof())), 1 << alignof());\n var z = reinterpret(uz);\n\n // log2(x) = log1p(z/c-1)/ln2 + log2(c) + k\n var r = z * invc - 1;\n var y0 = logc + k;\n\n // Pipelined polynomial evaluation to approximate log1p(r)/ln2.\n var y = A0 * r + A1;\n var p = A2 * r + A3;\n var q = A4 * r + y0;\n\n r *= r;\n q += p * r;\n y = y * (r * r) + q;\n\n return y;\n}\n\n// The output of log2 and thus the input of exp2 is either scaled by N\n// (in case of fast toint intrinsics) or not. The unscaled xd must be\n// in [-1021,1023], sign_bias sets the sign of the result.\n// @ts-ignore: decorator\n@inline\nfunction exp2f_inline(xd: f64, signBias: u32): f32 {\n const\n N = 1 << EXP2F_TABLE_BITS,\n N_MASK = N - 1,\n shift = reinterpret(0x4338000000000000) / N; // 0x1.8p+52\n\n const\n C0 = reinterpret(0x3FAC6AF84B912394), // 0x1.c6af84b912394p-5\n C1 = reinterpret(0x3FCEBFCE50FAC4F3), // 0x1.ebfce50fac4f3p-3\n C2 = reinterpret(0x3FE62E42FF0C52D6); // 0x1.62e42ff0c52d6p-1\n\n // x = k/N + r with r in [-1/(2N), 1/(2N)]\n var kd = (xd + shift);\n var ki = reinterpret(kd);\n var r = xd - (kd - shift);\n var t: u64, z: f64, y: f64, s: f64;\n\n // exp2(x) = 2^(k/N) * 2^r ~= s * (C0*r^3 + C1*r^2 + C2*r + 1)\n t = load(EXP2F_DATA_TAB + ((ki & N_MASK) << alignof()));\n t += (ki + signBias) << (52 - EXP2F_TABLE_BITS);\n s = reinterpret(t);\n z = C0 * r + C1;\n y = C2 * r + 1;\n y += z * (r * r);\n y *= s;\n return y;\n}\n\n// @ts-ignore: decorator\n@inline\nfunction xflowf(sign: u32, y: f32): f32 {\n return select(-y, y, sign) * y;\n}\n\n// @ts-ignore: decorator\n@inline\nfunction oflowf(sign: u32): f32 {\n return xflowf(sign, reinterpret(0x70000000)); // 0x1p97f\n}\n\n// @ts-ignore: decorator\n@inline\nfunction uflowf(sign: u32): f32 {\n return xflowf(sign, reinterpret(0x10000000)); // 0x1p-95f\n}\n\n// @ts-ignore: decorator\n@inline\nexport function powf_lut(x: f32, y: f32): f32 {\n const\n Ox1p23f = reinterpret(0x4B000000), // 0x1p23f\n UPPER_LIMIT = reinterpret(0x405FFFFFFFD1D571), // 0x1.fffffffd1d571p+6\n LOWER_LIMIT = -150.0,\n SIGN_BIAS = 1 << (EXP2F_TABLE_BITS + 11);\n\n var signBias: u32 = 0;\n var ix = reinterpret(x);\n var iy = reinterpret(y);\n var ny = 0;\n\n if (i32(ix - 0x00800000 >= 0x7f800000 - 0x00800000) | (ny = i32(zeroinfnanf(iy)))) {\n // Either (x < 0x1p-126 or inf or nan) or (y is 0 or inf or nan).\n if (ny) {\n if ((iy << 1) == 0) return 1.0;\n if (ix == 0x3F800000) return NaN; // original: 1.0\n if ((ix << 1) > (0x7F800000 << 1) || (iy << 1) > (0x7F800000 << 1)) return x + y;\n if ((ix << 1) == (0x3F800000 << 1)) return NaN; // original: 1.0\n if (((ix << 1) < (0x3F800000 << 1)) == !(iy >> 31)) return 0; // |x| < 1 && y==inf or |x| > 1 && y==-inf.\n return y * y;\n }\n if (zeroinfnanf(ix)) {\n let x2 = x * x;\n if ((ix >> 31) && checkintf(iy) == 1) x2 = -x2;\n return iy < 0 ? 1 / x2 : x2;\n }\n // x and y are non-zero finite.\n if (ix < 0) {\n // Finite x < 0.\n let yint = checkintf(iy);\n if (yint == 0) return (x - x) / (x - x);\n if (yint == 1) signBias = SIGN_BIAS;\n ix &= 0x7FFFFFFF;\n }\n if (ix < 0x00800000) {\n // Normalize subnormal x so exponent becomes negative.\n ix = reinterpret(x * Ox1p23f);\n ix &= 0x7FFFFFFF;\n ix -= 23 << 23;\n }\n }\n var logx = log2f_inline(ix);\n var ylogx = y * logx; // cannot overflow, y is single prec.\n if ((reinterpret(ylogx) >> 47 & 0xFFFF) >= 0x80BF) { // reinterpret(126.0) >> 47\n // |y * log(x)| >= 126\n if (ylogx > UPPER_LIMIT) return oflowf(signBias); // overflow\n if (ylogx <= LOWER_LIMIT) return uflowf(signBias); // underflow\n }\n return exp2f_inline(ylogx, signBias);\n}\n\n//\n// Lookup data for exp. See: https://git.musl-libc.org/cgit/musl/tree/src/math/exp.c\n//\n\n// @ts-ignore: decorator\n@inline const EXP_TABLE_BITS = 7;\n\n// @ts-ignore: decorator\n@lazy @inline const EXP_DATA_TAB = memory.data([\n 0x0000000000000000, 0x3FF0000000000000,\n 0x3C9B3B4F1A88BF6E, 0x3FEFF63DA9FB3335,\n 0xBC7160139CD8DC5D, 0x3FEFEC9A3E778061,\n 0xBC905E7A108766D1, 0x3FEFE315E86E7F85,\n 0x3C8CD2523567F613, 0x3FEFD9B0D3158574,\n 0xBC8BCE8023F98EFA, 0x3FEFD06B29DDF6DE,\n 0x3C60F74E61E6C861, 0x3FEFC74518759BC8,\n 0x3C90A3E45B33D399, 0x3FEFBE3ECAC6F383,\n 0x3C979AA65D837B6D, 0x3FEFB5586CF9890F,\n 0x3C8EB51A92FDEFFC, 0x3FEFAC922B7247F7,\n 0x3C3EBE3D702F9CD1, 0x3FEFA3EC32D3D1A2,\n 0xBC6A033489906E0B, 0x3FEF9B66AFFED31B,\n 0xBC9556522A2FBD0E, 0x3FEF9301D0125B51,\n 0xBC5080EF8C4EEA55, 0x3FEF8ABDC06C31CC,\n 0xBC91C923B9D5F416, 0x3FEF829AAEA92DE0,\n 0x3C80D3E3E95C55AF, 0x3FEF7A98C8A58E51,\n 0xBC801B15EAA59348, 0x3FEF72B83C7D517B,\n 0xBC8F1FF055DE323D, 0x3FEF6AF9388C8DEA,\n 0x3C8B898C3F1353BF, 0x3FEF635BEB6FCB75,\n 0xBC96D99C7611EB26, 0x3FEF5BE084045CD4,\n 0x3C9AECF73E3A2F60, 0x3FEF54873168B9AA,\n 0xBC8FE782CB86389D, 0x3FEF4D5022FCD91D,\n 0x3C8A6F4144A6C38D, 0x3FEF463B88628CD6,\n 0x3C807A05B0E4047D, 0x3FEF3F49917DDC96,\n 0x3C968EFDE3A8A894, 0x3FEF387A6E756238,\n 0x3C875E18F274487D, 0x3FEF31CE4FB2A63F,\n 0x3C80472B981FE7F2, 0x3FEF2B4565E27CDD,\n 0xBC96B87B3F71085E, 0x3FEF24DFE1F56381,\n 0x3C82F7E16D09AB31, 0x3FEF1E9DF51FDEE1,\n 0xBC3D219B1A6FBFFA, 0x3FEF187FD0DAD990,\n 0x3C8B3782720C0AB4, 0x3FEF1285A6E4030B,\n 0x3C6E149289CECB8F, 0x3FEF0CAFA93E2F56,\n 0x3C834D754DB0ABB6, 0x3FEF06FE0A31B715,\n 0x3C864201E2AC744C, 0x3FEF0170FC4CD831,\n 0x3C8FDD395DD3F84A, 0x3FEEFC08B26416FF,\n 0xBC86A3803B8E5B04, 0x3FEEF6C55F929FF1,\n 0xBC924AEDCC4B5068, 0x3FEEF1A7373AA9CB,\n 0xBC9907F81B512D8E, 0x3FEEECAE6D05D866,\n 0xBC71D1E83E9436D2, 0x3FEEE7DB34E59FF7,\n 0xBC991919B3CE1B15, 0x3FEEE32DC313A8E5,\n 0x3C859F48A72A4C6D, 0x3FEEDEA64C123422,\n 0xBC9312607A28698A, 0x3FEEDA4504AC801C,\n 0xBC58A78F4817895B, 0x3FEED60A21F72E2A,\n 0xBC7C2C9B67499A1B, 0x3FEED1F5D950A897,\n 0x3C4363ED60C2AC11, 0x3FEECE086061892D,\n 0x3C9666093B0664EF, 0x3FEECA41ED1D0057,\n 0x3C6ECCE1DAA10379, 0x3FEEC6A2B5C13CD0,\n 0x3C93FF8E3F0F1230, 0x3FEEC32AF0D7D3DE,\n 0x3C7690CEBB7AAFB0, 0x3FEEBFDAD5362A27,\n 0x3C931DBDEB54E077, 0x3FEEBCB299FDDD0D,\n 0xBC8F94340071A38E, 0x3FEEB9B2769D2CA7,\n 0xBC87DECCDC93A349, 0x3FEEB6DAA2CF6642,\n 0xBC78DEC6BD0F385F, 0x3FEEB42B569D4F82,\n 0xBC861246EC7B5CF6, 0x3FEEB1A4CA5D920F,\n 0x3C93350518FDD78E, 0x3FEEAF4736B527DA,\n 0x3C7B98B72F8A9B05, 0x3FEEAD12D497C7FD,\n 0x3C9063E1E21C5409, 0x3FEEAB07DD485429,\n 0x3C34C7855019C6EA, 0x3FEEA9268A5946B7,\n 0x3C9432E62B64C035, 0x3FEEA76F15AD2148,\n 0xBC8CE44A6199769F, 0x3FEEA5E1B976DC09,\n 0xBC8C33C53BEF4DA8, 0x3FEEA47EB03A5585,\n 0xBC845378892BE9AE, 0x3FEEA34634CCC320,\n 0xBC93CEDD78565858, 0x3FEEA23882552225,\n 0x3C5710AA807E1964, 0x3FEEA155D44CA973,\n 0xBC93B3EFBF5E2228, 0x3FEEA09E667F3BCD,\n 0xBC6A12AD8734B982, 0x3FEEA012750BDABF,\n 0xBC6367EFB86DA9EE, 0x3FEE9FB23C651A2F,\n 0xBC80DC3D54E08851, 0x3FEE9F7DF9519484,\n 0xBC781F647E5A3ECF, 0x3FEE9F75E8EC5F74,\n 0xBC86EE4AC08B7DB0, 0x3FEE9F9A48A58174,\n 0xBC8619321E55E68A, 0x3FEE9FEB564267C9,\n 0x3C909CCB5E09D4D3, 0x3FEEA0694FDE5D3F,\n 0xBC7B32DCB94DA51D, 0x3FEEA11473EB0187,\n 0x3C94ECFD5467C06B, 0x3FEEA1ED0130C132,\n 0x3C65EBE1ABD66C55, 0x3FEEA2F336CF4E62,\n 0xBC88A1C52FB3CF42, 0x3FEEA427543E1A12,\n 0xBC9369B6F13B3734, 0x3FEEA589994CCE13,\n 0xBC805E843A19FF1E, 0x3FEEA71A4623C7AD,\n 0xBC94D450D872576E, 0x3FEEA8D99B4492ED,\n 0x3C90AD675B0E8A00, 0x3FEEAAC7D98A6699,\n 0x3C8DB72FC1F0EAB4, 0x3FEEACE5422AA0DB,\n 0xBC65B6609CC5E7FF, 0x3FEEAF3216B5448C,\n 0x3C7BF68359F35F44, 0x3FEEB1AE99157736,\n 0xBC93091FA71E3D83, 0x3FEEB45B0B91FFC6,\n 0xBC5DA9B88B6C1E29, 0x3FEEB737B0CDC5E5,\n 0xBC6C23F97C90B959, 0x3FEEBA44CBC8520F,\n 0xBC92434322F4F9AA, 0x3FEEBD829FDE4E50,\n 0xBC85CA6CD7668E4B, 0x3FEEC0F170CA07BA,\n 0x3C71AFFC2B91CE27, 0x3FEEC49182A3F090,\n 0x3C6DD235E10A73BB, 0x3FEEC86319E32323,\n 0xBC87C50422622263, 0x3FEECC667B5DE565,\n 0x3C8B1C86E3E231D5, 0x3FEED09BEC4A2D33,\n 0xBC91BBD1D3BCBB15, 0x3FEED503B23E255D,\n 0x3C90CC319CEE31D2, 0x3FEED99E1330B358,\n 0x3C8469846E735AB3, 0x3FEEDE6B5579FDBF,\n 0xBC82DFCD978E9DB4, 0x3FEEE36BBFD3F37A,\n 0x3C8C1A7792CB3387, 0x3FEEE89F995AD3AD,\n 0xBC907B8F4AD1D9FA, 0x3FEEEE07298DB666,\n 0xBC55C3D956DCAEBA, 0x3FEEF3A2B84F15FB,\n 0xBC90A40E3DA6F640, 0x3FEEF9728DE5593A,\n 0xBC68D6F438AD9334, 0x3FEEFF76F2FB5E47,\n 0xBC91EEE26B588A35, 0x3FEF05B030A1064A,\n 0x3C74FFD70A5FDDCD, 0x3FEF0C1E904BC1D2,\n 0xBC91BDFBFA9298AC, 0x3FEF12C25BD71E09,\n 0x3C736EAE30AF0CB3, 0x3FEF199BDD85529C,\n 0x3C8EE3325C9FFD94, 0x3FEF20AB5FFFD07A,\n 0x3C84E08FD10959AC, 0x3FEF27F12E57D14B,\n 0x3C63CDAF384E1A67, 0x3FEF2F6D9406E7B5,\n 0x3C676B2C6C921968, 0x3FEF3720DCEF9069,\n 0xBC808A1883CCB5D2, 0x3FEF3F0B555DC3FA,\n 0xBC8FAD5D3FFFFA6F, 0x3FEF472D4A07897C,\n 0xBC900DAE3875A949, 0x3FEF4F87080D89F2,\n 0x3C74A385A63D07A7, 0x3FEF5818DCFBA487,\n 0xBC82919E2040220F, 0x3FEF60E316C98398,\n 0x3C8E5A50D5C192AC, 0x3FEF69E603DB3285,\n 0x3C843A59AC016B4B, 0x3FEF7321F301B460,\n 0xBC82D52107B43E1F, 0x3FEF7C97337B9B5F,\n 0xBC892AB93B470DC9, 0x3FEF864614F5A129,\n 0x3C74B604603A88D3, 0x3FEF902EE78B3FF6,\n 0x3C83C5EC519D7271, 0x3FEF9A51FBC74C83,\n 0xBC8FF7128FD391F0, 0x3FEFA4AFA2A490DA,\n 0xBC8DAE98E223747D, 0x3FEFAF482D8E67F1,\n 0x3C8EC3BC41AA2008, 0x3FEFBA1BEE615A27,\n 0x3C842B94C3A9EB32, 0x3FEFC52B376BBA97,\n 0x3C8A64A931D185EE, 0x3FEFD0765B6E4540,\n 0xBC8E37BAE43BE3ED, 0x3FEFDBFDAD9CBE14,\n 0x3C77893B4D91CD9D, 0x3FEFE7C1819E90D8,\n 0x3C5305C14160CC89, 0x3FEFF3C22B8F71F1\n]);\n\n// Handle cases that may overflow or underflow when computing the result that\n// is scale*(1+TMP) without intermediate rounding. The bit representation of\n// scale is in SBITS, however it has a computed exponent that may have\n// overflown into the sign bit so that needs to be adjusted before using it as\n// a double. (int32_t)KI is the k used in the argument reduction and exponent\n// adjustment of scale, positive k here means the result may overflow and\n// negative k means the result may underflow.\n// @ts-ignore: decorator\n@inline\nfunction specialcase(tmp: f64, sbits: u64, ki: u64): f64 {\n const\n Ox1p_1022 = reinterpret(0x0010000000000000), // 0x1p-1022\n Ox1p1009 = reinterpret(0x7F00000000000000); // 0x1p1009\n\n var scale: f64;\n if (!(ki & 0x80000000)) {\n // k > 0, the exponent of scale might have overflowed by <= 460.\n sbits -= u64(1009) << 52;\n scale = reinterpret(sbits);\n return Ox1p1009 * (scale + scale * tmp); // 0x1p1009\n }\n // k < 0, need special care in the subnormal range.\n sbits += u64(1022) << 52;\n // Note: sbits is signed scale.\n scale = reinterpret(sbits);\n var y = scale + scale * tmp;\n if (abs(y) < 1.0) {\n // Round y to the right precision before scaling it into the subnormal\n // range to avoid double rounding that can cause 0.5+E/2 ulp error where\n // E is the worst-case ulp error outside the subnormal range. So this\n // is only useful if the goal is better than 1 ulp worst-case error.\n let one = copysign(1.0, y);\n let lo = scale - y + scale * tmp;\n let hi = one + y;\n lo = one - hi + y + lo;\n y = (hi + lo) - one;\n // Fix the sign of 0.\n if (y == 0.0) y = reinterpret(sbits & 0x8000000000000000);\n }\n return y * Ox1p_1022;\n}\n\n// @ts-ignore: decorator\n@inline\nexport function exp_lut(x: f64): f64 {\n const\n N = 1 << EXP_TABLE_BITS,\n N_MASK = N - 1;\n\n const\n InvLn2N = reinterpret(0x3FF71547652B82FE) * N, // 0x1.71547652b82fep0\n NegLn2hiN = reinterpret(0xBF762E42FEFA0000), // -0x1.62e42fefa0000p-8\n NegLn2loN = reinterpret(0xBD0CF79ABC9E3B3A), // -0x1.cf79abc9e3b3ap-47\n shift = reinterpret(0x4338000000000000); // 0x1.8p52;\n\n const\n C2 = reinterpret(0x3FDFFFFFFFFFFDBD), // __exp_data.poly[0] (0x1.ffffffffffdbdp-2)\n C3 = reinterpret(0x3FC555555555543C), // __exp_data.poly[1] (0x1.555555555543cp-3)\n C4 = reinterpret(0x3FA55555CF172B91), // __exp_data.poly[2] (0x1.55555cf172b91p-5)\n C5 = reinterpret(0x3F81111167A4D017); // __exp_data.poly[3] (0x1.1111167a4d017p-7)\n\n var ux = reinterpret(x);\n var abstop = u32(ux >> 52) & 0x7FF;\n if (abstop - 0x3C9 >= 0x03F) {\n if (abstop - 0x3C9 >= 0x80000000) return 1;\n if (abstop >= 0x409) {\n if (ux == 0xFFF0000000000000) return 0;\n if (abstop >= 0x7FF) {\n return 1.0 + x;\n } else {\n return select(0, Infinity, ux < 0);\n }\n }\n // Large x is special cased below.\n abstop = 0;\n }\n\n // exp(x) = 2^(k/N) * exp(r), with exp(r) in [2^(-1/2N),2^(1/2N)]\n // x = ln2/N*k + r, with int k and r in [-ln2/2N, ln2/2N]\n var z = InvLn2N * x;\n // #if TOINT_INTRINSICS\n // \tkd = roundtoint(z);\n // \tki = converttoint(z);\n // #elif EXP_USE_TOINT_NARROW\n // \t// z - kd is in [-0.5-2^-16, 0.5] in all rounding modes.\n // var kd = z + shift;\n // var ki = reinterpret(kd) >> 16;\n // var kd = ki;\n // #else\n // z - kd is in [-1, 1] in non-nearest rounding modes.\n var kd = z + shift;\n var ki = reinterpret(kd);\n kd -= shift;\n // #endif\n var r = x + kd * NegLn2hiN + kd * NegLn2loN;\n // 2^(k/N) ~= scale * (1 + tail).\n var idx = usize((ki & N_MASK) << 1);\n var top = ki << (52 - EXP_TABLE_BITS);\n\n var tail = reinterpret(load(EXP_DATA_TAB + (idx << alignof()))); // T[idx]\n // This is only a valid scale when -1023*N < k < 1024*N\n var sbits = load(EXP_DATA_TAB + (idx << alignof()), 1 << alignof()) + top; // T[idx + 1]\n // exp(x) = 2^(k/N) * exp(r) ~= scale + scale * (tail + exp(r) - 1).\n // Evaluation is optimized assuming superscalar pipelined execution.\n var r2 = r * r;\n // Without fma the worst case error is 0.25/N ulp larger.\n // Worst case error is less than 0.5+1.11/N+(abs poly error * 2^53) ulp.\n var tmp = tail + r + r2 * (C2 + r * C3) + r2 * r2 * (C4 + r * C5);\n if (abstop == 0) return specialcase(tmp, sbits, ki);\n var scale = reinterpret(sbits);\n // Note: tmp == 0 or |tmp| > 2^-200 and scale > 2^-739, so there\n // is no spurious underflow here even without fma.\n return scale + scale * tmp;\n}\n\n//\n// Lookup data for exp2. See: https://git.musl-libc.org/cgit/musl/tree/src/math/exp2.c\n//\n\n// Handle cases that may overflow or underflow when computing the result that\n// is scale*(1+TMP) without intermediate rounding. The bit representation of\n// scale is in SBITS, however it has a computed exponent that may have\n// overflown into the sign bit so that needs to be adjusted before using it as\n// a double. (int32_t)KI is the k used in the argument reduction and exponent\n// adjustment of scale, positive k here means the result may overflow and\n// negative k means the result may underflow.\n// @ts-ignore: decorator\n@inline\nfunction specialcase2(tmp: f64, sbits: u64, ki: u64): f64 {\n const Ox1p_1022 = reinterpret(0x10000000000000); // 0x1p-1022\n var scale: f64;\n if ((ki & 0x80000000) == 0) {\n // k > 0, the exponent of scale might have overflowed by 1\n sbits -= u64(1) << 52;\n scale = reinterpret(sbits);\n return 2 * (scale * tmp + scale);\n }\n // k < 0, need special care in the subnormal range\n sbits += u64(1022) << 52;\n scale = reinterpret(sbits);\n var y = scale * tmp + scale;\n if (y < 1.0) {\n // Round y to the right precision before scaling it into the subnormal\n // range to avoid double rounding that can cause 0.5+E/2 ulp error where\n // E is the worst-case ulp error outside the subnormal range. So this\n // is only useful if the goal is better than 1 ulp worst-case error.\n let hi: f64, lo: f64;\n lo = scale - y + scale * tmp;\n hi = 1.0 + y;\n lo = 1.0 - hi + y + lo;\n y = (hi + lo) - 1.0;\n }\n return y * Ox1p_1022;\n}\n\n// @ts-ignore: decorator\n@inline\nexport function exp2_lut(x: f64): f64 {\n const\n N = 1 << EXP_TABLE_BITS,\n N_MASK = N - 1,\n shift = reinterpret(0x4338000000000000) / N; // 0x1.8p52\n\n const\n C1 = reinterpret(0x3FE62E42FEFA39EF), // 0x1.62e42fefa39efp-1\n C2 = reinterpret(0x3FCEBFBDFF82C424), // 0x1.ebfbdff82c424p-3\n C3 = reinterpret(0x3FAC6B08D70CF4B5), // 0x1.c6b08d70cf4b5p-5\n C4 = reinterpret(0x3F83B2ABD24650CC), // 0x1.3b2abd24650ccp-7\n C5 = reinterpret(0x3F55D7E09B4E3A84); // 0x1.5d7e09b4e3a84p-10\n\n var ux = reinterpret(x);\n var abstop = u32(ux >> 52) & 0x7ff;\n if (abstop - 0x3C9 >= 0x03F) {\n if (abstop - 0x3C9 >= 0x80000000) return 1.0;\n if (abstop >= 0x409) {\n if (ux == 0xFFF0000000000000) return 0;\n if (abstop >= 0x7FF) return 1.0 + x;\n if (ux >= 0) return Infinity;\n else if (ux >= 0xC090CC0000000000) return 0;\n }\n if ((ux << 1) > 0x811A000000000000) abstop = 0; // Large x is special cased below.\n }\n\n // exp2(x) = 2^(k/N) * 2^r, with 2^r in [2^(-1/2N),2^(1/2N)].\n // x = k/N + r, with int k and r in [-1/2N, 1/2N]\n var kd = x + shift;\n var ki = reinterpret(kd);\n kd -= shift; // k/N for int k\n var r = x - kd;\n // 2^(k/N) ~= scale * (1 + tail)\n var idx = usize((ki & N_MASK) << 1);\n var top = ki << (52 - EXP_TABLE_BITS);\n\n var tail = reinterpret(load(EXP_DATA_TAB + (idx << alignof()), 0 << alignof())); // T[idx])\n // This is only a valid scale when -1023*N < k < 1024*N\n var sbits = load(EXP_DATA_TAB + (idx << alignof()), 1 << alignof()) + top; // T[idx + 1]\n // exp2(x) = 2^(k/N) * 2^r ~= scale + scale * (tail + 2^r - 1).\n // Evaluation is optimized assuming superscalar pipelined execution\n var r2 = r * r;\n // Without fma the worst case error is 0.5/N ulp larger.\n // Worst case error is less than 0.5+0.86/N+(abs poly error * 2^53) ulp.\n var tmp = tail + r * C1 + r2 * (C2 + r * C3) + r2 * r2 * (C4 + r * C5);\n if (abstop == 0) return specialcase2(tmp, sbits, ki);\n var scale = reinterpret(sbits);\n // Note: tmp == 0 or |tmp| > 2^-65 and scale > 2^-928, so there\n // is no spurious underflow here even without fma.\n return scale * tmp + scale;\n}\n\n//\n// Lookup data for log2. See: https://git.musl-libc.org/cgit/musl/tree/src/math/log2.c\n//\n\n// @ts-ignore: decorator\n@inline const LOG2_TABLE_BITS = 6;\n\n/* Algorithm:\n\n x = 2^k z\n log2(x) = k + log2(c) + log2(z/c)\n log2(z/c) = poly(z/c - 1)\n\nwhere z is in [1.6p-1; 1.6p0] which is split into N subintervals and z falls\ninto the ith one, then table entries are computed as\n\n tab[i].invc = 1/c\n tab[i].logc = (double)log2(c)\n tab2[i].chi = (double)c\n tab2[i].clo = (double)(c - (double)c)\n\nwhere c is near the center of the subinterval and is chosen by trying +-2^29\nfloating point invc candidates around 1/center and selecting one for which\n\n 1) the rounding error in 0x1.8p10 + logc is 0,\n 2) the rounding error in z - chi - clo is < 0x1p-64 and\n 3) the rounding error in (double)log2(c) is minimized (< 0x1p-68).\n\nNote: 1) ensures that k + logc can be computed without rounding error, 2)\nensures that z/c - 1 can be computed as (z - chi - clo)*invc with close to a\nsingle rounding error when there is no fast fma for z*invc - 1, 3) ensures\nthat logc + poly(z/c - 1) has small error, however near x == 1 when\n|log2(x)| < 0x1p-4, this is not enough so that is special cased. */\n\n// @ts-ignore: decorator\n@lazy @inline const LOG2_DATA_TAB1 = memory.data([\n // invc , logc\n reinterpret(0x3FF724286BB1ACF8), reinterpret(0xBFE1095FEECDB000),\n reinterpret(0x3FF6E1F766D2CCA1), reinterpret(0xBFE08494BD76D000),\n reinterpret(0x3FF6A13D0E30D48A), reinterpret(0xBFE00143AEE8F800),\n reinterpret(0x3FF661EC32D06C85), reinterpret(0xBFDEFEC5360B4000),\n reinterpret(0x3FF623FA951198F8), reinterpret(0xBFDDFDD91AB7E000),\n reinterpret(0x3FF5E75BA4CF026C), reinterpret(0xBFDCFFAE0CC79000),\n reinterpret(0x3FF5AC055A214FB8), reinterpret(0xBFDC043811FDA000),\n reinterpret(0x3FF571ED0F166E1E), reinterpret(0xBFDB0B67323AE000),\n reinterpret(0x3FF53909590BF835), reinterpret(0xBFDA152F5A2DB000),\n reinterpret(0x3FF5014FED61ADDD), reinterpret(0xBFD9217F5AF86000),\n reinterpret(0x3FF4CAB88E487BD0), reinterpret(0xBFD8304DB0719000),\n reinterpret(0x3FF49539B4334FEE), reinterpret(0xBFD74189F9A9E000),\n reinterpret(0x3FF460CBDFAFD569), reinterpret(0xBFD6552BB5199000),\n reinterpret(0x3FF42D664EE4B953), reinterpret(0xBFD56B23A29B1000),\n reinterpret(0x3FF3FB01111DD8A6), reinterpret(0xBFD483650F5FA000),\n reinterpret(0x3FF3C995B70C5836), reinterpret(0xBFD39DE937F6A000),\n reinterpret(0x3FF3991C4AB6FD4A), reinterpret(0xBFD2BAA1538D6000),\n reinterpret(0x3FF3698E0CE099B5), reinterpret(0xBFD1D98340CA4000),\n reinterpret(0x3FF33AE48213E7B2), reinterpret(0xBFD0FA853A40E000),\n reinterpret(0x3FF30D191985BDB1), reinterpret(0xBFD01D9C32E73000),\n reinterpret(0x3FF2E025CAB271D7), reinterpret(0xBFCE857DA2FA6000),\n reinterpret(0x3FF2B404CF13CD82), reinterpret(0xBFCCD3C8633D8000),\n reinterpret(0x3FF288B02C7CCB50), reinterpret(0xBFCB26034C14A000),\n reinterpret(0x3FF25E2263944DE5), reinterpret(0xBFC97C1C2F4FE000),\n reinterpret(0x3FF234563D8615B1), reinterpret(0xBFC7D6023F800000),\n reinterpret(0x3FF20B46E33EAF38), reinterpret(0xBFC633A71A05E000),\n reinterpret(0x3FF1E2EEFDCDA3DD), reinterpret(0xBFC494F5E9570000),\n reinterpret(0x3FF1BB4A580B3930), reinterpret(0xBFC2F9E424E0A000),\n reinterpret(0x3FF19453847F2200), reinterpret(0xBFC162595AFDC000),\n reinterpret(0x3FF16E06C0D5D73C), reinterpret(0xBFBF9C9A75BD8000),\n reinterpret(0x3FF1485F47B7E4C2), reinterpret(0xBFBC7B575BF9C000),\n reinterpret(0x3FF12358AD0085D1), reinterpret(0xBFB960C60FF48000),\n reinterpret(0x3FF0FEF00F532227), reinterpret(0xBFB64CE247B60000),\n reinterpret(0x3FF0DB2077D03A8F), reinterpret(0xBFB33F78B2014000),\n reinterpret(0x3FF0B7E6D65980D9), reinterpret(0xBFB0387D1A42C000),\n reinterpret(0x3FF0953EFE7B408D), reinterpret(0xBFAA6F9208B50000),\n reinterpret(0x3FF07325CAC53B83), reinterpret(0xBFA47A954F770000),\n reinterpret(0x3FF05197E40D1B5C), reinterpret(0xBF9D23A8C50C0000),\n reinterpret(0x3FF03091C1208EA2), reinterpret(0xBF916A2629780000),\n reinterpret(0x3FF0101025B37E21), reinterpret(0xBF7720F8D8E80000),\n reinterpret(0x3FEFC07EF9CAA76B), reinterpret(0x3F86FE53B1500000),\n reinterpret(0x3FEF4465D3F6F184), reinterpret(0x3FA11CCCE10F8000),\n reinterpret(0x3FEECC079F84107F), reinterpret(0x3FAC4DFC8C8B8000),\n reinterpret(0x3FEE573A99975AE8), reinterpret(0x3FB3AA321E574000),\n reinterpret(0x3FEDE5D6F0BD3DE6), reinterpret(0x3FB918A0D08B8000),\n reinterpret(0x3FED77B681FF38B3), reinterpret(0x3FBE72E9DA044000),\n reinterpret(0x3FED0CB5724DE943), reinterpret(0x3FC1DCD2507F6000),\n reinterpret(0x3FECA4B2DC0E7563), reinterpret(0x3FC476AB03DEA000),\n reinterpret(0x3FEC3F8EE8D6CB51), reinterpret(0x3FC7074377E22000),\n reinterpret(0x3FEBDD2B4F020C4C), reinterpret(0x3FC98EDE8BA94000),\n reinterpret(0x3FEB7D6C006015CA), reinterpret(0x3FCC0DB86AD2E000),\n reinterpret(0x3FEB20366E2E338F), reinterpret(0x3FCE840AAFCEE000),\n reinterpret(0x3FEAC57026295039), reinterpret(0x3FD0790AB4678000),\n reinterpret(0x3FEA6D01BC2731DD), reinterpret(0x3FD1AC056801C000),\n reinterpret(0x3FEA16D3BC3FF18B), reinterpret(0x3FD2DB11D4FEE000),\n reinterpret(0x3FE9C2D14967FEAD), reinterpret(0x3FD406464EC58000),\n reinterpret(0x3FE970E4F47C9902), reinterpret(0x3FD52DBE093AF000),\n reinterpret(0x3FE920FB3982BCF2), reinterpret(0x3FD651902050D000),\n reinterpret(0x3FE8D30187F759F1), reinterpret(0x3FD771D2CDEAF000),\n reinterpret(0x3FE886E5EBB9F66D), reinterpret(0x3FD88E9C857D9000),\n reinterpret(0x3FE83C97B658B994), reinterpret(0x3FD9A80155E16000),\n reinterpret(0x3FE7F405FFC61022), reinterpret(0x3FDABE186ED3D000),\n reinterpret(0x3FE7AD22181415CA), reinterpret(0x3FDBD0F2AEA0E000),\n reinterpret(0x3FE767DCF99EFF8C), reinterpret(0x3FDCE0A43DBF4000)\n]);\n\n// @ts-ignore: decorator\n@lazy @inline const LOG2_DATA_TAB2 = memory.data([\n // chi , clo\n reinterpret(0x3FE6200012B90A8E), reinterpret(0x3C8904AB0644B605),\n reinterpret(0x3FE66000045734A6), reinterpret(0x3C61FF9BEA62F7A9),\n reinterpret(0x3FE69FFFC325F2C5), reinterpret(0x3C827ECFCB3C90BA),\n reinterpret(0x3FE6E00038B95A04), reinterpret(0x3C88FF8856739326),\n reinterpret(0x3FE71FFFE09994E3), reinterpret(0x3C8AFD40275F82B1),\n reinterpret(0x3FE7600015590E10), reinterpret(0xBC72FD75B4238341),\n reinterpret(0x3FE7A00012655BD5), reinterpret(0x3C7808E67C242B76),\n reinterpret(0x3FE7E0003259E9A6), reinterpret(0xBC6208E426F622B7),\n reinterpret(0x3FE81FFFEDB4B2D2), reinterpret(0xBC8402461EA5C92F),\n reinterpret(0x3FE860002DFAFCC3), reinterpret(0x3C6DF7F4A2F29A1F),\n reinterpret(0x3FE89FFFF78C6B50), reinterpret(0xBC8E0453094995FD),\n reinterpret(0x3FE8E00039671566), reinterpret(0xBC8A04F3BEC77B45),\n reinterpret(0x3FE91FFFE2BF1745), reinterpret(0xBC77FA34400E203C),\n reinterpret(0x3FE95FFFCC5C9FD1), reinterpret(0xBC76FF8005A0695D),\n reinterpret(0x3FE9A0003BBA4767), reinterpret(0x3C70F8C4C4EC7E03),\n reinterpret(0x3FE9DFFFE7B92DA5), reinterpret(0x3C8E7FD9478C4602),\n reinterpret(0x3FEA1FFFD72EFDAF), reinterpret(0xBC6A0C554DCDAE7E),\n reinterpret(0x3FEA5FFFDE04FF95), reinterpret(0x3C867DA98CE9B26B),\n reinterpret(0x3FEA9FFFCA5E8D2B), reinterpret(0xBC8284C9B54C13DE),\n reinterpret(0x3FEADFFFDDAD03EA), reinterpret(0x3C5812C8EA602E3C),\n reinterpret(0x3FEB1FFFF10D3D4D), reinterpret(0xBC8EFADDAD27789C),\n reinterpret(0x3FEB5FFFCE21165A), reinterpret(0x3C53CB1719C61237),\n reinterpret(0x3FEB9FFFD950E674), reinterpret(0x3C73F7D94194CE00),\n reinterpret(0x3FEBE000139CA8AF), reinterpret(0x3C750AC4215D9BC0),\n reinterpret(0x3FEC20005B46DF99), reinterpret(0x3C6BEEA653E9C1C9),\n reinterpret(0x3FEC600040B9F7AE), reinterpret(0xBC7C079F274A70D6),\n reinterpret(0x3FECA0006255FD8A), reinterpret(0xBC7A0B4076E84C1F),\n reinterpret(0x3FECDFFFD94C095D), reinterpret(0x3C88F933F99AB5D7),\n reinterpret(0x3FED1FFFF975D6CF), reinterpret(0xBC582C08665FE1BE),\n reinterpret(0x3FED5FFFA2561C93), reinterpret(0xBC7B04289BD295F3),\n reinterpret(0x3FED9FFF9D228B0C), reinterpret(0x3C870251340FA236),\n reinterpret(0x3FEDE00065BC7E16), reinterpret(0xBC75011E16A4D80C),\n reinterpret(0x3FEE200002F64791), reinterpret(0x3C89802F09EF62E0),\n reinterpret(0x3FEE600057D7A6D8), reinterpret(0xBC7E0B75580CF7FA),\n reinterpret(0x3FEEA00027EDC00C), reinterpret(0xBC8C848309459811),\n reinterpret(0x3FEEE0006CF5CB7C), reinterpret(0xBC8F8027951576F4),\n reinterpret(0x3FEF2000782B7DCC), reinterpret(0xBC8F81D97274538F),\n reinterpret(0x3FEF6000260C450A), reinterpret(0xBC4071002727FFDC),\n reinterpret(0x3FEF9FFFE88CD533), reinterpret(0xBC581BDCE1FDA8B0),\n reinterpret(0x3FEFDFFFD50F8689), reinterpret(0x3C87F91ACB918E6E),\n reinterpret(0x3FF0200004292367), reinterpret(0x3C9B7FF365324681),\n reinterpret(0x3FF05FFFE3E3D668), reinterpret(0x3C86FA08DDAE957B),\n reinterpret(0x3FF0A0000A85A757), reinterpret(0xBC57E2DE80D3FB91),\n reinterpret(0x3FF0E0001A5F3FCC), reinterpret(0xBC91823305C5F014),\n reinterpret(0x3FF11FFFF8AFBAF5), reinterpret(0xBC8BFABB6680BAC2),\n reinterpret(0x3FF15FFFE54D91AD), reinterpret(0xBC9D7F121737E7EF),\n reinterpret(0x3FF1A00011AC36E1), reinterpret(0x3C9C000A0516F5FF),\n reinterpret(0x3FF1E00019C84248), reinterpret(0xBC9082FBE4DA5DA0),\n reinterpret(0x3FF220000FFE5E6E), reinterpret(0xBC88FDD04C9CFB43),\n reinterpret(0x3FF26000269FD891), reinterpret(0x3C8CFE2A7994D182),\n reinterpret(0x3FF2A00029A6E6DA), reinterpret(0xBC700273715E8BC5),\n reinterpret(0x3FF2DFFFE0293E39), reinterpret(0x3C9B7C39DAB2A6F9),\n reinterpret(0x3FF31FFFF7DCF082), reinterpret(0x3C7DF1336EDC5254),\n reinterpret(0x3FF35FFFF05A8B60), reinterpret(0xBC9E03564CCD31EB),\n reinterpret(0x3FF3A0002E0EAECC), reinterpret(0x3C75F0E74BD3A477),\n reinterpret(0x3FF3E000043BB236), reinterpret(0x3C9C7DCB149D8833),\n reinterpret(0x3FF4200002D187FF), reinterpret(0x3C7E08AFCF2D3D28),\n reinterpret(0x3FF460000D387CB1), reinterpret(0x3C820837856599A6),\n reinterpret(0x3FF4A00004569F89), reinterpret(0xBC89FA5C904FBCD2),\n reinterpret(0x3FF4E000043543F3), reinterpret(0xBC781125ED175329),\n reinterpret(0x3FF51FFFCC027F0F), reinterpret(0x3C9883D8847754DC),\n reinterpret(0x3FF55FFFFD87B36F), reinterpret(0xBC8709E731D02807),\n reinterpret(0x3FF59FFFF21DF7BA), reinterpret(0x3C87F79F68727B02),\n reinterpret(0x3FF5DFFFEBFC3481), reinterpret(0xBC9180902E30E93E)\n]);\n\n// @ts-ignore: decorator\n@inline\nexport function log2_lut(x: f64): f64 {\n const N_MASK = (1 << LOG2_TABLE_BITS) - 1;\n\n const\n LO: u64 = 0x3FEEA4AF00000000, // reinterpret(1.0 - 0x1.5b51p-5)\n HI: u64 = 0x3FF0B55900000000; // reinterpret(1.0 + 0x1.6ab2p-5)\n\n const\n InvLn2hi = reinterpret(0x3FF7154765200000), // 0x1.7154765200000p+0\n InvLn2lo = reinterpret(0x3DE705FC2EEFA200), // 0x1.705fc2eefa200p-33\n Ox1p52 = reinterpret(0x4330000000000000); // 0x1p52\n\n const\n B0 = reinterpret(0xBFE71547652B82FE), // -0x1.71547652b82fep-1\n B1 = reinterpret(0x3FDEC709DC3A03F7), // 0x1.ec709dc3a03f7p-2\n B2 = reinterpret(0xBFD71547652B7C3F), // -0x1.71547652b7c3fp-2\n B3 = reinterpret(0x3FD2776C50F05BE4), // 0x1.2776c50f05be4p-2\n B4 = reinterpret(0xBFCEC709DD768FE5), // -0x1.ec709dd768fe5p-3\n B5 = reinterpret(0x3FCA61761EC4E736), // 0x1.a61761ec4e736p-3\n B6 = reinterpret(0xBFC7153FBC64A79B), // -0x1.7153fbc64a79bp-3\n B7 = reinterpret(0x3FC484D154F01B4A), // 0x1.484d154f01b4ap-3\n B8 = reinterpret(0xBFC289E4A72C383C), // -0x1.289e4a72c383cp-3\n B9 = reinterpret(0x3FC0B32F285AEE66); // 0x1.0b32f285aee66p-3\n\n const\n A0 = reinterpret(0xBFE71547652B8339), // -0x1.71547652b8339p-1\n A1 = reinterpret(0x3FDEC709DC3A04BE), // 0x1.ec709dc3a04bep-2\n A2 = reinterpret(0xBFD7154764702FFB), // -0x1.7154764702ffbp-2\n A3 = reinterpret(0x3FD2776C50034C48), // 0x1.2776c50034c48p-2\n A4 = reinterpret(0xBFCEC7B328EA92BC), // -0x1.ec7b328ea92bcp-3\n A5 = reinterpret(0x3FCA6225E117F92E); // 0x1.a6225e117f92ep-3\n\n var ix = reinterpret(x);\n if (ix - LO < HI - LO) {\n let r = x - 1.0;\n // #if __FP_FAST_FMA\n // hi = r * InvLn2hi;\n // lo = r * InvLn2lo + __builtin_fma(r, InvLn2hi, -hi);\n // #else\n let rhi = reinterpret(reinterpret(r) & 0xFFFFFFFF00000000);\n let rlo = r - rhi;\n let hi = rhi * InvLn2hi;\n let lo = rlo * InvLn2hi + r * InvLn2lo;\n // #endif\n let r2 = r * r; // rounding error: 0x1p-62\n let r4 = r2 * r2;\n // Worst-case error is less than 0.54 ULP (0.55 ULP without fma)\n let p = r2 * (B0 + r * B1);\n let y = hi + p;\n lo += hi - y + p;\n lo += r4 * (B2 + r * B3 + r2 * (B4 + r * B5) +\n r4 * (B6 + r * B7 + r2 * (B8 + r * B9)));\n return y + lo;\n }\n var top = u32(ix >> 48);\n if (top - 0x0010 >= 0x7ff0 - 0x0010) {\n // x < 0x1p-1022 or inf or nan.\n if ((ix << 1) == 0) return -1.0 / (x * x);\n if (ix == 0x7FF0000000000000) return x; // log(inf) == inf\n if ((top & 0x8000) || (top & 0x7FF0) == 0x7FF0) return (x - x) / (x - x);\n // x is subnormal, normalize it.\n ix = reinterpret(x * Ox1p52);\n ix -= u64(52) << 52;\n }\n\n // x = 2^k z; where z is in range [OFF,2*OFF) and exact.\n // The range is split into N subintervals.\n // The ith subinterval contains z and c is near its center.\n var tmp = ix - 0x3FE6000000000000;\n var i = ((tmp >> (52 - LOG2_TABLE_BITS)) & N_MASK);\n var k = tmp >> 52;\n var iz = ix - (tmp & 0xFFF0000000000000);\n\n var invc = load(LOG2_DATA_TAB1 + (i << (1 + alignof())), 0 << alignof()); // T[i].invc;\n var logc = load(LOG2_DATA_TAB1 + (i << (1 + alignof())), 1 << alignof()); // T[i].logc;\n var z = reinterpret(iz);\n var kd = k;\n\n // log2(x) = log2(z/c) + log2(c) + k.\n // r ~= z/c - 1, |r| < 1/(2*N).\n // #if __FP_FAST_FMA\n // \t// rounding error: 0x1p-55/N.\n // \tr = __builtin_fma(z, invc, -1.0);\n // \tt1 = r * InvLn2hi;\n // \tt2 = r * InvLn2lo + __builtin_fma(r, InvLn2hi, -t1);\n // #else\n // rounding error: 0x1p-55/N + 0x1p-65.\n var chi = load(LOG2_DATA_TAB2 + (i << (1 + alignof())), 0 << alignof()); // T[i].chi;\n var clo = load(LOG2_DATA_TAB2 + (i << (1 + alignof())), 1 << alignof()); // T[i].clo;\n\n var r = (z - chi - clo) * invc;\n var rhi = reinterpret(reinterpret(r) & 0xFFFFFFFF00000000);\n var rlo = r - rhi;\n var t1 = rhi * InvLn2hi;\n var t2 = rlo * InvLn2hi + r * InvLn2lo;\n // #endif\n\n // hi + lo = r/ln2 + log2(c) + k\n var t3 = kd + logc;\n var hi = t3 + t1;\n var lo = t3 - hi + t1 + t2;\n\n // log2(r+1) = r/ln2 + r^2*poly(r)\n // Evaluation is optimized assuming superscalar pipelined execution\n var r2 = r * r; // rounding error: 0x1p-54/N^2\n // Worst-case error if |y| > 0x1p-4: 0.547 ULP (0.550 ULP without fma).\n // ~ 0.5 + 2/N/ln2 + abs-poly-error*0x1p56 ULP (+ 0.003 ULP without fma).\n var p = A0 + r * A1 + r2 * (A2 + r * A3) + (r2 * r2) * (A4 + r * A5);\n return lo + r2 * p + hi;\n}\n\n//\n// Lookup data for log. See: https://git.musl-libc.org/cgit/musl/tree/src/math/log.c\n//\n\n// @ts-ignore: decorator\n@inline const LOG_TABLE_BITS = 7;\n\n/* Algorithm:\n\n x = 2^k z\n log(x) = k ln2 + log(c) + log(z/c)\n log(z/c) = poly(z/c - 1)\n\nwhere z is in [1.6p-1; 1.6p0] which is split into N subintervals and z falls\ninto the ith one, then table entries are computed as\n\n tab[i].invc = 1/c\n tab[i].logc = (double)log(c)\n tab2[i].chi = (double)c\n tab2[i].clo = (double)(c - (double)c)\n\nwhere c is near the center of the subinterval and is chosen by trying +-2^29\nfloating point invc candidates around 1/center and selecting one for which\n\n 1) the rounding error in 0x1.8p9 + logc is 0,\n 2) the rounding error in z - chi - clo is < 0x1p-66 and\n 3) the rounding error in (double)log(c) is minimized (< 0x1p-66).\n\nNote: 1) ensures that k*ln2hi + logc can be computed without rounding error,\n2) ensures that z/c - 1 can be computed as (z - chi - clo)*invc with close to\na single rounding error when there is no fast fma for z*invc - 1, 3) ensures\nthat logc + poly(z/c - 1) has small error, however near x == 1 when\n|log(x)| < 0x1p-4, this is not enough so that is special cased.*/\n\n// @ts-ignore: decorator\n@lazy @inline const LOG_DATA_TAB1 = memory.data([\n // invc , logc\n reinterpret(0x3FF734F0C3E0DE9F), reinterpret(0xBFD7CC7F79E69000),\n reinterpret(0x3FF713786A2CE91F), reinterpret(0xBFD76FEEC20D0000),\n reinterpret(0x3FF6F26008FAB5A0), reinterpret(0xBFD713E31351E000),\n reinterpret(0x3FF6D1A61F138C7D), reinterpret(0xBFD6B85B38287800),\n reinterpret(0x3FF6B1490BC5B4D1), reinterpret(0xBFD65D5590807800),\n reinterpret(0x3FF69147332F0CBA), reinterpret(0xBFD602D076180000),\n reinterpret(0x3FF6719F18224223), reinterpret(0xBFD5A8CA86909000),\n reinterpret(0x3FF6524F99A51ED9), reinterpret(0xBFD54F4356035000),\n reinterpret(0x3FF63356AA8F24C4), reinterpret(0xBFD4F637C36B4000),\n reinterpret(0x3FF614B36B9DDC14), reinterpret(0xBFD49DA7FDA85000),\n reinterpret(0x3FF5F66452C65C4C), reinterpret(0xBFD445923989A800),\n reinterpret(0x3FF5D867B5912C4F), reinterpret(0xBFD3EDF439B0B800),\n reinterpret(0x3FF5BABCCB5B90DE), reinterpret(0xBFD396CE448F7000),\n reinterpret(0x3FF59D61F2D91A78), reinterpret(0xBFD3401E17BDA000),\n reinterpret(0x3FF5805612465687), reinterpret(0xBFD2E9E2EF468000),\n reinterpret(0x3FF56397CEE76BD3), reinterpret(0xBFD2941B3830E000),\n reinterpret(0x3FF54725E2A77F93), reinterpret(0xBFD23EC58CDA8800),\n reinterpret(0x3FF52AFF42064583), reinterpret(0xBFD1E9E129279000),\n reinterpret(0x3FF50F22DBB2BDDF), reinterpret(0xBFD1956D2B48F800),\n reinterpret(0x3FF4F38F4734DED7), reinterpret(0xBFD141679AB9F800),\n reinterpret(0x3FF4D843CFDE2840), reinterpret(0xBFD0EDD094EF9800),\n reinterpret(0x3FF4BD3EC078A3C8), reinterpret(0xBFD09AA518DB1000),\n reinterpret(0x3FF4A27FC3E0258A), reinterpret(0xBFD047E65263B800),\n reinterpret(0x3FF4880524D48434), reinterpret(0xBFCFEB224586F000),\n reinterpret(0x3FF46DCE1B192D0B), reinterpret(0xBFCF474A7517B000),\n reinterpret(0x3FF453D9D3391854), reinterpret(0xBFCEA4443D103000),\n reinterpret(0x3FF43A2744B4845A), reinterpret(0xBFCE020D44E9B000),\n reinterpret(0x3FF420B54115F8FB), reinterpret(0xBFCD60A22977F000),\n reinterpret(0x3FF40782DA3EF4B1), reinterpret(0xBFCCC00104959000),\n reinterpret(0x3FF3EE8F5D57FE8F), reinterpret(0xBFCC202956891000),\n reinterpret(0x3FF3D5D9A00B4CE9), reinterpret(0xBFCB81178D811000),\n reinterpret(0x3FF3BD60C010C12B), reinterpret(0xBFCAE2C9CCD3D000),\n reinterpret(0x3FF3A5242B75DAB8), reinterpret(0xBFCA45402E129000),\n reinterpret(0x3FF38D22CD9FD002), reinterpret(0xBFC9A877681DF000),\n reinterpret(0x3FF3755BC5847A1C), reinterpret(0xBFC90C6D69483000),\n reinterpret(0x3FF35DCE49AD36E2), reinterpret(0xBFC87120A645C000),\n reinterpret(0x3FF34679984DD440), reinterpret(0xBFC7D68FB4143000),\n reinterpret(0x3FF32F5CCEFFCB24), reinterpret(0xBFC73CB83C627000),\n reinterpret(0x3FF3187775A10D49), reinterpret(0xBFC6A39A9B376000),\n reinterpret(0x3FF301C8373E3990), reinterpret(0xBFC60B3154B7A000),\n reinterpret(0x3FF2EB4EBB95F841), reinterpret(0xBFC5737D76243000),\n reinterpret(0x3FF2D50A0219A9D1), reinterpret(0xBFC4DC7B8FC23000),\n reinterpret(0x3FF2BEF9A8B7FD2A), reinterpret(0xBFC4462C51D20000),\n reinterpret(0x3FF2A91C7A0C1BAB), reinterpret(0xBFC3B08ABC830000),\n reinterpret(0x3FF293726014B530), reinterpret(0xBFC31B996B490000),\n reinterpret(0x3FF27DFA5757A1F5), reinterpret(0xBFC2875490A44000),\n reinterpret(0x3FF268B39B1D3BBF), reinterpret(0xBFC1F3B9F879A000),\n reinterpret(0x3FF2539D838FF5BD), reinterpret(0xBFC160C8252CA000),\n reinterpret(0x3FF23EB7AAC9083B), reinterpret(0xBFC0CE7F57F72000),\n reinterpret(0x3FF22A012BA940B6), reinterpret(0xBFC03CDC49FEA000),\n reinterpret(0x3FF2157996CC4132), reinterpret(0xBFBF57BDBC4B8000),\n reinterpret(0x3FF201201DD2FC9B), reinterpret(0xBFBE370896404000),\n reinterpret(0x3FF1ECF4494D480B), reinterpret(0xBFBD17983EF94000),\n reinterpret(0x3FF1D8F5528F6569), reinterpret(0xBFBBF9674ED8A000),\n reinterpret(0x3FF1C52311577E7C), reinterpret(0xBFBADC79202F6000),\n reinterpret(0x3FF1B17C74CB26E9), reinterpret(0xBFB9C0C3E7288000),\n reinterpret(0x3FF19E010C2C1AB6), reinterpret(0xBFB8A646B372C000),\n reinterpret(0x3FF18AB07BB670BD), reinterpret(0xBFB78D01B3AC0000),\n reinterpret(0x3FF1778A25EFBCB6), reinterpret(0xBFB674F145380000),\n reinterpret(0x3FF1648D354C31DA), reinterpret(0xBFB55E0E6D878000),\n reinterpret(0x3FF151B990275FDD), reinterpret(0xBFB4485CDEA1E000),\n reinterpret(0x3FF13F0EA432D24C), reinterpret(0xBFB333D94D6AA000),\n reinterpret(0x3FF12C8B7210F9DA), reinterpret(0xBFB22079F8C56000),\n reinterpret(0x3FF11A3028ECB531), reinterpret(0xBFB10E4698622000),\n reinterpret(0x3FF107FBDA8434AF), reinterpret(0xBFAFFA6C6AD20000),\n reinterpret(0x3FF0F5EE0F4E6BB3), reinterpret(0xBFADDA8D4A774000),\n reinterpret(0x3FF0E4065D2A9FCE), reinterpret(0xBFABBCECE4850000),\n reinterpret(0x3FF0D244632CA521), reinterpret(0xBFA9A1894012C000),\n reinterpret(0x3FF0C0A77CE2981A), reinterpret(0xBFA788583302C000),\n reinterpret(0x3FF0AF2F83C636D1), reinterpret(0xBFA5715E67D68000),\n reinterpret(0x3FF09DDB98A01339), reinterpret(0xBFA35C8A49658000),\n reinterpret(0x3FF08CABAF52E7DF), reinterpret(0xBFA149E364154000),\n reinterpret(0x3FF07B9F2F4E28FB), reinterpret(0xBF9E72C082EB8000),\n reinterpret(0x3FF06AB58C358F19), reinterpret(0xBF9A55F152528000),\n reinterpret(0x3FF059EEA5ECF92C), reinterpret(0xBF963D62CF818000),\n reinterpret(0x3FF04949CDD12C90), reinterpret(0xBF9228FB8CAA0000),\n reinterpret(0x3FF038C6C6F0ADA9), reinterpret(0xBF8C317B20F90000),\n reinterpret(0x3FF02865137932A9), reinterpret(0xBF8419355DAA0000),\n reinterpret(0x3FF0182427EA7348), reinterpret(0xBF781203C2EC0000),\n reinterpret(0x3FF008040614B195), reinterpret(0xBF60040979240000),\n reinterpret(0x3FEFE01FF726FA1A), reinterpret(0x3F6FEFF384900000),\n reinterpret(0x3FEFA11CC261EA74), reinterpret(0x3F87DC41353D0000),\n reinterpret(0x3FEF6310B081992E), reinterpret(0x3F93CEA3C4C28000),\n reinterpret(0x3FEF25F63CEEADCD), reinterpret(0x3F9B9FC114890000),\n reinterpret(0x3FEEE9C8039113E7), reinterpret(0x3FA1B0D8CE110000),\n reinterpret(0x3FEEAE8078CBB1AB), reinterpret(0x3FA58A5BD001C000),\n reinterpret(0x3FEE741AA29D0C9B), reinterpret(0x3FA95C8340D88000),\n reinterpret(0x3FEE3A91830A99B5), reinterpret(0x3FAD276AEF578000),\n reinterpret(0x3FEE01E009609A56), reinterpret(0x3FB07598E598C000),\n reinterpret(0x3FEDCA01E577BB98), reinterpret(0x3FB253F5E30D2000),\n reinterpret(0x3FED92F20B7C9103), reinterpret(0x3FB42EDD8B380000),\n reinterpret(0x3FED5CAC66FB5CCE), reinterpret(0x3FB606598757C000),\n reinterpret(0x3FED272CAA5EDE9D), reinterpret(0x3FB7DA76356A0000),\n reinterpret(0x3FECF26E3E6B2CCD), reinterpret(0x3FB9AB434E1C6000),\n reinterpret(0x3FECBE6DA2A77902), reinterpret(0x3FBB78C7BB0D6000),\n reinterpret(0x3FEC8B266D37086D), reinterpret(0x3FBD431332E72000),\n reinterpret(0x3FEC5894BD5D5804), reinterpret(0x3FBF0A3171DE6000),\n reinterpret(0x3FEC26B533BB9F8C), reinterpret(0x3FC067152B914000),\n reinterpret(0x3FEBF583EEECE73F), reinterpret(0x3FC147858292B000),\n reinterpret(0x3FEBC4FD75DB96C1), reinterpret(0x3FC2266ECDCA3000),\n reinterpret(0x3FEB951E0C864A28), reinterpret(0x3FC303D7A6C55000),\n reinterpret(0x3FEB65E2C5EF3E2C), reinterpret(0x3FC3DFC33C331000),\n reinterpret(0x3FEB374867C9888B), reinterpret(0x3FC4BA366B7A8000),\n reinterpret(0x3FEB094B211D304A), reinterpret(0x3FC5933928D1F000),\n reinterpret(0x3FEADBE885F2EF7E), reinterpret(0x3FC66ACD2418F000),\n reinterpret(0x3FEAAF1D31603DA2), reinterpret(0x3FC740F8EC669000),\n reinterpret(0x3FEA82E63FD358A7), reinterpret(0x3FC815C0F51AF000),\n reinterpret(0x3FEA5740EF09738B), reinterpret(0x3FC8E92954F68000),\n reinterpret(0x3FEA2C2A90AB4B27), reinterpret(0x3FC9BB3602F84000),\n reinterpret(0x3FEA01A01393F2D1), reinterpret(0x3FCA8BED1C2C0000),\n reinterpret(0x3FE9D79F24DB3C1B), reinterpret(0x3FCB5B515C01D000),\n reinterpret(0x3FE9AE2505C7B190), reinterpret(0x3FCC2967CCBCC000),\n reinterpret(0x3FE9852EF297CE2F), reinterpret(0x3FCCF635D5486000),\n reinterpret(0x3FE95CBAEEA44B75), reinterpret(0x3FCDC1BD3446C000),\n reinterpret(0x3FE934C69DE74838), reinterpret(0x3FCE8C01B8CFE000),\n reinterpret(0x3FE90D4F2F6752E6), reinterpret(0x3FCF5509C0179000),\n reinterpret(0x3FE8E6528EFFD79D), reinterpret(0x3FD00E6C121FB800),\n reinterpret(0x3FE8BFCE9FCC007C), reinterpret(0x3FD071B80E93D000),\n reinterpret(0x3FE899C0DABEC30E), reinterpret(0x3FD0D46B9E867000),\n reinterpret(0x3FE87427AA2317FB), reinterpret(0x3FD13687334BD000),\n reinterpret(0x3FE84F00ACB39A08), reinterpret(0x3FD1980D67234800),\n reinterpret(0x3FE82A49E8653E55), reinterpret(0x3FD1F8FFE0CC8000),\n reinterpret(0x3FE8060195F40260), reinterpret(0x3FD2595FD7636800),\n reinterpret(0x3FE7E22563E0A329), reinterpret(0x3FD2B9300914A800),\n reinterpret(0x3FE7BEB377DCB5AD), reinterpret(0x3FD3187210436000),\n reinterpret(0x3FE79BAA679725C2), reinterpret(0x3FD377266DEC1800),\n reinterpret(0x3FE77907F2170657), reinterpret(0x3FD3D54FFBAF3000),\n reinterpret(0x3FE756CADBD6130C), reinterpret(0x3FD432EEE32FE000)\n]);\n\n// @ts-ignore: decorator\n@lazy @inline const LOG_DATA_TAB2 = memory.data([\n // chi , clo\n reinterpret(0x3FE61000014FB66B), reinterpret(0x3C7E026C91425B3C),\n reinterpret(0x3FE63000034DB495), reinterpret(0x3C8DBFEA48005D41),\n reinterpret(0x3FE650000D94D478), reinterpret(0x3C8E7FA786D6A5B7),\n reinterpret(0x3FE67000074E6FAD), reinterpret(0x3C61FCEA6B54254C),\n reinterpret(0x3FE68FFFFEDF0FAE), reinterpret(0xBC7C7E274C590EFD),\n reinterpret(0x3FE6B0000763C5BC), reinterpret(0xBC8AC16848DCDA01),\n reinterpret(0x3FE6D0001E5CC1F6), reinterpret(0x3C833F1C9D499311),\n reinterpret(0x3FE6EFFFEB05F63E), reinterpret(0xBC7E80041AE22D53),\n reinterpret(0x3FE710000E869780), reinterpret(0x3C7BFF6671097952),\n reinterpret(0x3FE72FFFFC67E912), reinterpret(0x3C8C00E226BD8724),\n reinterpret(0x3FE74FFFDF81116A), reinterpret(0xBC6E02916EF101D2),\n reinterpret(0x3FE770000F679C90), reinterpret(0xBC67FC71CD549C74),\n reinterpret(0x3FE78FFFFA7EC835), reinterpret(0x3C81BEC19EF50483),\n reinterpret(0x3FE7AFFFFE20C2E6), reinterpret(0xBC707E1729CC6465),\n reinterpret(0x3FE7CFFFED3FC900), reinterpret(0xBC808072087B8B1C),\n reinterpret(0x3FE7EFFFE9261A76), reinterpret(0x3C8DC0286D9DF9AE),\n reinterpret(0x3FE81000049CA3E8), reinterpret(0x3C897FD251E54C33),\n reinterpret(0x3FE8300017932C8F), reinterpret(0xBC8AFEE9B630F381),\n reinterpret(0x3FE850000633739C), reinterpret(0x3C89BFBF6B6535BC),\n reinterpret(0x3FE87000204289C6), reinterpret(0xBC8BBF65F3117B75),\n reinterpret(0x3FE88FFFEBF57904), reinterpret(0xBC89006EA23DCB57),\n reinterpret(0x3FE8B00022BC04DF), reinterpret(0xBC7D00DF38E04B0A),\n reinterpret(0x3FE8CFFFE50C1B8A), reinterpret(0xBC88007146FF9F05),\n reinterpret(0x3FE8EFFFFC918E43), reinterpret(0x3C83817BD07A7038),\n reinterpret(0x3FE910001EFA5FC7), reinterpret(0x3C893E9176DFB403),\n reinterpret(0x3FE9300013467BB9), reinterpret(0x3C7F804E4B980276),\n reinterpret(0x3FE94FFFE6EE076F), reinterpret(0xBC8F7EF0D9FF622E),\n reinterpret(0x3FE96FFFDE3C12D1), reinterpret(0xBC7082AA962638BA),\n reinterpret(0x3FE98FFFF4458A0D), reinterpret(0xBC87801B9164A8EF),\n reinterpret(0x3FE9AFFFDD982E3E), reinterpret(0xBC8740E08A5A9337),\n reinterpret(0x3FE9CFFFED49FB66), reinterpret(0x3C3FCE08C19BE000),\n reinterpret(0x3FE9F00020F19C51), reinterpret(0xBC8A3FAA27885B0A),\n reinterpret(0x3FEA10001145B006), reinterpret(0x3C74FF489958DA56),\n reinterpret(0x3FEA300007BBF6FA), reinterpret(0x3C8CBEAB8A2B6D18),\n reinterpret(0x3FEA500010971D79), reinterpret(0x3C88FECADD787930),\n reinterpret(0x3FEA70001DF52E48), reinterpret(0xBC8F41763DD8ABDB),\n reinterpret(0x3FEA90001C593352), reinterpret(0xBC8EBF0284C27612),\n reinterpret(0x3FEAB0002A4F3E4B), reinterpret(0xBC69FD043CFF3F5F),\n reinterpret(0x3FEACFFFD7AE1ED1), reinterpret(0xBC823EE7129070B4),\n reinterpret(0x3FEAEFFFEE510478), reinterpret(0x3C6A063EE00EDEA3),\n reinterpret(0x3FEB0FFFDB650D5B), reinterpret(0x3C5A06C8381F0AB9),\n reinterpret(0x3FEB2FFFFEAACA57), reinterpret(0xBC79011E74233C1D),\n reinterpret(0x3FEB4FFFD995BADC), reinterpret(0xBC79FF1068862A9F),\n reinterpret(0x3FEB7000249E659C), reinterpret(0x3C8AFF45D0864F3E),\n reinterpret(0x3FEB8FFFF9871640), reinterpret(0x3C7CFE7796C2C3F9),\n reinterpret(0x3FEBAFFFD204CB4F), reinterpret(0xBC63FF27EEF22BC4),\n reinterpret(0x3FEBCFFFD2415C45), reinterpret(0xBC6CFFB7EE3BEA21),\n reinterpret(0x3FEBEFFFF86309DF), reinterpret(0xBC814103972E0B5C),\n reinterpret(0x3FEC0FFFE1B57653), reinterpret(0x3C8BC16494B76A19),\n reinterpret(0x3FEC2FFFF1FA57E3), reinterpret(0xBC64FEEF8D30C6ED),\n reinterpret(0x3FEC4FFFDCBFE424), reinterpret(0xBC843F68BCEC4775),\n reinterpret(0x3FEC6FFFED54B9F7), reinterpret(0x3C847EA3F053E0EC),\n reinterpret(0x3FEC8FFFEB998FD5), reinterpret(0x3C7383068DF992F1),\n reinterpret(0x3FECB0002125219A), reinterpret(0xBC68FD8E64180E04),\n reinterpret(0x3FECCFFFDD94469C), reinterpret(0x3C8E7EBE1CC7EA72),\n reinterpret(0x3FECEFFFEAFDC476), reinterpret(0x3C8EBE39AD9F88FE),\n reinterpret(0x3FED1000169AF82B), reinterpret(0x3C757D91A8B95A71),\n reinterpret(0x3FED30000D0FF71D), reinterpret(0x3C89C1906970C7DA),\n reinterpret(0x3FED4FFFEA790FC4), reinterpret(0xBC580E37C558FE0C),\n reinterpret(0x3FED70002EDC87E5), reinterpret(0xBC7F80D64DC10F44),\n reinterpret(0x3FED900021DC82AA), reinterpret(0xBC747C8F94FD5C5C),\n reinterpret(0x3FEDAFFFD86B0283), reinterpret(0x3C8C7F1DC521617E),\n reinterpret(0x3FEDD000296C4739), reinterpret(0x3C88019EB2FFB153),\n reinterpret(0x3FEDEFFFE54490F5), reinterpret(0x3C6E00D2C652CC89),\n reinterpret(0x3FEE0FFFCDABF694), reinterpret(0xBC7F8340202D69D2),\n reinterpret(0x3FEE2FFFDB52C8DD), reinterpret(0x3C7B00C1CA1B0864),\n reinterpret(0x3FEE4FFFF24216EF), reinterpret(0x3C72FFA8B094AB51),\n reinterpret(0x3FEE6FFFE88A5E11), reinterpret(0xBC57F673B1EFBE59),\n reinterpret(0x3FEE9000119EFF0D), reinterpret(0xBC84808D5E0BC801),\n reinterpret(0x3FEEAFFFDFA51744), reinterpret(0x3C780006D54320B5),\n reinterpret(0x3FEED0001A127FA1), reinterpret(0xBC5002F860565C92),\n reinterpret(0x3FEEF00007BABCC4), reinterpret(0xBC8540445D35E611),\n reinterpret(0x3FEF0FFFF57A8D02), reinterpret(0xBC4FFB3139EF9105),\n reinterpret(0x3FEF30001EE58AC7), reinterpret(0x3C8A81ACF2731155),\n reinterpret(0x3FEF4FFFF5823494), reinterpret(0x3C8A3F41D4D7C743),\n reinterpret(0x3FEF6FFFFCA94C6B), reinterpret(0xBC6202F41C987875),\n reinterpret(0x3FEF8FFFE1F9C441), reinterpret(0x3C777DD1F477E74B),\n reinterpret(0x3FEFAFFFD2E0E37E), reinterpret(0xBC6F01199A7CA331),\n reinterpret(0x3FEFD0001C77E49E), reinterpret(0x3C7181EE4BCEACB1),\n reinterpret(0x3FEFEFFFF7E0C331), reinterpret(0xBC6E05370170875A),\n reinterpret(0x3FF00FFFF465606E), reinterpret(0xBC8A7EAD491C0ADA),\n reinterpret(0x3FF02FFFF3867A58), reinterpret(0xBC977F69C3FCB2E0),\n reinterpret(0x3FF04FFFFDFC0D17), reinterpret(0x3C97BFFE34CB945B),\n reinterpret(0x3FF0700003CD4D82), reinterpret(0x3C820083C0E456CB),\n reinterpret(0x3FF08FFFF9F2CBE8), reinterpret(0xBC6DFFDFBE37751A),\n reinterpret(0x3FF0B000010CDA65), reinterpret(0xBC913F7FAEE626EB),\n reinterpret(0x3FF0D00001A4D338), reinterpret(0x3C807DFA79489FF7),\n reinterpret(0x3FF0EFFFFADAFDFD), reinterpret(0xBC77040570D66BC0),\n reinterpret(0x3FF110000BBAFD96), reinterpret(0x3C8E80D4846D0B62),\n reinterpret(0x3FF12FFFFAE5F45D), reinterpret(0x3C9DBFFA64FD36EF),\n reinterpret(0x3FF150000DD59AD9), reinterpret(0x3C9A0077701250AE),\n reinterpret(0x3FF170000F21559A), reinterpret(0x3C8DFDF9E2E3DEEE),\n reinterpret(0x3FF18FFFFC275426), reinterpret(0x3C910030DC3B7273),\n reinterpret(0x3FF1B000123D3C59), reinterpret(0x3C997F7980030188),\n reinterpret(0x3FF1CFFFF8299EB7), reinterpret(0xBC65F932AB9F8C67),\n reinterpret(0x3FF1EFFFF48AD400), reinterpret(0x3C937FBF9DA75BEB),\n reinterpret(0x3FF210000C8B86A4), reinterpret(0x3C9F806B91FD5B22),\n reinterpret(0x3FF2300003854303), reinterpret(0x3C93FFC2EB9FBF33),\n reinterpret(0x3FF24FFFFFBCF684), reinterpret(0x3C7601E77E2E2E72),\n reinterpret(0x3FF26FFFF52921D9), reinterpret(0x3C7FFCBB767F0C61),\n reinterpret(0x3FF2900014933A3C), reinterpret(0xBC7202CA3C02412B),\n reinterpret(0x3FF2B00014556313), reinterpret(0xBC92808233F21F02),\n reinterpret(0x3FF2CFFFEBFE523B), reinterpret(0xBC88FF7E384FDCF2),\n reinterpret(0x3FF2F0000BB8AD96), reinterpret(0xBC85FF51503041C5),\n reinterpret(0x3FF30FFFFB7AE2AF), reinterpret(0xBC810071885E289D),\n reinterpret(0x3FF32FFFFEAC5F7F), reinterpret(0xBC91FF5D3FB7B715),\n reinterpret(0x3FF350000CA66756), reinterpret(0x3C957F82228B82BD),\n reinterpret(0x3FF3700011FBF721), reinterpret(0x3C8000BAC40DD5CC),\n reinterpret(0x3FF38FFFF9592FB9), reinterpret(0xBC943F9D2DB2A751),\n reinterpret(0x3FF3B00004DDD242), reinterpret(0x3C857F6B707638E1),\n reinterpret(0x3FF3CFFFF5B2C957), reinterpret(0x3C7A023A10BF1231),\n reinterpret(0x3FF3EFFFEAB0B418), reinterpret(0x3C987F6D66B152B0),\n reinterpret(0x3FF410001532AFF4), reinterpret(0x3C67F8375F198524),\n reinterpret(0x3FF4300017478B29), reinterpret(0x3C8301E672DC5143),\n reinterpret(0x3FF44FFFE795B463), reinterpret(0x3C89FF69B8B2895A),\n reinterpret(0x3FF46FFFE80475E0), reinterpret(0xBC95C0B19BC2F254),\n reinterpret(0x3FF48FFFEF6FC1E7), reinterpret(0x3C9B4009F23A2A72),\n reinterpret(0x3FF4AFFFE5BEA704), reinterpret(0xBC94FFB7BF0D7D45),\n reinterpret(0x3FF4D000171027DE), reinterpret(0xBC99C06471DC6A3D),\n reinterpret(0x3FF4F0000FF03EE2), reinterpret(0x3C977F890B85531C),\n reinterpret(0x3FF5100012DC4BD1), reinterpret(0x3C6004657166A436),\n reinterpret(0x3FF530001605277A), reinterpret(0xBC96BFCECE233209),\n reinterpret(0x3FF54FFFECDB704C), reinterpret(0xBC8902720505A1D7),\n reinterpret(0x3FF56FFFEF5F54A9), reinterpret(0x3C9BBFE60EC96412),\n reinterpret(0x3FF5900017E61012), reinterpret(0x3C887EC581AFEF90),\n reinterpret(0x3FF5B00003C93E92), reinterpret(0xBC9F41080ABF0CC0),\n reinterpret(0x3FF5D0001D4919BC), reinterpret(0xBC98812AFB254729),\n reinterpret(0x3FF5EFFFE7B87A89), reinterpret(0xBC947EB780ED6904)\n]);\n\n// @ts-ignore: decorator\n@inline\nexport function log_lut(x: f64): f64 {\n const N_MASK = (1 << LOG_TABLE_BITS) - 1;\n\n const\n B0 = reinterpret(0xBFE0000000000000), // -0x1p-1\n B1 = reinterpret(0x3FD5555555555577), // 0x1.5555555555577p-2\n B2 = reinterpret(0xBFCFFFFFFFFFFDCB), // -0x1.ffffffffffdcbp-3\n B3 = reinterpret(0x3FC999999995DD0C), // 0x1.999999995dd0cp-3\n B4 = reinterpret(0xBFC55555556745A7), // -0x1.55555556745a7p-3\n B5 = reinterpret(0x3FC24924A344DE30), // 0x1.24924a344de3p-3\n B6 = reinterpret(0xBFBFFFFFA4423D65), // -0x1.fffffa4423d65p-4\n B7 = reinterpret(0x3FBC7184282AD6CA), // 0x1.c7184282ad6cap-4\n B8 = reinterpret(0xBFB999EB43B068FF), // -0x1.999eb43b068ffp-4\n B9 = reinterpret(0x3FB78182F7AFD085), // 0x1.78182f7afd085p-4\n B10 = reinterpret(0xBFB5521375D145CD); // -0x1.5521375d145cdp-4\n\n const\n A0 = reinterpret(0xBFE0000000000001), // -0x1.0000000000001p-1\n A1 = reinterpret(0x3FD555555551305B), // 0x1.555555551305bp-2\n A2 = reinterpret(0xBFCFFFFFFFEB4590), // -0x1.fffffffeb459p-3\n A3 = reinterpret(0x3FC999B324F10111), // 0x1.999b324f10111p-3\n A4 = reinterpret(0xBFC55575E506C89F); // -0x1.55575e506c89fp-3\n\n const\n LO: u64 = 0x3FEE000000000000,\n HI: u64 = 0x3FF1090000000000;\n\n const\n Ln2hi = reinterpret(0x3FE62E42FEFA3800), // 0x1.62e42fefa3800p-1\n Ln2lo = reinterpret(0x3D2EF35793C76730), // 0x1.ef35793c76730p-45\n Ox1p27 = reinterpret(0x41A0000000000000), // 0x1p27\n Ox1p52 = reinterpret(0x4330000000000000); // 0x1p52\n\n var ix = reinterpret(x);\n if (ix - LO < HI - LO) {\n let r = x - 1.0;\n let r2 = r * r;\n let r3 = r2 * r;\n let y =\n r3 * (B1 + r * B2 + r2 * B3 +\n r3 * (B4 + r * B5 + r2 * B6 +\n r3 * (B7 + r * B8 + r2 * B9 + r3 * B10)));\n // Worst-case error is around 0.507 ULP\n let w = r * Ox1p27;\n let rhi = r + w - w;\n let rlo = r - rhi;\n w = rhi * rhi * B0; // B[0] == -0.5\n let hi = r + w;\n let lo = r - hi + w;\n lo += B0 * rlo * (rhi + r);\n return y + lo + hi;\n }\n var top = u32(ix >> 48);\n if (top - 0x0010 >= 0x7FF0 - 0x0010) {\n // x < 0x1p-1022 or inf or nan\n if ((ix << 1) == 0) return -1.0 / (x * x);\n if (ix == reinterpret(Infinity)) return x; // log(inf) == inf\n if ((top & 0x8000) || (top & 0x7FF0) == 0x7FF0) return (x - x) / (x - x);\n // x is subnormal, normalize it\n ix = reinterpret(x * Ox1p52);\n ix -= u64(52) << 52;\n }\n\n // x = 2^k z; where z is in range [OFF,2*OFF) and exact.\n // The range is split into N subintervals.\n // The ith subinterval contains z and c is near its center.\n var tmp = ix - 0x3FE6000000000000;\n var i = ((tmp >> (52 - LOG_TABLE_BITS)) & N_MASK);\n var k = tmp >> 52;\n var iz = ix - (tmp & (u64(0xFFF) << 52));\n\n var invc = load(LOG_DATA_TAB1 + (i << (1 + alignof())), 0 << alignof()); // T[i].invc;\n var logc = load(LOG_DATA_TAB1 + (i << (1 + alignof())), 1 << alignof()); // T[i].logc;\n var z = reinterpret(iz);\n\n // log(x) = log1p(z/c-1) + log(c) + k*Ln2.\n // r ~= z/c - 1, |r| < 1/(2*N)\n // #if __FP_FAST_FMA\n // \t// rounding error: 0x1p-55/N\n // \tr = __builtin_fma(z, invc, -1.0);\n // #else\n // rounding error: 0x1p-55/N + 0x1p-66\n const chi = load(LOG_DATA_TAB2 + (i << (1 + alignof())), 0 << alignof()); // T2[i].chi\n const clo = load(LOG_DATA_TAB2 + (i << (1 + alignof())), 1 << alignof()); // T2[i].clo\n var r = (z - chi - clo) * invc;\n // #endif\n var kd = k;\n\n // hi + lo = r + log(c) + k*Ln2\n var w = kd * Ln2hi + logc;\n var hi = w + r;\n var lo = w - hi + r + kd * Ln2lo;\n\n // log(x) = lo + (log1p(r) - r) + hi\n var r2 = r * r; // rounding error: 0x1p-54/N^2\n // Worst case error if |y| > 0x1p-5:\n // 0.5 + 4.13/N + abs-poly-error*2^57 ULP (+ 0.002 ULP without fma)\n // Worst case error if |y| > 0x1p-4:\n // 0.5 + 2.06/N + abs-poly-error*2^56 ULP (+ 0.001 ULP without fma).\n return lo + r2 * A0 + r * r2 * (A1 + r * A2 + r2 * (A3 + r * A4)) + hi;\n}\n\n//\n// Lookup data for pow. See: https://git.musl-libc.org/cgit/musl/tree/src/math/pow.c\n//\n\n// @ts-ignore: decorator\n@inline const POW_LOG_TABLE_BITS = 7;\n\n/* Algorithm:\n\n x = 2^k z\n log(x) = k ln2 + log(c) + log(z/c)\n log(z/c) = poly(z/c - 1)\n\nwhere z is in [0x1.69555p-1; 0x1.69555p0] which is split into N subintervals\nand z falls into the ith one, then table entries are computed as\n\n tab[i].invc = 1/c\n tab[i].logc = round(0x1p43*log(c))/0x1p43\n tab[i].logctail = (double)(log(c) - logc)\n\nwhere c is chosen near the center of the subinterval such that 1/c has only a\nfew precision bits so z/c - 1 is exactly representible as double:\n\n 1/c = center < 1 ? round(N/center)/N : round(2*N/center)/N/2\n\nNote: |z/c - 1| < 1/N for the chosen c, |log(c) - logc - logctail| < 0x1p-97,\nthe last few bits of logc are rounded away so k*ln2hi + logc has no rounding\nerror and the interval for z is selected such that near x == 1, where log(x)\nis tiny, large cancellation error is avoided in logc + poly(z/c - 1). */\n\n// @ts-ignore: decorator\n@lazy @inline const POW_LOG_DATA_TAB = memory.data([\n // invc ,pad, logc , logctail\n reinterpret(0x3FF6A00000000000), 0, reinterpret(0xBFD62C82F2B9C800), reinterpret(0x3CFAB42428375680),\n reinterpret(0x3FF6800000000000), 0, reinterpret(0xBFD5D1BDBF580800), reinterpret(0xBD1CA508D8E0F720),\n reinterpret(0x3FF6600000000000), 0, reinterpret(0xBFD5767717455800), reinterpret(0xBD2362A4D5B6506D),\n reinterpret(0x3FF6400000000000), 0, reinterpret(0xBFD51AAD872DF800), reinterpret(0xBCE684E49EB067D5),\n reinterpret(0x3FF6200000000000), 0, reinterpret(0xBFD4BE5F95777800), reinterpret(0xBD041B6993293EE0),\n reinterpret(0x3FF6000000000000), 0, reinterpret(0xBFD4618BC21C6000), reinterpret(0x3D13D82F484C84CC),\n reinterpret(0x3FF5E00000000000), 0, reinterpret(0xBFD404308686A800), reinterpret(0x3CDC42F3ED820B3A),\n reinterpret(0x3FF5C00000000000), 0, reinterpret(0xBFD3A64C55694800), reinterpret(0x3D20B1C686519460),\n reinterpret(0x3FF5A00000000000), 0, reinterpret(0xBFD347DD9A988000), reinterpret(0x3D25594DD4C58092),\n reinterpret(0x3FF5800000000000), 0, reinterpret(0xBFD2E8E2BAE12000), reinterpret(0x3D267B1E99B72BD8),\n reinterpret(0x3FF5600000000000), 0, reinterpret(0xBFD2895A13DE8800), reinterpret(0x3D15CA14B6CFB03F),\n reinterpret(0x3FF5600000000000), 0, reinterpret(0xBFD2895A13DE8800), reinterpret(0x3D15CA14B6CFB03F),\n reinterpret(0x3FF5400000000000), 0, reinterpret(0xBFD22941FBCF7800), reinterpret(0xBD165A242853DA76),\n reinterpret(0x3FF5200000000000), 0, reinterpret(0xBFD1C898C1699800), reinterpret(0xBD1FAFBC68E75404),\n reinterpret(0x3FF5000000000000), 0, reinterpret(0xBFD1675CABABA800), reinterpret(0x3D1F1FC63382A8F0),\n reinterpret(0x3FF4E00000000000), 0, reinterpret(0xBFD1058BF9AE4800), reinterpret(0xBD26A8C4FD055A66),\n reinterpret(0x3FF4C00000000000), 0, reinterpret(0xBFD0A324E2739000), reinterpret(0xBD0C6BEE7EF4030E),\n reinterpret(0x3FF4A00000000000), 0, reinterpret(0xBFD0402594B4D000), reinterpret(0xBCF036B89EF42D7F),\n reinterpret(0x3FF4A00000000000), 0, reinterpret(0xBFD0402594B4D000), reinterpret(0xBCF036B89EF42D7F),\n reinterpret(0x3FF4800000000000), 0, reinterpret(0xBFCFB9186D5E4000), reinterpret(0x3D0D572AAB993C87),\n reinterpret(0x3FF4600000000000), 0, reinterpret(0xBFCEF0ADCBDC6000), reinterpret(0x3D2B26B79C86AF24),\n reinterpret(0x3FF4400000000000), 0, reinterpret(0xBFCE27076E2AF000), reinterpret(0xBD172F4F543FFF10),\n reinterpret(0x3FF4200000000000), 0, reinterpret(0xBFCD5C216B4FC000), reinterpret(0x3D21BA91BBCA681B),\n reinterpret(0x3FF4000000000000), 0, reinterpret(0xBFCC8FF7C79AA000), reinterpret(0x3D27794F689F8434),\n reinterpret(0x3FF4000000000000), 0, reinterpret(0xBFCC8FF7C79AA000), reinterpret(0x3D27794F689F8434),\n reinterpret(0x3FF3E00000000000), 0, reinterpret(0xBFCBC286742D9000), reinterpret(0x3D194EB0318BB78F),\n reinterpret(0x3FF3C00000000000), 0, reinterpret(0xBFCAF3C94E80C000), reinterpret(0x3CBA4E633FCD9066),\n reinterpret(0x3FF3A00000000000), 0, reinterpret(0xBFCA23BC1FE2B000), reinterpret(0xBD258C64DC46C1EA),\n reinterpret(0x3FF3A00000000000), 0, reinterpret(0xBFCA23BC1FE2B000), reinterpret(0xBD258C64DC46C1EA),\n reinterpret(0x3FF3800000000000), 0, reinterpret(0xBFC9525A9CF45000), reinterpret(0xBD2AD1D904C1D4E3),\n reinterpret(0x3FF3600000000000), 0, reinterpret(0xBFC87FA06520D000), reinterpret(0x3D2BBDBF7FDBFA09),\n reinterpret(0x3FF3400000000000), 0, reinterpret(0xBFC7AB890210E000), reinterpret(0x3D2BDB9072534A58),\n reinterpret(0x3FF3400000000000), 0, reinterpret(0xBFC7AB890210E000), reinterpret(0x3D2BDB9072534A58),\n reinterpret(0x3FF3200000000000), 0, reinterpret(0xBFC6D60FE719D000), reinterpret(0xBD10E46AA3B2E266),\n reinterpret(0x3FF3000000000000), 0, reinterpret(0xBFC5FF3070A79000), reinterpret(0xBD1E9E439F105039),\n reinterpret(0x3FF3000000000000), 0, reinterpret(0xBFC5FF3070A79000), reinterpret(0xBD1E9E439F105039),\n reinterpret(0x3FF2E00000000000), 0, reinterpret(0xBFC526E5E3A1B000), reinterpret(0xBD20DE8B90075B8F),\n reinterpret(0x3FF2C00000000000), 0, reinterpret(0xBFC44D2B6CCB8000), reinterpret(0x3D170CC16135783C),\n reinterpret(0x3FF2C00000000000), 0, reinterpret(0xBFC44D2B6CCB8000), reinterpret(0x3D170CC16135783C),\n reinterpret(0x3FF2A00000000000), 0, reinterpret(0xBFC371FC201E9000), reinterpret(0x3CF178864D27543A),\n reinterpret(0x3FF2800000000000), 0, reinterpret(0xBFC29552F81FF000), reinterpret(0xBD248D301771C408),\n reinterpret(0x3FF2600000000000), 0, reinterpret(0xBFC1B72AD52F6000), reinterpret(0xBD2E80A41811A396),\n reinterpret(0x3FF2600000000000), 0, reinterpret(0xBFC1B72AD52F6000), reinterpret(0xBD2E80A41811A396),\n reinterpret(0x3FF2400000000000), 0, reinterpret(0xBFC0D77E7CD09000), reinterpret(0x3D0A699688E85BF4),\n reinterpret(0x3FF2400000000000), 0, reinterpret(0xBFC0D77E7CD09000), reinterpret(0x3D0A699688E85BF4),\n reinterpret(0x3FF2200000000000), 0, reinterpret(0xBFBFEC9131DBE000), reinterpret(0xBD2575545CA333F2),\n reinterpret(0x3FF2000000000000), 0, reinterpret(0xBFBE27076E2B0000), reinterpret(0x3D2A342C2AF0003C),\n reinterpret(0x3FF2000000000000), 0, reinterpret(0xBFBE27076E2B0000), reinterpret(0x3D2A342C2AF0003C),\n reinterpret(0x3FF1E00000000000), 0, reinterpret(0xBFBC5E548F5BC000), reinterpret(0xBD1D0C57585FBE06),\n reinterpret(0x3FF1C00000000000), 0, reinterpret(0xBFBA926D3A4AE000), reinterpret(0x3D253935E85BAAC8),\n reinterpret(0x3FF1C00000000000), 0, reinterpret(0xBFBA926D3A4AE000), reinterpret(0x3D253935E85BAAC8),\n reinterpret(0x3FF1A00000000000), 0, reinterpret(0xBFB8C345D631A000), reinterpret(0x3D137C294D2F5668),\n reinterpret(0x3FF1A00000000000), 0, reinterpret(0xBFB8C345D631A000), reinterpret(0x3D137C294D2F5668),\n reinterpret(0x3FF1800000000000), 0, reinterpret(0xBFB6F0D28AE56000), reinterpret(0xBD269737C93373DA),\n reinterpret(0x3FF1600000000000), 0, reinterpret(0xBFB51B073F062000), reinterpret(0x3D1F025B61C65E57),\n reinterpret(0x3FF1600000000000), 0, reinterpret(0xBFB51B073F062000), reinterpret(0x3D1F025B61C65E57),\n reinterpret(0x3FF1400000000000), 0, reinterpret(0xBFB341D7961BE000), reinterpret(0x3D2C5EDACCF913DF),\n reinterpret(0x3FF1400000000000), 0, reinterpret(0xBFB341D7961BE000), reinterpret(0x3D2C5EDACCF913DF),\n reinterpret(0x3FF1200000000000), 0, reinterpret(0xBFB16536EEA38000), reinterpret(0x3D147C5E768FA309),\n reinterpret(0x3FF1000000000000), 0, reinterpret(0xBFAF0A30C0118000), reinterpret(0x3D2D599E83368E91),\n reinterpret(0x3FF1000000000000), 0, reinterpret(0xBFAF0A30C0118000), reinterpret(0x3D2D599E83368E91),\n reinterpret(0x3FF0E00000000000), 0, reinterpret(0xBFAB42DD71198000), reinterpret(0x3D1C827AE5D6704C),\n reinterpret(0x3FF0E00000000000), 0, reinterpret(0xBFAB42DD71198000), reinterpret(0x3D1C827AE5D6704C),\n reinterpret(0x3FF0C00000000000), 0, reinterpret(0xBFA77458F632C000), reinterpret(0xBD2CFC4634F2A1EE),\n reinterpret(0x3FF0C00000000000), 0, reinterpret(0xBFA77458F632C000), reinterpret(0xBD2CFC4634F2A1EE),\n reinterpret(0x3FF0A00000000000), 0, reinterpret(0xBFA39E87B9FEC000), reinterpret(0x3CF502B7F526FEAA),\n reinterpret(0x3FF0A00000000000), 0, reinterpret(0xBFA39E87B9FEC000), reinterpret(0x3CF502B7F526FEAA),\n reinterpret(0x3FF0800000000000), 0, reinterpret(0xBF9F829B0E780000), reinterpret(0xBD2980267C7E09E4),\n reinterpret(0x3FF0800000000000), 0, reinterpret(0xBF9F829B0E780000), reinterpret(0xBD2980267C7E09E4),\n reinterpret(0x3FF0600000000000), 0, reinterpret(0xBF97B91B07D58000), reinterpret(0xBD288D5493FAA639),\n reinterpret(0x3FF0400000000000), 0, reinterpret(0xBF8FC0A8B0FC0000), reinterpret(0xBCDF1E7CF6D3A69C),\n reinterpret(0x3FF0400000000000), 0, reinterpret(0xBF8FC0A8B0FC0000), reinterpret(0xBCDF1E7CF6D3A69C),\n reinterpret(0x3FF0200000000000), 0, reinterpret(0xBF7FE02A6B100000), reinterpret(0xBD19E23F0DDA40E4),\n reinterpret(0x3FF0200000000000), 0, reinterpret(0xBF7FE02A6B100000), reinterpret(0xBD19E23F0DDA40E4),\n reinterpret(0x3FF0000000000000), 0, 0, 0,\n reinterpret(0x3FF0000000000000), 0, 0, 0,\n reinterpret(0x3FEFC00000000000), 0, reinterpret(0x3F80101575890000), reinterpret(0xBD10C76B999D2BE8),\n reinterpret(0x3FEF800000000000), 0, reinterpret(0x3F90205658938000), reinterpret(0xBD23DC5B06E2F7D2),\n reinterpret(0x3FEF400000000000), 0, reinterpret(0x3F98492528C90000), reinterpret(0xBD2AA0BA325A0C34),\n reinterpret(0x3FEF000000000000), 0, reinterpret(0x3FA0415D89E74000), reinterpret(0x3D0111C05CF1D753),\n reinterpret(0x3FEEC00000000000), 0, reinterpret(0x3FA466AED42E0000), reinterpret(0xBD2C167375BDFD28),\n reinterpret(0x3FEE800000000000), 0, reinterpret(0x3FA894AA149FC000), reinterpret(0xBD197995D05A267D),\n reinterpret(0x3FEE400000000000), 0, reinterpret(0x3FACCB73CDDDC000), reinterpret(0xBD1A68F247D82807),\n reinterpret(0x3FEE200000000000), 0, reinterpret(0x3FAEEA31C006C000), reinterpret(0xBD0E113E4FC93B7B),\n reinterpret(0x3FEDE00000000000), 0, reinterpret(0x3FB1973BD1466000), reinterpret(0xBD25325D560D9E9B),\n reinterpret(0x3FEDA00000000000), 0, reinterpret(0x3FB3BDF5A7D1E000), reinterpret(0x3D2CC85EA5DB4ED7),\n reinterpret(0x3FED600000000000), 0, reinterpret(0x3FB5E95A4D97A000), reinterpret(0xBD2C69063C5D1D1E),\n reinterpret(0x3FED400000000000), 0, reinterpret(0x3FB700D30AEAC000), reinterpret(0x3CEC1E8DA99DED32),\n reinterpret(0x3FED000000000000), 0, reinterpret(0x3FB9335E5D594000), reinterpret(0x3D23115C3ABD47DA),\n reinterpret(0x3FECC00000000000), 0, reinterpret(0x3FBB6AC88DAD6000), reinterpret(0xBD1390802BF768E5),\n reinterpret(0x3FECA00000000000), 0, reinterpret(0x3FBC885801BC4000), reinterpret(0x3D2646D1C65AACD3),\n reinterpret(0x3FEC600000000000), 0, reinterpret(0x3FBEC739830A2000), reinterpret(0xBD2DC068AFE645E0),\n reinterpret(0x3FEC400000000000), 0, reinterpret(0x3FBFE89139DBE000), reinterpret(0xBD2534D64FA10AFD),\n reinterpret(0x3FEC000000000000), 0, reinterpret(0x3FC1178E8227E000), reinterpret(0x3D21EF78CE2D07F2),\n reinterpret(0x3FEBE00000000000), 0, reinterpret(0x3FC1AA2B7E23F000), reinterpret(0x3D2CA78E44389934),\n reinterpret(0x3FEBA00000000000), 0, reinterpret(0x3FC2D1610C868000), reinterpret(0x3D039D6CCB81B4A1),\n reinterpret(0x3FEB800000000000), 0, reinterpret(0x3FC365FCB0159000), reinterpret(0x3CC62FA8234B7289),\n reinterpret(0x3FEB400000000000), 0, reinterpret(0x3FC4913D8333B000), reinterpret(0x3D25837954FDB678),\n reinterpret(0x3FEB200000000000), 0, reinterpret(0x3FC527E5E4A1B000), reinterpret(0x3D2633E8E5697DC7),\n reinterpret(0x3FEAE00000000000), 0, reinterpret(0x3FC6574EBE8C1000), reinterpret(0x3D19CF8B2C3C2E78),\n reinterpret(0x3FEAC00000000000), 0, reinterpret(0x3FC6F0128B757000), reinterpret(0xBD25118DE59C21E1),\n reinterpret(0x3FEAA00000000000), 0, reinterpret(0x3FC7898D85445000), reinterpret(0xBD1C661070914305),\n reinterpret(0x3FEA600000000000), 0, reinterpret(0x3FC8BEAFEB390000), reinterpret(0xBD073D54AAE92CD1),\n reinterpret(0x3FEA400000000000), 0, reinterpret(0x3FC95A5ADCF70000), reinterpret(0x3D07F22858A0FF6F),\n reinterpret(0x3FEA000000000000), 0, reinterpret(0x3FCA93ED3C8AE000), reinterpret(0xBD28724350562169),\n reinterpret(0x3FE9E00000000000), 0, reinterpret(0x3FCB31D8575BD000), reinterpret(0xBD0C358D4EACE1AA),\n reinterpret(0x3FE9C00000000000), 0, reinterpret(0x3FCBD087383BE000), reinterpret(0xBD2D4BC4595412B6),\n reinterpret(0x3FE9A00000000000), 0, reinterpret(0x3FCC6FFBC6F01000), reinterpret(0xBCF1EC72C5962BD2),\n reinterpret(0x3FE9600000000000), 0, reinterpret(0x3FCDB13DB0D49000), reinterpret(0xBD2AFF2AF715B035),\n reinterpret(0x3FE9400000000000), 0, reinterpret(0x3FCE530EFFE71000), reinterpret(0x3CC212276041F430),\n reinterpret(0x3FE9200000000000), 0, reinterpret(0x3FCEF5ADE4DD0000), reinterpret(0xBCCA211565BB8E11),\n reinterpret(0x3FE9000000000000), 0, reinterpret(0x3FCF991C6CB3B000), reinterpret(0x3D1BCBECCA0CDF30),\n reinterpret(0x3FE8C00000000000), 0, reinterpret(0x3FD07138604D5800), reinterpret(0x3CF89CDB16ED4E91),\n reinterpret(0x3FE8A00000000000), 0, reinterpret(0x3FD0C42D67616000), reinterpret(0x3D27188B163CEAE9),\n reinterpret(0x3FE8800000000000), 0, reinterpret(0x3FD1178E8227E800), reinterpret(0xBD2C210E63A5F01C),\n reinterpret(0x3FE8600000000000), 0, reinterpret(0x3FD16B5CCBACF800), reinterpret(0x3D2B9ACDF7A51681),\n reinterpret(0x3FE8400000000000), 0, reinterpret(0x3FD1BF99635A6800), reinterpret(0x3D2CA6ED5147BDB7),\n reinterpret(0x3FE8200000000000), 0, reinterpret(0x3FD214456D0EB800), reinterpret(0x3D0A87DEBA46BAEA),\n reinterpret(0x3FE7E00000000000), 0, reinterpret(0x3FD2BEF07CDC9000), reinterpret(0x3D2A9CFA4A5004F4),\n reinterpret(0x3FE7C00000000000), 0, reinterpret(0x3FD314F1E1D36000), reinterpret(0xBD28E27AD3213CB8),\n reinterpret(0x3FE7A00000000000), 0, reinterpret(0x3FD36B6776BE1000), reinterpret(0x3D116ECDB0F177C8),\n reinterpret(0x3FE7800000000000), 0, reinterpret(0x3FD3C25277333000), reinterpret(0x3D183B54B606BD5C),\n reinterpret(0x3FE7600000000000), 0, reinterpret(0x3FD419B423D5E800), reinterpret(0x3D08E436EC90E09D),\n reinterpret(0x3FE7400000000000), 0, reinterpret(0x3FD4718DC271C800), reinterpret(0xBD2F27CE0967D675),\n reinterpret(0x3FE7200000000000), 0, reinterpret(0x3FD4C9E09E173000), reinterpret(0xBD2E20891B0AD8A4),\n reinterpret(0x3FE7000000000000), 0, reinterpret(0x3FD522AE0738A000), reinterpret(0x3D2EBE708164C759),\n reinterpret(0x3FE6E00000000000), 0, reinterpret(0x3FD57BF753C8D000), reinterpret(0x3D1FADEDEE5D40EF),\n reinterpret(0x3FE6C00000000000), 0, reinterpret(0x3FD5D5BDDF596000), reinterpret(0xBD0A0B2A08A465DC)\n]);\n\n// Returns 0 if not int, 1 if odd int, 2 if even int. The argument is\n// the bit representation of a non-zero finite floating-point value.\n// @ts-ignore: decorator\n@inline\nfunction checkint(iy: u64): i32 {\n var e = iy >> 52 & 0x7FF;\n if (e < 0x3FF ) return 0;\n if (e > 0x3FF + 52) return 2;\n e = u64(1) << (0x3FF + 52 - e);\n if (iy & (e - 1)) return 0;\n if (iy & e ) return 1;\n return 2;\n}\n\n// @ts-ignore: decorator\n@inline\nfunction xflow(sign: u32, y: f64): f64 {\n return select(-y, y, sign) * y;\n}\n\n// @ts-ignore: decorator\n@inline\nfunction uflow(sign: u32): f64 {\n return xflow(sign, reinterpret(0x1000000000000000)); // 0x1p-767\n}\n\n// @ts-ignore: decorator\n@inline\nfunction oflow(sign: u32): f64 {\n return xflow(sign, reinterpret(0x7000000000000000)); // 0x1p769\n}\n\n// Returns 1 if input is the bit representation of 0, infinity or nan.\n// @ts-ignore: decorator\n@inline\nfunction zeroinfnan(u: u64): bool {\n return (u << 1) - 1 >= 0xFFE0000000000000 - 1;\n}\n\n// @ts-ignore: decorator\n@lazy var log_tail: f64 = 0;\n\n// Compute y+TAIL = log(x) where the rounded result is y and TAIL has about\n// additional 15 bits precision. IX is the bit representation of x, but\n// normalized in the subnormal range using the sign bit for the exponent.\n// @ts-ignore: decorator\n@inline\nfunction log_inline(ix: u64): f64 {\n const N = 1 << POW_LOG_TABLE_BITS;\n const N_MASK = N - 1;\n\n const\n Ln2hi = reinterpret(0x3FE62E42FEFA3800),\n Ln2lo = reinterpret(0x3D2EF35793C76730);\n\n const\n A0 = reinterpret(0xBFE0000000000000),\n A1 = reinterpret(0xBFE5555555555560),\n A2 = reinterpret(0x3FE0000000000006),\n A3 = reinterpret(0x3FE999999959554E),\n A4 = reinterpret(0xBFE555555529A47A),\n A5 = reinterpret(0xBFF2495B9B4845E9),\n A6 = reinterpret(0x3FF0002B8B263FC3);\n\n // x = 2^k z; where z is in range [OFF,2*OFF) and exact.\n // The range is split into N subintervals.\n // The ith subinterval contains z and c is near its center.\n var tmp = ix - 0x3fE6955500000000;\n var i = usize((tmp >> (52 - POW_LOG_TABLE_BITS)) & N_MASK);\n var k = tmp >> 52;\n var iz = ix - (tmp & u64(0xFFF) << 52);\n var z = reinterpret(iz);\n var kd = k;\n\n // log(x) = k*Ln2 + log(c) + log1p(z/c-1).\n var invc = load(POW_LOG_DATA_TAB + (i << (2 + alignof())), 0 << alignof()); // tab[i].invc\n var logc = load(POW_LOG_DATA_TAB + (i << (2 + alignof())), 2 << alignof()); // tab[i].logc\n var logctail = load(POW_LOG_DATA_TAB + (i << (2 + alignof())), 3 << alignof()); // tab[i].logctail\n\n // Note: 1/c is j/N or j/N/2 where j is an integer in [N,2N) and\n // |z/c - 1| < 1/N, so r = z/c - 1 is exactly representible.\n // Split z such that rhi, rlo and rhi*rhi are exact and |rlo| <= |r|.\n var zhi = reinterpret((iz + u64(0x80000000)) & 0xFFFFFFFF00000000);\n var zlo = z - zhi;\n var rhi = zhi * invc - 1.0;\n var rlo = zlo * invc;\n var r = rhi + rlo;\n\n // k * Ln2 + log(c) + r.\n var t1 = kd * Ln2hi + logc;\n var t2 = t1 + r;\n var lo1 = kd * Ln2lo + logctail;\n var lo2 = t1 - t2 + r;\n\n // Evaluation is optimized assuming superscalar pipelined execution.\n var ar = A0 * r; // A[0] = -0.5\n var ar2 = r * ar;\n var ar3 = r * ar2;\n // k * Ln2 + log(c) + r + A[0] * r * r.\n var arhi = A0 * rhi;\n var arhi2 = rhi * arhi;\n var hi = t2 + arhi2;\n var lo3 = rlo * (ar + arhi);\n var lo4 = t2 - hi + arhi2;\n\n // p = log1p(r) - r - A[0] * r * r.\n var p = ar3 * (A1 + r * A2 + ar2 * (A3 + r * A4 + ar2 * (A5 + r * A6)));\n var lo = lo1 + lo2 + lo3 + lo4 + p;\n var y = hi + lo;\n log_tail = hi - y + lo;\n\n return y;\n}\n\n// @ts-ignore: decorator\n@inline const SIGN_BIAS = 0x800 << EXP_TABLE_BITS;\n\n// Computes sign*exp(x+xtail) where |xtail| < 2^-8/N and |xtail| <= |x|.\n// The sign_bias argument is SIGN_BIAS or 0 and sets the sign to -1 or 1.\n// @ts-ignore: decorator\n@inline\nfunction exp_inline(x: f64, xtail: f64, sign_bias: u32): f64 {\n const N = 1 << EXP_TABLE_BITS;\n const N_MASK = N - 1;\n\n const\n InvLn2N = reinterpret(0x3FF71547652B82FE) * N, // 0x1.71547652b82fep0\n NegLn2hiN = reinterpret(0xBF762E42FEFA0000), // -0x1.62e42fefa0000p-8\n NegLn2loN = reinterpret(0xBD0CF79ABC9E3B3A), // -0x1.cf79abc9e3b3ap-47\n shift = reinterpret(0x4338000000000000); // 0x1.8p52\n\n const\n C2 = reinterpret(0x3FDFFFFFFFFFFDBD), // __exp_data.poly[0] (0x1.ffffffffffdbdp-2)\n C3 = reinterpret(0x3FC555555555543C), // __exp_data.poly[1] (0x1.555555555543cp-3)\n C4 = reinterpret(0x3FA55555CF172B91), // __exp_data.poly[2] (0x1.55555cf172b91p-5)\n C5 = reinterpret(0x3F81111167A4D017); // __exp_data.poly[3] (0x1.1111167a4d017p-7)\n\n var abstop: u32;\n var ki: u64, top: u64, sbits: u64;\n var idx: usize;\n // double_t for better performance on targets with FLT_EVAL_METHOD==2.\n var kd: f64, z: f64, r: f64, r2: f64, scale: f64, tail: f64, tmp: f64;\n\n var ux = reinterpret(x);\n abstop = u32(ux >> 52) & 0x7FF;\n if (abstop - 0x3C9 >= 0x03F) {\n if (abstop - 0x3C9 >= 0x80000000) {\n // Avoid spurious underflow for tiny x.\n // Note: 0 is common input.\n return select(-1.0, 1.0, sign_bias);\n }\n if (abstop >= 0x409) { // top12(1024.0)\n // Note: inf and nan are already handled.\n return ux < 0\n ? uflow(sign_bias)\n : oflow(sign_bias);\n }\n // Large x is special cased below.\n abstop = 0;\n }\n\n // exp(x) = 2^(k/N) * exp(r), with exp(r) in [2^(-1/2N),2^(1/2N)].\n // x = ln2/N*k + r, with int k and r in [-ln2/2N, ln2/2N].\n z = InvLn2N * x;\n\n // #if TOINT_INTRINSICS\n // kd = roundtoint(z);\n // ki = converttoint(z);\n // #elif EXP_USE_TOINT_NARROW\n // // z - kd is in [-0.5-2^-16, 0.5] in all rounding modes.\n // kd = eval_as_double(z + shift);\n // ki = asuint64(kd) >> 16;\n // kd = (double_t)(int32_t)ki;\n // #else\n // z - kd is in [-1, 1] in non-nearest rounding modes\n kd = z + shift;\n ki = reinterpret(kd);\n kd -= shift;\n // #endif\n r = x + kd * NegLn2hiN + kd * NegLn2loN;\n // The code assumes 2^-200 < |xtail| < 2^-8/N\n r += xtail;\n // 2^(k/N) ~= scale * (1 + tail)\n idx = usize((ki & N_MASK) << 1);\n top = (ki + sign_bias) << (52 - EXP_TABLE_BITS);\n\n tail = reinterpret(load(EXP_DATA_TAB + (idx << alignof())));\n // This is only a valid scale when -1023*N < k < 1024*N\n sbits = load(EXP_DATA_TAB + (idx << alignof()), 1 << alignof()) + top;\n // exp(x) = 2^(k/N) * exp(r) ~= scale + scale * (tail + exp(r) - 1).\n // Evaluation is optimized assuming superscalar pipelined execution.\n r2 = r * r;\n // Without fma the worst case error is 0.25/N ulp larger.\n // Worst case error is less than 0.5+1.11/N+(abs poly error * 2^53) ulp\n tmp = tail + r + r2 * (C2 + r * C3) + r2 * r2 * (C4 + r * C5);\n if (abstop == 0) return specialcase(tmp, sbits, ki);\n scale = reinterpret(sbits);\n // Note: tmp == 0 or |tmp| > 2^-200 and scale > 2^-739, so there\n // is no spurious underflow here even without fma.\n return scale + scale * tmp;\n}\n\n// @ts-ignore: decorator\n@inline\nexport function pow_lut(x: f64, y: f64): f64 {\n const Ox1p52 = reinterpret(0x4330000000000000); // 0x1p52\n\n var sign_bias: u32 = 0;\n var ix = reinterpret(x);\n var iy = reinterpret(y);\n var topx = ix >> 52;\n var topy = iy >> 52;\n\n if (topx - 0x001 >= 0x7FF - 0x001 || (topy & 0x7FF) - 0x3BE >= 0x43e - 0x3BE) {\n // Note: if |y| > 1075 * ln2 * 2^53 ~= 0x1.749p62 then pow(x,y) = inf/0\n // and if |y| < 2^-54 / 1075 ~= 0x1.e7b6p-65 then pow(x,y) = +-1.\n // Special cases: (x < 0x1p-126 or inf or nan) or\n // (|y| < 0x1p-65 or |y| >= 0x1p63 or nan).\n if (zeroinfnan(iy)) {\n if ((iy << 1) == 0) return 1.0;\n if (ix == 0x3FF0000000000000) return NaN; // original: 1.0\n if ((ix << 1) > 0xFFE0000000000000 || (iy << 1) > 0xFFE0000000000000) return x + y;\n if ((ix << 1) == 0x7FE0000000000000) return NaN; // original: 1.0\n if (((ix << 1) < 0x7FE0000000000000) == !(iy >> 63)) return 0; // |x|<1 && y==inf or |x|>1 && y==-inf.\n return y * y;\n }\n if (zeroinfnan(ix)) {\n let x2 = x * x;\n if (i32(ix >> 63) && checkint(iy) == 1) x2 = -x2;\n return iy < 0 ? 1 / x2 : x2;\n }\n // Here x and y are non-zero finite\n if (ix < 0) {\n // Finite x < 0\n let yint = checkint(iy);\n if (yint == 0) return (x - x) / (x - x);\n if (yint == 1) sign_bias = SIGN_BIAS;\n ix &= 0x7FFFFFFFFFFFFFFF;\n topx &= 0x7FF;\n }\n if ((topy & 0x7FF) - 0x3BE >= 0x43E - 0x3BE) {\n // Note: sign_bias == 0 here because y is not odd.\n if (ix == 0x3FF0000000000000) return 1;\n if ((topy & 0x7FF) < 0x3BE) return 1; // |y| < 2^-65, x^y ~= 1 + y*log(x).\n return (ix > 0x3FF0000000000000) == (topy < 0x800) ? Infinity : 0;\n }\n if (topx == 0) {\n // Normalize subnormal x so exponent becomes negative.\n ix = reinterpret(x * Ox1p52);\n ix &= 0x7FFFFFFFFFFFFFFF;\n ix -= u64(52) << 52;\n }\n }\n\n var hi = log_inline(ix);\n var lo = log_tail;\n var ehi: f64, elo: f64;\n // #if __FP_FAST_FMA\n // ehi = y * hi;\n // elo = y * lo + __builtin_fma(y, hi, -ehi);\n // #else\n var yhi = reinterpret(iy & 0xFFFFFFFFF8000000);\n var ylo = y - yhi;\n var lhi = reinterpret(reinterpret(hi) & 0xFFFFFFFFF8000000);\n var llo = hi - lhi + lo;\n ehi = yhi * lhi;\n elo = ylo * lhi + y * llo; // |elo| < |ehi| * 2^-25.\n // #endif\n return exp_inline(ehi, elo, sign_bias);\n}\n","/// \n\nimport { idof } from \"../builtins\";\nimport { CharCode } from \"./string\";\n\n// @ts-ignore: decorator\n@inline\nexport const MAX_DOUBLE_LENGTH = 28;\n\n// @ts-ignore: decorator\n@lazy @inline const POWERS10 = memory.data([\n 1,\n 10,\n 100,\n 1000,\n 10000,\n 100000,\n 1000000,\n 10000000,\n 100000000,\n 1000000000\n]);\n\n/*\n Lookup table for pairwise char codes in range [0-99]\n\n \"00\", \"01\", \"02\", \"03\", \"04\", \"05\", \"06\", \"07\", \"08\", \"09\",\n \"10\", \"11\", \"12\", \"13\", \"14\", \"15\", \"16\", \"17\", \"18\", \"19\",\n \"20\", \"21\", \"22\", \"23\", \"24\", \"25\", \"26\", \"27\", \"28\", \"29\",\n \"30\", \"31\", \"32\", \"33\", \"34\", \"35\", \"36\", \"37\", \"38\", \"39\",\n \"40\", \"41\", \"42\", \"43\", \"44\", \"45\", \"46\", \"47\", \"48\", \"49\",\n \"50\", \"51\", \"52\", \"53\", \"54\", \"55\", \"56\", \"57\", \"58\", \"59\",\n \"60\", \"61\", \"62\", \"63\", \"64\", \"65\", \"66\", \"67\", \"68\", \"69\",\n \"70\", \"71\", \"72\", \"73\", \"74\", \"75\", \"76\", \"77\", \"78\", \"79\",\n \"80\", \"81\", \"82\", \"83\", \"84\", \"85\", \"86\", \"87\", \"88\", \"89\",\n \"90\", \"91\", \"92\", \"93\", \"94\", \"95\", \"96\", \"97\", \"98\", \"99\"\n*/\n// @ts-ignore: decorator\n@lazy @inline const DIGITS = memory.data([\n 0x00300030, 0x00310030, 0x00320030, 0x00330030, 0x00340030,\n 0x00350030, 0x00360030, 0x00370030, 0x00380030, 0x00390030,\n 0x00300031, 0x00310031, 0x00320031, 0x00330031, 0x00340031,\n 0x00350031, 0x00360031, 0x00370031, 0x00380031, 0x00390031,\n 0x00300032, 0x00310032, 0x00320032, 0x00330032, 0x00340032,\n 0x00350032, 0x00360032, 0x00370032, 0x00380032, 0x00390032,\n 0x00300033, 0x00310033, 0x00320033, 0x00330033, 0x00340033,\n 0x00350033, 0x00360033, 0x00370033, 0x00380033, 0x00390033,\n 0x00300034, 0x00310034, 0x00320034, 0x00330034, 0x00340034,\n 0x00350034, 0x00360034, 0x00370034, 0x00380034, 0x00390034,\n 0x00300035, 0x00310035, 0x00320035, 0x00330035, 0x00340035,\n 0x00350035, 0x00360035, 0x00370035, 0x00380035, 0x00390035,\n 0x00300036, 0x00310036, 0x00320036, 0x00330036, 0x00340036,\n 0x00350036, 0x00360036, 0x00370036, 0x00380036, 0x00390036,\n 0x00300037, 0x00310037, 0x00320037, 0x00330037, 0x00340037,\n 0x00350037, 0x00360037, 0x00370037, 0x00380037, 0x00390037,\n 0x00300038, 0x00310038, 0x00320038, 0x00330038, 0x00340038,\n 0x00350038, 0x00360038, 0x00370038, 0x00380038, 0x00390038,\n 0x00300039, 0x00310039, 0x00320039, 0x00330039, 0x00340039,\n 0x00350039, 0x00360039, 0x00370039, 0x00380039, 0x00390039\n]);\n\n// Lookup table for pairwise char codes in range [0x00-0xFF]\n// @ts-ignore: decorator\n@lazy @inline const HEX_DIGITS =\n\"000102030405060708090a0b0c0d0e0f\\\n101112131415161718191a1b1c1d1e1f\\\n202122232425262728292a2b2c2d2e2f\\\n303132333435363738393a3b3c3d3e3f\\\n404142434445464748494a4b4c4d4e4f\\\n505152535455565758595a5b5c5d5e5f\\\n606162636465666768696a6b6c6d6e6f\\\n707172737475767778797a7b7c7d7e7f\\\n808182838485868788898a8b8c8d8e8f\\\n909192939495969798999a9b9c9d9e9f\\\na0a1a2a3a4a5a6a7a8a9aaabacadaeaf\\\nb0b1b2b3b4b5b6b7b8b9babbbcbdbebf\\\nc0c1c2c3c4c5c6c7c8c9cacbcccdcecf\\\nd0d1d2d3d4d5d6d7d8d9dadbdcdddedf\\\ne0e1e2e3e4e5e6e7e8e9eaebecedeeef\\\nf0f1f2f3f4f5f6f7f8f9fafbfcfdfeff\";\n\n// @ts-ignore: decorator\n@lazy @inline const ANY_DIGITS = \"0123456789abcdefghijklmnopqrstuvwxyz\";\n\n// @ts-ignore: decorator\n@lazy @inline const EXP_POWERS = memory.data([/* eslint-disable indent */\n -1220, -1193, -1166, -1140, -1113, -1087, -1060, -1034, -1007, -980,\n -954, -927, -901, -874, -847, -821, -794, -768, -741, -715,\n -688, -661, -635, -608, -582, -555, -529, -502, -475, -449,\n -422, -396, -369, -343, -316, -289, -263, -236, -210, -183,\n -157, -130, -103, -77, -50, -24, 3, 30, 56, 83,\n 109, 136, 162, 189, 216, 242, 269, 295, 322, 348,\n 375, 402, 428, 455, 481, 508, 534, 561, 588, 614,\n 641, 667, 694, 720, 747, 774, 800, 827, 853, 880,\n 907, 933, 960, 986, 1013, 1039, 1066\n/* eslint-enable indent */]);\n\n// 1e-348, 1e-340, ..., 1e340\n// @ts-ignore: decorator\n@lazy @inline const FRC_POWERS = memory.data([\n 0xFA8FD5A0081C0288, 0xBAAEE17FA23EBF76, 0x8B16FB203055AC76, 0xCF42894A5DCE35EA,\n 0x9A6BB0AA55653B2D, 0xE61ACF033D1A45DF, 0xAB70FE17C79AC6CA, 0xFF77B1FCBEBCDC4F,\n 0xBE5691EF416BD60C, 0x8DD01FAD907FFC3C, 0xD3515C2831559A83, 0x9D71AC8FADA6C9B5,\n 0xEA9C227723EE8BCB, 0xAECC49914078536D, 0x823C12795DB6CE57, 0xC21094364DFB5637,\n 0x9096EA6F3848984F, 0xD77485CB25823AC7, 0xA086CFCD97BF97F4, 0xEF340A98172AACE5,\n 0xB23867FB2A35B28E, 0x84C8D4DFD2C63F3B, 0xC5DD44271AD3CDBA, 0x936B9FCEBB25C996,\n 0xDBAC6C247D62A584, 0xA3AB66580D5FDAF6, 0xF3E2F893DEC3F126, 0xB5B5ADA8AAFF80B8,\n 0x87625F056C7C4A8B, 0xC9BCFF6034C13053, 0x964E858C91BA2655, 0xDFF9772470297EBD,\n 0xA6DFBD9FB8E5B88F, 0xF8A95FCF88747D94, 0xB94470938FA89BCF, 0x8A08F0F8BF0F156B,\n 0xCDB02555653131B6, 0x993FE2C6D07B7FAC, 0xE45C10C42A2B3B06, 0xAA242499697392D3,\n 0xFD87B5F28300CA0E, 0xBCE5086492111AEB, 0x8CBCCC096F5088CC, 0xD1B71758E219652C,\n 0x9C40000000000000, 0xE8D4A51000000000, 0xAD78EBC5AC620000, 0x813F3978F8940984,\n 0xC097CE7BC90715B3, 0x8F7E32CE7BEA5C70, 0xD5D238A4ABE98068, 0x9F4F2726179A2245,\n 0xED63A231D4C4FB27, 0xB0DE65388CC8ADA8, 0x83C7088E1AAB65DB, 0xC45D1DF942711D9A,\n 0x924D692CA61BE758, 0xDA01EE641A708DEA, 0xA26DA3999AEF774A, 0xF209787BB47D6B85,\n 0xB454E4A179DD1877, 0x865B86925B9BC5C2, 0xC83553C5C8965D3D, 0x952AB45CFA97A0B3,\n 0xDE469FBD99A05FE3, 0xA59BC234DB398C25, 0xF6C69A72A3989F5C, 0xB7DCBF5354E9BECE,\n 0x88FCF317F22241E2, 0xCC20CE9BD35C78A5, 0x98165AF37B2153DF, 0xE2A0B5DC971F303A,\n 0xA8D9D1535CE3B396, 0xFB9B7CD9A4A7443C, 0xBB764C4CA7A44410, 0x8BAB8EEFB6409C1A,\n 0xD01FEF10A657842C, 0x9B10A4E5E9913129, 0xE7109BFBA19C0C9D, 0xAC2820D9623BF429,\n 0x80444B5E7AA7CF85, 0xBF21E44003ACDD2D, 0x8E679C2F5E44FF8F, 0xD433179D9C8CB841,\n 0x9E19DB92B4E31BA9, 0xEB96BF6EBADF77D9, 0xAF87023B9BF0EE6B\n]);\n\n// @ts-ignore: decorator\n@inline\nexport function isPowerOf2(value: T): bool {\n return popcnt(value) == 1;\n}\n\n// Count number of decimals for u32 values\n// In our case input value always non-zero so we can simplify some parts\nexport function decimalCount32(value: u32): u32 {\n if (value < 100000) {\n if (value < 100) {\n return 1 + u32(value >= 10);\n } else {\n return 3 + u32(value >= 10000) + u32(value >= 1000);\n }\n } else {\n if (value < 10000000) {\n return 6 + u32(value >= 1000000);\n } else {\n return 8 + u32(value >= 1000000000) + u32(value >= 100000000);\n }\n }\n}\n\n// Count number of decimals for u64 values\n// In our case input value always greater than 2^32-1 so we can skip some parts\nexport function decimalCount64High(value: u64): u32 {\n if (value < 1000000000000000) {\n if (value < 1000000000000) {\n return 10 + u32(value >= 100000000000) + u32(value >= 10000000000);\n } else {\n return 13 + u32(value >= 100000000000000) + u32(value >= 10000000000000);\n }\n } else {\n if (value < 100000000000000000) {\n return 16 + u32(value >= 10000000000000000);\n } else {\n return 18 + u32(value >= 10000000000000000000) + u32(value >= 1000000000000000000);\n }\n }\n}\n\nfunction ulog_base(num: u64, base: i32): u32 {\n if (isPowerOf2(base)) {\n return (63 - clz(num)) / (31 - clz(base)) + 1;\n }\n var b64 = u64(base), b = b64, e: u32 = 1;\n while (num >= b) {\n num /= b;\n b *= b;\n e <<= 1;\n }\n while (num >= 1) {\n num /= b64;\n e++;\n }\n return e - 1;\n}\n\nfunction utoa32_dec_lut(buffer: usize, num: u32, offset: usize): void {\n while (num >= 10000) {\n // in most VMs i32/u32 div and modulo by constant can be shared and simplificate\n let t = num / 10000;\n let r = num % 10000;\n num = t;\n\n let d1 = r / 100;\n let d2 = r % 100;\n\n let digits1 = load(DIGITS + (d1 << alignof()));\n let digits2 = load(DIGITS + (d2 << alignof()));\n\n offset -= 4;\n store(buffer + (offset << 1), digits1 | (digits2 << 32));\n }\n\n if (num >= 100) {\n let t = num / 100;\n let d1 = num % 100;\n num = t;\n offset -= 2;\n let digits = load(DIGITS + (d1 << alignof()));\n store(buffer + (offset << 1), digits);\n }\n\n if (num >= 10) {\n offset -= 2;\n let digits = load(DIGITS + (num << alignof()));\n store(buffer + (offset << 1), digits);\n } else {\n offset -= 1;\n let digit = CharCode._0 + num;\n store(buffer + (offset << 1), digit);\n }\n}\n\nfunction utoa64_dec_lut(buffer: usize, num: u64, offset: usize): void {\n while (num >= 100000000) {\n let t = num / 100000000;\n let r = (num - t * 100000000);\n num = t;\n\n let b = r / 10000;\n let c = r % 10000;\n\n let b1 = b / 100;\n let b2 = b % 100;\n let c1 = c / 100;\n let c2 = c % 100;\n\n let digits1 = load(DIGITS + (c1 << alignof()));\n let digits2 = load(DIGITS + (c2 << alignof()));\n\n offset -= 4;\n store(buffer + (offset << 1), digits1 | (digits2 << 32));\n\n digits1 = load(DIGITS + (b1 << alignof()));\n digits2 = load(DIGITS + (b2 << alignof()));\n\n offset -= 4;\n store(buffer + (offset << 1), digits1 | (digits2 << 32));\n }\n\n utoa32_dec_lut(buffer, num, offset);\n}\n\nfunction utoa_hex_lut(buffer: usize, num: u64, offset: usize): void {\n const lut = changetype(HEX_DIGITS);\n while (offset >= 2) {\n offset -= 2;\n store(\n buffer + (offset << 1),\n load(lut + ((num & 0xFF) << alignof()))\n );\n num >>= 8;\n }\n if (offset & 1) {\n store(buffer, load(lut + (num << 6)));\n }\n}\n\nfunction utoa_dec_simple(buffer: usize, num: T, offset: usize): void {\n do {\n let t = num / 10;\n let r = (num % 10);\n num = changetype(t);\n offset--;\n store(buffer + (offset << 1), CharCode._0 + r);\n } while (num);\n}\n\nfunction utoa_hex_simple(buffer: usize, num: T, offset: usize): void {\n do {\n let d = num & 0x0F | CharCode._0;\n d += select(0x27, 0, d > CharCode._9);\n offset--;\n store(buffer + (offset << 1), d);\n // @ts-ignore: type\n num >>= 4;\n } while (num);\n}\n\n// @ts-ignore: decorator\n@inline\nexport function utoa32_dec_core(buffer: usize, num: u32, offset: usize): void {\n if (ASC_SHRINK_LEVEL >= 1) {\n utoa_dec_simple(buffer, num, offset);\n } else {\n utoa32_dec_lut(buffer, num, offset);\n }\n}\n\n// @ts-ignore: decorator\n@inline\nfunction utoa32_hex_core(buffer: usize, num: u32, offset: usize): void {\n if (ASC_SHRINK_LEVEL >= 1) {\n utoa_hex_simple(buffer, num, offset);\n } else {\n utoa_hex_lut(buffer, num, offset);\n }\n}\n\n// @ts-ignore: decorator\n@inline\nfunction utoa64_dec_core(buffer: usize, num: u64, offset: usize): void {\n if (ASC_SHRINK_LEVEL >= 1) {\n utoa_dec_simple(buffer, num, offset);\n } else {\n utoa64_dec_lut(buffer, num, offset);\n }\n}\n\n// @ts-ignore: decorator\n@inline\nfunction utoa64_hex_core(buffer: usize, num: u64, offset: usize): void {\n if (ASC_SHRINK_LEVEL >= 1) {\n utoa_hex_simple(buffer, num, offset);\n } else {\n utoa_hex_lut(buffer, num, offset);\n }\n}\n\nfunction utoa64_any_core(buffer: usize, num: u64, offset: usize, radix: i32): void {\n const lut = changetype(ANY_DIGITS);\n var base = u64(radix);\n if ((radix & (radix - 1)) == 0) { // for radix which pow of two\n let shift = u64(ctz(radix) & 7);\n let mask = base - 1;\n do {\n offset--;\n store(buffer + (offset << 1), load(lut + (usize(num & mask) << 1)));\n num >>= shift;\n } while (num);\n } else {\n do {\n offset--;\n let q = num / base;\n store(buffer + (offset << 1), load(lut + (usize(num - q * base) << 1)));\n num = q;\n } while (num);\n }\n}\n\nexport function utoa32(value: u32, radix: i32): String {\n if (radix < 2 || radix > 36) {\n throw new RangeError(\"toString() radix argument must be between 2 and 36\");\n }\n if (!value) return \"0\";\n var out: String;\n\n if (radix == 10) {\n let decimals = decimalCount32(value);\n out = changetype(__new(decimals << 1, idof()));\n utoa32_dec_core(changetype(out), value, decimals);\n } else if (radix == 16) {\n let decimals = (31 - clz(value) >> 2) + 1;\n out = changetype(__new(decimals << 1, idof()));\n utoa32_hex_core(changetype(out), value, decimals);\n } else {\n let decimals = ulog_base(value, radix);\n out = changetype(__new(decimals << 1, idof()));\n utoa64_any_core(changetype(out), value, decimals, radix);\n }\n return out;\n}\n\nexport function itoa32(value: i32, radix: i32): String {\n if (radix < 2 || radix > 36) {\n throw new RangeError(\"toString() radix argument must be between 2 and 36\");\n }\n if (!value) return \"0\";\n\n var sign = (value >>> 31) << 1;\n if (sign) value = -value;\n var out: String;\n\n if (radix == 10) {\n let decimals = decimalCount32(value);\n out = changetype(__new((decimals << 1) + sign, idof()));\n utoa32_dec_core(changetype(out) + sign, value, decimals);\n } else if (radix == 16) {\n let decimals = (31 - clz(value) >> 2) + 1;\n out = changetype(__new((decimals << 1) + sign, idof()));\n utoa32_hex_core(changetype(out) + sign, value, decimals);\n } else {\n let val32 = u32(value);\n let decimals = ulog_base(val32, radix);\n out = changetype(__new((decimals << 1) + sign, idof()));\n utoa64_any_core(changetype(out) + sign, val32, decimals, radix);\n }\n if (sign) store(changetype(out), CharCode.MINUS);\n return out;\n}\n\nexport function utoa64(value: u64, radix: i32): String {\n if (radix < 2 || radix > 36) {\n throw new RangeError(\"toString() radix argument must be between 2 and 36\");\n }\n if (!value) return \"0\";\n var out: String;\n\n if (radix == 10) {\n if (value <= u32.MAX_VALUE) {\n let val32 = value;\n let decimals = decimalCount32(val32);\n out = changetype(__new(decimals << 1, idof()));\n utoa32_dec_core(changetype(out), val32, decimals);\n } else {\n let decimals = decimalCount64High(value);\n out = changetype(__new(decimals << 1, idof()));\n utoa64_dec_core(changetype(out), value, decimals);\n }\n } else if (radix == 16) {\n let decimals = (63 - u32(clz(value)) >> 2) + 1;\n out = changetype(__new(decimals << 1, idof()));\n utoa64_hex_core(changetype(out), value, decimals);\n } else {\n let decimals = ulog_base(value, radix);\n out = changetype(__new(decimals << 1, idof()));\n utoa64_any_core(changetype(out), value, decimals, radix);\n }\n return out;\n}\n\nexport function itoa64(value: i64, radix: i32): String {\n if (radix < 2 || radix > 36) {\n throw new RangeError(\"toString() radix argument must be between 2 and 36\");\n }\n if (!value) return \"0\";\n\n var sign = u32(value >>> 63) << 1;\n if (sign) value = -value;\n var out: String;\n\n if (radix == 10) {\n if (value <= u32.MAX_VALUE) {\n let val32 = value;\n let decimals = decimalCount32(val32);\n out = changetype(__new((decimals << 1) + sign, idof()));\n utoa32_dec_core(changetype(out) + sign, val32, decimals);\n } else {\n let decimals = decimalCount64High(value);\n out = changetype(__new((decimals << 1) + sign, idof()));\n utoa64_dec_core(changetype(out) + sign, value, decimals);\n }\n } else if (radix == 16) {\n let decimals = (63 - u32(clz(value)) >> 2) + 1;\n out = changetype(__new((decimals << 1) + sign, idof()));\n utoa64_hex_core(changetype(out) + sign, value, decimals);\n } else {\n let decimals = ulog_base(value, radix);\n out = changetype(__new((decimals << 1) + sign, idof()));\n utoa64_any_core(changetype(out) + sign, value, decimals, radix);\n }\n if (sign) store(changetype(out), CharCode.MINUS);\n return out;\n}\n\n// @ts-ignore: decorator\n@lazy var _K: i32 = 0;\n\n// // @ts-ignore: decorator\n// @lazy\n// var _frc: u64 = 0;\n\n// @ts-ignore: decorator\n@lazy var _exp: i32 = 0;\n\n// @ts-ignore: decorator\n@lazy var _frc_minus: u64 = 0;\n\n// @ts-ignore: decorator\n@lazy var _frc_plus: u64 = 0;\n\n// @ts-ignore: decorator\n@lazy var _frc_pow: u64 = 0;\n\n// @ts-ignore: decorator\n@lazy var _exp_pow: i32 = 0;\n\n// @ts-ignore: decorator\n@inline\nfunction umul64f(u: u64, v: u64): u64 {\n var u0 = u & 0xFFFFFFFF;\n var v0 = v & 0xFFFFFFFF;\n\n var u1 = u >> 32;\n var v1 = v >> 32;\n\n var l = u0 * v0;\n var t = u1 * v0 + (l >> 32);\n var w = u0 * v1 + (t & 0xFFFFFFFF);\n\n w += 0x7FFFFFFF; // rounding\n\n t >>= 32;\n w >>= 32;\n\n return u1 * v1 + t + w;\n}\n\n// @ts-ignore: decorator\n@inline\nfunction umul64e(e1: i32, e2: i32): i32 {\n return e1 + e2 + 64; // where 64 is significand size\n}\n\n// @ts-ignore: decorator\n@inline\nfunction normalizedBoundaries(f: u64, e: i32): void {\n var frc = (f << 1) + 1;\n var exp = e - 1;\n var off = clz(frc);\n frc <<= off;\n exp -= off;\n\n var m = 1 + i32(f == 0x0010000000000000);\n\n _frc_plus = frc;\n _frc_minus = ((f << m) - 1) << e - m - exp;\n _exp = exp;\n}\n\n// @ts-ignore: decorator\n@inline\nfunction grisuRound(buffer: usize, len: i32, delta: u64, rest: u64, ten_kappa: u64, wp_w: u64): void {\n var lastp = buffer + ((len - 1) << 1);\n var digit = load(lastp);\n while (\n rest < wp_w &&\n delta - rest >= ten_kappa && (\n rest + ten_kappa < wp_w ||\n wp_w - rest > rest + ten_kappa - wp_w\n )\n ) {\n --digit;\n rest += ten_kappa;\n }\n store(lastp, digit);\n}\n\n// @ts-ignore: decorator\n@inline\nfunction getCachedPower(minExp: i32): void {\n const c = reinterpret(0x3FD34413509F79FE); // 1 / lg(10) = 0.30102999566398114\n var dk = (-61 - minExp) * c + 347;\t // dk must be positive, so can do ceiling in positive\n var k = dk;\n k += i32(k != dk); // conversion with ceil\n\n var index = (k >> 3) + 1;\n _K = 348 - (index << 3);\t// decimal exponent no need lookup table\n _frc_pow = load(FRC_POWERS + (index << alignof()));\n _exp_pow = load(EXP_POWERS + (index << alignof()));\n}\n\n// @ts-ignore: decorator\n@inline\nfunction grisu2(value: f64, buffer: usize, sign: i32): i32 {\n\n // frexp routine\n var uv = reinterpret(value);\n var exp = i32((uv & 0x7FF0000000000000) >>> 52);\n var sid = uv & 0x000FFFFFFFFFFFFF;\n var frc = (u64(exp != 0) << 52) + sid;\n exp = select(exp, 1, exp) - (0x3FF + 52);\n\n normalizedBoundaries(frc, exp);\n getCachedPower(_exp);\n\n // normalize\n var off = clz(frc);\n frc <<= off;\n exp -= off;\n\n var frc_pow = _frc_pow;\n var exp_pow = _exp_pow;\n\n var w_frc = umul64f(frc, frc_pow);\n var w_exp = umul64e(exp, exp_pow);\n\n var wp_frc = umul64f(_frc_plus, frc_pow) - 1;\n var wp_exp = umul64e(_exp, exp_pow);\n\n var wm_frc = umul64f(_frc_minus, frc_pow) + 1;\n var delta = wp_frc - wm_frc;\n\n return genDigits(buffer, w_frc, w_exp, wp_frc, wp_exp, delta, sign);\n}\n\nfunction genDigits(buffer: usize, w_frc: u64, w_exp: i32, mp_frc: u64, mp_exp: i32, delta: u64, sign: i32): i32 {\n var one_exp = -mp_exp;\n var one_frc = (1) << one_exp;\n var mask = one_frc - 1;\n\n var wp_w_frc = mp_frc - w_frc;\n\n var p1 = u32(mp_frc >> one_exp);\n var p2 = mp_frc & mask;\n\n var kappa = decimalCount32(p1);\n var len = sign;\n\n while (kappa > 0) {\n let d: u32;\n switch (kappa) {\n case 10: { d = p1 / 1000000000; p1 %= 1000000000; break; }\n case 9: { d = p1 / 100000000; p1 %= 100000000; break; }\n case 8: { d = p1 / 10000000; p1 %= 10000000; break; }\n case 7: { d = p1 / 1000000; p1 %= 1000000; break; }\n case 6: { d = p1 / 100000; p1 %= 100000; break; }\n case 5: { d = p1 / 10000; p1 %= 10000; break; }\n case 4: { d = p1 / 1000; p1 %= 1000; break; }\n case 3: { d = p1 / 100; p1 %= 100; break; }\n case 2: { d = p1 / 10; p1 %= 10; break; }\n case 1: { d = p1; p1 = 0; break; }\n default: { d = 0; break; }\n }\n\n if (d | len) store(buffer + (len++ << 1), CharCode._0 + d);\n\n --kappa;\n let tmp = ((p1) << one_exp) + p2;\n if (tmp <= delta) {\n _K += kappa;\n grisuRound(buffer, len, delta, tmp, load(POWERS10 + (kappa << alignof())) << one_exp, wp_w_frc);\n return len;\n }\n }\n\n while (true) {\n p2 *= 10;\n delta *= 10;\n\n let d = p2 >> one_exp;\n if (d | len) store(buffer + (len++ << 1), CharCode._0 + d);\n\n p2 &= mask;\n --kappa;\n if (p2 < delta) {\n _K += kappa;\n wp_w_frc *= load(POWERS10 + (-kappa << alignof()));\n grisuRound(buffer, len, delta, p2, one_frc, wp_w_frc);\n return len;\n }\n }\n}\n\n// @ts-ignore: decorator\n@inline\nfunction genExponent(buffer: usize, k: i32): i32 {\n var sign = k < 0;\n if (sign) k = -k;\n var decimals = decimalCount32(k) + 1;\n utoa32_dec_core(buffer, k, decimals);\n store(buffer, select(CharCode.MINUS, CharCode.PLUS, sign));\n return decimals;\n}\n\nfunction prettify(buffer: usize, length: i32, k: i32): i32 {\n if (!k) {\n store(buffer + (length << 1), CharCode.DOT | (CharCode._0 << 16));\n return length + 2;\n }\n\n var kk = length + k;\n if (length <= kk && kk <= 21) {\n // 1234e7 -> 12340000000\n for (let i = length; i < kk; ++i) {\n store(buffer + (i << 1), CharCode._0);\n }\n store(buffer + (kk << 1), CharCode.DOT | (CharCode._0 << 16));\n return kk + 2;\n } else if (kk > 0 && kk <= 21) {\n // 1234e-2 -> 12.34\n let ptr = buffer + (kk << 1);\n memory.copy(\n ptr + 2,\n ptr,\n -k << 1\n );\n store(buffer + (kk << 1), CharCode.DOT);\n return length + 1;\n } else if (-6 < kk && kk <= 0) {\n // 1234e-6 -> 0.001234\n let offset = 2 - kk;\n memory.copy(\n buffer + (offset << 1),\n buffer,\n length << 1\n );\n store(buffer, CharCode._0 | (CharCode.DOT << 16));\n for (let i = 2; i < offset; ++i) {\n store(buffer + (i << 1), CharCode._0);\n }\n return length + offset;\n } else if (length == 1) {\n // 1e30\n store(buffer, CharCode.e, 2);\n length = genExponent(buffer + 4, kk - 1);\n return length + 2;\n } else {\n let len = length << 1;\n memory.copy(\n buffer + 4,\n buffer + 2,\n len - 2\n );\n store(buffer, CharCode.DOT, 2);\n store(buffer + len, CharCode.e, 2);\n length += genExponent(buffer + len + 4, kk - 1);\n return length + 2;\n }\n}\n\nfunction dtoa_core(buffer: usize, value: f64): i32 {\n var sign = i32(value < 0);\n if (sign) {\n value = -value;\n store(buffer, CharCode.MINUS);\n }\n // assert(value > 0 && value <= 1.7976931348623157e308);\n var len = grisu2(value, buffer, sign);\n len = prettify(buffer + (sign << 1), len - sign, _K);\n return len + sign;\n}\n\n// @ts-ignore: decorator\n@lazy @inline const dtoa_buf = memory.data(MAX_DOUBLE_LENGTH << 1);\n\nexport function dtoa(value: f64): String {\n if (value == 0) return \"0.0\";\n if (!isFinite(value)) {\n if (isNaN(value)) return \"NaN\";\n return select(\"-Infinity\", \"Infinity\", value < 0);\n }\n var size = dtoa_core(dtoa_buf, value) << 1;\n var result = changetype(__new(size, idof()));\n memory.copy(changetype(result), dtoa_buf, size);\n return result;\n}\n\nexport function itoa_buffered(buffer: usize, value: T): u32 {\n var sign: u32 = 0;\n if (isSigned()) {\n sign = u32(value < 0);\n if (sign) {\n if (sizeof() == 1) {\n if (value == -0x80) {\n // -0x80 -> -128\n store(buffer,\n CharCode.MINUS |\n (CharCode._0 + 1) << 16 |\n (CharCode._0 + 2) << 32 |\n (CharCode._0 + 8) << 48\n );\n return 4;\n }\n }\n if (sizeof() == 2) {\n if (value == -0x8000) {\n // -0x8000 -> -32768\n store(buffer,\n CharCode.MINUS |\n (CharCode._0 + 3) << 16 |\n (CharCode._0 + 2) << 32 |\n (CharCode._0 + 7) << 48\n ); // -327\n store(buffer + 8,\n (CharCode._0 + 6) << 0 |\n (CharCode._0 + 8) << 16\n ); // 68\n return 6;\n }\n }\n store(buffer, CharCode.MINUS);\n // @ts-ignore\n value = -value;\n }\n }\n var dest = buffer + (sign << 1);\n if (ASC_SHRINK_LEVEL <= 1) {\n if (isSigned()) {\n if (sizeof() <= 4) {\n if (value < 10) {\n store(dest, value | CharCode._0);\n return 1 + sign;\n }\n } else {\n if (value < 10) {\n store(dest, value | CharCode._0);\n return 1 + sign;\n }\n }\n } else {\n if (value < 10) {\n store(buffer, value | CharCode._0);\n return 1;\n }\n }\n }\n var decimals: u32 = 0;\n if (sizeof() <= 4) {\n let val32 = value;\n decimals = decimalCount32(val32);\n utoa32_dec_core(dest, val32, decimals);\n } else {\n if (value <= u32.MAX_VALUE) {\n let val32 = value;\n decimals = decimalCount32(val32);\n utoa32_dec_core(dest, val32, decimals);\n } else {\n let val64 = value;\n decimals = decimalCount64High(val64);\n utoa64_dec_core(dest, val64, decimals);\n }\n }\n return sign + decimals;\n}\n\nexport function dtoa_buffered(buffer: usize, value: f64): u32 {\n if (value == 0) {\n store(buffer, CharCode._0);\n store(buffer, CharCode.DOT, 2);\n store(buffer, CharCode._0, 4);\n return 3;\n }\n if (!isFinite(value)) {\n if (isNaN(value)) {\n store(buffer, CharCode.N);\n store(buffer, CharCode.a, 2);\n store(buffer, CharCode.N, 4);\n return 3;\n } else {\n let sign = value < 0;\n if (sign) {\n store(buffer, CharCode.MINUS); // -\n buffer += 2;\n }\n store(buffer, 0x690066006E0049, 0); // ifnI\n store(buffer, 0x7900740069006E, 8); // ytin\n return 8 + u32(sign);\n }\n }\n return dtoa_core(buffer, value);\n}\n","import {\n itoa32,\n utoa32,\n itoa64,\n utoa64,\n dtoa,\n itoa_buffered,\n dtoa_buffered,\n MAX_DOUBLE_LENGTH\n} from \"./number\";\n\nimport {\n ipow32\n} from \"../math\";\n\n// All tables are stored as two staged lookup tables (static tries)\n// because the full range of Unicode symbols can't be efficiently\n// represented as-is in memory (see Unicode spec ch 5, p.196):\n// https://www.unicode.org/versions/Unicode12.0.0/ch05.pdf\n// Tables have been generated using these forked musl tools:\n// https://github.com/MaxGraey/musl-chartable-tools/tree/case-ignorable\n\n// Lookup table to check if a character is alphanumeric or not\n// See: https://git.musl-libc.org/cgit/musl/tree/src/ctype/alpha.h\n// size: 3904 bytes\n// @ts-ignore\n@inline @lazy const ALPHA_TABLE = memory.data([\n 18,17,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,17,34,35,36,17,37,38,39,40,\n 41,42,43,44,17,45,46,47,16,16,48,16,16,16,16,16,16,16,49,50,51,16,52,53,16,16,\n 17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,54,\n 17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,\n 17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,\n 17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,\n 17,17,17,55,17,17,17,17,56,17,57,58,59,60,61,62,17,17,17,17,17,17,17,17,17,17,\n 17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,\n 17,17,17,17,17,17,17,63,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,17,64,65,17,66,67,\n 68,69,70,71,72,73,74,17,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,\n 93,94,16,95,96,97,98,17,17,17,99,100,101,16,16,16,16,16,16,16,16,16,16,17,17,\n 17,17,102,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,17,17,103,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,17,17,104,105,16,16,106,107,17,17,17,17,17,17,17,17,17,17,17,17,17,\n 17,17,17,17,17,17,17,17,17,17,108,17,17,17,17,109,110,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 17,111,112,16,16,16,16,16,16,16,16,16,113,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,114,115,116,117,16,16,16,16,16,16,16,16,118,\n 119,120,16,16,16,16,16,121,122,16,16,16,16,123,16,16,124,16,16,16,16,16,16,16,\n 16,16,125,16,16,16,\n 16,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,255,255,\n 255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,\n 255,255,255,255,255,255,255,255,255,255,255,0,0,0,0,0,0,0,0,254,255,255,7,254,\n 255,255,7,0,0,0,0,0,4,32,4,255,255,127,255,255,255,127,255,255,255,255,255,\n 255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,\n 255,195,255,3,0,31,80,0,0,0,0,0,0,0,0,0,0,32,0,0,0,0,0,223,188,64,215,255,255,\n 251,255,255,255,255,255,255,255,255,255,191,255,255,255,255,255,255,255,255,\n 255,255,255,255,255,255,255,255,255,3,252,255,255,255,255,255,255,255,255,255,\n 255,255,255,255,255,255,255,255,255,255,255,254,255,255,255,127,2,255,255,255,\n 255,255,1,0,0,0,0,255,191,182,0,255,255,255,135,7,0,0,0,255,7,255,255,255,255,\n 255,255,255,254,255,195,255,255,255,255,255,255,255,255,255,255,255,255,239,\n 31,254,225,255,\n 159,0,0,255,255,255,255,255,255,0,224,255,255,255,255,255,255,255,255,255,255,\n 255,255,3,0,255,255,255,255,255,7,48,4,255,255,255,252,255,31,0,0,255,255,255,\n 1,255,7,0,0,0,0,0,0,255,255,223,255,255,0,240,255,248,3,255,255,255,255,255,\n 255,255,255,255,239,255,223,225,255,207,255,254,255,239,159,249,255,255,253,\n 197,227,159,89,128,176,207,255,3,16,238,135,249,255,255,253,109,195,135,25,2,\n 94,192,255,63,0,238,191,251,255,255,253,237,227,191,27,1,0,207,255,0,30,238,\n 159,249,255,255,253,237,227,159,25,192,176,207,255,2,0,236,199,61,214,24,199,\n 255,195,199,29,129,0,192,255,0,0,239,223,253,255,255,253,255,227,223,29,96,7,\n 207,255,0,0,239,223,253,255,255,253,239,227,223,29,96,64,207,255,6,0,255,223,\n 253,255,255,255,255,231,223,93,240,128,207,255,0,252,238,255,127,252,255,255,\n 251,47,127,128,95,255,192,255,12,0,254,255,255,255,255,127,255,7,63,32,255,3,\n 0,0,0,0,214,247,255,255,175,255,255,59,95,32,255,243,0,0,0,\n 0,1,0,0,0,255,3,0,0,255,254,255,255,255,31,254,255,3,255,255,254,255,255,255,\n 31,0,0,0,0,0,0,0,0,255,255,255,255,255,255,127,249,255,3,255,255,255,255,255,\n 255,255,255,255,63,255,255,255,255,191,32,255,255,255,255,255,247,255,255,255,\n 255,255,255,255,255,255,61,127,61,255,255,255,255,255,61,255,255,255,255,61,\n 127,61,255,127,255,255,255,255,255,255,255,61,255,255,255,255,255,255,255,255,\n 7,0,0,0,0,255,255,0,0,255,255,255,255,255,255,255,255,255,255,63,63,254,255,\n 255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,\n 255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,\n 255,255,255,255,255,159,255,255,254,255,255,7,255,255,255,255,255,255,255,255,\n 255,199,255,1,255,223,15,0,255,255,15,0,255,255,15,0,255,223,13,0,255,255,255,\n 255,255,255,207,255,255,1,128,16,255,3,0,0,0,0,255,3,255,255,255,255,255,255,\n 255,255,255,255,255,1,255,255,255,255,255,7,255,255,255,255,255,255,255,255,\n 63,\n 0,255,255,255,127,255,15,255,1,192,255,255,255,255,63,31,0,255,255,255,255,\n 255,15,255,255,255,3,255,3,0,0,0,0,255,255,255,15,255,255,255,255,255,255,255,\n 127,254,255,31,0,255,3,255,3,128,0,0,128,1,0,0,0,0,0,0,0,255,255,255,255,255,\n 255,239,255,239,15,255,3,0,0,0,0,255,255,255,255,255,243,255,255,255,255,255,\n 255,191,255,3,0,255,255,255,255,255,255,127,0,255,227,255,255,255,255,255,63,\n 255,1,255,255,255,255,255,231,0,0,0,0,0,222,111,4,255,255,255,255,255,255,255,\n 255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,0,0,0,0,\n 128,255,31,0,255,255,63,63,255,255,255,255,63,63,255,170,255,255,255,63,255,\n 255,255,255,255,255,223,95,220,31,207,15,255,31,220,31,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,2,128,0,0,255,31,0,0,0,0,0,0,0,0,0,0,0,0,132,252,47,62,80,189,255,243,\n 224,67,0,0,255,255,255,255,255,1,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,192,255,255,255,255,255,255,3,0,\n 0,255,255,255,255,255,127,255,255,255,255,255,127,255,255,255,255,255,255,255,\n 255,255,255,255,255,255,255,255,255,31,120,12,0,255,255,255,255,191,32,255,\n 255,255,255,255,255,255,128,0,0,255,255,127,0,127,127,127,127,127,127,127,127,\n 255,255,255,255,0,0,0,0,0,128,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,224,0,0,0,254,3,62,31,254,255,255,255,255,255,255,255,255,255,127,224,254,\n 255,255,255,255,255,255,255,255,255,255,247,224,255,255,255,255,255,254,255,\n 255,255,255,255,255,255,255,255,255,127,0,0,255,255,255,255,0,0,0,0,0,0,255,\n 255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,\n 255,255,255,255,255,255,0,0,0,0,0,0,0,0,255,255,255,255,255,255,255,255,255,\n 255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,\n 255,255,255,\n 31,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,31,0,0,\n 0,0,0,0,0,0,255,255,255,255,255,63,255,31,255,255,255,15,0,0,255,255,255,255,\n 255,127,240,143,255,255,255,255,255,255,255,255,255,255,255,255,255,255,0,0,0,\n 0,128,255,252,255,255,255,255,255,255,255,255,255,255,255,255,249,255,255,255,\n 255,255,255,252,7,0,0,0,0,224,255,191,255,255,255,255,0,0,0,255,255,255,255,\n 255,255,15,0,255,255,255,255,255,255,255,255,47,0,255,3,0,0,252,232,255,255,\n 255,255,255,7,255,255,255,255,7,0,255,255,255,31,255,255,255,255,255,255,247,\n 255,0,128,255,3,255,255,255,127,255,255,255,255,255,255,127,0,255,63,255,3,\n 255,255,127,252,255,255,255,255,255,255,255,127,5,0,0,56,255,255,60,0,126,126,\n 126,0,127,127,255,255,255,255,255,247,255,3,255,255,255,255,255,255,255,255,\n 255,255,255,255,255,255,255,7,255,3,255,255,255,255,255,255,255,255,255,255,\n 255,255,255,255,255,255,255,255,255,255,15,0,255,255,127,248,255,255,255,255,\n 255,\n 15,255,255,255,255,255,255,255,255,255,255,255,255,255,63,255,255,255,255,255,\n 255,255,255,255,255,255,255,255,3,0,0,0,0,127,0,248,224,255,253,127,95,219,\n 255,255,255,255,255,255,255,255,255,255,255,255,255,3,0,0,0,248,255,255,255,\n 255,255,255,255,255,255,255,255,255,63,0,0,255,255,255,255,255,255,255,255,\n 252,255,255,255,255,255,255,0,0,0,0,0,255,15,0,0,0,0,0,0,0,0,0,0,0,0,0,0,223,\n 255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,31,0,0,255,3,\n 254,255,255,7,254,255,255,7,192,255,255,255,255,255,255,255,255,255,255,127,\n 252,252,252,28,0,0,0,0,255,239,255,255,127,255,255,183,255,63,255,63,0,0,0,0,\n 255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,7,0,0,0,0,0,0,0,0,\n 255,255,255,255,255,255,31,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,255,255,255,31,255,255,255,255,255,255,1,0,0,0,0,\n 0,255,255,255,255,0,224,255,255,255,7,255,255,255,255,255,7,255,255,255,63,\n 255,255,255,255,15,255,62,0,0,0,0,0,255,255,255,255,255,255,255,255,255,255,\n 255,255,255,255,255,255,255,255,255,63,255,3,255,255,255,255,15,255,255,255,\n 255,15,255,255,255,255,255,0,255,255,255,255,255,255,15,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,255,255,255,255,255,255,127,0,255,255,63,0,255,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,63,253,255,255,255,255,191,145,255,255,63,0,255,255,\n 127,0,255,255,255,127,0,0,0,0,0,0,0,0,255,255,55,0,255,255,63,0,255,255,255,3,\n 0,0,0,0,0,0,0,0,255,255,255,255,255,255,255,192,0,0,0,0,0,0,0,0,111,240,239,\n 254,255,255,63,0,0,0,0,0,255,255,255,31,255,255,255,31,0,0,0,0,255,254,255,\n 255,31,0,0,0,255,255,255,255,255,255,63,0,255,255,63,0,255,255,7,0,255,255,3,\n 0,0,0,0,0,0,0,0,0,0,0,0,\n 0,255,255,255,255,255,255,255,255,255,1,0,0,0,0,0,0,255,255,255,255,255,255,7,\n 0,255,255,255,255,255,255,7,0,255,255,255,255,255,0,255,3,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,255,255,255,255,\n 255,27,3,0,0,0,0,0,0,0,0,0,255,255,255,31,128,0,255,255,63,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,255,255,31,0,0,0,255,255,127,0,255,255,255,255,255,255,255,255,63,0,0,\n 0,192,255,0,0,252,255,255,255,255,255,255,1,0,0,255,255,255,1,255,3,255,255,\n 255,255,255,255,199,255,240,0,255,255,255,255,71,0,255,255,255,255,255,255,\n 255,255,30,192,255,23,0,0,0,0,255,255,251,255,255,255,159,64,0,0,0,0,0,0,0,0,\n 127,189,255,191,255,1,255,255,255,255,255,255,255,1,255,3,239,159,249,255,255,\n 253,237,227,159,25,129,224,15,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,255,255,255,255,255,255,255,255,187,7,255,131,3,0,0,0,255,255,255,255,255,\n 255,255,255,179,0,255,3,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,255,255,255,\n 255,255,255,63,127,0,0,0,63,0,0,0,0,255,255,255,255,255,255,255,127,17,0,255,\n 3,0,0,0,0,255,255,255,255,255,255,63,1,255,3,0,0,0,0,0,0,255,255,255,231,255,\n 7,255,3,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,255,255,255,255,255,\n 255,255,1,0,0,0,0,0,0,0,0,0,0,0,0,255,255,255,255,255,255,255,255,255,3,0,128,\n 127,242,111,255,255,255,191,153,7,0,255,3,0,0,0,0,0,0,0,0,255,252,255,255,255,\n 255,255,252,26,0,0,0,255,255,255,255,255,255,231,127,0,0,255,255,255,255,255,\n 255,255,255,255,32,0,0,0,0,255,255,255,255,255,255,255,1,255,253,255,255,255,\n 255,127,127,1,0,255,3,0,0,252,255,255,255,252,255,255,254,127,0,0,0,0,0,0,0,0,\n 0,127,251,255,255,255,255,127,180,203,0,255,3,191,253,255,255,255,127,123,1,\n 255,3,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,255,255,127,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,\n 0,0,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,\n 255,3,0,0,0,0,0,0,0,0,0,0,0,0,255,255,255,255,255,255,255,255,255,255,255,255,\n 255,127,0,0,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,\n 255,255,255,255,255,255,255,255,15,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,255,255,255,255,255,127,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,255,255,255,255,255,255,255,255,127,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,\n 0,255,255,255,255,255,255,255,1,255,255,255,127,255,3,0,0,0,0,0,0,0,0,0,0,0,0,\n 255,255,255,63,0,0,255,255,255,255,255,255,0,0,15,0,255,3,248,255,255,224,255,\n 255,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,255,255,255,255,255,255,255,\n 255,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,255,255,255,255,255,255,255,255,255,135,\n 255,255,255,255,255,255,255,128,255,255,0,0,0,0,0,0,0,0,11,0,3,0,255,255,255,\n 255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,\n 255,255,255,255,255,255,255,255,255,0,255,255,255,255,255,255,255,255,255,255,\n 255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,63,0,0,0,0,0,\n 255,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,255,255,255,\n 127,0,0,0,0,0,0,7,0,240,0,255,255,255,255,255,255,255,255,255,255,255,255,255,\n 255,255,255,255,\n 255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,\n 255,255,255,255,255,255,255,255,255,255,255,255,255,15,255,255,255,255,255,\n 255,255,255,255,255,255,255,255,7,255,31,255,1,255,67,0,0,0,0,0,0,0,0,0,0,0,0,\n 255,255,255,255,255,255,255,255,255,255,223,255,255,255,255,255,255,255,255,\n 223,100,222,255,235,239,255,255,255,255,255,255,255,191,231,223,223,255,255,\n 255,123,95,252,253,255,255,255,255,255,255,255,255,255,255,255,255,255,255,\n 255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,\n 255,255,255,255,255,255,255,255,63,255,255,255,253,255,255,247,255,255,255,\n 247,255,255,223,255,255,255,223,255,255,127,255,255,255,127,255,255,255,253,\n 255,255,255,253,255,255,247,207,255,255,255,255,255,255,127,255,255,249,219,7,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,255,255,255,255,255,31,\n 128,63,255,67,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,255,255,255,255,255,15,255,\n 3,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,\n 255,255,255,255,255,31,0,0,0,0,0,0,0,255,255,255,255,255,255,255,255,143,8,\n 255,3,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,239,255,255,255,150,254,247,10,\n 132,234,150,170,150,247,247,94,255,251,255,15,238,251,255,15,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,255,255,255,3,255,255,255,3,255,255,255,3,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,255,3\n]);\n\n// size: 1568 bytes (compressed to ~1380 bytes after binaryen)\n// @ts-ignore: decorator\n@lazy @inline const CASED = memory.data([\n 18,19,20,21,22,23,16,16,16,16,16,16,16,16,16,16,\n 24,16,16,25,16,16,16,16,16,16,16,16,26,27,17,28,\n 29,30,16,16,31,16,16,16,16,16,16,16,32,33,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,34,35,16,16,16,36,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,37,16,16,16,38,\n 16,16,16,16,39,16,16,16,16,16,16,16,40,16,16,16,\n 16,16,16,16,16,16,16,16,41,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,42,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,43,44,45,46,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,47,16,16,16,16,16,16,\n 16,48,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,\n 255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,\n 0,0,0,0,0,0,0,0,254,255,255,7,254,255,255,7,0,0,0,0,0,4,32,4,\n 255,255,127,255,255,255,127,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,\n 255,255,255,255,255,255,255,247,240,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,\n 255,255,255,255,255,255,255,255,255,255,239,255,255,255,255,1,3,0,0,0,31,0,0,0,\n 0,0,0,0,0,0,0,0,32,0,0,0,0,0,207,188,64,215,255,255,251,255,255,255,\n 255,255,255,255,255,255,191,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,\n 3,252,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,254,255,\n 255,255,127,0,255,255,255,255,255,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,255,255,255,255,\n 191,32,255,255,255,255,255,231,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,255,255,255,255,255,255,255,255,255,255,63,63,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,255,1,255,255,255,255,255,231,0,0,0,0,0,0,0,0,\n 255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,\n 0,0,0,0,0,0,0,0,255,255,63,63,255,255,255,255,63,63,255,170,255,255,255,63,\n 255,255,255,255,255,255,223,95,220,31,207,15,255,31,220,31,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,2,128,0,0,255,31,0,0,0,0,0,0,0,0,0,0,0,0,\n 132,252,47,62,80,189,31,242,224,67,0,0,255,255,255,255,24,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,192,255,255,255,255,255,255,3,0,0,255,255,255,255,255,127,255,255,\n 255,255,255,127,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,31,120,12,0,\n 255,255,255,255,191,32,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,255,255,255,255,255,63,0,0,\n 255,255,255,63,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,252,255,255,255,\n 255,255,255,255,255,255,255,255,255,120,255,255,255,255,255,255,252,7,0,0,0,0,96,7,\n 0,0,0,0,0,0,255,255,255,255,255,247,255,1,255,255,255,255,255,255,255,255,255,255,\n 0,0,0,0,0,0,0,0,127,0,248,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,254,255,255,7,\n 254,255,255,7,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 255,255,255,255,255,255,255,255,255,255,0,0,0,0,0,0,0,0,0,0,0,0,255,255,\n 255,255,15,255,255,255,255,15,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 255,255,255,255,255,255,7,0,255,255,255,255,255,255,7,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,255,255,255,255,255,255,255,255,0,0,0,0,\n 0,0,0,0,0,0,0,0,255,255,255,255,255,255,255,255,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,255,255,255,255,255,255,255,255,255,255,223,255,255,255,255,255,\n 255,255,255,223,100,222,255,235,239,255,255,255,255,255,255,255,191,231,223,223,255,255,255,123,\n 95,252,253,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,\n 255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,63,255,255,255,\n 253,255,255,247,255,255,255,247,255,255,223,255,255,255,223,255,255,127,255,255,255,127,255,255,\n 255,253,255,255,255,253,255,255,247,15,0,0,0,0,0,0,255,255,255,255,255,255,255,255,\n 15,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,255,255,255,3,255,255,255,3,255,255,255,3,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0\n]);\n\n// size: 2976 bytes (compressed to ~2050 bytes after binaryen)\n// @ts-ignore: decorator\n@lazy @inline const CASE_IGNORABLES = memory.data([\n 18,16,19,20,21,22,23,24,25,26,27,28,29,30,31,32,\n 33,16,16,34,16,16,16,35,36,37,38,39,40,41,16,42,\n 43,16,16,16,16,16,16,16,16,16,16,16,44,45,46,16,\n 47,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 48,16,16,16,49,16,50,51,52,53,54,55,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,56,16,16,57,58,\n 16,59,60,61,16,16,16,16,16,16,62,16,16,63,64,65,\n 66,67,68,69,70,71,72,73,74,75,76,16,77,78,79,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,80,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,81,82,16,16,16,83,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,84,16,16,16,\n 16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,\n 16,85,86,16,16,16,16,16,16,16,87,16,16,16,16,16,\n 88,89,90,16,16,16,16,16,91,92,16,16,16,16,16,16,\n 16,16,16,93,16,16,16,16,16,16,16,16,16,16,16,16,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,\n 255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,\n 0,0,0,0,128,64,0,4,0,0,0,64,1,0,0,0,0,0,0,0,0,161,144,1,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,\n 255,255,255,255,255,255,48,4,176,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,248,3,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,130,0,0,0,0,\n 0,0,254,255,255,255,255,191,182,0,0,0,0,0,16,0,63,0,255,23,0,0,0,0,\n 1,248,255,255,0,0,1,0,0,0,0,0,0,0,0,0,0,0,192,191,255,61,0,0,\n 0,128,2,0,0,0,255,255,255,7,0,0,0,0,0,0,0,0,0,0,192,255,1,0,\n 0,0,0,0,0,248,63,36,0,0,192,255,255,63,0,0,0,0,0,14,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,248,255,255,255,255,255,7,0,0,0,0,0,0,20,\n 254,33,254,0,12,0,2,0,2,0,0,0,0,0,0,16,30,32,0,0,12,0,0,64,\n 6,0,0,0,0,0,0,16,134,57,2,0,0,0,35,0,6,0,0,0,0,0,0,16,\n 190,33,0,0,12,0,0,252,2,0,0,0,0,0,0,144,30,32,96,0,12,0,0,0,\n 4,0,0,0,0,0,0,0,1,32,0,0,0,0,0,0,17,0,0,0,0,0,0,192,\n 193,61,96,0,12,0,0,0,2,0,0,0,0,0,0,144,64,48,0,0,12,0,0,0,\n 3,0,0,0,0,0,0,24,30,32,0,0,12,0,0,0,2,0,0,0,0,0,0,0,\n 0,4,92,0,0,0,0,0,0,0,0,0,0,0,242,7,192,127,0,0,0,0,0,0,\n 0,0,0,0,0,0,242,31,64,63,0,0,0,0,0,0,0,0,0,3,0,0,160,2,\n 0,0,0,0,0,0,254,127,223,224,255,254,255,255,255,31,64,0,0,0,0,0,0,0,\n 0,0,0,0,0,224,253,102,0,0,0,195,1,0,30,0,100,32,0,32,0,0,0,0,\n 0,0,0,0,0,0,0,16,0,0,0,0,0,0,0,0,0,0,0,224,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,28,0,0,0,28,0,\n 0,0,12,0,0,0,12,0,0,0,0,0,0,0,176,63,64,254,143,32,0,0,0,0,\n 0,120,0,0,0,0,0,0,8,0,0,0,0,0,0,0,96,0,0,0,0,2,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,135,1,4,14,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,128,9,0,0,0,0,\n 0,0,64,127,229,31,248,159,0,0,0,0,128,0,255,255,1,0,0,0,0,0,0,0,\n 15,0,0,0,0,0,208,23,4,0,0,0,0,248,15,0,3,0,0,0,60,59,0,0,\n 0,0,0,0,64,163,3,0,0,0,0,0,0,240,207,0,0,0,0,0,0,0,0,63,\n 0,0,0,0,0,0,0,0,0,0,247,255,253,33,16,3,0,0,0,0,0,240,255,255,\n 255,255,255,255,255,7,0,1,0,0,0,248,255,255,255,255,255,255,255,255,255,255,255,251,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,160,\n 3,224,0,224,0,224,0,96,0,248,0,3,144,124,0,0,0,0,0,0,223,255,2,128,\n 0,0,255,31,0,0,0,0,0,0,255,255,255,255,1,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,48,0,0,0,0,0,0,0,0,0,0,0,0,0,128,3,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,128,0,128,0,0,0,0,0,0,0,0,\n 0,0,0,0,255,255,255,255,0,0,0,0,0,128,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,32,0,0,0,0,60,62,8,\n 0,0,0,0,0,0,0,0,0,0,0,126,0,0,0,0,0,0,0,0,0,0,0,112,\n 0,0,32,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,63,0,16,0,0,0,0,0,0,\n 0,0,0,0,0,128,247,191,0,0,0,240,0,0,0,0,0,0,0,0,0,0,3,0,\n 255,255,255,255,3,0,0,0,0,0,0,0,0,0,1,0,0,7,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,3,68,8,0,0,96,16,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,48,0,0,0,255,255,3,128,0,0,0,0,192,63,0,0,\n 128,255,3,0,0,0,0,0,7,0,0,0,0,0,200,51,0,128,0,0,96,0,0,0,\n 0,0,0,0,0,126,102,0,8,16,0,0,0,0,1,16,0,0,0,0,0,0,157,193,\n 2,0,0,32,0,48,88,0,0,0,0,0,0,0,0,0,0,0,0,248,0,14,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,32,33,0,0,0,0,0,64,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,252,255,3,0,0,0,0,0,0,0,\n 255,255,8,0,255,255,0,0,0,0,36,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,128,128,64,0,4,0,0,0,64,1,0,0,0,0,0,1,0,\n 0,0,0,192,0,0,0,0,0,0,0,0,8,0,0,14,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,32,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,192,7,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,110,240,0,0,0,0,0,135,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,96,0,0,0,\n 0,0,0,0,240,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,24,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 192,255,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 2,0,0,0,0,0,0,255,127,0,0,0,0,0,0,128,3,0,0,0,0,0,120,38,\n 0,32,0,0,0,0,0,0,7,0,0,0,128,239,31,0,0,0,0,0,0,0,8,0,\n 3,0,0,0,0,0,192,127,0,158,0,0,0,0,0,0,0,0,0,0,0,128,211,64,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,128,248,7,0,0,\n 3,0,0,0,0,0,0,24,1,0,0,0,192,31,31,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,255,92,0,0,64,0,0,0,0,\n 0,0,0,0,0,0,248,133,13,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,60,176,1,0,0,48,0,0,0,0,\n 0,0,0,0,0,0,248,167,1,0,0,0,0,0,0,0,0,0,0,0,0,40,191,0,\n 0,0,0,0,0,0,0,0,0,0,0,224,188,15,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,128,255,6,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,88,8,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,240,12,1,0,0,0,254,7,0,0,0,0,248,121,128,0,126,14,0,0,0,0,\n 0,252,127,3,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,127,191,\n 0,0,0,0,0,0,0,0,0,0,252,255,255,252,109,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,126,180,191,0,0,0,0,0,0,0,0,0,163,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,24,0,0,0,0,0,0,0,255,1,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,31,0,0,0,0,0,0,0,127,0,15,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,128,0,0,0,0,0,0,0,128,255,255,0,0,0,0,0,0,0,0,27,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,96,15,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,128,3,248,255,\n 231,15,0,0,0,60,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 28,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 255,255,255,255,255,255,127,248,255,255,255,255,255,31,32,0,16,0,0,248,254,255,0,0,\n 0,0,0,0,0,0,0,0,127,255,255,249,219,7,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,255,63,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,240,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,127,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 240,15,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,\n 0,0,0,0,0,0,0,248\n]);\n\n// @ts-ignore: decorator\n@lazy @inline const LOWER127 = memory.data([\n 0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,\n 16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,\n 32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,\n 48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,\n 64,\n 97,98,99,100,101,102,103,104,105,106,107,108,109,\n 110,111,112,113,114,115,116,117,118,119,120,121,122,\n 91,92,93,94,95,96,\n 97,98,99,100,101,102,103,104,105,106,107,108,109,\n 110,111,112,113,114,115,116,117,118,119,120,121,122,\n 123,124,125,126,127\n]);\n\n// @ts-ignore: decorator\n@lazy @inline const UPPER127 = memory.data([\n 0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,\n 16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,\n 32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,\n 48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,\n 64,\n 65,66,67,68,69,70,71,72,73,74,75,76,77,\n 78,79,80,81,82,83,84,85,86,87,88,89,90,\n 91,92,93,94,95,96,\n 65,66,67,68,69,70,71,72,73,74,75,76,77,\n 78,79,80,81,82,83,84,85,86,87,88,89,90,\n 123,124,125,126,127\n]);\n\n// 23 * 8 = 184 bytes\n// @ts-ignore: decorator\n@lazy @inline const POWERS10 = memory.data([\n 1e00, 1e01, 1e02, 1e03, 1e04, 1e05, 1e06, 1e07, 1e08, 1e09,\n 1e10, 1e11, 1e12, 1e13, 1e14, 1e15, 1e16, 1e17, 1e18, 1e19,\n 1e20, 1e21, 1e22\n]);\n\n// @ts-ignore: decorator\n@inline\nexport const enum CharCode {\n PERCENT = 0x25,\n PLUS = 0x2B,\n MINUS = 0x2D,\n DOT = 0x2E,\n _0 = 0x30,\n _1 = 0x31,\n _2 = 0x32,\n _3 = 0x33,\n _4 = 0x34,\n _5 = 0x35,\n _6 = 0x36,\n _7 = 0x37,\n _8 = 0x38,\n _9 = 0x39,\n A = 0x41,\n B = 0x42,\n E = 0x45,\n I = 0x49,\n N = 0x4E,\n O = 0x4F,\n X = 0x58,\n Z = 0x5A,\n a = 0x61,\n b = 0x62,\n e = 0x65,\n n = 0x6E,\n o = 0x6F,\n u = 0x75,\n x = 0x78,\n z = 0x7A\n}\n\n// @ts-ignore: decorator\n@inline\nexport function isAscii(c: u32): bool {\n return !(c >> 7);\n}\n\n// @ts-ignore: decorator\n@inline\nexport function isLower8(c: u32): bool {\n return c - CharCode.a < 26;\n}\n\n// @ts-ignore: decorator\n@inline\nexport function isUpper8(c: u32): bool {\n return c - CharCode.A < 26;\n}\n\nexport function isSpace(c: u32): bool {\n if (c < 0x1680) { // < (1)\n // , , , , , and \n // (c == 0x20 || c == 0xA0) was optimized to (c | 0x80) == 0xA0\n return ((c | 0x80) == 0xA0) || (c - 0x09 <= 0x0D - 0x09);\n }\n if (c - 0x2000 <= 0x200A - 0x2000) return true;\n switch (c) {\n case 0x1680: // (1)\n case 0x2028: // (2)\n case 0x2029: // \n case 0x202F: // \n case 0x205F: // \n case 0x3000: // \n case 0xFEFF: return true; // \n }\n return false;\n}\n\nexport function isAlpha(c: u32): bool {\n if (isAscii(c)) return (c | 32) - CharCode.a < 26;\n if (c < 0x20000) {\n // @ts-ignore: cast\n return stagedBinaryLookup(ALPHA_TABLE, c);\n }\n return c < 0x2FFFE;\n}\n\n// @ts-ignore: decorator\n@inline\nexport function isCased(c: u32): bool {\n // @ts-ignore: cast\n return c < 0x1F18A && stagedBinaryLookup(CASED, c);\n}\n\n// @ts-ignore: decorator\n@inline\nexport function isCaseIgnorable(c: u32): bool {\n // @ts-ignore: cast\n return c < 0xE01F0 && stagedBinaryLookup(CASE_IGNORABLES, c);\n}\n\n// @ts-ignore: decorator\n@inline\nexport function isFinalSigma(buffer: usize, index: isize, len: isize): bool {\n const lookaheadLimit = 30; // max lookahead limit\n var found = false;\n var pos = index;\n var minPos = max(0, pos - lookaheadLimit);\n while (pos > minPos) {\n let c = codePointBefore(buffer, pos);\n if (!isCaseIgnorable(c)) {\n if (isCased(c)) {\n found = true;\n } else {\n return false;\n }\n }\n pos -= isize(c >= 0x10000) + 1;\n }\n if (!found) return false;\n pos = index + 1;\n var maxPos = min(pos + lookaheadLimit, len);\n while (pos < maxPos) {\n let c = load(buffer + (pos << 1));\n if (u32((c & 0xFC00) == 0xD800) & u32(pos + 1 != len)) {\n let c1 = load(buffer + (pos << 1), 2);\n if ((c1 & 0xFC00) == 0xDC00) {\n c = (c - 0xD800 << 10) + (c1 - 0xDC00) + 0x10000;\n }\n }\n if (!isCaseIgnorable(c)) {\n return !isCased(c);\n }\n pos += isize(c >= 0x10000) + 1;\n }\n return true;\n}\n\n// @ts-ignore: decorator\n@inline\nfunction codePointBefore(buffer: usize, index: isize): i32 {\n if (index <= 0) return -1;\n var c = load(buffer + (index - 1 << 1));\n if (u32((c & 0xFC00) == 0xDC00) & u32(index - 2 >= 0)) {\n let c1 = load(buffer + (index - 2 << 1));\n if ((c1 & 0xFC00) == 0xD800) {\n return ((c1 & 0x3FF) << 10) + (c & 0x3FF) + 0x10000;\n }\n }\n return (c & 0xF800) == 0xD800 ? 0xFFFD : c;\n}\n\n// Search routine for two-staged lookup tables\nfunction stagedBinaryLookup(table: usize, c: u32): bool {\n return ((load(table + (load(table + (c >>> 8)) << 5) + ((c & 255) >> 3)) >>> (c & 7)) & 1);\n}\n\nexport function compareImpl(str1: string, index1: usize, str2: string, index2: usize, len: usize): i32 {\n var ptr1 = changetype(str1) + (index1 << 1);\n var ptr2 = changetype(str2) + (index2 << 1);\n if (ASC_SHRINK_LEVEL < 2) {\n if (len >= 4 && !((ptr1 & 7) | (ptr2 & 7))) {\n do {\n if (load(ptr1) != load(ptr2)) break;\n ptr1 += 8;\n ptr2 += 8;\n len -= 4;\n } while (len >= 4);\n }\n }\n while (len--) {\n let a = load(ptr1);\n let b = load(ptr2);\n if (a != b) return a - b;\n ptr1 += 2;\n ptr2 += 2;\n }\n return 0;\n}\n\n// @ts-ignore: decorator\n@inline\nexport function toLower8(c: u32): u32 {\n if (ASC_SHRINK_LEVEL > 0) {\n return c | u32(isUpper8(c)) << 5;\n } else {\n return load(LOWER127 + c);\n }\n}\n\n// @ts-ignore: decorator\n@inline\nexport function toUpper8(c: u32): u32 {\n if (ASC_SHRINK_LEVEL > 0) {\n return c & ~(u32(isLower8(c)) << 5);\n } else {\n return load(UPPER127 + c);\n }\n}\n\n/** Parses a string to an integer (usually), using the specified radix. */\nexport function strtol(str: string, radix: i32 = 0): T {\n var len = str.length;\n if (!len) {\n if (isFloat()) {\n // @ts-ignore: cast\n return NaN;\n } else {\n // @ts-ignore: cast\n return 0;\n }\n }\n\n var ptr = changetype(str) /* + HEAD -> offset */;\n var code = load(ptr);\n\n // trim white spaces\n while (isSpace(code)) {\n code = load(ptr += 2);\n --len;\n }\n // determine sign\n // @ts-ignore\n var sign: T = 1;\n if (code == CharCode.MINUS || code == CharCode.PLUS) {\n if (!--len) {\n if (isFloat()) {\n // @ts-ignore: cast\n return NaN;\n } else {\n // @ts-ignore: cast\n return 0;\n }\n }\n if (code == CharCode.MINUS) {\n // @ts-ignore: type\n sign = -1;\n }\n code = load(ptr += 2);\n }\n\n // See https://tc39.es/ecma262/#sec-parseint-string-radix\n if (radix) {\n if (radix < 2 || radix > 36) {\n if (isFloat()) {\n // @ts-ignore: cast\n return NaN;\n } else {\n // @ts-ignore: cast\n return 0;\n }\n }\n // handle case as parseInt(\"0xFF\", 16) by spec\n if (radix == 16) {\n if (\n len > 2 &&\n code == CharCode._0 &&\n (load(ptr, 2) | 32) == CharCode.x\n ) {\n ptr += 4; len -= 2;\n }\n }\n } else {\n // determine radix by literal prefix\n if (code == CharCode._0 && len > 2) {\n switch (load(ptr, 2) | 32) {\n case CharCode.b: {\n ptr += 4; len -= 2;\n radix = 2;\n break;\n }\n case CharCode.o: {\n ptr += 4; len -= 2;\n radix = 8;\n break;\n }\n case CharCode.x: {\n ptr += 4; len -= 2;\n radix = 16;\n break;\n }\n }\n }\n if (!radix) radix = 10;\n }\n\n // calculate value\n // @ts-ignore: type\n var num: T = 0;\n var initial = len - 1;\n while (len--) {\n code = load(ptr);\n if (code - CharCode._0 < 10) {\n code -= CharCode._0;\n } else if (code - CharCode.A <= (CharCode.Z - CharCode.A)) {\n code -= CharCode.A - 10;\n } else if (code - CharCode.a <= (CharCode.z - CharCode.a)) {\n code -= CharCode.a - 10;\n }\n if (code >= radix) {\n if (initial == len) {\n if (isFloat()) {\n // @ts-ignore: cast\n return NaN;\n } else {\n // @ts-ignore: cast\n return 0;\n }\n }\n break;\n }\n // @ts-ignore: type\n num = num * radix + code;\n ptr += 2;\n }\n // @ts-ignore: type\n return sign * num;\n}\n\nexport function strtod(str: string): f64 {\n var len = str.length;\n if (!len) return NaN;\n\n var ptr = changetype(str);\n var code = load(ptr);\n\n var sign = 1.0;\n // skip white spaces\n while (len && isSpace(code)) {\n code = load(ptr += 2);\n --len;\n }\n if (!len) return NaN;\n\n // try parse '-' or '+'\n if (code == CharCode.MINUS) {\n if (!--len) return NaN;\n code = load(ptr += 2);\n sign = -1;\n } else if (code == CharCode.PLUS) {\n if (!--len) return NaN;\n code = load(ptr += 2);\n }\n\n // try parse Infinity\n if (len >= 8 && code == CharCode.I) {\n if (\n load(ptr, 0) == 0x690066006E0049 && // ifnI\n load(ptr, 8) == 0x7900740069006E // ytin\n ) {\n return Infinity * sign;\n }\n return NaN;\n }\n // validate next symbol\n if (code != CharCode.DOT && (code - CharCode._0) >= 10) {\n return NaN;\n }\n var savedPtr = ptr;\n // skip zeros\n while (code == CharCode._0) {\n code = load(ptr += 2);\n --len;\n }\n if (len <= 0) return 0.0 * sign;\n const capacity = 19; // int(64 * 0.3010)\n var pointed = false;\n var consumed = 0;\n var position = 0;\n var x: u64 = 0;\n if (code == CharCode.DOT) {\n let noDigits = !(savedPtr - ptr);\n ptr += 2; --len;\n if (!len && noDigits) return NaN;\n for (pointed = true; (code = load(ptr)) == CharCode._0; --position, ptr += 2) --len;\n if (len <= 0) return 0.0 * sign;\n if (!position && noDigits && code - CharCode._0 >= 10) return NaN;\n }\n for (let digit = code - CharCode._0; digit < 10 || (code == CharCode.DOT && !pointed); digit = code - CharCode._0) {\n if (digit < 10) {\n x = consumed < capacity ? 10 * x + digit : x | u64(!!digit);\n ++consumed;\n } else {\n position = consumed;\n pointed = true;\n }\n if (!--len) break;\n code = load(ptr += 2);\n }\n\n if (!pointed) position = consumed;\n return copysign(scientific(x, position - min(capacity, consumed) + parseExp(ptr, len)), sign);\n}\n\nexport function strtob(str: string): bool {\n var size: usize = str.length << 1;\n var offset: usize = 0;\n if (size > 8) {\n // try trim end whitespaces first\n while (size && isSpace(load(changetype(str) + size - 2))) size -= 2;\n if (size > 8) {\n // trim start whitespaces\n while (offset < size && isSpace(load(changetype(str) + offset))) offset += 2;\n size -= offset;\n }\n }\n if (size != 8) return false;\n // \"true\" represents as \\00\\e\\00\\u\\00\\e\\00\\t (00 65 00 75 00 72 00 74)\n return load(changetype(str) + offset) == 0x0065_0075_0072_0074;\n}\n\nexport function joinBooleanArray(dataStart: usize, length: i32, separator: string): string {\n var lastIndex = length - 1;\n if (lastIndex < 0) return \"\";\n if (!lastIndex) return select(\"true\", \"false\", load(dataStart));\n\n var sepLen = separator.length;\n var valueLen = 5; // max possible length of element len(\"false\")\n var estLen = (valueLen + sepLen) * lastIndex + valueLen;\n var result = changetype(__new(estLen << 1, idof()));\n var offset = 0;\n var value: bool;\n for (let i = 0; i < lastIndex; ++i) {\n value = load(dataStart + i);\n valueLen = 4 + i32(!value);\n memory.copy(\n changetype(result) + (offset << 1),\n changetype(select(\"true\", \"false\", value)),\n valueLen << 1\n );\n offset += valueLen;\n if (sepLen) {\n memory.copy(\n changetype(result) + (offset << 1),\n changetype(separator),\n sepLen << 1\n );\n offset += sepLen;\n }\n }\n value = load(dataStart + lastIndex);\n valueLen = 4 + i32(!value);\n memory.copy(\n changetype(result) + (offset << 1),\n changetype(select(\"true\", \"false\", value)),\n valueLen << 1\n );\n offset += valueLen;\n\n if (estLen > offset) return result.substring(0, offset);\n return result;\n}\n\nexport function joinIntegerArray(dataStart: usize, length: i32, separator: string): string {\n var lastIndex = length - 1;\n if (lastIndex < 0) return \"\";\n if (!lastIndex) {\n let value = load(dataStart);\n if (isSigned()) {\n if (sizeof() <= 4) {\n // @ts-ignore: type\n return changetype(itoa32(value, 10));\n } else {\n // @ts-ignore: type\n return changetype(itoa64(value, 10));\n }\n } else {\n if (sizeof() <= 4) {\n // @ts-ignore: type\n return changetype(utoa32(value, 10));\n } else {\n // @ts-ignore: type\n return changetype(utoa64(value, 10));\n }\n }\n }\n\n var sepLen = separator.length;\n const valueLen = (sizeof() <= 4 ? 10 : 20) + i32(isSigned());\n var estLen = (valueLen + sepLen) * lastIndex + valueLen;\n var result = changetype(__new(estLen << 1, idof()));\n var offset = 0;\n var value: T;\n for (let i = 0; i < lastIndex; ++i) {\n value = load(dataStart + (i << alignof()));\n // @ts-ignore: type\n offset += itoa_buffered(changetype(result) + (offset << 1), value);\n if (sepLen) {\n memory.copy(\n changetype(result) + (offset << 1),\n changetype(separator),\n sepLen << 1\n );\n offset += sepLen;\n }\n }\n value = load(dataStart + (lastIndex << alignof()));\n // @ts-ignore: type\n offset += itoa_buffered(changetype(result) + (offset << 1), value);\n if (estLen > offset) return result.substring(0, offset);\n return result;\n}\n\nexport function joinFloatArray(dataStart: usize, length: i32, separator: string): string {\n var lastIndex = length - 1;\n if (lastIndex < 0) return \"\";\n if (!lastIndex) {\n return changetype(dtoa(\n // @ts-ignore: type\n load(dataStart))\n );\n }\n\n const valueLen = MAX_DOUBLE_LENGTH;\n var sepLen = separator.length;\n var estLen = (valueLen + sepLen) * lastIndex + valueLen;\n var result = changetype(__new(estLen << 1, idof()));\n var offset = 0;\n var value: T;\n for (let i = 0; i < lastIndex; ++i) {\n value = load(dataStart + (i << alignof()));\n // @ts-ignore: type\n offset += dtoa_buffered(changetype(result) + (offset << 1), value);\n if (sepLen) {\n memory.copy(\n changetype(result) + (offset << 1),\n changetype(separator),\n sepLen << 1\n );\n offset += sepLen;\n }\n }\n value = load(dataStart + (lastIndex << alignof()));\n // @ts-ignore: type\n offset += dtoa_buffered(changetype(result) + (offset << 1), value);\n if (estLen > offset) return result.substring(0, offset);\n return result;\n}\n\nexport function joinStringArray(dataStart: usize, length: i32, separator: string): string {\n var lastIndex = length - 1;\n if (lastIndex < 0) return \"\";\n if (!lastIndex) {\n // @ts-ignore: type\n return load(dataStart) || \"\";\n }\n var estLen = 0;\n var value: string;\n for (let i = 0; i < length; ++i) {\n value = load(dataStart + (i << alignof()));\n if (changetype(value) != 0) estLen += value.length;\n }\n var offset = 0;\n var sepLen = separator.length;\n var result = changetype(__new((estLen + sepLen * lastIndex) << 1, idof()));\n for (let i = 0; i < lastIndex; ++i) {\n value = load(dataStart + (i << alignof()));\n if (changetype(value) != 0) {\n let valueLen = value.length;\n memory.copy(\n changetype(result) + (offset << 1),\n changetype(value),\n valueLen << 1\n );\n offset += valueLen;\n }\n if (sepLen) {\n memory.copy(\n changetype(result) + (offset << 1),\n changetype(separator),\n sepLen << 1\n );\n offset += sepLen;\n }\n }\n value = load(dataStart + (lastIndex << alignof()));\n if (changetype(value) != 0) {\n memory.copy(\n changetype(result) + (offset << 1),\n changetype(value),\n value.length << 1\n );\n }\n return result;\n}\n\nexport function joinReferenceArray(dataStart: usize, length: i32, separator: string): string {\n var lastIndex = length - 1;\n if (lastIndex < 0) return \"\";\n var value: T;\n if (!lastIndex) {\n value = load(dataStart);\n // @ts-ignore: type\n return value != null ? value.toString() : \"\";\n }\n var result = \"\";\n var sepLen = separator.length;\n for (let i = 0; i < lastIndex; ++i) {\n value = load(dataStart + (i << alignof()));\n // @ts-ignore: type\n if (value != null) result += value.toString();\n if (sepLen) result += separator;\n }\n value = load(dataStart + (lastIndex << alignof()));\n // @ts-ignore: type\n if (value != null) result += value.toString();\n return result;\n}\n\n// @ts-ignore: decorator\n@inline\nfunction scientific(significand: u64, exp: i32): f64 {\n if (!significand || exp < -342) return 0;\n if (exp > 308) return Infinity;\n // Try use fast path\n // Use fast path for string-to-double conversion if possible\n // see http://www.exploringbinary.com/fast-path-decimal-to-floating-point-conversion\n // Simple integer\n var significandf = significand;\n if (!exp) return significandf;\n if (exp > 22 && exp <= 22 + 15) {\n significandf *= pow10(exp - 22);\n exp = 22;\n }\n if (significand <= 9007199254740991 && abs(exp) <= 22) {\n if (exp > 0) return significandf * pow10(exp);\n return significandf / pow10(-exp);\n } else if (exp < 0) {\n return scaledown(significand, exp);\n } else {\n return scaleup(significand, exp);\n }\n}\n\n// Adopted from metallic lib:\n// https://github.com/jdh8/metallic/blob/master/src/stdlib/parse/scientific.h\n// @ts-ignore: decorator\n@inline\nfunction scaledown(significand: u64, exp: i32): f64 {\n const denom: u64 = 6103515625; // 1e14 * 0x1p-14\n const scale = reinterpret(0x3F06849B86A12B9B); // 1e-14 * 0x1p32\n\n var shift = clz(significand);\n significand <<= shift;\n shift = exp - shift;\n\n for (; exp <= -14; exp += 14) {\n let q = significand / denom;\n let r = significand % denom;\n let s = clz(q);\n significand = (q << s) + nearest(scale * (r << (s - 18)));\n shift -= s;\n }\n var b = ipow32(5, -exp);\n var q = significand / b;\n var r = significand % b;\n var s = clz(q);\n significand = (q << s) + (reinterpret(reinterpret(r) + (s << 52)) / b);\n shift -= s;\n\n return NativeMath.scalbn(significand, shift);\n}\n\n// Adopted from metallic lib:\n// https://github.com/jdh8/metallic/blob/master/src/stdlib/parse/scientific.h\n// @ts-ignore: decorator\n@inline\nfunction scaleup(significand: u64, exp: i32): f64 {\n const coeff: u32 = 1220703125; // 1e13 * 0x1p-13;\n var shift = ctz(significand);\n significand >>= shift;\n shift += exp;\n\n __fixmulShift = shift;\n for (; exp >= 13; exp -= 13) {\n significand = fixmul(significand, coeff);\n }\n significand = fixmul(significand, ipow32(5, exp));\n shift = __fixmulShift;\n return NativeMath.scalbn(significand, shift);\n}\n\n// Adopted from metallic lib:\n// https://github.com/jdh8/metallic/blob/master/src/stdlib/parse/scientific.h\n// @ts-ignore: decorator\n@inline\nfunction parseExp(ptr: usize, len: i32): i32 {\n var sign = 1, magnitude = 0;\n var code = load(ptr);\n // check code is 'e' or 'E'\n if ((code | 32) != CharCode.e) return 0;\n\n if (!--len) return 0;\n code = load(ptr += 2);\n if (code == CharCode.MINUS) {\n if (!--len) return 0;\n code = load(ptr += 2);\n sign = -1;\n } else if (code == CharCode.PLUS) {\n if (!--len) return 0;\n code = load(ptr += 2);\n }\n // skip zeros\n while (code == CharCode._0) {\n if (!--len) return 0;\n code = load(ptr += 2);\n }\n for (let digit: u32 = code - CharCode._0; len && digit < 10; digit = code - CharCode._0) {\n if (magnitude >= 3200) return sign * 3200;\n magnitude = 10 * magnitude + digit;\n code = load(ptr += 2);\n --len;\n }\n return sign * magnitude;\n}\n\n// @ts-ignore: decorator\n@lazy var __fixmulShift: u64 = 0;\n\n// Adopted from metallic lib:\n// https://github.com/jdh8/metallic/blob/master/src/stdlib/parse/scientific.h\n// @ts-ignore: decorator\n@inline\nfunction fixmul(a: u64, b: u32): u64 {\n var low = (a & 0xFFFFFFFF) * b;\n var high = (a >> 32) * b + (low >> 32);\n var overflow = (high >> 32);\n var space = clz(overflow);\n var revspace: u64 = 32 - space;\n __fixmulShift += revspace;\n return (high << space | (low & 0xFFFFFFFF) >> revspace) + (low << space >> 31 & 1);\n}\n\n// @ts-ignore: decorator\n@inline\nfunction pow10(n: i32): f64 {\n // argument `n` should bounds in [0, 22] range\n return load(POWERS10 + (n << alignof()));\n}\n","import { Math as JSMath } from \"./bindings/dom\";\nexport { JSMath };\n\nimport {\n pow_lut, exp_lut, exp2_lut, log_lut, log2_lut,\n powf_lut, expf_lut, exp2f_lut, logf_lut, log2f_lut\n} from \"./util/math\";\n\nimport {\n abs as builtin_abs,\n ceil as builtin_ceil,\n clz as builtin_clz,\n copysign as builtin_copysign,\n floor as builtin_floor,\n max as builtin_max,\n min as builtin_min,\n sqrt as builtin_sqrt,\n trunc as builtin_trunc\n} from \"./builtins\";\n\n// SUN COPYRIGHT NOTICE\n//\n// Copyright (C) 1993 by Sun Microsystems, Inc. All rights reserved.\n// Developed at SunPro, a Sun Microsystems, Inc. business.\n// Permission to use, copy, modify, and distribute this software\n// is freely granted, provided that this notice is preserved.\n//\n// Applies to all functions marked with a comment referring here.\n\n/** @internal */\n// @ts-ignore: decorator\n@lazy var rempio2_y0: f64, rempio2_y1: f64, res128_hi: u64;\n\n/** @internal */\n// @ts-ignore: decorator\n@lazy @inline const PIO2_TABLE = memory.data([\n 0x00000000A2F9836E, 0x4E441529FC2757D1, 0xF534DDC0DB629599, 0x3C439041FE5163AB,\n 0xDEBBC561B7246E3A, 0x424DD2E006492EEA, 0x09D1921CFE1DEB1C, 0xB129A73EE88235F5,\n 0x2EBB4484E99C7026, 0xB45F7E413991D639, 0x835339F49C845F8B, 0xBDF9283B1FF897FF,\n 0xDE05980FEF2F118B, 0x5A0A6D1F6D367ECF, 0x27CB09B74F463F66, 0x9E5FEA2D7527BAC7,\n 0xEBE5F17B3D0739F7, 0x8A5292EA6BFB5FB1, 0x1F8D5D0856033046, 0xFC7B6BABF0CFBC20,\n 0x9AF4361DA9E39161, 0x5EE61B086599855F, 0x14A068408DFFD880, 0x4D73273106061557\n]);\n\n/** @internal */\nfunction R(z: f64): f64 { // Rational approximation of (asin(x)-x)/x^3\n const // see: musl/src/math/asin.c and SUN COPYRIGHT NOTICE above\n pS0 = reinterpret(0x3FC5555555555555), // 1.66666666666666657415e-01\n pS1 = reinterpret(0xBFD4D61203EB6F7D), // -3.25565818622400915405e-01\n pS2 = reinterpret(0x3FC9C1550E884455), // 2.01212532134862925881e-01\n pS3 = reinterpret(0xBFA48228B5688F3B), // -4.00555345006794114027e-02\n pS4 = reinterpret(0x3F49EFE07501B288), // 7.91534994289814532176e-04\n pS5 = reinterpret(0x3F023DE10DFDF709), // 3.47933107596021167570e-05\n qS1 = reinterpret(0xC0033A271C8A2D4B), // -2.40339491173441421878e+00\n qS2 = reinterpret(0x40002AE59C598AC8), // 2.02094576023350569471e+00\n qS3 = reinterpret(0xBFE6066C1B8D0159), // -6.88283971605453293030e-01\n qS4 = reinterpret(0x3FB3B8C5B12E9282); // 7.70381505559019352791e-02\n\n var p = z * (pS0 + z * (pS1 + z * (pS2 + z * (pS3 + z * (pS4 + z * pS5)))));\n var q = 1.0 + z * (qS1 + z * (qS2 + z * (qS3 + z * qS4)));\n return p / q;\n}\n\n/** @internal */\n// @ts-ignore: decorator\n@inline\nfunction expo2(x: f64, sign: f64): f64 { // exp(x)/2 for x >= log(DBL_MAX)\n const // see: musl/src/math/__expo2.c\n k = 2043,\n kln2 = reinterpret(0x40962066151ADD8B); // 0x1.62066151add8bp+10\n var scale = reinterpret(((0x3FF + k / 2) << 20) << 32);\n // in directed rounding correct sign before rounding or overflow is important\n return NativeMath.exp(x - kln2) * (sign * scale) * scale;\n}\n\n/** @internal */\n/* Helper function to eventually get bits of π/2 * |x|\n *\n * y = π/4 * (frac << clz(frac) >> 11)\n * return clz(frac)\n *\n * Right shift 11 bits to make upper half fit in `double`\n */\n// @ts-ignore: decorator\n@inline\nfunction pio2_right(q0: u64, q1: u64): u64 { // see: jdh8/metallic/blob/master/src/math/double/rem_pio2.c\n // Bits of π/4\n const p0: u64 = 0xC4C6628B80DC1CD1;\n const p1: u64 = 0xC90FDAA22168C234;\n\n const Ox1p_64 = reinterpret(0x3BF0000000000000); // 0x1p-64\n const Ox1p_75 = reinterpret(0x3B40000000000000); // 0x1p-75\n\n var shift = clz(q1);\n\n q1 = q1 << shift | q0 >> (64 - shift);\n q0 <<= shift;\n\n var lo = umuldi(p1, q1);\n var hi = res128_hi;\n\n var ahi = hi >> 11;\n var alo = lo >> 11 | hi << 53;\n var blo = (Ox1p_75 * p0 * q1 + Ox1p_75 * p1 * q0);\n\n rempio2_y0 = (ahi + u64(lo < blo));\n rempio2_y1 = Ox1p_64 * (alo + blo);\n\n return shift;\n}\n\n/** @internal */\n// @ts-ignore: decorator\n@inline\nfunction umuldi(u: u64, v: u64): u64 {\n var u1: u64 , v1: u64, w0: u64, w1: u64, t: u64;\n\n u1 = u & 0xFFFFFFFF;\n v1 = v & 0xFFFFFFFF;\n\n u >>= 32;\n v >>= 32;\n\n t = u1 * v1;\n w0 = t & 0xFFFFFFFF;\n t = u * v1 + (t >> 32);\n w1 = t >> 32;\n t = u1 * v + (t & 0xFFFFFFFF);\n\n res128_hi = u * v + w1 + (t >> 32);\n return (t << 32) + w0;\n}\n\n/** @internal */\nfunction pio2_large_quot(x: f64, u: i64): i32 { // see: jdh8/metallic/blob/master/src/math/double/rem_pio2.c\n var magnitude = u & 0x7FFFFFFFFFFFFFFF;\n var offset = (magnitude >> 52) - 1045;\n var shift = offset & 63;\n var tblPtr = PIO2_TABLE + ((offset >> 6) << 3);\n var s0: u64, s1: u64, s2: u64;\n\n var b0 = load(tblPtr, 0 << 3);\n var b1 = load(tblPtr, 1 << 3);\n var b2 = load(tblPtr, 2 << 3);\n\n // Get 192 bits of 0x1p-31 / π with `offset` bits skipped\n if (shift) {\n let rshift = 64 - shift;\n let b3 = load(tblPtr, 3 << 3);\n s0 = b1 >> rshift | b0 << shift;\n s1 = b2 >> rshift | b1 << shift;\n s2 = b3 >> rshift | b2 << shift;\n } else {\n s0 = b0;\n s1 = b1;\n s2 = b2;\n }\n\n var significand = (u & 0x000FFFFFFFFFFFFF) | 0x0010000000000000;\n\n // First 128 bits of fractional part of x/(2π)\n var blo = umuldi(s1, significand);\n var bhi = res128_hi;\n\n var ahi = s0 * significand;\n var clo = (s2 >> 32) * (significand >> 32);\n var plo = blo + clo;\n var phi = ahi + bhi + u64(plo < clo);\n\n // r: u128 = p << 2\n var rlo = plo << 2;\n var rhi = phi << 2 | plo >> 62;\n\n // s: i128 = r >> 127\n var slo = rhi >> 63;\n var shi = slo >> 1;\n var q = (phi >> 62) - slo;\n\n var shifter = 0x3CB0000000000000 - (pio2_right(rlo ^ slo, rhi ^ shi) << 52);\n var signbit = (u ^ rhi) & 0x8000000000000000;\n var coeff = reinterpret(shifter | signbit);\n\n rempio2_y0 *= coeff;\n rempio2_y1 *= coeff;\n\n return q;\n}\n\n/** @internal */\n// @ts-ignore: decorator\n@inline\nfunction rempio2(x: f64, u: u64, sign: i32): i32 {\n const\n pio2_1 = reinterpret(0x3FF921FB54400000), // 1.57079632673412561417e+00\n pio2_1t = reinterpret(0x3DD0B4611A626331), // 6.07710050650619224932e-11\n pio2_2 = reinterpret(0x3DD0B4611A600000), // 6.07710050630396597660e-11\n pio2_2t = reinterpret(0x3BA3198A2E037073), // 2.02226624879595063154e-21\n pio2_3 = reinterpret(0x3BA3198A2E000000), // 2.02226624871116645580e-21\n pio2_3t = reinterpret(0x397B839A252049C1), // 8.47842766036889956997e-32\n invpio2 = reinterpret(0x3FE45F306DC9C883); // 0.63661977236758134308\n\n var ix = (u >> 32) & 0x7FFFFFFF;\n\n if (ASC_SHRINK_LEVEL < 1) {\n if (ix < 0x4002D97C) { // |x| < 3pi/4, special case with n=+-1\n let q = 1, z: f64, y0: f64, y1: f64;\n if (!sign) {\n z = x - pio2_1;\n if (ix != 0x3FF921FB) { // 33+53 bit pi is good enough\n y0 = z - pio2_1t;\n y1 = (z - y0) - pio2_1t;\n } else { // near pi/2, use 33+33+53 bit pi\n z -= pio2_2;\n y0 = z - pio2_2t;\n y1 = (z - y0) - pio2_2t;\n }\n } else { // negative x\n z = x + pio2_1;\n if (ix != 0x3FF921FB) { // 33+53 bit pi is good enough\n y0 = z + pio2_1t;\n y1 = (z - y0) + pio2_1t;\n } else { // near pi/2, use 33+33+53 bit pi\n z += pio2_2;\n y0 = z + pio2_2t;\n y1 = (z - y0) + pio2_2t;\n }\n q = -1;\n }\n rempio2_y0 = y0;\n rempio2_y1 = y1;\n return q;\n }\n }\n\n if (ix < 0x413921FB) { // |x| ~< 2^20*pi/2 (1647099)\n // Use precise Cody Waite scheme\n let q = nearest(x * invpio2);\n let r = x - q * pio2_1;\n let w = q * pio2_1t; // 1st round good to 85 bit\n let j = ix >> 20;\n let y0 = r - w;\n let hi = (reinterpret(y0) >> 32);\n let i = j - ((hi >> 20) & 0x7FF);\n\n if (i > 16) { // 2nd iteration needed, good to 118\n let t = r;\n w = q * pio2_2;\n r = t - w;\n w = q * pio2_2t - ((t - r) - w);\n y0 = r - w;\n hi = (reinterpret(y0) >> 32);\n i = j - ((hi >> 20) & 0x7FF);\n if (i > 49) { // 3rd iteration need, 151 bits acc\n let t = r;\n w = q * pio2_3;\n r = t - w;\n w = q * pio2_3t - ((t - r) - w);\n y0 = r - w;\n }\n }\n let y1 = (r - y0) - w;\n rempio2_y0 = y0;\n rempio2_y1 = y1;\n return q;\n }\n var q = pio2_large_quot(x, u);\n return select(-q, q, sign);\n}\n\n/** @internal */\n// @ts-ignore: decorator\n@inline\nfunction sin_kern(x: f64, y: f64, iy: i32): f64 { // see: musl/tree/src/math/__sin.c\n const\n S1 = reinterpret(0xBFC5555555555549), // -1.66666666666666324348e-01\n S2 = reinterpret(0x3F8111111110F8A6), // 8.33333333332248946124e-03\n S3 = reinterpret(0xBF2A01A019C161D5), // -1.98412698298579493134e-04\n S4 = reinterpret(0x3EC71DE357B1FE7D), // 2.75573137070700676789e-06\n S5 = reinterpret(0xBE5AE5E68A2B9CEB), // -2.50507602534068634195e-08\n S6 = reinterpret(0x3DE5D93A5ACFD57C); // 1.58969099521155010221e-10\n\n var z = x * x;\n var w = z * z;\n var r = S2 + z * (S3 + z * S4) + z * w * (S5 + z * S6);\n var v = z * x;\n if (!iy) {\n return x + v * (S1 + z * r);\n } else {\n return x - ((z * (0.5 * y - v * r) - y) - v * S1);\n }\n}\n\n/** @internal */\n// @ts-ignore: decorator\n@inline\nfunction cos_kern(x: f64, y: f64): f64 { // see: musl/tree/src/math/__cos.c\n const\n C1 = reinterpret(0x3FA555555555554C), // 4.16666666666666019037e-02\n C2 = reinterpret(0xBF56C16C16C15177), // -1.38888888888741095749e-03\n C3 = reinterpret(0x3EFA01A019CB1590), // 2.48015872894767294178e-05\n C4 = reinterpret(0xBE927E4F809C52AD), // -2.75573143513906633035e-07\n C5 = reinterpret(0x3E21EE9EBDB4B1C4), // 2.08757232129817482790e-09\n C6 = reinterpret(0xBDA8FAE9BE8838D4); // -1.13596475577881948265e-11\n\n var z = x * x;\n var w = z * z;\n var r = z * (C1 + z * (C2 + z * C3)) + w * w * (C4 + z * (C5 + z * C6));\n var hz = 0.5 * z;\n w = 1.0 - hz;\n return w + (((1.0 - w) - hz) + (z * r - x * y));\n}\n\n/** @internal */\nfunction tan_kern(x: f64, y: f64, iy: i32): f64 { // see: src/lib/msun/src/k_tan.c\n const\n T0 = reinterpret(0x3FD5555555555563), // 3.33333333333334091986e-01\n T1 = reinterpret(0x3FC111111110FE7A), // 1.33333333333201242699e-01\n T2 = reinterpret(0x3FABA1BA1BB341FE), // 5.39682539762260521377e-02\n T3 = reinterpret(0x3F9664F48406D637), // 2.18694882948595424599e-02\n T4 = reinterpret(0x3F8226E3E96E8493), // 8.86323982359930005737e-03\n T5 = reinterpret(0x3F6D6D22C9560328), // 3.59207910759131235356e-03\n T6 = reinterpret(0x3F57DBC8FEE08315), // 1.45620945432529025516e-03\n T7 = reinterpret(0x3F4344D8F2F26501), // 5.88041240820264096874e-04\n T8 = reinterpret(0x3F3026F71A8D1068), // 2.46463134818469906812e-04\n T9 = reinterpret(0x3F147E88A03792A6), // 7.81794442939557092300e-05\n T10 = reinterpret(0x3F12B80F32F0A7E9), // 7.14072491382608190305e-05\n T11 = reinterpret(0xBEF375CBDB605373), // -1.85586374855275456654e-05\n T12 = reinterpret(0x3EFB2A7074BF7AD4); // 2.59073051863633712884e-05\n\n const\n one = reinterpret(0x3FF0000000000000), // 1.00000000000000000000e+00\n pio4 = reinterpret(0x3FE921FB54442D18), // 7.85398163397448278999e-01\n pio4lo = reinterpret(0x3C81A62633145C07); // 3.06161699786838301793e-17\n\n var z: f64, r: f64, v: f64, w: f64, s: f64;\n var hx = (reinterpret(x) >> 32); // high word of x\n var ix = hx & 0x7FFFFFFF; // high word of |x|\n var big = ix >= 0x3FE59428;\n if (big) { // |x| >= 0.6744\n if (hx < 0) { x = -x, y = -y; }\n z = pio4 - x;\n w = pio4lo - y;\n x = z + w;\n y = 0.0;\n }\n z = x * x;\n w = z * z;\n r = T1 + w * (T3 + w * (T5 + w * (T7 + w * (T9 + w * T11))));\n v = z * (T2 + w * (T4 + w * (T6 + w * (T8 + w * (T10 + w * T12)))));\n s = z * x;\n r = y + z * (s * (r + v) + y);\n r += T0 * s;\n w = x + r;\n if (big) {\n v = iy;\n return (1 - ((hx >> 30) & 2)) * (v - 2.0 * (x - (w * w / (w + v) - r)));\n }\n if (iy == 1) return w;\n var a: f64, t: f64;\n z = w;\n z = reinterpret(reinterpret(z) & 0xFFFFFFFF00000000);\n v = r - (z - x); // z + v = r + x\n t = a = -one / w; // a = -1.0 / w\n t = reinterpret(reinterpret(t) & 0xFFFFFFFF00000000);\n s = one + t * z;\n return t + a * (s + t * v);\n}\n\n/** @internal */\nfunction dtoi32(x: f64): i32 {\n if (ASC_SHRINK_LEVEL > 0) {\n const inv32 = 1.0 / 4294967296;\n return (x - 4294967296 * floor(x * inv32));\n } else {\n let result = 0;\n let u = reinterpret(x);\n let e = (u >> 52) & 0x7FF;\n if (e <= 1023 + 30) {\n result = x;\n } else if (e <= 1023 + 30 + 53) {\n let v = (u & ((1 << 52) - 1)) | (1 << 52);\n v = v << e - 1023 - 52 + 32;\n result = (v >> 32);\n result = select(-result, result, u < 0);\n }\n return result;\n }\n}\n\n// @ts-ignore: decorator\n@lazy var random_seeded = false;\n\n// @ts-ignore: decorator\n@lazy var random_state0_64: u64, random_state1_64: u64;\n\n// @ts-ignore: decorator\n@lazy var random_state0_32: u32, random_state1_32: u32;\n\nfunction murmurHash3(h: u64): u64 { // Force all bits of a hash block to avalanche\n h ^= h >> 33; // see: https://github.com/aappleby/smhasher\n h *= 0xFF51AFD7ED558CCD;\n h ^= h >> 33;\n h *= 0xC4CEB9FE1A85EC53;\n h ^= h >> 33;\n return h;\n}\n\nfunction splitMix32(h: u32): u32 {\n h += 0x6D2B79F5;\n h = (h ^ (h >> 15)) * (h | 1);\n h ^= h + (h ^ (h >> 7)) * (h | 61);\n return h ^ (h >> 14);\n}\n\nexport namespace NativeMath {\n\n // @ts-ignore: decorator\n @lazy\n export const E = reinterpret(0x4005BF0A8B145769); // 2.7182818284590452354\n\n // @ts-ignore: decorator\n @lazy\n export const LN2 = reinterpret(0x3FE62E42FEFA39EF); // 0.69314718055994530942\n\n // @ts-ignore: decorator\n @lazy\n export const LN10 = reinterpret(0x40026BB1BBB55516); // 2.30258509299404568402\n\n // @ts-ignore: decorator\n @lazy\n export const LOG2E = reinterpret(0x3FF71547652B82FE); // 1.4426950408889634074\n\n // @ts-ignore: decorator\n @lazy\n export const LOG10E = reinterpret(0x3FDBCB7B1526E50E); // 0.43429448190325182765\n\n // @ts-ignore: decorator\n @lazy\n export const PI = reinterpret(0x400921FB54442D18); // 3.14159265358979323846\n\n // @ts-ignore: decorator\n @lazy\n export const SQRT1_2 = reinterpret(0x3FE6A09E667F3BCD); // 0.70710678118654752440\n\n // @ts-ignore: decorator\n @lazy\n export const SQRT2 = reinterpret(0x3FF6A09E667F3BCD); // 1.41421356237309504880\n\n // @ts-ignore: decorator\n @lazy\n export var sincos_sin: f64 = 0;\n\n // @ts-ignore: decorator\n @lazy\n export var sincos_cos: f64 = 0;\n\n // @ts-ignore: decorator\n @inline export function abs(x: f64): f64 {\n return builtin_abs(x);\n }\n\n export function acos(x: f64): f64 { // see: musl/src/math/acos.c and SUN COPYRIGHT NOTICE above\n const\n pio2_hi = reinterpret(0x3FF921FB54442D18), // 1.57079632679489655800e+00\n pio2_lo = reinterpret(0x3C91A62633145C07), // 6.12323399573676603587e-17\n Ox1p_120f = reinterpret(0x03800000);\n\n var hx = (reinterpret(x) >> 32);\n var ix = hx & 0x7FFFFFFF;\n if (ix >= 0x3FF00000) {\n let lx = reinterpret(x);\n if ((ix - 0x3FF00000 | lx) == 0) {\n if (hx < 0) return 2 * pio2_hi + Ox1p_120f;\n return 0;\n }\n return 0 / (x - x);\n }\n if (ix < 0x3FE00000) {\n if (ix <= 0x3C600000) return pio2_hi + Ox1p_120f;\n return pio2_hi - (x - (pio2_lo - x * R(x * x)));\n }\n var s: f64, w: f64, z: f64;\n if (hx < 0) {\n // z = (1.0 + x) * 0.5;\n z = 0.5 + x * 0.5;\n s = builtin_sqrt(z);\n w = R(z) * s - pio2_lo;\n return 2 * (pio2_hi - (s + w));\n }\n // z = (1.0 - x) * 0.5;\n z = 0.5 - x * 0.5;\n s = builtin_sqrt(z);\n var df = reinterpret(reinterpret(s) & 0xFFFFFFFF00000000);\n var c = (z - df * df) / (s + df);\n w = R(z) * s + c;\n return 2 * (df + w);\n }\n\n export function acosh(x: f64): f64 { // see: musl/src/math/acosh.c\n const s = reinterpret(0x3FE62E42FEFA39EF);\n var u = reinterpret(x);\n // Prevent propagation for all input values less than 1.0.\n // Note musl lib didn't fix this yet.\n if (u < 0x3FF0000000000000) return (x - x) / 0.0;\n var e = u >> 52 & 0x7FF;\n if (e < 0x3FF + 1) return log1p(x - 1 + builtin_sqrt((x - 1) * (x - 1) + 2 * (x - 1)));\n if (e < 0x3FF + 26) return log(2 * x - 1 / (x + builtin_sqrt(x * x - 1)));\n return log(x) + s;\n }\n\n export function asin(x: f64): f64 { // see: musl/src/math/asin.c and SUN COPYRIGHT NOTICE above\n const\n pio2_hi = reinterpret(0x3FF921FB54442D18), // 1.57079632679489655800e+00\n pio2_lo = reinterpret(0x3C91A62633145C07), // 6.12323399573676603587e-17\n Ox1p_120f = reinterpret(0x03800000);\n\n var hx = (reinterpret(x) >> 32);\n var ix = hx & 0x7FFFFFFF;\n if (ix >= 0x3FF00000) {\n let lx = reinterpret(x);\n if ((ix - 0x3FF00000 | lx) == 0) return x * pio2_hi + Ox1p_120f;\n return 0 / (x - x);\n }\n if (ix < 0x3FE00000) {\n if (ix < 0x3E500000 && ix >= 0x00100000) return x;\n return x + x * R(x * x);\n }\n // var z = (1.0 - builtin_abs(x)) * 0.5;\n var z = 0.5 - builtin_abs(x) * 0.5;\n var s = builtin_sqrt(z);\n var r = R(z);\n if (ix >= 0x3FEF3333) x = pio2_hi - (2 * (s + s * r) - pio2_lo);\n else {\n let f = reinterpret(reinterpret(s) & 0xFFFFFFFF00000000);\n let c = (z - f * f) / (s + f);\n x = 0.5 * pio2_hi - (2 * s * r - (pio2_lo - 2 * c) - (0.5 * pio2_hi - 2 * f));\n }\n return select(-x, x, hx < 0);\n }\n\n export function asinh(x: f64): f64 { // see: musl/src/math/asinh.c\n const c = reinterpret(0x3FE62E42FEFA39EF); // 0.693147180559945309417232121458176568\n var u = reinterpret(x);\n var e = u >> 52 & 0x7FF;\n var y = reinterpret(u & 0x7FFFFFFFFFFFFFFF);\n if (e >= 0x3FF + 26) y = log(y) + c;\n else if (e >= 0x3FF + 1) y = log(2 * y + 1 / (builtin_sqrt(y * y + 1) + y));\n else if (e >= 0x3FF - 26) y = log1p(y + y * y / (builtin_sqrt(y * y + 1) + 1));\n return builtin_copysign(y, x);\n }\n\n export function atan(x: f64): f64 { // see musl/src/math/atan.c and SUN COPYRIGHT NOTICE above\n const\n atanhi0 = reinterpret(0x3FDDAC670561BB4F), // 4.63647609000806093515e-01\n atanhi1 = reinterpret(0x3FE921FB54442D18), // 7.85398163397448278999e-01\n atanhi2 = reinterpret(0x3FEF730BD281F69B), // 9.82793723247329054082e-01\n atanhi3 = reinterpret(0x3FF921FB54442D18), // 1.57079632679489655800e+00\n atanlo0 = reinterpret(0x3C7A2B7F222F65E2), // 2.26987774529616870924e-17\n atanlo1 = reinterpret(0x3C81A62633145C07), // 3.06161699786838301793e-17\n atanlo2 = reinterpret(0x3C7007887AF0CBBD), // 1.39033110312309984516e-17\n atanlo3 = reinterpret(0x3C91A62633145C07), // 6.12323399573676603587e-17\n aT0 = reinterpret(0x3FD555555555550D), // 3.33333333333329318027e-01\n aT1 = reinterpret(0xBFC999999998EBC4), // -1.99999999998764832476e-01\n aT2 = reinterpret(0x3FC24924920083FF), // 1.42857142725034663711e-01\n aT3 = reinterpret(0xBFBC71C6FE231671), // -1.11111104054623557880e-01,\n aT4 = reinterpret(0x3FB745CDC54C206E), // 9.09088713343650656196e-02\n aT5 = reinterpret(0xBFB3B0F2AF749A6D), // -7.69187620504482999495e-02\n aT6 = reinterpret(0x3FB10D66A0D03D51), // 6.66107313738753120669e-02\n aT7 = reinterpret(0xBFADDE2D52DEFD9A), // -5.83357013379057348645e-02\n aT8 = reinterpret(0x3FA97B4B24760DEB), // 4.97687799461593236017e-02\n aT9 = reinterpret(0xBFA2B4442C6A6C2F), // -3.65315727442169155270e-02\n aT10 = reinterpret(0x3F90AD3AE322DA11), // 1.62858201153657823623e-02\n Ox1p_120f = reinterpret(0x03800000);\n\n var ix = (reinterpret(x) >> 32);\n var sx = x;\n ix &= 0x7FFFFFFF;\n var z: f64;\n if (ix >= 0x44100000) {\n if (isNaN(x)) return x;\n z = atanhi3 + Ox1p_120f;\n return builtin_copysign(z, sx);\n }\n var id: i32;\n if (ix < 0x3FDC0000) {\n if (ix < 0x3E400000) return x;\n id = -1;\n } else {\n x = builtin_abs(x);\n if (ix < 0x3FF30000) {\n if (ix < 0x3FE60000) {\n id = 0;\n x = (2.0 * x - 1.0) / (2.0 + x);\n } else {\n id = 1;\n x = (x - 1.0) / (x + 1.0);\n }\n } else {\n if (ix < 0x40038000) {\n id = 2;\n x = (x - 1.5) / (1.0 + 1.5 * x);\n } else {\n id = 3;\n x = -1.0 / x;\n }\n }\n }\n z = x * x;\n var w = z * z;\n var s1 = z * (aT0 + w * (aT2 + w * (aT4 + w * (aT6 + w * (aT8 + w * aT10)))));\n var s2 = w * (aT1 + w * (aT3 + w * (aT5 + w * (aT7 + w * aT9))));\n var s3 = x * (s1 + s2);\n if (id < 0) return x - s3;\n switch (id) {\n case 0: { z = atanhi0 - ((s3 - atanlo0) - x); break; }\n case 1: { z = atanhi1 - ((s3 - atanlo1) - x); break; }\n case 2: { z = atanhi2 - ((s3 - atanlo2) - x); break; }\n case 3: { z = atanhi3 - ((s3 - atanlo3) - x); break; }\n default: unreachable();\n }\n return builtin_copysign(z, sx);\n }\n\n export function atanh(x: f64): f64 { // see: musl/src/math/atanh.c\n var u = reinterpret(x);\n var e = u >> 52 & 0x7FF;\n var y = builtin_abs(x);\n if (e < 0x3FF - 1) {\n if (e >= 0x3FF - 32) y = 0.5 * log1p(2 * y + 2 * y * y / (1 - y));\n } else {\n y = 0.5 * log1p(2 * (y / (1 - y)));\n }\n return builtin_copysign(y, x);\n }\n\n export function atan2(y: f64, x: f64): f64 { // see: musl/src/math/atan2.c and SUN COPYRIGHT NOTICE above\n const pi_lo = reinterpret(0x3CA1A62633145C07); // 1.2246467991473531772E-16\n if (isNaN(x) || isNaN(y)) return x + y;\n var u = reinterpret(x);\n var ix = (u >> 32);\n var lx = u;\n u = reinterpret(y);\n var iy = (u >> 32);\n var ly = u;\n if ((ix - 0x3FF00000 | lx) == 0) return atan(y);\n var m = ((iy >> 31) & 1) | ((ix >> 30) & 2);\n ix = ix & 0x7FFFFFFF;\n iy = iy & 0x7FFFFFFF;\n if ((iy | ly) == 0) {\n switch (m) {\n case 0:\n case 1: return y;\n case 2: return PI;\n case 3: return -PI;\n }\n }\n if ((ix | lx) == 0) return m & 1 ? -PI / 2 : PI / 2;\n if (ix == 0x7FF00000) {\n if (iy == 0x7FF00000) {\n let t = m & 2 ? 3 * PI / 4 : PI / 4;\n return m & 1 ? -t : t;\n } else {\n let t = m & 2 ? PI : 0;\n return m & 1 ? -t : t;\n }\n }\n var z: f64;\n if (ix + (64 << 20) < iy || iy == 0x7FF00000) return m & 1 ? -PI / 2 : PI / 2;\n if ((m & 2) && iy + (64 << 20) < ix) z = 0;\n else z = atan(builtin_abs(y / x));\n switch (m) {\n case 0: return z;\n case 1: return -z;\n case 2: return PI - (z - pi_lo);\n case 3: return (z - pi_lo) - PI;\n }\n unreachable();\n return 0;\n }\n\n export function cbrt(x: f64): f64 { // see: musl/src/math/cbrt.c and SUN COPYRIGHT NOTICE above\n const\n B1 = 715094163,\n B2 = 696219795,\n P0 = reinterpret(0x3FFE03E60F61E692), // 1.87595182427177009643\n P1 = reinterpret(0xBFFE28E092F02420), // -1.88497979543377169875\n P2 = reinterpret(0x3FF9F1604A49D6C2), // 1.621429720105354466140\n P3 = reinterpret(0xBFE844CBBEE751D9), // -0.758397934778766047437\n P4 = reinterpret(0x3FC2B000D4E4EDD7), // 0.145996192886612446982\n Ox1p54 = reinterpret(0x4350000000000000); // 0x1p54\n\n var u = reinterpret(x);\n var hx = (u >> 32) & 0x7FFFFFFF;\n if (hx >= 0x7FF00000) return x + x;\n if (hx < 0x00100000) {\n u = reinterpret(x * Ox1p54);\n hx = (u >> 32) & 0x7FFFFFFF;\n if (hx == 0) return x;\n hx = hx / 3 + B2;\n } else {\n hx = hx / 3 + B1;\n }\n u &= 1 << 63;\n u |= hx << 32;\n var t = reinterpret(u);\n var r = (t * t) * (t / x);\n t = t * ((P0 + r * (P1 + r * P2)) + ((r * r) * r) * (P3 + r * P4));\n t = reinterpret((reinterpret(t) + 0x80000000) & 0xFFFFFFFFC0000000);\n var s = t * t;\n r = x / s;\n r = (r - t) / (2 * t + r);\n t = t + t * r;\n return t;\n }\n\n // @ts-ignore: decorator\n @inline\n export function ceil(x: f64): f64 {\n return builtin_ceil(x);\n }\n\n export function clz32(x: f64): f64 {\n if (!isFinite(x)) return 32;\n /*\n * Wasm (MVP) and JS have different approaches for double->int conversions.\n *\n * For emulate JS conversion behavior and avoid trapping from wasm we should modulate by MAX_INT\n * our float-point arguments before actual convertion to integers.\n */\n return builtin_clz(dtoi32(x));\n }\n\n export function cos(x: f64): f64 { // see: musl/src/math/cos.c\n var u = reinterpret(x);\n var ux = u32(u >> 32);\n var sign = ux >> 31;\n\n ux &= 0x7FFFFFFF;\n\n // |x| ~< pi/4\n if (ux <= 0x3FE921FB) {\n if (ux < 0x3E46A09E) { // |x| < 2**-27 * sqrt(2)\n return 1.0;\n }\n return cos_kern(x, 0);\n }\n\n // sin(Inf or NaN) is NaN\n if (ux >= 0x7FF00000) return x - x;\n\n // argument reduction needed\n var n = rempio2(x, u, sign);\n var y0 = rempio2_y0;\n var y1 = rempio2_y1;\n\n x = n & 1 ? sin_kern(y0, y1, 1) : cos_kern(y0, y1);\n return (n + 1) & 2 ? -x : x;\n }\n\n export function cosh(x: f64): f64 { // see: musl/src/math/cosh.c\n var u = reinterpret(x);\n u &= 0x7FFFFFFFFFFFFFFF;\n x = reinterpret(u);\n var w = (u >> 32);\n var t: f64;\n if (w < 0x3FE62E42) {\n if (w < 0x3FF00000 - (26 << 20)) return 1;\n t = expm1(x);\n // return 1 + t * t / (2 * (1 + t));\n return 1 + t * t / (2 + 2 * t);\n }\n if (w < 0x40862E42) {\n t = exp(x);\n return 0.5 * (t + 1 / t);\n }\n t = expo2(x, 1);\n return t;\n }\n\n export function exp(x: f64): f64 { // see: musl/src/math/exp.c and SUN COPYRIGHT NOTICE above\n if (ASC_SHRINK_LEVEL < 1) {\n return exp_lut(x);\n } else {\n const\n ln2hi = reinterpret(0x3FE62E42FEE00000), // 6.93147180369123816490e-01\n ln2lo = reinterpret(0x3DEA39EF35793C76), // 1.90821492927058770002e-10\n invln2 = reinterpret(0x3FF71547652B82FE), // 1.44269504088896338700e+00\n P1 = reinterpret(0x3FC555555555553E), // 1.66666666666666019037e-01\n P2 = reinterpret(0xBF66C16C16BEBD93), // -2.77777777770155933842e-03\n P3 = reinterpret(0x3F11566AAF25DE2C), // 6.61375632143793436117e-05\n P4 = reinterpret(0xBEBBBD41C5D26BF1), // -1.65339022054652515390e-06\n P5 = reinterpret(0x3E66376972BEA4D0), // 4.13813679705723846039e-08\n overflow = reinterpret(0x40862E42FEFA39EF), // 709.782712893383973096\n underflow = reinterpret(0xC0874910D52D3051), // -745.13321910194110842\n Ox1p1023 = reinterpret(0x7FE0000000000000); // 0x1p1023\n\n let hx = u32(reinterpret(x) >> 32);\n let sign = hx >> 31;\n hx &= 0x7FFFFFFF;\n if (hx >= 0x4086232B) {\n if (isNaN(x)) return x;\n if (x > overflow) return x * Ox1p1023;\n if (x < underflow) return 0;\n }\n let hi: f64, lo: f64 = 0;\n let k = 0;\n if (hx > 0x3FD62E42) {\n if (hx >= 0x3FF0A2B2) {\n k = i32(invln2 * x + builtin_copysign(0.5, x));\n } else {\n k = 1 - (sign << 1);\n }\n hi = x - k * ln2hi;\n lo = k * ln2lo;\n x = hi - lo;\n } else if (hx > 0x3E300000) {\n hi = x;\n } else return 1.0 + x;\n let xs = x * x;\n // var c = x - xp2 * (P1 + xp2 * (P2 + xp2 * (P3 + xp2 * (P4 + xp2 * P5))));\n let xq = xs * xs;\n let c = x - (xs * P1 + xq * ((P2 + xs * P3) + xq * (P4 + xs * P5)));\n let y = 1.0 + (x * c / (2 - c) - lo + hi);\n return k == 0 ? y : scalbn(y, k);\n }\n }\n\n export function exp2(x: f64): f64 {\n return exp2_lut(x);\n }\n\n export function expm1(x: f64): f64 { // see: musl/src/math/expm1.c and SUN COPYRIGHT NOTICE above\n const\n o_threshold = reinterpret(0x40862E42FEFA39EF), // 7.09782712893383973096e+02\n ln2_hi = reinterpret(0x3FE62E42FEE00000), // 6.93147180369123816490e-01\n ln2_lo = reinterpret(0x3DEA39EF35793C76), // 1.90821492927058770002e-10\n invln2 = reinterpret(0x3FF71547652B82FE), // 1.44269504088896338700e+00\n Q1 = reinterpret(0xBFA11111111110F4), // -3.33333333333331316428e-02\n Q2 = reinterpret(0x3F5A01A019FE5585), // 1.58730158725481460165e-03\n Q3 = reinterpret(0xBF14CE199EAADBB7), // -7.93650757867487942473e-05\n Q4 = reinterpret(0x3ED0CFCA86E65239), // 4.00821782732936239552e-06\n Q5 = reinterpret(0xBE8AFDB76E09C32D), // -2.01099218183624371326e-07\n Ox1p1023 = reinterpret(0x7FE0000000000000); // 0x1p1023\n\n var u = reinterpret(x);\n var hx = u32(u >> 32) & 0x7FFFFFFF;\n var sign = u32(u >> 63);\n var k = 0;\n if (hx >= 0x4043687A) {\n if (isNaN(x)) return x;\n if (sign) return -1;\n if (x > o_threshold) return x * Ox1p1023;\n }\n var c = 0.0, t: f64;\n if (hx > 0x3FD62E42) {\n k = select(\n 1 - (sign << 1),\n i32(invln2 * x + builtin_copysign(0.5, x)),\n hx < 0x3FF0A2B2\n );\n t = k;\n let hi = x - t * ln2_hi;\n let lo = t * ln2_lo;\n x = hi - lo;\n c = (hi - x) - lo;\n } else if (hx < 0x3C900000) return x;\n var hfx = 0.5 * x;\n var hxs = x * hfx;\n // var r1 = 1.0 + hxs * (Q1 + hxs * (Q2 + hxs * (Q3 + hxs * (Q4 + hxs * Q5))));\n var hxq = hxs * hxs;\n var r1 = (1.0 + hxs * Q1) + hxq * ((Q2 + hxs * Q3) + hxq * (Q4 + hxs * Q5));\n t = 3.0 - r1 * hfx;\n var e = hxs * ((r1 - t) / (6.0 - x * t));\n if (k == 0) return x - (x * e - hxs);\n e = x * (e - c) - c;\n e -= hxs;\n if (k == -1) return 0.5 * (x - e) - 0.5;\n if (k == 1) {\n if (x < -0.25) return -2.0 * (e - (x + 0.5));\n return 1.0 + 2.0 * (x - e);\n }\n u = (0x3FF + k) << 52;\n var twopk = reinterpret(u);\n var y: f64;\n if (k < 0 || k > 56) {\n y = x - e + 1.0;\n if (k == 1024) y = y * 2.0 * Ox1p1023;\n else y = y * twopk;\n return y - 1.0;\n }\n u = (0x3FF - k) << 52;\n y = reinterpret(u);\n if (k < 20) y = (1 - y) - e;\n else y = 1 - (e + y);\n return (x + y) * twopk;\n }\n\n // @ts-ignore: decorator\n @inline\n export function floor(x: f64): f64 {\n return builtin_floor(x);\n }\n\n // @ts-ignore: decorator\n @inline\n export function fround(x: f64): f64 {\n return x;\n }\n\n export function hypot(x: f64, y: f64): f64 { // see: musl/src/math/hypot.c\n const\n SPLIT = reinterpret(0x41A0000000000000) + 1, // 0x1p27 + 1\n Ox1p700 = reinterpret(0x6BB0000000000000),\n Ox1p_700 = reinterpret(0x1430000000000000);\n\n var ux = reinterpret(x);\n var uy = reinterpret(y);\n ux &= 0x7FFFFFFFFFFFFFFF;\n uy &= 0x7FFFFFFFFFFFFFFF;\n if (ux < uy) {\n let ut = ux;\n ux = uy;\n uy = ut;\n }\n var ex = i32(ux >> 52);\n var ey = i32(uy >> 52);\n y = reinterpret(uy);\n if (ey == 0x7FF) return y;\n x = reinterpret(ux);\n if (ex == 0x7FF || uy == 0) return x;\n if (ex - ey > 64) return x + y;\n var z = 1.0;\n if (ex > 0x3FF + 510) {\n z = Ox1p700;\n x *= Ox1p_700;\n y *= Ox1p_700;\n } else if (ey < 0x3FF - 450) {\n z = Ox1p_700;\n x *= Ox1p700;\n y *= Ox1p700;\n }\n var c = x * SPLIT;\n var h = x - c + c;\n var l = x - h;\n var hx = x * x;\n var lx = h * h - hx + (2 * h + l) * l;\n c = y * SPLIT;\n h = y - c + c;\n l = y - h;\n var hy = y * y;\n var ly = h * h - hy + (2 * h + l) * l;\n return z * builtin_sqrt(ly + lx + hy + hx);\n }\n\n export function imul(x: f64, y: f64): f64 {\n /*\n * Wasm (MVP) and JS have different approaches for double->int conversions.\n *\n * For emulate JS conversion behavior and avoid trapping from wasm we should modulate by MAX_INT\n * our float-point arguments before actual convertion to integers.\n */\n if (!isFinite(x + y)) return 0;\n return dtoi32(x) * dtoi32(y);\n }\n\n export function log(x: f64): f64 { // see: musl/src/math/log.c and SUN COPYRIGHT NOTICE above\n if (ASC_SHRINK_LEVEL < 1) {\n return log_lut(x);\n } else {\n const\n ln2_hi = reinterpret(0x3FE62E42FEE00000), // 6.93147180369123816490e-01\n ln2_lo = reinterpret(0x3DEA39EF35793C76), // 1.90821492927058770002e-10\n Lg1 = reinterpret(0x3FE5555555555593), // 6.666666666666735130e-01\n Lg2 = reinterpret(0x3FD999999997FA04), // 3.999999999940941908e-01\n Lg3 = reinterpret(0x3FD2492494229359), // 2.857142874366239149e-01\n Lg4 = reinterpret(0x3FCC71C51D8E78AF), // 2.222219843214978396e-01\n Lg5 = reinterpret(0x3FC7466496CB03DE), // 1.818357216161805012e-01\n Lg6 = reinterpret(0x3FC39A09D078C69F), // 1.531383769920937332e-01\n Lg7 = reinterpret(0x3FC2F112DF3E5244), // 1.479819860511658591e-01\n Ox1p54 = reinterpret(0x4350000000000000); // 0x1p54\n\n let u = reinterpret(x);\n let hx = u32(u >> 32);\n let k = 0;\n let sign = hx >> 31;\n if (sign || hx < 0x00100000) {\n if (u << 1 == 0) return -1 / (x * x);\n if (sign) return (x - x) / 0.0;\n k -= 54;\n x *= Ox1p54;\n u = reinterpret(x);\n hx = u32(u >> 32);\n } else if (hx >= 0x7FF00000) {\n return x;\n } else if (hx == 0x3FF00000 && u << 32 == 0) {\n return 0;\n }\n hx += 0x3FF00000 - 0x3FE6A09E;\n k += (hx >> 20) - 0x3FF;\n hx = (hx & 0x000FFFFF) + 0x3FE6A09E;\n u = hx << 32 | (u & 0xFFFFFFFF);\n x = reinterpret(u);\n let f = x - 1.0;\n let hfsq = 0.5 * f * f;\n let s = f / (2.0 + f);\n let z = s * s;\n let w = z * z;\n let t1 = w * (Lg2 + w * (Lg4 + w * Lg6));\n let t2 = z * (Lg1 + w * (Lg3 + w * (Lg5 + w * Lg7)));\n let r = t2 + t1;\n let dk = k;\n return s * (hfsq + r) + dk * ln2_lo - hfsq + f + dk * ln2_hi;\n }\n }\n\n export function log10(x: f64): f64 { // see: musl/src/math/log10.c and SUN COPYRIGHT NOTICE above\n const\n ivln10hi = reinterpret(0x3FDBCB7B15200000), // 4.34294481878168880939e-01\n ivln10lo = reinterpret(0x3DBB9438CA9AADD5), // 2.50829467116452752298e-11\n log10_2hi = reinterpret(0x3FD34413509F6000), // 3.01029995663611771306e-01\n log10_2lo = reinterpret(0x3D59FEF311F12B36), // 3.69423907715893078616e-13\n Lg1 = reinterpret(0x3FE5555555555593), // 6.666666666666735130e-01\n Lg2 = reinterpret(0x3FD999999997FA04), // 3.999999999940941908e-01\n Lg3 = reinterpret(0x3FD2492494229359), // 2.857142874366239149e-01\n Lg4 = reinterpret(0x3FCC71C51D8E78AF), // 2.222219843214978396e-01\n Lg5 = reinterpret(0x3FC7466496CB03DE), // 1.818357216161805012e-01\n Lg6 = reinterpret(0x3FC39A09D078C69F), // 1.531383769920937332e-01\n Lg7 = reinterpret(0x3FC2F112DF3E5244), // 1.479819860511658591e-01\n Ox1p54 = reinterpret(0x4350000000000000); // 0x1p54\n\n var u = reinterpret(x);\n var hx = u32(u >> 32);\n var k = 0;\n var sign = hx >> 31;\n if (sign || hx < 0x00100000) {\n if (u << 1 == 0) return -1 / (x * x);\n if (sign) return (x - x) / 0.0;\n k -= 54;\n x *= Ox1p54;\n u = reinterpret(x);\n hx = u32(u >> 32);\n } else if (hx >= 0x7FF00000) {\n return x;\n } else if (hx == 0x3FF00000 && u << 32 == 0) {\n return 0;\n }\n hx += 0x3FF00000 - 0x3FE6A09E;\n k += i32(hx >> 20) - 0x3FF;\n hx = (hx & 0x000FFFFF) + 0x3FE6A09E;\n u = hx << 32 | (u & 0xFFFFFFFF);\n x = reinterpret(u);\n var f = x - 1.0;\n var hfsq = 0.5 * f * f;\n var s = f / (2.0 + f);\n var z = s * s;\n var w = z * z;\n var t1 = w * (Lg2 + w * (Lg4 + w * Lg6));\n var t2 = z * (Lg1 + w * (Lg3 + w * (Lg5 + w * Lg7)));\n var r = t2 + t1;\n var hi = f - hfsq;\n u = reinterpret(hi);\n u &= 0xFFFFFFFF00000000;\n hi = reinterpret(u);\n var lo = f - hi - hfsq + s * (hfsq + r);\n var val_hi = hi * ivln10hi;\n var dk = k;\n var y = dk * log10_2hi;\n var val_lo = dk * log10_2lo + (lo + hi) * ivln10lo + lo * ivln10hi;\n w = y + val_hi;\n val_lo += (y - w) + val_hi;\n return val_lo + w;\n }\n\n export function log1p(x: f64): f64 { // see: musl/src/math/log1p.c and SUN COPYRIGHT NOTICE above\n const\n ln2_hi = reinterpret(0x3FE62E42FEE00000), // 6.93147180369123816490e-01\n ln2_lo = reinterpret(0x3DEA39EF35793C76), // 1.90821492927058770002e-10\n Lg1 = reinterpret(0x3FE5555555555593), // 6.666666666666735130e-01\n Lg2 = reinterpret(0x3FD999999997FA04), // 3.999999999940941908e-01\n Lg3 = reinterpret(0x3FD2492494229359), // 2.857142874366239149e-01\n Lg4 = reinterpret(0x3FCC71C51D8E78AF), // 2.222219843214978396e-01\n Lg5 = reinterpret(0x3FC7466496CB03DE), // 1.818357216161805012e-01\n Lg6 = reinterpret(0x3FC39A09D078C69F), // 1.531383769920937332e-01\n Lg7 = reinterpret(0x3FC2F112DF3E5244); // 1.479819860511658591e-01\n\n var u = reinterpret(x);\n var hx = u32(u >> 32);\n var k = 1;\n var c = 0.0, f = 0.0;\n if (hx < 0x3FDA827A || bool(hx >> 31)) {\n if (hx >= 0xBFF00000) {\n if (x == -1) return x / 0.0;\n return (x - x) / 0.0;\n }\n if (hx << 1 < 0x3CA00000 << 1) return x;\n if (hx <= 0xBFD2BEC4) {\n k = 0;\n c = 0;\n f = x;\n }\n } else if (hx >= 0x7FF00000) return x;\n if (k) {\n u = reinterpret(1 + x);\n let hu = u32(u >> 32);\n hu += 0x3FF00000 - 0x3FE6A09E;\n k = i32(hu >> 20) - 0x3FF;\n if (k < 54) {\n let uf = reinterpret(u);\n c = k >= 2 ? 1 - (uf - x) : x - (uf - 1);\n c /= uf;\n } else c = 0;\n hu = (hu & 0x000FFFFF) + 0x3FE6A09E;\n u = hu << 32 | (u & 0xFFFFFFFF);\n f = reinterpret(u) - 1;\n }\n var hfsq = 0.5 * f * f;\n var s = f / (2.0 + f);\n var z = s * s;\n var w = z * z;\n var t1 = w * (Lg2 + w * (Lg4 + w * Lg6));\n var t2 = z * (Lg1 + w * (Lg3 + w * (Lg5 + w * Lg7)));\n var r = t2 + t1;\n var dk = k;\n return s * (hfsq + r) + (dk * ln2_lo + c) - hfsq + f + dk * ln2_hi;\n }\n\n export function log2(x: f64): f64 { // see: musl/src/math/log2.c and SUN COPYRIGHT NOTICE above\n if (ASC_SHRINK_LEVEL < 1) {\n return log2_lut(x);\n } else {\n const\n ivln2hi = reinterpret(0x3FF7154765200000), // 1.44269504072144627571e+00\n ivln2lo = reinterpret(0x3DE705FC2EEFA200), // 1.67517131648865118353e-10\n Lg1 = reinterpret(0x3FE5555555555593), // 6.666666666666735130e-01\n Lg2 = reinterpret(0x3FD999999997FA04), // 3.999999999940941908e-01\n Lg3 = reinterpret(0x3FD2492494229359), // 2.857142874366239149e-01\n Lg4 = reinterpret(0x3FCC71C51D8E78AF), // 2.222219843214978396e-01\n Lg5 = reinterpret(0x3FC7466496CB03DE), // 1.818357216161805012e-01\n Lg6 = reinterpret(0x3FC39A09D078C69F), // 1.531383769920937332e-01\n Lg7 = reinterpret(0x3FC2F112DF3E5244), // 1.479819860511658591e-01\n Ox1p54 = reinterpret(0x4350000000000000); // 1p54\n\n let u = reinterpret(x);\n let hx = u32(u >> 32);\n let k = 0;\n let sign = hx >> 31;\n if (sign || hx < 0x00100000) {\n if (u << 1 == 0) return -1 / (x * x);\n if (sign) return (x - x) / 0.0;\n k -= 54;\n x *= Ox1p54;\n u = reinterpret(x);\n hx = u32(u >> 32);\n } else if (hx >= 0x7FF00000) {\n return x;\n } else if (hx == 0x3FF00000 && u << 32 == 0) {\n return 0;\n }\n hx += 0x3FF00000 - 0x3FE6A09E;\n k += i32(hx >> 20) - 0x3FF;\n hx = (hx & 0x000FFFFF) + 0x3FE6A09E;\n u = hx << 32 | (u & 0xFFFFFFFF);\n x = reinterpret(u);\n let f = x - 1.0;\n let hfsq = 0.5 * f * f;\n let s = f / (2.0 + f);\n let z = s * s;\n let w = z * z;\n let t1 = w * (Lg2 + w * (Lg4 + w * Lg6));\n let t2 = z * (Lg1 + w * (Lg3 + w * (Lg5 + w * Lg7)));\n let r = t2 + t1;\n let hi = f - hfsq;\n u = reinterpret(hi);\n u &= 0xFFFFFFFF00000000;\n hi = reinterpret(u);\n let lo = f - hi - hfsq + s * (hfsq + r);\n let val_hi = hi * ivln2hi;\n let val_lo = (lo + hi) * ivln2lo + lo * ivln2hi;\n let y = k;\n w = y + val_hi;\n val_lo += (y - w) + val_hi;\n val_hi = w;\n return val_lo + val_hi;\n }\n }\n\n // @ts-ignore: decorator\n @inline\n export function max(value1: f64, value2: f64): f64 {\n return builtin_max(value1, value2);\n }\n\n // @ts-ignore: decorator\n @inline\n export function min(value1: f64, value2: f64): f64 {\n return builtin_min(value1, value2);\n }\n\n export function pow(x: f64, y: f64): f64 { // see: musl/src/math/pow.c and SUN COPYRIGHT NOTICE above\n // TODO: remove this fast pathes after introduced own mid-end IR with \"stdlib call simplify\" transforms\n if (builtin_abs(y) <= 2) {\n if (y == 2.0) return x * x;\n if (y == 0.5) {\n return select(\n builtin_abs(builtin_sqrt(x)),\n Infinity,\n x != -Infinity\n );\n }\n if (y == -1.0) return 1 / x;\n if (y == 1.0) return x;\n if (y == 0.0) return 1.0;\n }\n if (ASC_SHRINK_LEVEL < 1) {\n return pow_lut(x, y);\n } else {\n const\n dp_h1 = reinterpret(0x3FE2B80340000000), // 5.84962487220764160156e-01\n dp_l1 = reinterpret(0x3E4CFDEB43CFD006), // 1.35003920212974897128e-08\n two53 = reinterpret(0x4340000000000000), // 9007199254740992.0\n huge = reinterpret(0x7E37E43C8800759C), // 1e+300\n tiny = reinterpret(0x01A56E1FC2F8F359), // 1e-300\n L1 = reinterpret(0x3FE3333333333303), // 5.99999999999994648725e-01\n L2 = reinterpret(0x3FDB6DB6DB6FABFF), // 4.28571428578550184252e-01\n L3 = reinterpret(0x3FD55555518F264D), // 3.33333329818377432918e-01\n L4 = reinterpret(0x3FD17460A91D4101), // 2.72728123808534006489e-01\n L5 = reinterpret(0x3FCD864A93C9DB65), // 2.30660745775561754067e-01\n L6 = reinterpret(0x3FCA7E284A454EEF), // 2.06975017800338417784e-01\n P1 = reinterpret(0x3FC555555555553E), // 1.66666666666666019037e-01\n P2 = reinterpret(0xBF66C16C16BEBD93), // -2.77777777770155933842e-03\n P3 = reinterpret(0x3F11566AAF25DE2C), // 6.61375632143793436117e-05\n P4 = reinterpret(0xBEBBBD41C5D26BF1), // -1.65339022054652515390e-06\n P5 = reinterpret(0x3E66376972BEA4D0), // 4.13813679705723846039e-08\n lg2 = reinterpret(0x3FE62E42FEFA39EF), // 6.93147180559945286227e-01\n lg2_h = reinterpret(0x3FE62E4300000000), // 6.93147182464599609375e-01\n lg2_l = reinterpret(0xBE205C610CA86C39), // -1.90465429995776804525e-09\n ovt = reinterpret(0x3C971547652B82FE), // 8.0085662595372944372e-017\n cp = reinterpret(0x3FEEC709DC3A03FD), // 9.61796693925975554329e-01\n cp_h = reinterpret(0x3FEEC709E0000000), // 9.61796700954437255859e-01\n cp_l = reinterpret(0xBE3E2FE0145B01F5), // -7.02846165095275826516e-09\n ivln2 = reinterpret(0x3FF71547652B82FE), // 1.44269504088896338700e+00\n ivln2_h = reinterpret(0x3FF7154760000000), // 1.44269502162933349609e+00\n ivln2_l = reinterpret(0x3E54AE0BF85DDF44), // 1.92596299112661746887e-08\n inv3 = reinterpret(0x3FD5555555555555); // 0.3333333333333333333333\n\n let u_ = reinterpret(x);\n let hx = i32(u_ >> 32);\n let lx = u_;\n u_ = reinterpret(y);\n let hy = i32(u_ >> 32);\n let ly = u_;\n let ix = hx & 0x7FFFFFFF;\n let iy = hy & 0x7FFFFFFF;\n if ((iy | ly) == 0) return 1.0; // x**0 = 1, even if x is NaN\n // if (hx == 0x3FF00000 && lx == 0) return 1.0; // C: 1**y = 1, even if y is NaN, JS: NaN\n if ( // NaN if either arg is NaN\n ix > 0x7FF00000 || (ix == 0x7FF00000 && lx != 0) ||\n iy > 0x7FF00000 || (iy == 0x7FF00000 && ly != 0)\n ) return x + y;\n let yisint = 0, k: i32;\n if (hx < 0) {\n if (iy >= 0x43400000) yisint = 2;\n else if (iy >= 0x3FF00000) {\n k = (iy >> 20) - 0x3FF;\n let offset = select(52, 20, k > 20) - k;\n let Ly = select(ly, iy, k > 20);\n let jj = Ly >> offset;\n if ((jj << offset) == Ly) yisint = 2 - (jj & 1);\n }\n }\n if (ly == 0) {\n if (iy == 0x7FF00000) { // y is +-inf\n if (((ix - 0x3FF00000) | lx) == 0) return NaN; // C: (-1)**+-inf is 1, JS: NaN\n else if (ix >= 0x3FF00000) return hy >= 0 ? y : 0.0; // (|x|>1)**+-inf = inf,0\n else return hy >= 0 ? 0.0 : -y; // (|x|<1)**+-inf = 0,inf\n }\n if (iy == 0x3FF00000) {\n if (hy >= 0) return x;\n return 1 / x;\n }\n if (hy == 0x40000000) return x * x;\n if (hy == 0x3FE00000) {\n if (hx >= 0) return builtin_sqrt(x);\n }\n }\n let ax = builtin_abs(x), z: f64;\n if (lx == 0) {\n if (ix == 0 || ix == 0x7FF00000 || ix == 0x3FF00000) {\n z = ax;\n if (hy < 0) z = 1.0 / z;\n if (hx < 0) {\n if (((ix - 0x3FF00000) | yisint) == 0) {\n let d = z - z;\n z = d / d;\n } else if (yisint == 1) z = -z;\n }\n return z;\n }\n }\n let s = 1.0;\n if (hx < 0) {\n if (yisint == 0) {\n let d = x - x;\n return d / d;\n }\n if (yisint == 1) s = -1.0;\n }\n let t1: f64, t2: f64, p_h: f64, p_l: f64, r: f64, t: f64, u: f64, v: f64, w: f64;\n let j: i32, n: i32;\n if (iy > 0x41E00000) {\n if (iy > 0x43F00000) {\n if (ix <= 0x3FEFFFFF) return hy < 0 ? huge * huge : tiny * tiny;\n if (ix >= 0x3FF00000) return hy > 0 ? huge * huge : tiny * tiny;\n }\n if (ix < 0x3FEFFFFF) return hy < 0 ? s * huge * huge : s * tiny * tiny;\n if (ix > 0x3FF00000) return hy > 0 ? s * huge * huge : s * tiny * tiny;\n t = ax - 1.0;\n w = (t * t) * (0.5 - t * (inv3 - t * 0.25));\n u = ivln2_h * t;\n v = t * ivln2_l - w * ivln2;\n t1 = u + v;\n t1 = reinterpret(reinterpret(t1) & 0xFFFFFFFF00000000);\n t2 = v - (t1 - u);\n } else {\n let ss: f64, s2: f64, s_h: f64, s_l: f64, t_h: f64, t_l: f64;\n n = 0;\n if (ix < 0x00100000) {\n ax *= two53;\n n -= 53;\n ix = (reinterpret(ax) >> 32);\n }\n n += (ix >> 20) - 0x3FF;\n j = ix & 0x000FFFFF;\n ix = j | 0x3FF00000;\n if (j <= 0x3988E) k = 0;\n else if (j < 0xBB67A) k = 1;\n else {\n k = 0;\n n += 1;\n ix -= 0x00100000;\n }\n ax = reinterpret(reinterpret(ax) & 0xFFFFFFFF | (ix << 32));\n let bp = select(1.5, 1.0, k); // k ? 1.5 : 1.0\n u = ax - bp;\n v = 1.0 / (ax + bp);\n ss = u * v;\n s_h = ss;\n s_h = reinterpret(reinterpret(s_h) & 0xFFFFFFFF00000000);\n t_h = reinterpret(u64(((ix >> 1) | 0x20000000) + 0x00080000 + (k << 18)) << 32);\n t_l = ax - (t_h - bp);\n s_l = v * ((u - s_h * t_h) - s_h * t_l);\n s2 = ss * ss;\n r = s2 * s2 * (L1 + s2 * (L2 + s2 * (L3 + s2 * (L4 + s2 * (L5 + s2 * L6)))));\n r += s_l * (s_h + ss);\n s2 = s_h * s_h;\n t_h = 3.0 + s2 + r;\n t_h = reinterpret(reinterpret(t_h) & 0xFFFFFFFF00000000);\n t_l = r - ((t_h - 3.0) - s2);\n u = s_h * t_h;\n v = s_l * t_h + t_l * ss;\n p_h = u + v;\n p_h = reinterpret(reinterpret(p_h) & 0xFFFFFFFF00000000);\n p_l = v - (p_h - u);\n let z_h = cp_h * p_h;\n let dp_l = select(dp_l1, 0.0, k);\n let z_l = cp_l * p_h + p_l * cp + dp_l;\n t = n;\n let dp_h = select(dp_h1, 0.0, k);\n t1 = ((z_h + z_l) + dp_h) + t;\n t1 = reinterpret(reinterpret(t1) & 0xFFFFFFFF00000000);\n t2 = z_l - (((t1 - t) - dp_h) - z_h);\n }\n let y1 = y;\n y1 = reinterpret(reinterpret(y1) & 0xFFFFFFFF00000000);\n p_l = (y - y1) * t1 + y * t2;\n p_h = y1 * t1;\n z = p_l + p_h;\n u_ = reinterpret(z);\n j = u32(u_ >> 32);\n let i = u_;\n if (j >= 0x40900000) {\n if (((j - 0x40900000) | i) != 0) return s * huge * huge;\n if (p_l + ovt > z - p_h) return s * huge * huge;\n } else if ((j & 0x7FFFFFFF) >= 0x4090CC00) {\n if (((j - 0xC090CC00) | i) != 0) return s * tiny * tiny;\n if (p_l <= z - p_h) return s * tiny * tiny;\n }\n i = j & 0x7FFFFFFF;\n k = (i >> 20) - 0x3FF;\n n = 0;\n if (i > 0x3FE00000) {\n n = j + (0x00100000 >> (k + 1));\n k = ((n & 0x7FFFFFFF) >> 20) - 0x3FF;\n t = 0.0;\n t = reinterpret(u64(n & ~(0x000FFFFF >> k)) << 32);\n n = ((n & 0x000FFFFF) | 0x00100000) >> (20 - k);\n if (j < 0) n = -n;\n p_h -= t;\n }\n t = p_l + p_h;\n t = reinterpret(reinterpret(t) & 0xFFFFFFFF00000000);\n u = t * lg2_h;\n v = (p_l - (t - p_h)) * lg2 + t * lg2_l;\n z = u + v;\n w = v - (z - u);\n t = z * z;\n t1 = z - t * (P1 + t * (P2 + t * (P3 + t * (P4 + t * P5))));\n r = (z * t1) / (t1 - 2.0) - (w + z * w);\n z = 1.0 - (r - z);\n j = u32(reinterpret(z) >> 32);\n j += n << 20;\n if ((j >> 20) <= 0) z = scalbn(z, n);\n else z = reinterpret(reinterpret(z) & 0xFFFFFFFF | (j << 32));\n return s * z;\n }\n }\n\n export function seedRandom(value: i64): void {\n // Instead zero seed use golden ratio:\n // phi = (1 + sqrt(5)) / 2\n // trunc(2^64 / phi) = 0x9e3779b97f4a7c15\n if (value == 0) value = 0x9e3779b97f4a7c15;\n random_state0_64 = murmurHash3(value);\n random_state1_64 = murmurHash3(~random_state0_64);\n random_state0_32 = splitMix32(value);\n random_state1_32 = splitMix32(random_state0_32);\n random_seeded = true;\n }\n\n export function random(): f64 { // see: v8/src/base/utils/random-number-generator.cc\n if (!random_seeded) seedRandom(reinterpret(seed()));\n var s1 = random_state0_64;\n var s0 = random_state1_64;\n random_state0_64 = s0;\n s1 ^= s1 << 23;\n s1 ^= s1 >> 17;\n s1 ^= s0;\n s1 ^= s0 >> 26;\n random_state1_64 = s1;\n var r = (s0 >> 12) | 0x3FF0000000000000;\n return reinterpret(r) - 1;\n }\n\n export function round(x: f64): f64 {\n if (ASC_SHRINK_LEVEL > 0) {\n return builtin_ceil(x) - f64(builtin_ceil(x) - 0.5 > x);\n } else {\n let roundUp = builtin_ceil(x);\n return select(roundUp, roundUp - 1.0, roundUp - 0.5 <= x);\n }\n }\n\n export function sign(x: f64): f64 {\n if (ASC_SHRINK_LEVEL > 0) {\n return select(builtin_copysign(1, x), x, builtin_abs(x) > 0);\n } else {\n return select(1, select(-1, x, x < 0), x > 0);\n }\n }\n\n // @ts-ignore: decorator\n @inline\n export function signbit(x: f64): bool {\n return bool(reinterpret(x) >>> 63);\n }\n\n export function sin(x: f64): f64 { // see: musl/src/math/sin.c\n var u = reinterpret(x);\n var ux = u32(u >> 32);\n var sign = ux >> 31;\n\n ux &= 0x7FFFFFFF;\n\n // |x| ~< pi/4\n if (ux <= 0x3FE921FB) {\n if (ux < 0x3E500000) { // |x| < 2**-26\n return x;\n }\n return sin_kern(x, 0.0, 0);\n }\n\n // sin(Inf or NaN) is NaN\n if (ux >= 0x7FF00000) return x - x;\n\n // argument reduction needed\n var n = rempio2(x, u, sign);\n var y0 = rempio2_y0;\n var y1 = rempio2_y1;\n\n x = n & 1 ? cos_kern(y0, y1) : sin_kern(y0, y1, 1);\n return n & 2 ? -x : x;\n }\n\n export function sinh(x: f64): f64 { // see: musl/src/math/sinh.c\n var u = reinterpret(x) & 0x7FFFFFFFFFFFFFFF;\n var a = reinterpret(u);\n var w = u32(u >> 32);\n var h = builtin_copysign(0.5, x);\n if (w < 0x40862E42) {\n let t = expm1(a);\n if (w < 0x3FF00000) {\n if (w < 0x3FF00000 - (26 << 20)) return x;\n return h * (2 * t - t * t / (t + 1));\n }\n return h * (t + t / (t + 1));\n }\n return expo2(a, 2 * h);\n }\n\n // @ts-ignore: decorator\n @inline\n export function sqrt(x: f64): f64 {\n return builtin_sqrt(x);\n }\n\n export function tan(x: f64): f64 { // see: musl/src/math/tan.c\n var u = reinterpret(x);\n var ux = u32(u >> 32);\n var sign = ux >>> 31;\n\n ux &= 0x7FFFFFFF;\n\n // |x| ~< pi/4\n if (ux <= 0x3FE921FB) {\n if (ux < 0x3E400000) { // |x| < 2**-27\n return x;\n }\n return tan_kern(x, 0.0, 1);\n }\n\n // tan(Inf or NaN) is NaN\n if (ux >= 0x7FF00000) return x - x;\n\n var n = rempio2(x, u, sign);\n return tan_kern(rempio2_y0, rempio2_y1, 1 - ((n & 1) << 1));\n }\n\n export function tanh(x: f64): f64 { // see: musl/src/math/tanh.c\n var u = reinterpret(x);\n u &= 0x7FFFFFFFFFFFFFFF;\n var y = reinterpret(u);\n var w = u32(u >> 32);\n var t: f64;\n if (w > 0x3FE193EA) {\n if (w > 0x40340000) {\n t = 1 - 0 / y;\n } else {\n t = expm1(2 * y);\n t = 1 - 2 / (t + 2);\n }\n } else if (w > 0x3FD058AE) {\n t = expm1(2 * y);\n t = t / (t + 2);\n } else if (w >= 0x00100000) {\n t = expm1(-2 * y);\n t = -t / (t + 2);\n } else t = y;\n return builtin_copysign(t, x);\n }\n\n // @ts-ignore: decorator\n @inline\n export function trunc(x: f64): f64 {\n return builtin_trunc(x);\n }\n\n export function scalbn(x: f64, n: i32): f64 { // see: https://git.musl-libc.org/cgit/musl/tree/src/math/scalbn.c\n const\n Ox1p53 = reinterpret(0x4340000000000000),\n Ox1p1023 = reinterpret(0x7FE0000000000000),\n Ox1p_1022 = reinterpret(0x0010000000000000);\n\n var y = x;\n if (n > 1023) {\n y *= Ox1p1023;\n n -= 1023;\n if (n > 1023) {\n y *= Ox1p1023;\n n = builtin_min(n - 1023, 1023);\n }\n } else if (n < -1022) {\n // make sure final n < -53 to avoid double\n // rounding in the subnormal range\n y *= Ox1p_1022 * Ox1p53;\n n += 1022 - 53;\n if (n < -1022) {\n y *= Ox1p_1022 * Ox1p53;\n n = builtin_max(n + 1022 - 53, -1022);\n }\n }\n return y * reinterpret((0x3FF + n) << 52);\n }\n\n export function mod(x: f64, y: f64): f64 { // see: musl/src/math/fmod.c\n if (builtin_abs(y) == 1.0) {\n // x % 1, x % -1 ==> sign(x) * abs(x - 1.0 * trunc(x / 1.0))\n // TODO: move this rule to compiler's optimization pass.\n // It could be apply for any x % C_pot, where \"C_pot\" is pow of two const.\n return builtin_copysign(x - builtin_trunc(x), x);\n }\n var ux = reinterpret(x);\n var uy = reinterpret(y);\n var ex = i64(ux >> 52 & 0x7FF);\n var ey = i64(uy >> 52 & 0x7FF);\n var sx = ux >> 63;\n var uy1 = uy << 1;\n if (uy1 == 0 || ex == 0x7FF || isNaN(y)) {\n let m = x * y;\n return m / m;\n }\n var ux1 = ux << 1;\n if (ux1 <= uy1) {\n return x * f64(ux1 != uy1);\n }\n if (!ex) {\n ex -= builtin_clz(ux << 12);\n ux <<= 1 - ex;\n } else {\n ux &= u64(-1) >> 12;\n ux |= 1 << 52;\n }\n if (!ey) {\n ey -= builtin_clz(uy << 12);\n uy <<= 1 - ey;\n } else {\n uy &= u64(-1) >> 12;\n uy |= 1 << 52;\n }\n while (ex > ey) {\n if (ux >= uy) {\n if (ux == uy) return 0 * x;\n ux -= uy;\n }\n ux <<= 1;\n --ex;\n }\n if (ux >= uy) {\n if (ux == uy) return 0 * x;\n ux -= uy;\n }\n // for (; !(ux >> 52); ux <<= 1) --ex;\n var shift = builtin_clz(ux << 11);\n ex -= shift;\n ux <<= shift;\n if (ex > 0) {\n ux -= 1 << 52;\n ux |= ex << 52;\n } else {\n ux >>= -ex + 1;\n }\n return reinterpret(ux | (sx << 63));\n }\n\n export function rem(x: f64, y: f64): f64 { // see: musl/src/math/remquo.c\n var ux = reinterpret(x);\n var uy = reinterpret(y);\n var ex = i64(ux >> 52 & 0x7FF);\n var ey = i64(uy >> 52 & 0x7FF);\n if (uy << 1 == 0 || ex == 0x7FF || isNaN(y)) {\n let m = x * y;\n return m / m;\n }\n if (ux << 1 == 0) return x;\n var uxi = ux;\n if (!ex) {\n ex -= builtin_clz(uxi << 12);\n uxi <<= 1 - ex;\n } else {\n uxi &= u64(-1) >> 12;\n uxi |= 1 << 52;\n }\n if (!ey) {\n ey -= builtin_clz(uy << 12);\n uy <<= 1 - ey;\n } else {\n uy &= u64(-1) >> 12;\n uy |= 1 << 52;\n }\n var q: u32 = 0;\n do {\n if (ex < ey) {\n if (ex + 1 == ey) break; // goto end\n return x;\n }\n while (ex > ey) {\n if (uxi >= uy) {\n uxi -= uy;\n ++q;\n }\n uxi <<= 1;\n q <<= 1;\n --ex;\n }\n if (uxi >= uy) {\n uxi -= uy;\n ++q;\n }\n if (uxi == 0) ex = -60;\n else {\n let shift = builtin_clz(uxi << 11);\n ex -= shift;\n uxi <<= shift;\n }\n break;\n } while (false);\n // end:\n if (ex > 0) {\n uxi -= 1 << 52;\n uxi |= ex << 52;\n } else {\n uxi >>= -ex + 1;\n }\n x = reinterpret(uxi);\n y = builtin_abs(y);\n var x2 = x + x;\n if (ex == ey || (ex + 1 == ey && (x2 > y || (x2 == y && (q & 1))))) {\n x -= y;\n // ++q;\n }\n return ux < 0 ? -x : x;\n }\n\n export function sincos(x: f64): void { // see: musl/tree/src/math/sincos.c\n var u = reinterpret(x);\n var ux = u32(u >> 32);\n var sign = ux >> 31;\n ux &= 0x7FFFFFFF;\n\n if (ux <= 0x3FE921FB) { // |x| ~<= π/4\n if (ux < 0x3E46A09E) { // if |x| < 2**-27 * sqrt(2)\n sincos_sin = x;\n sincos_cos = 1;\n return;\n }\n sincos_sin = sin_kern(x, 0, 0);\n sincos_cos = cos_kern(x, 0);\n return;\n }\n // sin(Inf or NaN) is NaN\n if (ux >= 0x7F800000) {\n let xx = x - x;\n sincos_sin = xx;\n sincos_cos = xx;\n return;\n }\n // general argument reduction needed\n var n = rempio2(x, u, sign);\n var y0 = rempio2_y0;\n var y1 = rempio2_y1;\n var s = sin_kern(y0, y1, 1);\n var c = cos_kern(y0, y1);\n var sin = s, cos = c;\n if (n & 1) {\n sin = c;\n cos = -s;\n }\n if (n & 2) {\n sin = -sin;\n cos = -cos;\n }\n sincos_sin = sin;\n sincos_cos = cos;\n }\n}\n\n// @ts-ignore: decorator\n@lazy var rempio2f_y: f64;\n\n// @ts-ignore: decorator\n@lazy @inline const PIO2F_TABLE = memory.data([\n 0xA2F9836E4E441529,\n 0xFC2757D1F534DDC0,\n 0xDB6295993C439041,\n 0xFE5163ABDEBBC561\n]);\n\nfunction Rf(z: f32): f32 { // Rational approximation of (asin(x)-x)/x^3\n const // see: musl/src/math/asinf.c and SUN COPYRIGHT NOTICE above\n pS0 = reinterpret(0x3E2AAA75), // 1.6666586697e-01f\n pS1 = reinterpret(0xBD2F13BA), // -4.2743422091e-02f\n pS2 = reinterpret(0xBC0DD36B), // -8.6563630030e-03f\n qS1 = reinterpret(0xBF34E5AE); // -7.0662963390e-01f\n\n var p = z * (pS0 + z * (pS1 + z * pS2));\n var q: f32 = 1 + z * qS1;\n return p / q;\n}\n\n// @ts-ignore: decorator\n@inline\nfunction expo2f(x: f32, sign: f32): f32 { // exp(x)/2 for x >= log(DBL_MAX)\n const // see: musl/src/math/__expo2f.c\n k = 235,\n kln2 = reinterpret(0x4322E3BC); // 0x1.45c778p+7f\n var scale = reinterpret(u32(0x7F + (k >> 1)) << 23);\n // in directed rounding correct sign before rounding or overflow is important\n return NativeMathf.exp(x - kln2) * (sign * scale) * scale;\n}\n\n// @ts-ignore: decorator\n@inline\nfunction pio2f_large_quot(x: f32, u: i32): i32 { // see: jdh8/metallic/blob/master/src/math/float/rem_pio2f.c\n const coeff = reinterpret(0x3BF921FB54442D18); // π * 0x1p-65 = 8.51530395021638647334e-20\n\n var offset = (u >> 23) - 152;\n var shift = u64(offset & 63);\n var tblPtr = PIO2F_TABLE + (offset >> 6 << 3);\n\n var b0 = load(tblPtr, 0 << 3);\n var b1 = load(tblPtr, 1 << 3);\n var lo: u64;\n\n if (shift > 32) {\n let b2 = load(tblPtr, 2 << 3);\n lo = b2 >> (96 - shift);\n lo |= b1 << (shift - 32);\n } else {\n lo = b1 >> (32 - shift);\n }\n\n var hi = (b1 >> (64 - shift)) | (b0 << shift);\n var mantissa: u64 = (u & 0x007FFFFF) | 0x00800000;\n var product = mantissa * hi + (mantissa * lo >> 32);\n var r: i64 = product << 2;\n var q = i32((product >> 62) + (r >>> 63));\n rempio2f_y = copysign(coeff, x) * r;\n return q;\n}\n\n// @ts-ignore: decorator\n@inline\nfunction rempio2f(x: f32, u: u32, sign: i32): i32 { // see: jdh8/metallic/blob/master/src/math/float/rem_pio2f.c\n const\n pi2hi = reinterpret(0x3FF921FB50000000), // 1.57079631090164184570\n pi2lo = reinterpret(0x3E5110B4611A6263), // 1.58932547735281966916e-8\n _2_pi = reinterpret(0x3FE45F306DC9C883); // 0.63661977236758134308\n\n if (u < 0x4DC90FDB) { // π * 0x1p28\n let q = nearest(x * _2_pi);\n rempio2f_y = x - q * pi2hi - q * pi2lo;\n return q;\n }\n\n var q = pio2f_large_quot(x, u);\n return select(-q, q, sign);\n}\n\n// |sin(x)/x - s(x)| < 2**-37.5 (~[-4.89e-12, 4.824e-12]).\n// @ts-ignore: decorator\n@inline\nfunction sin_kernf(x: f64): f32 { // see: musl/tree/src/math/__sindf.c\n const\n S1 = reinterpret(0xBFC5555554CBAC77), // -0x15555554cbac77.0p-55\n S2 = reinterpret(0x3F811110896EFBB2), // 0x111110896efbb2.0p-59\n S3 = reinterpret(0xBF2A00F9E2CAE774), // -0x1a00f9e2cae774.0p-65\n S4 = reinterpret(0x3EC6CD878C3B46A7); // 0x16cd878c3b46a7.0p-71\n\n var z = x * x;\n var w = z * z;\n var r = S3 + z * S4;\n var s = z * x;\n return f32((x + s * (S1 + z * S2)) + s * w * r);\n}\n\n// |cos(x) - c(x)| < 2**-34.1 (~[-5.37e-11, 5.295e-11]).\n// @ts-ignore: decorator\n@inline\nfunction cos_kernf(x: f64): f32 { // see: musl/tree/src/math/__cosdf.c\n const\n C0 = reinterpret(0xBFDFFFFFFD0C5E81), // -0x1ffffffd0c5e81.0p-54\n C1 = reinterpret(0x3FA55553E1053A42), // 0x155553e1053a42.0p-57\n C2 = reinterpret(0xBF56C087E80F1E27), // -0x16c087e80f1e27.0p-62\n C3 = reinterpret(0x3EF99342E0EE5069); // 0x199342e0ee5069.0p-68\n\n var z = x * x;\n var w = z * z;\n var r = C2 + z * C3;\n return f32(((1 + z * C0) + w * C1) + (w * z) * r);\n}\n\n// |tan(x)/x - t(x)| < 2**-25.5 (~[-2e-08, 2e-08]).\n// @ts-ignore: decorator\n@inline\nfunction tan_kernf(x: f64, odd: i32): f32 { // see: musl/tree/src/math/__tandf.c\n const\n T0 = reinterpret(0x3FD5554D3418C99F), // 0x15554d3418c99f.0p-54\n T1 = reinterpret(0x3FC112FD38999F72), // 0x1112fd38999f72.0p-55\n T2 = reinterpret(0x3FAB54C91D865AFE), // 0x1b54c91d865afe.0p-57\n T3 = reinterpret(0x3F991DF3908C33CE), // 0x191df3908c33ce.0p-58\n T4 = reinterpret(0x3F685DADFCECF44E), // 0x185dadfcecf44e.0p-61\n T5 = reinterpret(0x3F8362B9BF971BCD); // 0x1362b9bf971bcd.0p-59\n\n var z = x * x;\n var r = T4 + z * T5;\n var t = T2 + z * T3;\n var w = z * z;\n var s = z * x;\n var u = T0 + z * T1;\n\n r = (x + s * u) + (s * w) * (t + w * r);\n return f32(odd ? -1 / r : r);\n}\n\n// See: jdh8/metallic/src/math/float/log2f.c and jdh8/metallic/src/math/float/kernel/atanh.h\n// @ts-ignore: decorator\n@inline\nfunction log2f(x: f64): f64 {\n const\n log2e = reinterpret(0x3FF71547652B82FE), // 1.44269504088896340736\n c0 = reinterpret(0x3FD555554FD9CAEF), // 0.33333332822728226129\n c1 = reinterpret(0x3FC999A7A8AF4132), // 0.20000167595436263505\n c2 = reinterpret(0x3FC2438D79437030), // 0.14268654271188685375\n c3 = reinterpret(0x3FBE2F663B001C97); // 0.11791075649681414150\n\n var i = reinterpret(x);\n var exponent = (i - 0x3FE6A09E667F3BCD) >> 52;\n x = reinterpret(i - (exponent << 52));\n x = (x - 1) / (x + 1);\n var xx = x * x;\n var y = x + x * xx * (c0 + c1 * xx + (c2 + c3 * xx) * (xx * xx));\n return (2 * log2e) * y + exponent;\n}\n\n// See: jdh8/metallic/src/math/float/exp2f.h and jdh8/metallic/blob/master/src/math/float/kernel/exp2f.h\n// @ts-ignore: decorator\n@inline\nfunction exp2f(x: f64): f64 {\n const\n c0 = reinterpret(0x3FE62E4302FCC24A), // 6.931471880289532425e-1\n c1 = reinterpret(0x3FCEBFBE07D97B91), // 2.402265108421173406e-1\n c2 = reinterpret(0x3FAC6AF6CCFC1A65), // 5.550357105498874537e-2\n c3 = reinterpret(0x3F83B29E3CE9AEF6), // 9.618030771171497658e-3\n c4 = reinterpret(0x3F55F0896145A89F), // 1.339086685300950937e-3\n c5 = reinterpret(0x3F2446C81E384864); // 1.546973499989028719e-4\n\n if (x < -1022) return 0;\n if (x >= 1024) return Infinity;\n\n var n = nearest(x);\n x -= n;\n var xx = x * x;\n var y = 1 + x * (c0 + c1 * x + (c2 + c3 * x) * xx + (c4 + c5 * x) * (xx * xx));\n return reinterpret(reinterpret(y) + (n << 52));\n}\n\nexport namespace NativeMathf {\n\n // @ts-ignore: decorator\n @lazy\n export const E = NativeMath.E;\n\n // @ts-ignore: decorator\n @lazy\n export const LN2 = NativeMath.LN2;\n\n // @ts-ignore: decorator\n @lazy\n export const LN10 = NativeMath.LN10;\n\n // @ts-ignore: decorator\n @lazy\n export const LOG2E = NativeMath.LOG2E;\n\n // @ts-ignore: decorator\n @lazy\n export const LOG10E = NativeMath.LOG10E;\n\n // @ts-ignore: decorator\n @lazy\n export const PI = NativeMath.PI;\n\n // @ts-ignore: decorator\n @lazy\n export const SQRT1_2 = NativeMath.SQRT1_2;\n\n // @ts-ignore: decorator\n @lazy\n export const SQRT2 = NativeMath.SQRT2;\n\n // @ts-ignore: decorator\n @lazy\n export var sincos_sin: f32 = 0;\n\n // @ts-ignore: decorator\n @lazy\n export var sincos_cos: f32 = 0;\n\n // @ts-ignore: decorator\n @inline\n export function abs(x: f32): f32 {\n return builtin_abs(x);\n }\n\n export function acos(x: f32): f32 { // see: musl/src/math/acosf.c and SUN COPYRIGHT NOTICE above\n const\n pio2_hi = reinterpret(0x3FC90FDA), // 1.5707962513e+00f\n pio2_lo = reinterpret(0x33A22168), // 7.5497894159e-08f\n Ox1p_120f = reinterpret(0x03800000); // 0x1p-120f\n\n var hx = reinterpret(x);\n var ix = hx & 0x7FFFFFFF;\n if (ix >= 0x3F800000) {\n if (ix == 0x3F800000) {\n return select(2 * pio2_hi + Ox1p_120f, 0, hx < 0);\n }\n return 0 / (x - x);\n }\n if (ix < 0x3F000000) {\n if (ix <= 0x32800000) return pio2_hi + Ox1p_120f;\n return pio2_hi - (x - (pio2_lo - x * Rf(x * x)));\n }\n var z: f32, w: f32, s: f32;\n if (hx < 0) {\n // z = (1 + x) * 0.5;\n z = 0.5 + x * 0.5;\n s = builtin_sqrt(z);\n w = Rf(z) * s - pio2_lo;\n return 2 * (pio2_hi - (s + w));\n }\n // z = (1 - x) * 0.5;\n z = 0.5 - x * 0.5;\n s = builtin_sqrt(z);\n hx = reinterpret(s);\n var df = reinterpret(hx & 0xFFFFF000);\n var c = (z - df * df) / (s + df);\n w = Rf(z) * s + c;\n return 2 * (df + w);\n }\n\n export function acosh(x: f32): f32 { // see: musl/src/math/acoshf.c\n const s = reinterpret(0x3F317218); // 0.693147180559945309417232121458176568f\n var u = reinterpret(x);\n var a = u & 0x7FFFFFFF;\n if (a < 0x3F800000 + (1 << 23)) { // |x| < 2, invalid if x < 1\n let xm1 = x - 1;\n return log1p(xm1 + builtin_sqrt(xm1 * (xm1 + 2)));\n }\n if (u < 0x3F800000 + (12 << 23)) { // 2 <= x < 0x1p12\n return log(2 * x - 1 / (x + builtin_sqrt(x * x - 1)));\n }\n // x >= 0x1p12 or x <= -2 or NaN\n return log(x) + s;\n }\n\n export function asin(x: f32): f32 { // see: musl/src/math/asinf.c and SUN COPYRIGHT NOTICE above\n const\n pio2 = reinterpret(0x3FC90FDB), // 1.570796326794896558e+00f\n Ox1p_120f = reinterpret(0x03800000); // 0x1p-120f\n\n var sx = x;\n var hx = reinterpret(x) & 0x7FFFFFFF;\n if (hx >= 0x3F800000) {\n if (hx == 0x3F800000) return x * pio2 + Ox1p_120f;\n return 0 / (x - x);\n }\n if (hx < 0x3F000000) {\n if (hx < 0x39800000 && hx >= 0x00800000) return x;\n return x + x * Rf(x * x);\n }\n // var z: f32 = (1 - builtin_abs(x)) * 0.5;\n var z: f32 = 0.5 - builtin_abs(x) * 0.5;\n var s = builtin_sqrt(z); // sic\n x = f32(pio2 - 2 * (s + s * Rf(z)));\n return builtin_copysign(x, sx);\n }\n\n export function asinh(x: f32): f32 { // see: musl/src/math/asinhf.c\n const c = reinterpret(0x3F317218); // 0.693147180559945309417232121458176568f\n var u = reinterpret(x) & 0x7FFFFFFF;\n var y = reinterpret(u);\n if (u >= 0x3F800000 + (12 << 23)) y = log(y) + c;\n else if (u >= 0x3F800000 + (1 << 23)) y = log(2 * y + 1 / (builtin_sqrt(y * y + 1) + y));\n else if (u >= 0x3F800000 - (12 << 23)) y = log1p(y + y * y / (builtin_sqrt(y * y + 1) + 1));\n return builtin_copysign(y, x);\n }\n\n export function atan(x: f32): f32 { // see: musl/src/math/atanf.c and SUN COPYRIGHT NOTICE above\n const\n atanhi0 = reinterpret(0x3EED6338), // 4.6364760399e-01f\n atanhi1 = reinterpret(0x3F490FDA), // 7.8539812565e-01f\n atanhi2 = reinterpret(0x3F7B985E), // 9.8279368877e-01f\n atanhi3 = reinterpret(0x3FC90FDA), // 1.5707962513e+00f\n atanlo0 = reinterpret(0x31AC3769), // 5.0121582440e-09f\n atanlo1 = reinterpret(0x33222168), // 3.7748947079e-08f\n atanlo2 = reinterpret(0x33140FB4), // 3.4473217170e-08f\n atanlo3 = reinterpret(0x33A22168), // 7.5497894159e-08f\n aT0 = reinterpret(0x3EAAAAA9), // 3.3333328366e-01f\n aT1 = reinterpret(0xBE4CCA98), // -1.9999158382e-01f\n aT2 = reinterpret(0x3E11F50D), // 1.4253635705e-01f\n aT3 = reinterpret(0xBDDA1247), // -1.0648017377e-01f\n aT4 = reinterpret(0x3D7CAC25), // 6.1687607318e-02f\n Ox1p_120f = reinterpret(0x03800000); // 0x1p-120f\n\n var ix = reinterpret(x);\n var sx = x;\n ix &= 0x7FFFFFFF;\n var z: f32;\n if (ix >= 0x4C800000) {\n if (isNaN(x)) return x;\n z = atanhi3 + Ox1p_120f;\n return builtin_copysign(z, sx);\n }\n var id: i32;\n if (ix < 0x3EE00000) {\n if (ix < 0x39800000) return x;\n id = -1;\n } else {\n x = builtin_abs(x);\n if (ix < 0x3F980000) {\n if (ix < 0x3F300000) {\n id = 0;\n x = (2.0 * x - 1.0) / (2.0 + x);\n } else {\n id = 1;\n x = (x - 1.0) / (x + 1.0);\n }\n } else {\n if (ix < 0x401C0000) {\n id = 2;\n x = (x - 1.5) / (1.0 + 1.5 * x);\n } else {\n id = 3;\n x = -1.0 / x;\n }\n }\n }\n z = x * x;\n var w = z * z;\n var s1 = z * (aT0 + w * (aT2 + w * aT4));\n var s2 = w * (aT1 + w * aT3);\n var s3 = x * (s1 + s2);\n if (id < 0) return x - s3;\n switch (id) {\n case 0: { z = atanhi0 - ((s3 - atanlo0) - x); break; }\n case 1: { z = atanhi1 - ((s3 - atanlo1) - x); break; }\n case 2: { z = atanhi2 - ((s3 - atanlo2) - x); break; }\n case 3: { z = atanhi3 - ((s3 - atanlo3) - x); break; }\n default: unreachable();\n }\n return builtin_copysign(z, sx);\n }\n\n export function atanh(x: f32): f32 { // see: musl/src/math/atanhf.c\n var u = reinterpret(x);\n var y = builtin_abs(x);\n if (u < 0x3F800000 - (1 << 23)) {\n if (u >= 0x3F800000 - (32 << 23)) y = 0.5 * log1p(2 * y * (1.0 + y / (1 - y)));\n } else y = 0.5 * log1p(2 * (y / (1 - y)));\n return builtin_copysign(y, x);\n }\n\n export function atan2(y: f32, x: f32): f32 { // see: musl/src/math/atan2f.c and SUN COPYRIGHT NOTICE above\n const\n pi = reinterpret(0x40490FDB), // 3.1415927410e+00f\n pi_lo = reinterpret(0xB3BBBD2E); // -8.7422776573e-08f\n\n if (isNaN(x) || isNaN(y)) return x + y;\n var ix = reinterpret(x);\n var iy = reinterpret(y);\n if (ix == 0x3F800000) return atan(y);\n var m = u32(((iy >> 31) & 1) | ((ix >> 30) & 2));\n ix &= 0x7FFFFFFF;\n iy &= 0x7FFFFFFF;\n if (iy == 0) {\n switch (m) {\n case 0:\n case 1: return y;\n case 2: return pi;\n case 3: return -pi;\n }\n }\n if (ix == 0) return m & 1 ? -pi / 2 : pi / 2;\n if (ix == 0x7F800000) {\n if (iy == 0x7F800000) {\n let t: f32 = m & 2 ? 3 * pi / 4 : pi / 4;\n return m & 1 ? -t : t;\n } else {\n let t: f32 = m & 2 ? pi : 0.0;\n return m & 1 ? -t : t;\n }\n }\n if (ix + (26 << 23) < iy || iy == 0x7F800000) return m & 1 ? -pi / 2 : pi / 2;\n var z: f32;\n if ((m & 2) && iy + (26 << 23) < ix) z = 0.0;\n else z = atan(builtin_abs(y / x));\n switch (m) {\n case 0: return z;\n case 1: return -z;\n case 2: return pi - (z - pi_lo);\n case 3: return (z - pi_lo) - pi;\n }\n unreachable();\n return 0;\n }\n\n export function cbrt(x: f32): f32 { // see: musl/src/math/cbrtf.c and SUN COPYRIGHT NOTICE above\n const\n B1 = 709958130,\n B2 = 642849266,\n Ox1p24f = reinterpret(0x4B800000);\n\n var u = reinterpret(x);\n var hx = u & 0x7FFFFFFF;\n if (hx >= 0x7F800000) return x + x;\n if (hx < 0x00800000) {\n if (hx == 0) return x;\n u = reinterpret(x * Ox1p24f);\n hx = u & 0x7FFFFFFF;\n hx = hx / 3 + B2;\n } else {\n hx = hx / 3 + B1;\n }\n u &= 0x80000000;\n u |= hx;\n var t = reinterpret(u);\n var r = t * t * t;\n t = t * (x + x + r) / (x + r + r);\n r = t * t * t;\n t = t * (x + x + r) / (x + r + r);\n return t;\n }\n\n // @ts-ignore: decorator\n @inline\n export function ceil(x: f32): f32 {\n return builtin_ceil(x);\n }\n\n export function clz32(x: f32): f32 {\n if (!isFinite(x)) return 32;\n return builtin_clz(dtoi32(x));\n }\n\n export function cos(x: f32): f32 { // see: musl/src/math/cosf.c\n const\n c1pio2 = reinterpret(0x3FF921FB54442D18), // M_PI_2 * 1\n c2pio2 = reinterpret(0x400921FB54442D18), // M_PI_2 * 2\n c3pio2 = reinterpret(0x4012D97C7F3321D2), // M_PI_2 * 3\n c4pio2 = reinterpret(0x401921FB54442D18); // M_PI_2 * 4\n\n var ux = reinterpret(x);\n var sign = ux >> 31;\n ux &= 0x7FFFFFFF;\n\n if (ux <= 0x3F490FDA) { // |x| ~<= π/4\n if (ux < 0x39800000) { // |x| < 2**-12\n // raise inexact if x != 0\n return 1;\n }\n return cos_kernf(x);\n }\n\n if (ASC_SHRINK_LEVEL < 1) {\n if (ux <= 0x407B53D1) { // |x| ~<= 5π/4\n if (ux > 0x4016CBE3) { // |x| ~> 3π/4\n return -cos_kernf(sign ? x + c2pio2 : x - c2pio2);\n } else {\n return sign ? sin_kernf(x + c1pio2) : sin_kernf(c1pio2 - x);\n }\n }\n if (ux <= 0x40E231D5) { // |x| ~<= 9π/4\n if (ux > 0x40AFEDDF) { // |x| ~> 7π/4\n return cos_kernf(sign ? x + c4pio2 : x - c4pio2);\n } else {\n return sign ? sin_kernf(-x - c3pio2) : sin_kernf(x - c3pio2);\n }\n }\n }\n\n // cos(Inf or NaN) is NaN\n if (ux >= 0x7F800000) return x - x;\n\n // general argument reduction needed\n var n = rempio2f(x, ux, sign);\n var y = rempio2f_y;\n\n var t = n & 1 ? sin_kernf(y) : cos_kernf(y);\n return (n + 1) & 2 ? -t : t;\n }\n\n export function cosh(x: f32): f32 { // see: musl/src/math/coshf.c\n var u = reinterpret(x);\n u &= 0x7FFFFFFF;\n x = reinterpret(u);\n if (u < 0x3F317217) {\n if (u < 0x3F800000 - (12 << 23)) return 1;\n let t = expm1(x);\n // return 1 + t * t / (2 * (1 + t));\n return 1 + t * t / (2 + 2 * t);\n }\n if (u < 0x42B17217) {\n let t = exp(x);\n // return 0.5 * (t + 1 / t);\n return 0.5 * t + 0.5 / t;\n }\n return expo2f(x, 1);\n }\n\n // @ts-ignore: decorator\n @inline\n export function floor(x: f32): f32 {\n return builtin_floor(x);\n }\n\n export function exp(x: f32): f32 { // see: musl/src/math/expf.c and SUN COPYRIGHT NOTICE above\n if (ASC_SHRINK_LEVEL < 1) {\n return expf_lut(x);\n } else {\n const\n ln2hi = reinterpret(0x3F317200), // 6.9314575195e-1f\n ln2lo = reinterpret(0x35BFBE8E), // 1.4286067653e-6f\n invln2 = reinterpret(0x3FB8AA3B), // 1.4426950216e+0f\n P1 = reinterpret(0x3E2AAA8F), // 1.6666625440e-1f\n P2 = reinterpret(0xBB355215), // -2.7667332906e-3f\n Ox1p127f = reinterpret(0x7F000000); // 0x1p+127f\n\n let hx = reinterpret(x);\n let sign = hx >> 31;\n hx &= 0x7FFFFFFF;\n if (hx >= 0x42AEAC50) {\n if (hx > 0x7F800000) return x; // NaN\n if (hx >= 0x42B17218) {\n if (!sign) return x * Ox1p127f;\n else if (hx >= 0x42CFF1B5) return 0;\n }\n }\n let hi: f32, lo: f32;\n let k: i32;\n if (hx > 0x3EB17218) {\n if (hx > 0x3F851592) {\n k = i32(invln2 * x + builtin_copysign(0.5, x));\n } else {\n k = 1 - (sign << 1);\n }\n hi = x - k * ln2hi;\n lo = k * ln2lo;\n x = hi - lo;\n } else if (hx > 0x39000000) {\n k = 0;\n hi = x;\n lo = 0;\n } else {\n return 1 + x;\n }\n let xx = x * x;\n let c = x - xx * (P1 + xx * P2);\n let y: f32 = 1 + (x * c / (2 - c) - lo + hi);\n return k == 0 ? y : scalbn(y, k);\n }\n }\n\n export function exp2(x: f32): f32 {\n return exp2f_lut(x);\n }\n\n export function expm1(x: f32): f32 { // see: musl/src/math/expm1f.c and SUN COPYRIGHT NOTICE above\n const\n ln2_hi = reinterpret(0x3F317180), // 6.9313812256e-01f\n ln2_lo = reinterpret(0x3717F7D1), // 9.0580006145e-06f\n invln2 = reinterpret(0x3FB8AA3B), // 1.4426950216e+00f\n Q1 = reinterpret(0xBD088868), // -3.3333212137e-02f\n Q2 = reinterpret(0x3ACF3010), // 1.5807170421e-03f\n Ox1p127f = reinterpret(0x7F000000); // 0x1p+127f\n\n var u = reinterpret(x);\n var hx = u & 0x7FFFFFFF;\n var sign = u >> 31;\n if (hx >= 0x4195B844) {\n if (hx > 0x7F800000) return x;\n if (sign) return -1;\n if (hx > 0x42B17217) { // x > log(FLT_MAX)\n x *= Ox1p127f;\n return x;\n }\n }\n var c: f32 = 0.0, t: f32, k: i32;\n if (hx > 0x3EB17218) {\n k = select(\n 1 - (sign << 1),\n i32(invln2 * x + builtin_copysign(0.5, x)),\n hx < 0x3F851592\n );\n t = k;\n let hi = x - t * ln2_hi;\n let lo = t * ln2_lo;\n x = hi - lo;\n c = (hi - x) - lo;\n } else if (hx < 0x33000000) {\n return x;\n } else k = 0;\n var hfx: f32 = 0.5 * x;\n var hxs: f32 = x * hfx;\n var r1: f32 = 1.0 + hxs * (Q1 + hxs * Q2);\n t = 3.0 - r1 * hfx;\n var e = hxs * ((r1 - t) / (6.0 - x * t));\n if (k == 0) return x - (x * e - hxs);\n e = x * (e - c) - c;\n e -= hxs;\n if (k == -1) return 0.5 * (x - e) - 0.5;\n if (k == 1) {\n if (x < -0.25) return -2.0 * (e - (x + 0.5));\n return 1.0 + 2.0 * (x - e);\n }\n u = (0x7F + k) << 23;\n var twopk = reinterpret(u);\n var y: f32;\n if (k < 0 || k > 56) {\n y = x - e + 1.0;\n if (k == 128) y = y * 2.0 * Ox1p127f;\n else y = y * twopk;\n return y - 1.0;\n }\n u = (0x7F - k) << 23;\n y = reinterpret(u);\n if (k < 20) y = (1 - y) - e;\n else y = 1 - (e + y);\n return (x + y) * twopk;\n }\n\n // @ts-ignore: decorator\n @inline\n export function fround(x: f32): f32 {\n return x;\n }\n\n export function hypot(x: f32, y: f32): f32 { // see: musl/src/math/hypotf.c\n const\n Ox1p90f = reinterpret(0x6C800000),\n Ox1p_90f = reinterpret(0x12800000);\n\n var ux = reinterpret(x);\n var uy = reinterpret(y);\n ux &= 0x7FFFFFFF;\n uy &= 0x7FFFFFFF;\n if (ux < uy) {\n let ut = ux;\n ux = uy;\n uy = ut;\n }\n x = reinterpret(ux);\n y = reinterpret(uy);\n if (uy == 0xFF << 23) return y;\n if (ux >= 0xFF << 23 || uy == 0 || ux - uy >= 25 << 23) return x + y;\n var z: f32 = 1;\n if (ux >= (0x7F + 60) << 23) {\n z = Ox1p90f;\n x *= Ox1p_90f;\n y *= Ox1p_90f;\n } else if (uy < (0x7F - 60) << 23) {\n z = Ox1p_90f;\n x *= Ox1p90f;\n y *= Ox1p90f;\n }\n return z * builtin_sqrt(f32(x * x + y * y));\n }\n\n // @ts-ignore: decorator\n @inline\n export function imul(x: f32, y: f32): f32 {\n /*\n * Wasm (MVP) and JS have different approaches for double->int conversions.\n *\n * For emulate JS conversion behavior and avoid trapping from wasm we should modulate by MAX_INT\n * our float-point arguments before actual convertion to integers.\n */\n if (!isFinite(x + y)) return 0;\n return (dtoi32(x) * dtoi32(y));\n }\n\n export function log(x: f32): f32 { // see: musl/src/math/logf.c and SUN COPYRIGHT NOTICE above\n if (ASC_SHRINK_LEVEL < 1) {\n return logf_lut(x);\n } else {\n const\n ln2_hi = reinterpret(0x3F317180), // 6.9313812256e-01f\n ln2_lo = reinterpret(0x3717F7D1), // 9.0580006145e-06f\n Lg1 = reinterpret(0x3F2AAAAA), // 0xaaaaaa.0p-24f\n Lg2 = reinterpret(0x3ECCCE13), // 0xccce13.0p-25f\n Lg3 = reinterpret(0x3E91E9EE), // 0x91e9ee.0p-25f\n Lg4 = reinterpret(0x3E789E26), // 0xf89e26.0p-26f\n Ox1p25f = reinterpret(0x4C000000);\n\n let u = reinterpret(x);\n let k = 0;\n let sign = u >> 31;\n if (sign || u < 0x00800000) {\n if (u << 1 == 0) return -1 / (x * x);\n if (sign) return (x - x) / 0;\n k -= 25;\n x *= Ox1p25f;\n u = reinterpret(x);\n } else if (u >= 0x7F800000) {\n return x;\n } else if (u == 0x3F800000) {\n return 0;\n }\n u += 0x3F800000 - 0x3F3504F3;\n k += i32(u >> 23) - 0x7F;\n u = (u & 0x007FFFFF) + 0x3F3504F3;\n x = reinterpret(u);\n let f = x - 1.0;\n let s = f / (2.0 + f);\n let z = s * s;\n let w = z * z;\n let t1 = w * (Lg2 + w * Lg4);\n let t2 = z * (Lg1 + w * Lg3);\n let r = t2 + t1;\n let hfsq = 0.5 * f * f;\n let dk = k;\n return s * (hfsq + r) + dk * ln2_lo - hfsq + f + dk * ln2_hi;\n }\n }\n\n export function log10(x: f32): f32 { // see: musl/src/math/log10f.c and SUN COPYRIGHT NOTICE above\n const\n ivln10hi = reinterpret(0x3EDE6000), // 4.3432617188e-01f\n ivln10lo = reinterpret(0xB804EAD9), // -3.1689971365e-05f\n log10_2hi = reinterpret(0x3E9A2080), // 3.0102920532e-01f\n log10_2lo = reinterpret(0x355427DB), // 7.9034151668e-07f\n Lg1 = reinterpret(0x3F2AAAAA), // 0xaaaaaa.0p-24f, 0.66666662693f\n Lg2 = reinterpret(0x3ECCCE13), // 0xccce13.0p-25f, 0.40000972152f\n Lg3 = reinterpret(0x3E91E9EE), // 0x91e9ee.0p-25f, 0.28498786688f\n Lg4 = reinterpret(0x3E789E26), // 0xf89e26.0p-26f, 0.24279078841f\n Ox1p25f = reinterpret(0x4C000000); // 0x1p25f\n\n var ux = reinterpret(x);\n var k = 0;\n var sign = ux >> 31;\n if (sign || ux < 0x00800000) {\n if (ux << 1 == 0) return -1 / (x * x);\n if (sign) return (x - x) / 0.0;\n k -= 25;\n x *= Ox1p25f;\n ux = reinterpret(x);\n } else if (ux >= 0x7F800000) {\n return x;\n } else if (ux == 0x3F800000) {\n return 0;\n }\n ux += 0x3F800000 - 0x3F3504F3;\n k += i32(ux >> 23) - 0x7F;\n ux = (ux & 0x007FFFFF) + 0x3F3504F3;\n x = reinterpret(ux);\n var f = x - 1.0;\n var s = f / (2.0 + f);\n var z = s * s;\n var w = z * z;\n var t1 = w * (Lg2 + w * Lg4);\n var t2 = z * (Lg1 + w * Lg3);\n var r = t2 + t1;\n var hfsq: f32 = 0.5 * f * f;\n var hi = f - hfsq;\n ux = reinterpret(hi);\n ux &= 0xFFFFF000;\n hi = reinterpret(ux);\n var lo = f - hi - hfsq + s * (hfsq + r);\n var dk = k;\n return dk * log10_2lo + (lo + hi) * ivln10lo + lo * ivln10hi + hi * ivln10hi + dk * log10_2hi;\n }\n\n export function log1p(x: f32): f32 { // see: musl/src/math/log1pf.c and SUN COPYRIGHT NOTICE above\n const\n ln2_hi = reinterpret(0x3F317180), // 6.9313812256e-01\n ln2_lo = reinterpret(0x3717F7D1), // 9.0580006145e-06\n Lg1 = reinterpret(0x3F2AAAAA), // 0xaaaaaa.0p-24f, 0.66666662693f\n Lg2 = reinterpret(0x3ECCCE13), // 0xccce13.0p-25f, 0.40000972152f\n Lg3 = reinterpret(0x3E91E9EE), // 0x91e9ee.0p-25f, 0.28498786688f\n Lg4 = reinterpret(0x3E789E26); // 0xf89e26.0p-26f, 0.24279078841f\n\n var ix = reinterpret(x);\n var c: f32 = 0;\n var f: f32 = 0;\n var k = 1;\n if (ix < 0x3ED413D0 || bool(ix >> 31)) {\n if (ix >= 0xBF800000) {\n if (x == -1) return x / 0.0;\n return (x - x) / 0.0;\n }\n if (ix << 1 < 0x33800000 << 1) return x;\n if (ix <= 0xBE95F619) {\n k = 0;\n c = 0;\n f = x;\n }\n } else if (ix >= 0x7F800000) return x;\n if (k) {\n let uf: f32 = 1 + x;\n let iu = reinterpret(uf);\n iu += 0x3F800000 - 0x3F3504F3;\n k = i32(iu >> 23) - 0x7F;\n if (k < 25) {\n c = k >= 2 ? 1 - (uf - x) : x - (uf - 1);\n c /= uf;\n } else c = 0;\n iu = (iu & 0x007FFFFF) + 0x3F3504F3;\n f = reinterpret(iu) - 1;\n }\n var s = f / (2.0 + f);\n var z = s * s;\n var w = z * z;\n var t1 = w * (Lg2 + w * Lg4);\n var t2 = z * (Lg1 + w * Lg3);\n var r = t2 + t1;\n var hfsq: f32 = 0.5 * f * f;\n var dk = k;\n return s * (hfsq + r) + (dk * ln2_lo + c) - hfsq + f + dk * ln2_hi;\n }\n\n export function log2(x: f32): f32 { // see: musl/src/math/log2f.c and SUN COPYRIGHT NOTICE above\n if (ASC_SHRINK_LEVEL < 1) {\n return log2f_lut(x);\n } else {\n const\n ivln2hi = reinterpret(0x3FB8B000), // 1.4428710938e+00f\n ivln2lo = reinterpret(0xB9389AD4), // -1.7605285393e-04\n Lg1 = reinterpret(0x3F2AAAAA), // 0xaaaaaa.0p-24f, 0.66666662693f\n Lg2 = reinterpret(0x3ECCCE13), // 0xccce13.0p-25f, 0.40000972152f\n Lg3 = reinterpret(0x3E91E9EE), // 0x91e9ee.0p-25f, 0.28498786688f\n Lg4 = reinterpret(0x3E789E26), // 0xf89e26.0p-26f, 0.24279078841f\n Ox1p25f = reinterpret(0x4C000000); // 0x1p25f\n\n let ux = reinterpret(x);\n let k = 0;\n let sign = ux >> 31;\n if (sign || ux < 0x00800000) {\n if (ux << 1 == 0) return -1 / (x * x);\n if (sign) return (x - x) / 0.0;\n k -= 25;\n x *= Ox1p25f;\n ux = reinterpret(x);\n } else if (ux >= 0x7F800000) {\n return x;\n } else if (ux == 0x3F800000) {\n return 0;\n }\n ux += 0x3F800000 - 0x3F3504F3;\n k += i32(ux >> 23) - 0x7F;\n ux = (ux & 0x007FFFFF) + 0x3F3504F3;\n x = reinterpret(ux);\n let f = x - 1.0;\n let s = f / (2.0 + f);\n let z = s * s;\n let w = z * z;\n let t1 = w * (Lg2 + w * Lg4);\n let t2 = z * (Lg1 + w * Lg3);\n let r = t2 + t1;\n let hfsq: f32 = 0.5 * f * f;\n let hi = f - hfsq;\n let u = reinterpret(hi);\n u &= 0xFFFFF000;\n hi = reinterpret(u);\n let lo: f32 = f - hi - hfsq + s * (hfsq + r);\n let dk = k;\n return (lo + hi) * ivln2lo + lo * ivln2hi + hi * ivln2hi + dk;\n }\n }\n\n // @ts-ignore: decorator\n @inline\n export function max(value1: f32, value2: f32): f32 {\n return builtin_max(value1, value2);\n }\n\n // @ts-ignore: decorator\n @inline\n export function min(value1: f32, value2: f32): f32 {\n return builtin_min(value1, value2);\n }\n\n export function pow(x: f32, y: f32): f32 {\n // TODO: remove this fast pathes after introduced own mid-end IR with \"stdlib call simplify\" transforms\n if (builtin_abs(y) <= 2) {\n if (y == 2.0) return x * x;\n if (y == 0.5) {\n return select(\n builtin_abs(builtin_sqrt(x)),\n Infinity,\n x != -Infinity\n );\n }\n if (y == -1.0) return 1 / x;\n if (y == 1.0) return x;\n if (y == 0.0) return 1.0;\n }\n if (ASC_SHRINK_LEVEL < 1) {\n // see: musl/src/math/powf.c\n return powf_lut(x, y);\n } else {\n // based on: jdh8/metallic/src/math/float/powf.c\n if (y == 0) return 1;\n // @ts-ignore: cast\n if (isNaN(x) | isNaN(y)) {\n return NaN;\n }\n let sign: u32 = 0;\n let uy = reinterpret(y);\n let ux = reinterpret(x);\n let sx = ux >> 31;\n ux &= 0x7FFFFFFF;\n if (sx && nearest(y) == y) {\n x = -x;\n sx = 0;\n sign = u32(nearest(y * 0.5) != y * 0.5) << 31;\n }\n let m: u32;\n if (ux == 0x3F800000) { // x == 1\n m = sx | u32((uy & 0x7FFFFFFF) == 0x7F800000) ? 0x7FC00000 : 0x3F800000;\n } else if (ux == 0) {\n m = uy < 0 ? 0x7F800000 : 0;\n } else if (ux == 0x7F800000) {\n m = uy < 0 ? 0 : 0x7F800000;\n } else if (sx) {\n m = 0x7FC00000;\n } else {\n m = reinterpret(exp2f(y * log2f(x)));\n }\n return reinterpret(m | sign);\n }\n }\n\n // @ts-ignore: decorator\n @inline\n export function seedRandom(value: i64): void {\n NativeMath.seedRandom(value);\n }\n\n // Using xoroshiro64starstar from http://xoshiro.di.unimi.it/xoroshiro64starstar.c\n export function random(): f32 {\n if (!random_seeded) seedRandom(reinterpret(seed()));\n\n var s0 = random_state0_32;\n var s1 = random_state1_32;\n var r = rotl(s0 * 0x9E3779BB, 5) * 5;\n\n s1 ^= s0;\n random_state0_32 = rotl(s0, 26) ^ s1 ^ (s1 << 9);\n random_state1_32 = rotl(s1, 13);\n\n return reinterpret((r >> 9) | (127 << 23)) - 1.0;\n }\n\n export function round(x: f32): f32 {\n if (ASC_SHRINK_LEVEL > 0) {\n return builtin_ceil(x) - f32(builtin_ceil(x) - 0.5 > x);\n } else {\n let roundUp = builtin_ceil(x);\n return select(roundUp, roundUp - 1.0, roundUp - 0.5 <= x);\n }\n }\n\n export function sign(x: f32): f32 {\n if (ASC_SHRINK_LEVEL > 0) {\n return select(builtin_copysign(1, x), x, builtin_abs(x) > 0);\n } else {\n return select(1, select(-1, x, x < 0), x > 0);\n }\n }\n\n // @ts-ignore: decorator\n @inline\n export function signbit(x: f32): bool {\n return (reinterpret(x) >>> 31);\n }\n\n export function sin(x: f32): f32 { // see: musl/src/math/sinf.c\n const\n s1pio2 = reinterpret(0x3FF921FB54442D18), // M_PI_2 * 1\n s2pio2 = reinterpret(0x400921FB54442D18), // M_PI_2 * 2\n s3pio2 = reinterpret(0x4012D97C7F3321D2), // M_PI_2 * 3\n s4pio2 = reinterpret(0x401921FB54442D18); // M_PI_2 * 4\n\n var ux = reinterpret(x);\n var sign = ux >> 31;\n ux &= 0x7FFFFFFF;\n\n if (ux <= 0x3F490FDA) { // |x| ~<= π/4\n if (ux < 0x39800000) { // |x| < 2**-12\n return x;\n }\n return sin_kernf(x);\n }\n\n if (ASC_SHRINK_LEVEL < 1) {\n if (ux <= 0x407B53D1) { // |x| ~<= 5π/4\n if (ux <= 0x4016CBE3) { // |x| ~<= 3π/4\n return sign ? -cos_kernf(x + s1pio2) : cos_kernf(x - s1pio2);\n }\n return sin_kernf(-(sign ? x + s2pio2 : x - s2pio2));\n }\n\n if (ux <= 0x40E231D5) { // |x| ~<= 9π/4\n if (ux <= 0x40AFEDDF) { // |x| ~<= 7π/4\n return sign ? cos_kernf(x + s3pio2) : -cos_kernf(x - s3pio2);\n }\n return sin_kernf(sign ? x + s4pio2 : x - s4pio2);\n }\n }\n\n // sin(Inf or NaN) is NaN\n if (ux >= 0x7F800000) return x - x;\n\n var n = rempio2f(x, ux, sign);\n var y = rempio2f_y;\n\n var t = n & 1 ? cos_kernf(y) : sin_kernf(y);\n return n & 2 ? -t : t;\n }\n\n export function sinh(x: f32): f32 { // see: musl/src/math/sinhf.c\n var u = reinterpret(x) & 0x7FFFFFFF;\n var a = reinterpret(u);\n var h = builtin_copysign(0.5, x);\n if (u < 0x42B17217) {\n let t = expm1(a);\n if (u < 0x3F800000) {\n if (u < 0x3F800000 - (12 << 23)) return x;\n return h * (2 * t - t * t / (t + 1));\n }\n return h * (t + t / (t + 1));\n }\n return expo2f(a, 2 * h);\n }\n\n // @ts-ignore: decorator\n @inline\n export function sqrt(x: f32): f32 {\n return builtin_sqrt(x);\n }\n\n export function tan(x: f32): f32 { // see: musl/src/math/tanf.c\n const\n t1pio2 = reinterpret(0x3FF921FB54442D18), // 1 * M_PI_2\n t2pio2 = reinterpret(0x400921FB54442D18), // 2 * M_PI_2\n t3pio2 = reinterpret(0x4012D97C7F3321D2), // 3 * M_PI_2\n t4pio2 = reinterpret(0x401921FB54442D18); // 4 * M_PI_2\n\n var ux = reinterpret(x);\n var sign = ux >> 31;\n ux &= 0x7FFFFFFF;\n\n if (ux <= 0x3F490FDA) { // |x| ~<= π/4\n if (ux < 0x39800000) { // |x| < 2**-12\n return x;\n }\n return tan_kernf(x, 0);\n }\n\n if (ASC_SHRINK_LEVEL < 1) {\n if (ux <= 0x407B53D1) { // |x| ~<= 5π/4\n if (ux <= 0x4016CBE3) { // |x| ~<= 3π/4\n return tan_kernf((sign ? x + t1pio2 : x - t1pio2), 1);\n } else {\n return tan_kernf((sign ? x + t2pio2 : x - t2pio2), 0);\n }\n }\n if (ux <= 0x40E231D5) { // |x| ~<= 9π/4\n if (ux <= 0x40AFEDDF) { // |x| ~<= 7π/4\n return tan_kernf((sign ? x + t3pio2 : x - t3pio2), 1);\n } else {\n return tan_kernf((sign ? x + t4pio2 : x - t4pio2), 0);\n }\n }\n }\n\n // tan(Inf or NaN) is NaN\n if (ux >= 0x7F800000) return x - x;\n\n // argument reduction\n var n = rempio2f(x, ux, sign);\n var y = rempio2f_y;\n return tan_kernf(y, n & 1);\n }\n\n export function tanh(x: f32): f32 { // see: musl/src/math/tanhf.c\n var u = reinterpret(x);\n u &= 0x7FFFFFFF;\n var y = reinterpret(u);\n var t: f32;\n if (u > 0x3F0C9F54) {\n if (u > 0x41200000) t = 1 + 0 / y;\n else {\n t = expm1(2 * y);\n t = 1 - 2 / (t + 2);\n }\n } else if (u > 0x3E82C578) {\n t = expm1(2 * y);\n t = t / (t + 2);\n } else if (u >= 0x00800000) {\n t = expm1(-2 * y);\n t = -t / (t + 2);\n } else t = y;\n return builtin_copysign(t, x);\n }\n\n // @ts-ignore: decorator\n @inline\n export function trunc(x: f32): f32 {\n return builtin_trunc(x);\n }\n\n export function scalbn(x: f32, n: i32): f32 { // see: https://git.musl-libc.org/cgit/musl/tree/src/math/scalbnf.c\n const\n Ox1p24f = reinterpret(0x4B800000),\n Ox1p127f = reinterpret(0x7F000000),\n Ox1p_126f = reinterpret(0x00800000);\n\n var y = x;\n if (n > 127) {\n y *= Ox1p127f;\n n -= 127;\n if (n > 127) {\n y *= Ox1p127f;\n n = builtin_min(n - 127, 127);\n }\n } else if (n < -126) {\n y *= Ox1p_126f * Ox1p24f;\n n += 126 - 24;\n if (n < -126) {\n y *= Ox1p_126f * Ox1p24f;\n n = builtin_max(n + 126 - 24, -126);\n }\n }\n return y * reinterpret((0x7F + n) << 23);\n }\n\n export function mod(x: f32, y: f32): f32 { // see: musl/src/math/fmodf.c\n if (builtin_abs(y) == 1.0) {\n // x % 1, x % -1 ==> sign(x) * abs(x - 1.0 * trunc(x / 1.0))\n // TODO: move this rule to compiler's optimization pass.\n // It could be apply for any x % C_pot, where \"C_pot\" is pow of two const.\n return builtin_copysign(x - builtin_trunc(x), x);\n }\n var ux = reinterpret(x);\n var uy = reinterpret(y);\n var ex = i32(ux >> 23 & 0xFF);\n var ey = i32(uy >> 23 & 0xFF);\n var sm = ux & 0x80000000;\n var uy1 = uy << 1;\n if (uy1 == 0 || ex == 0xFF || isNaN(y)) {\n let m = x * y;\n return m / m;\n }\n var ux1 = ux << 1;\n if (ux1 <= uy1) {\n return x * f32(ux1 != uy1);\n }\n if (!ex) {\n ex -= builtin_clz(ux << 9);\n ux <<= 1 - ex;\n } else {\n ux &= -1 >> 9;\n ux |= 1 << 23;\n }\n if (!ey) {\n ey -= builtin_clz(uy << 9);\n uy <<= 1 - ey;\n } else {\n uy &= u32(-1) >> 9;\n uy |= 1 << 23;\n }\n while (ex > ey) {\n if (ux >= uy) {\n if (ux == uy) return 0 * x;\n ux -= uy;\n }\n ux <<= 1;\n --ex;\n }\n if (ux >= uy) {\n if (ux == uy) return 0 * x;\n ux -= uy;\n }\n // for (; !(ux >> 23); ux <<= 1) --ex;\n var shift = builtin_clz(ux << 8);\n ex -= shift;\n ux <<= shift;\n if (ex > 0) {\n ux -= 1 << 23;\n ux |= ex << 23;\n } else {\n ux >>= -ex + 1;\n }\n return reinterpret(ux | sm);\n }\n\n export function rem(x: f32, y: f32): f32 { // see: musl/src/math/remquof.c\n var ux = reinterpret(x);\n var uy = reinterpret(y);\n var ex = i32(ux >> 23 & 0xFF);\n var ey = i32(uy >> 23 & 0xFF);\n var uxi = ux;\n if (uy << 1 == 0 || ex == 0xFF || isNaN(y)) return (x * y) / (x * y);\n if (ux << 1 == 0) return x;\n if (!ex) {\n ex -= builtin_clz(uxi << 9);\n uxi <<= 1 - ex;\n } else {\n uxi &= u32(-1) >> 9;\n uxi |= 1 << 23;\n }\n if (!ey) {\n ey -= builtin_clz(uy << 9);\n uy <<= 1 - ey;\n } else {\n uy &= u32(-1) >> 9;\n uy |= 1 << 23;\n }\n var q = 0;\n do {\n if (ex < ey) {\n if (ex + 1 == ey) break; // goto end\n return x;\n }\n while (ex > ey) {\n if (uxi >= uy) {\n uxi -= uy;\n ++q;\n }\n uxi <<= 1;\n q <<= 1;\n --ex;\n }\n if (uxi >= uy) {\n uxi -= uy;\n ++q;\n }\n if (uxi == 0) ex = -30;\n else {\n let shift = builtin_clz(uxi << 8);\n ex -= shift;\n uxi <<= shift;\n }\n break;\n } while (false);\n // end:\n if (ex > 0) {\n uxi -= 1 << 23;\n uxi |= ex << 23;\n } else {\n uxi >>= -ex + 1;\n }\n x = reinterpret(uxi);\n y = builtin_abs(y);\n var x2 = x + x;\n if (ex == ey || (ex + 1 == ey && (x2 > y || (x2 == y && bool(q & 1))))) {\n x -= y;\n // q++;\n }\n return ux < 0 ? -x : x;\n }\n\n export function sincos(x: f32): void { // see: musl/tree/src/math/sincosf.c\n const\n s1pio2 = reinterpret(0x3FF921FB54442D18), // 1 * M_PI_2\n s2pio2 = reinterpret(0x400921FB54442D18), // 2 * M_PI_2\n s3pio2 = reinterpret(0x4012D97C7F3321D2), // 3 * M_PI_2\n s4pio2 = reinterpret(0x401921FB54442D18); // 4 * M_PI_2\n\n var ux = reinterpret(x);\n var sign = ux >> 31;\n ux &= 0x7FFFFFFF;\n\n if (ux <= 0x3F490FDA) { // |x| ~<= π/4\n if (ux < 0x39800000) { // |x| < 2**-12\n sincos_sin = x;\n sincos_cos = 1;\n return;\n }\n sincos_sin = sin_kernf(x);\n sincos_cos = cos_kernf(x);\n return;\n }\n if (ASC_SHRINK_LEVEL < 1) {\n if (ux <= 0x407B53D1) { // |x| ~<= 5π/4\n if (ux <= 0x4016CBE3) { // |x| ~<= 3π/4\n if (sign) {\n sincos_sin = -cos_kernf(x + s1pio2);\n sincos_cos = sin_kernf(x + s1pio2);\n } else {\n sincos_sin = cos_kernf(s1pio2 - x);\n sincos_cos = sin_kernf(s1pio2 - x);\n }\n return;\n }\n // -sin(x + c) is not correct if x+c could be 0: -0 vs +0\n sincos_sin = -sin_kernf(sign ? x + s2pio2 : x - s2pio2);\n sincos_cos = -cos_kernf(sign ? x + s2pio2 : x - s2pio2);\n return;\n }\n if (ux <= 0x40E231D5) { // |x| ~<= 9π/4\n if (ux <= 0x40AFEDDF) { // |x| ~<= 7π/4\n if (sign) {\n sincos_sin = cos_kernf(x + s3pio2);\n sincos_cos = -sin_kernf(x + s3pio2);\n } else {\n sincos_sin = -cos_kernf(x - s3pio2);\n sincos_cos = sin_kernf(x - s3pio2);\n }\n return;\n }\n sincos_sin = sin_kernf(sign ? x + s4pio2 : x - s4pio2);\n sincos_cos = cos_kernf(sign ? x + s4pio2 : x - s4pio2);\n return;\n }\n }\n // sin(Inf or NaN) is NaN\n if (ux >= 0x7F800000) {\n let xx = x - x;\n sincos_sin = xx;\n sincos_cos = xx;\n return;\n }\n // general argument reduction needed\n var n = rempio2f(x, ux, sign);\n var y = rempio2f_y;\n var s = sin_kernf(y);\n var c = cos_kernf(y);\n var sin = s, cos = c;\n if (n & 1) {\n sin = c;\n cos = -s;\n }\n if (n & 2) {\n sin = -sin;\n cos = -cos;\n }\n sincos_sin = sin;\n sincos_cos = cos;\n }\n}\n\nexport function ipow32(x: i32, e: i32): i32 {\n var out = 1;\n if (ASC_SHRINK_LEVEL < 1) {\n if (x == 2) {\n return select(1 << e, 0, e < 32);\n }\n if (e <= 0) {\n if (x == -1) return select(-1, 1, e & 1);\n return i32(e == 0) | i32(x == 1);\n }\n else if (e == 1) return x;\n else if (e == 2) return x * x;\n else if (e < 32) {\n let log = 32 - clz(e);\n // 32 = 2 ^ 5, so need only five cases.\n // But some extra cases needs for properly overflowing\n switch (log) {\n case 5: {\n if (e & 1) out *= x;\n e >>>= 1;\n x *= x;\n }\n case 4: {\n if (e & 1) out *= x;\n e >>>= 1;\n x *= x;\n }\n case 3: {\n if (e & 1) out *= x;\n e >>>= 1;\n x *= x;\n }\n case 2: {\n if (e & 1) out *= x;\n e >>>= 1;\n x *= x;\n }\n case 1: {\n if (e & 1) out *= x;\n }\n }\n return out;\n }\n }\n while (e) {\n if (e & 1) out *= x;\n e >>>= 1;\n x *= x;\n }\n return out;\n}\n\nexport function ipow64(x: i64, e: i64): i64 {\n var out: i64 = 1;\n if (ASC_SHRINK_LEVEL < 1) {\n if (x == 2) {\n return select(1 << e, 0, e < 64);\n }\n if (e <= 0) {\n if (x == -1) return select(-1, 1, e & 1);\n return i64(e == 0) | i64(x == 1);\n }\n else if (e == 1) return x;\n else if (e == 2) return x * x;\n else if (e < 64) {\n let log = 64 - clz(e);\n // 64 = 2 ^ 6, so need only six cases.\n // But some extra cases needs for properly overflowing\n switch (log) {\n case 6: {\n if (e & 1) out *= x;\n e >>>= 1;\n x *= x;\n }\n case 5: {\n if (e & 1) out *= x;\n e >>>= 1;\n x *= x;\n }\n case 4: {\n if (e & 1) out *= x;\n e >>>= 1;\n x *= x;\n }\n case 3: {\n if (e & 1) out *= x;\n e >>>= 1;\n x *= x;\n }\n case 2: {\n if (e & 1) out *= x;\n e >>>= 1;\n x *= x;\n }\n case 1: {\n if (e & 1) out *= x;\n }\n }\n return out;\n }\n }\n while (e) {\n if (e & 1) out *= x;\n e >>>= 1;\n x *= x;\n }\n return out;\n}\n\n/*\nTODO:\nIn compile time if only exponent is constant we could replace ipow32/ipow64 by shortest addition chains\nwhich usually faster than exponentiation by squaring\n\nfor ipow32 and e < 32:\n\nlet b: i32, c: i32, d: i32, h: i32, k: i32, g: i32;\nswitch (e) {\n case 1: return x;\n case 2: return x * x;\n case 3: return x * x * x;\n case 4: return (b = x * x) * b;\n case 5: return (b = x * x) * b * x;\n case 6: return (b = x * x) * b * b;\n case 7: return (b = x * x) * b * b * x;\n case 8: return (d = (b = x * x) * b) * d;\n case 9: return (c = x * x * x) * c * c;\n case 10: return (d = (b = x * x) * b) * d * b;\n case 11: return (d = (b = x * x) * b) * d * b * x;\n case 12: return (d = (b = x * x) * b) * d * d;\n case 13: return (d = (b = x * x) * b) * d * d * x;\n case 14: return (d = (b = x * x) * b) * d * d * b;\n case 15: return (k = (b = x * x) * b * x) * k * k;\n case 16: return (h = (d = (b = x * x) * b) * d) * h;\n case 17: return (h = (d = (b = x * x) * b) * d) * h * x;\n case 18: return (h = (d = (b = x * x) * b) * d * x) * h;\n case 19: return (h = (d = (b = x * x) * b) * d * x) * h * x;\n case 20: return (h = (k = (b = x * x) * b * x) * k) * h;\n case 21: return (h = (k = (b = x * x) * b * x) * k) * h * x;\n case 22: return (g = (h = (k = (b = x * x) * b * x) * k) * x) * g;\n case 23: return (h = (d = (c = (b = x * x) * x) * b) * d) * h * c;\n case 24: return (h = (d = (c = x * x * x) * c) * d) * h;\n case 25: return (h = (d = (c = x * x * x) * c) * d) * h * x;\n case 26: return (g = (h = (d = (c = x * x * x) * c) * d) * x) * g;\n case 27: return (h = (d = (c = x * x * x) * c) * d) * h * c;\n case 28: return (h = (d = (c = x * x * x) * c * x) * d) * h;\n case 29: return (h = (d = (c = x * x * x) * c * x) * d) * h * x;\n case 30: return (h = (d = (c = x * x * x) * c) * d * c) * h;\n case 31: return (h = (d = (c = x * x * x) * c) * d * c) * h * x;\n}\n\nfor ipow64: TODO\nswitch (e) {\n case 32:\n ...\n case 63:\n}\n*/\n","// This file is shared with the compiler and must remain portable\n\n/** Runtime types. */\nexport enum Runtime {\n /** Simple bump allocator without GC. */\n Stub = 0,\n /** Stop the world semi-automatic GC. */\n Minimal = 1,\n /** incremental GC. */\n Incremental = 2,\n}\n","import { compareImpl } from \"./string\";\n\ntype Comparator = (a: T, b: T) => i32;\n\n// @ts-ignore: decorator\n@lazy @inline const EMPTY = u32.MAX_VALUE;\n// @ts-ignore: decorator\n@inline const INSERTION_SORT_THRESHOLD = 48;\n// @ts-ignore: decorator\n@inline const MIN_RUN_LENGTH = 32;\n\n// @ts-ignore: decorator\n@inline\nfunction log2u(n: u32): u32 {\n return 31 - clz(n);\n}\n\n// @ts-ignore: decorator\n@inline\nexport function COMPARATOR(): Comparator {\n if (isInteger()) {\n if (isSigned() && sizeof() <= 4) {\n return (a, b) => i32(a) - i32(b);\n } else {\n return (a, b) => i32(a > b) - i32(a < b);\n }\n } else if (isFloat()) {\n if (sizeof() == 4) {\n return (a, b) => {\n var ia = reinterpret(f32(a));\n var ib = reinterpret(f32(b));\n ia ^= ia >> 31 >>> 1;\n ib ^= ib >> 31 >>> 1;\n return i32(ia > ib) - i32(ia < ib);\n };\n } else {\n return (a, b) => {\n var ia = reinterpret(f64(a));\n var ib = reinterpret(f64(b));\n ia ^= ia >> 63 >>> 1;\n ib ^= ib >> 63 >>> 1;\n return i32(ia > ib) - i32(ia < ib);\n };\n }\n } else if (isString()) {\n return (a, b) => {\n if (\n changetype(a) == changetype(b) ||\n changetype(a) == 0 ||\n changetype(b) == 0\n ) return 0;\n var alen = changetype(a).length;\n var blen = changetype(b).length;\n if (!(alen | blen)) return 0;\n if (!alen) return -1;\n if (!blen) return 1;\n let res = compareImpl(\n changetype(a), 0,\n changetype(b), 0,\n min(alen, blen)\n );\n return res ? res : alen - blen;\n };\n } else {\n return (a, b) => i32(a > b) - i32(a < b);\n }\n}\n\n// Power Sort implementation (stable) from paper \"Nearly-Optimal Mergesorts\"\n// https://arxiv.org/pdf/1805.04154.pdf\n// This method usually outperform TimSort.\n// TODO: refactor c >>> 31 to c < 0 when binaryen will support this opt\nexport function SORT(\n ptr: usize,\n len: i32,\n comparator: Comparator\n): void {\n if (len <= INSERTION_SORT_THRESHOLD) {\n if (len <= 1) return;\n if (ASC_SHRINK_LEVEL < 1) {\n switch (len) {\n case 3: {\n let a = load(ptr, 0);\n let b = load(ptr, 1 << alignof());\n let c = comparator(a, b) > 0;\n store(ptr, select(b, a, c), 0);\n a = select(a, b, c);\n b = load(ptr, 2 << alignof());\n c = comparator(a, b) > 0;\n store(ptr, select(b, a, c), 1 << alignof());\n store(ptr, select(a, b, c), 2 << alignof());\n }\n case 2: {\n let a = load(ptr, 0);\n let b = load(ptr, 1 << alignof());\n let c = comparator(a, b) > 0;\n store(ptr, select(b, a, c), 0);\n store(ptr, select(a, b, c), 1 << alignof());\n return;\n }\n }\n }\n insertionSort(ptr, 0, len - 1, 0, comparator);\n return;\n }\n\n var lgPlus2 = log2u(len) + 2;\n var lgPlus2Size = lgPlus2 << alignof();\n var leftRunStartBuf = __alloc(lgPlus2Size << 1);\n var leftRunEndBuf = leftRunStartBuf + lgPlus2Size;\n\n for (let i: u32 = 0; i < lgPlus2; ++i) {\n store(leftRunStartBuf + (i << alignof()), EMPTY);\n }\n\n var buffer = __alloc(len << alignof());\n\n var hi = len - 1;\n var endA = extendRunRight(ptr, 0, hi, comparator);\n var lenA = endA + 1;\n\n if (lenA < MIN_RUN_LENGTH) {\n endA = min(hi, MIN_RUN_LENGTH - 1);\n insertionSort(ptr, 0, endA, lenA, comparator);\n }\n\n var top: u32 = 0, startA = 0;\n while (endA < hi) {\n let startB = endA + 1;\n let endB = extendRunRight(ptr, startB, hi, comparator);\n let lenB = endB - startB + 1;\n\n if (lenB < MIN_RUN_LENGTH) {\n endB = min(hi, startB + MIN_RUN_LENGTH - 1);\n insertionSort(ptr, startB, endB, lenB, comparator);\n }\n\n let k = nodePower(0, hi, startA, startB, endB);\n\n for (let i = top; i > k; --i) {\n let start = load(leftRunStartBuf + (i << alignof()));\n if (start != EMPTY) {\n mergeRuns(\n ptr,\n start,\n load(leftRunEndBuf + (i << alignof())) + 1,\n endA,\n buffer,\n comparator\n );\n startA = start;\n store(leftRunStartBuf + (i << alignof()), EMPTY);\n }\n }\n\n store(leftRunStartBuf + (k << alignof()), startA);\n store(leftRunEndBuf + (k << alignof()), endA);\n startA = startB;\n endA = endB;\n top = k;\n }\n\n for (let i = top; i != 0; --i) {\n let start = load(leftRunStartBuf + (i << alignof()));\n if (start != EMPTY) {\n mergeRuns(\n ptr,\n start,\n load(leftRunEndBuf + (i << alignof())) + 1,\n hi,\n buffer,\n comparator\n );\n }\n }\n // dealloc aux buffers\n __free(buffer);\n __free(leftRunStartBuf);\n}\n\nfunction insertionSort(\n ptr: usize,\n left: i32,\n right: i32,\n presorted: i32,\n comparator: Comparator\n): void {\n if (ASC_SHRINK_LEVEL >= 1) {\n // slightly improved original insertion sort\n for (let i = left + presorted; i <= right; ++i) {\n let j = i - 1;\n let a = load(ptr + (i << alignof()));\n while (j >= left) {\n let b = load(ptr + (j << alignof()));\n if (comparator(a, b) < 0) {\n store(ptr + (j << alignof()), b, 1 << alignof()); --j;\n } else break;\n }\n store(ptr + (j << alignof()), a, 1 << alignof());\n }\n } else {\n // even-odd two-way insertion sort which allow increase minRunLen\n let range = right - left + 1;\n let i = left + select(range & 1, presorted - ((range - presorted) & 1), presorted == 0);\n for (; i <= right; i += 2) {\n let a = load(ptr + (i << alignof()), 0);\n let b = load(ptr + (i << alignof()), 1 << alignof());\n let min = b, max = a;\n if (comparator(a, b) <= 0) {\n min = a, max = b;\n }\n let j = i - 1;\n while (j >= left) {\n a = load(ptr + (j << alignof()));\n if (comparator(a, max) > 0) {\n store(ptr + (j << alignof()), a, 2 << alignof()); --j;\n } else break;\n }\n store(ptr + (j << alignof()), max, 2 << alignof());\n while (j >= left) {\n a = load(ptr + (j << alignof()));\n if (comparator(a, min) > 0) {\n store(ptr + (j << alignof()), a, 1 << alignof()); --j;\n } else break;\n }\n store(ptr + (j << alignof()), min, 1 << alignof());\n }\n }\n}\n\nfunction nodePower(left: u32, right: u32, startA: u32, startB: u32, endB: u32): u32 {\n var n: u64 = right - left + 1;\n var s = startB - (left << 1);\n var l = startA + s;\n var r = endB + s + 1;\n var a = (l << 30) / n;\n var b = (r << 30) / n;\n return clz((a ^ b));\n}\n\nfunction extendRunRight(\n ptr: usize,\n i: i32,\n right: i32,\n comparator: Comparator\n): i32 {\n if (i == right) return i;\n var j = i;\n if (comparator(\n load(ptr + ( j << alignof())),\n load(ptr + (++j << alignof()))\n ) > 0) {\n while (\n j < right &&\n (comparator(\n load(ptr + (j << alignof()), 1 << alignof()),\n load(ptr + (j << alignof()))\n ) >>> 31) // < 0\n ) ++j;\n // reverse\n let k = j;\n while (i < k) {\n let tmp = load(ptr + (i << alignof()));\n store(ptr + (i << alignof()), load(ptr + (k << alignof()))); ++i;\n store(ptr + (k << alignof()), tmp); --k;\n }\n } else {\n while (\n j < right &&\n comparator(\n load(ptr + (j << alignof()), 1 << alignof()),\n load(ptr + (j << alignof()))\n ) >= 0\n ) ++j;\n }\n return j;\n}\n\n// Merges arr[l..m - 1] and arr[m..r]\nfunction mergeRuns(\n ptr: usize,\n l: i32,\n m: i32,\n r: i32,\n buffer: usize,\n comparator: Comparator\n): void {\n --m;\n var i: i32, j: i32, t = r + m;\n for (i = m + 1; i > l; --i) {\n store(\n buffer + ((i - 1) << alignof()),\n load(ptr + ((i - 1) << alignof()))\n );\n }\n for (j = m; j < r; ++j) {\n store(\n buffer + ((t - j) << alignof()),\n load(ptr + (j << alignof()), 1 << alignof())\n );\n }\n for (let k = l; k <= r; ++k) {\n let a = load(buffer + (j << alignof()));\n let b = load(buffer + (i << alignof()));\n if (comparator(a, b) < 0) {\n store(ptr + (k << alignof()), a);\n --j;\n } else {\n store(ptr + (k << alignof()), b);\n ++i;\n }\n }\n}\n","/// \n\nimport { BLOCK_MAXSIZE } from \"./rt/common\";\nimport { Runtime } from \"shared/runtime\";\nimport { COMPARATOR, SORT } from \"./util/sort\";\nimport { REVERSE, FILL } from \"./util/bytes\";\nimport { joinBooleanArray, joinIntegerArray, joinFloatArray, joinStringArray, joinReferenceArray } from \"./util/string\";\nimport { idof, isArray as builtin_isArray } from \"./builtins\";\nimport { E_INDEXOUTOFRANGE, E_INVALIDLENGTH, E_EMPTYARRAY, E_HOLEYARRAY } from \"./util/error\";\n\n// @ts-ignore: decorator\n@inline @lazy const MIN_SIZE: usize = 8;\n\n/** Ensures that the given array has _at least_ the specified backing size. */\nfunction ensureCapacity(array: usize, newSize: usize, alignLog2: u32, canGrow: bool = true): void {\n // Depends on the fact that Arrays mimic ArrayBufferView\n var oldCapacity = changetype(array).byteLength;\n if (newSize > oldCapacity >>> alignLog2) {\n if (newSize > BLOCK_MAXSIZE >>> alignLog2) throw new RangeError(E_INVALIDLENGTH);\n let oldData = changetype(changetype(array).buffer);\n // Grows old capacity by factor of two.\n // Make sure we don't reach BLOCK_MAXSIZE for new growed capacity.\n let newCapacity = max(newSize, MIN_SIZE) << alignLog2;\n if (canGrow) newCapacity = max(min(oldCapacity << 1, BLOCK_MAXSIZE), newCapacity);\n let newData = __renew(oldData, newCapacity);\n // __new / __renew already init memory range as zeros in Incremental runtime.\n // So try to avoid this.\n if (ASC_RUNTIME != Runtime.Incremental) {\n memory.fill(newData + oldCapacity, 0, newCapacity - oldCapacity);\n }\n if (newData != oldData) { // oldData has been free'd\n store(array, newData, offsetof(\"buffer\"));\n store(array, newData, offsetof(\"dataStart\"));\n __link(array, changetype(newData), false);\n }\n store(array, newCapacity, offsetof(\"byteLength\"));\n }\n}\n\nexport class Array {\n [key: number]: T;\n\n // Mimicking ArrayBufferView isn't strictly necessary here but is done to allow glue code\n // to work with typed and normal arrays interchangeably. Technically, normal arrays do not need\n // `dataStart` (equals `buffer`) and `byteLength` (equals computed `buffer.byteLength`), but the\n // block is 16 bytes anyway so it's fine to have a couple extra fields in there.\n\n private buffer: ArrayBuffer;\n @unsafe readonly dataStart: usize;\n private byteLength: i32; // Uses here as capacity\n\n // Also note that Array with non-nullable T must guard against uninitialized null values\n // whenever an element is accessed. Otherwise, the compiler wouldn't be able to guarantee\n // type-safety anymore. For lack of a better word, such an array is \"holey\".\n\n private length_: i32;\n\n static isArray(value: U): bool {\n return isReference() ? changetype(value) != 0 && builtin_isArray(value) : false;\n }\n\n static create(capacity: i32 = 0): Array {\n WARNING(\"'Array.create' is deprecated. Use 'new Array' instead, making sure initial elements are initialized.\");\n var array = new Array(capacity);\n array.length = 0;\n return array;\n }\n\n constructor(length: i32 = 0) {\n if (length > BLOCK_MAXSIZE >>> alignof()) throw new RangeError(E_INVALIDLENGTH);\n // reserve capacity for at least MIN_SIZE elements\n var bufferSize = max(length, MIN_SIZE) << alignof();\n var buffer = changetype(__new(bufferSize, idof()));\n if (ASC_RUNTIME != Runtime.Incremental) {\n memory.fill(changetype(buffer), 0, bufferSize);\n }\n this.buffer = buffer; // links\n this.dataStart = changetype(buffer);\n this.byteLength = bufferSize;\n this.length_ = length;\n }\n\n get length(): i32 {\n return this.length_;\n }\n\n set length(newLength: i32) {\n ensureCapacity(changetype(this), newLength, alignof(), false);\n this.length_ = newLength;\n }\n\n every(fn: (value: T, index: i32, array: Array) => bool): bool {\n for (let i = 0, len = this.length_; i < min(len, this.length_); ++i) {\n if (!fn(load(this.dataStart + (i << alignof())), i, this)) return false;\n }\n return true;\n }\n\n findIndex(fn: (value: T, index: i32, array: Array) => bool): i32 {\n for (let i = 0, len = this.length_; i < min(len, this.length_); ++i) {\n if (fn(load(this.dataStart + (i << alignof())), i, this)) return i;\n }\n return -1;\n }\n\n findLastIndex(fn: (value: T, index: i32, array: Array) => bool): i32 {\n for (let i = this.length_ - 1; i >= 0; --i) {\n if (fn(load(this.dataStart + (i << alignof())), i, this)) return i;\n }\n return -1;\n }\n\n @operator(\"[]\") private __get(index: i32): T {\n if (index >= this.length_) throw new RangeError(E_INDEXOUTOFRANGE);\n var value = load(this.dataStart + (index << alignof()));\n if (isReference()) {\n if (!isNullable()) {\n if (!changetype(value)) throw new Error(E_HOLEYARRAY);\n }\n }\n return value;\n }\n\n @unsafe @operator(\"{}\") private __uget(index: i32): T {\n return load(this.dataStart + (index << alignof()));\n }\n\n @operator(\"[]=\") private __set(index: i32, value: T): void {\n if (index >= this.length_) {\n if (index < 0) throw new RangeError(E_INDEXOUTOFRANGE);\n ensureCapacity(changetype(this), index + 1, alignof());\n this.length_ = index + 1;\n }\n this.__uset(index, value);\n }\n\n @unsafe @operator(\"{}=\") private __uset(index: i32, value: T): void {\n store(this.dataStart + (index << alignof()), value);\n if (isManaged()) {\n __link(changetype(this), changetype(value), true);\n }\n }\n\n at(index: i32): T {\n var len = this.length_;\n index += select(0, len, index >= 0);\n if (index >= len) throw new RangeError(E_INDEXOUTOFRANGE);\n var value = load(this.dataStart + (index << alignof()));\n if (isReference()) {\n if (!isNullable()) {\n if (!changetype(value)) throw new Error(E_HOLEYARRAY);\n }\n }\n return value;\n }\n\n fill(value: T, start: i32 = 0, end: i32 = i32.MAX_VALUE): Array {\n if (isManaged()) {\n FILL(this.dataStart, this.length_, changetype(value), start, end);\n __link(changetype(this), changetype(value), false);\n } else {\n FILL(this.dataStart, this.length_, value, start, end);\n }\n return this;\n }\n\n includes(value: T, fromIndex: i32 = 0): bool {\n if (isFloat()) {\n let len = this.length_;\n if (len == 0 || fromIndex >= len) return false;\n if (fromIndex < 0) fromIndex = max(len + fromIndex, 0);\n let ptr = this.dataStart;\n while (fromIndex < len) {\n let elem = load(ptr + (fromIndex << alignof()));\n // @ts-ignore\n if (elem == value || isNaN(elem) & isNaN(value)) return true;\n ++fromIndex;\n }\n return false;\n } else {\n return this.indexOf(value, fromIndex) >= 0;\n }\n }\n\n indexOf(value: T, fromIndex: i32 = 0): i32 {\n var len = this.length_;\n if (len == 0 || fromIndex >= len) return -1;\n if (fromIndex < 0) fromIndex = max(len + fromIndex, 0);\n var ptr = this.dataStart;\n while (fromIndex < len) {\n if (load(ptr + (fromIndex << alignof())) == value) return fromIndex;\n ++fromIndex;\n }\n return -1;\n }\n\n lastIndexOf(value: T, fromIndex: i32 = this.length_): i32 {\n var len = this.length_;\n if (len == 0) return -1;\n if (fromIndex < 0) fromIndex = len + fromIndex;\n else if (fromIndex >= len) fromIndex = len - 1;\n var ptr = this.dataStart;\n while (fromIndex >= 0) {\n if (load(ptr + (fromIndex << alignof())) == value) return fromIndex;\n --fromIndex;\n }\n return -1;\n }\n\n push(value: T): i32 {\n var oldLen = this.length_;\n var len = oldLen + 1;\n ensureCapacity(changetype(this), len, alignof());\n if (isManaged()) {\n store(this.dataStart + (oldLen << alignof()), changetype(value));\n __link(changetype(this), changetype(value), true);\n } else {\n store(this.dataStart + (oldLen << alignof()), value);\n }\n this.length_ = len;\n return len;\n }\n\n concat(other: Array): Array {\n var thisLen = this.length_;\n var otherLen = other.length_;\n var outLen = thisLen + otherLen;\n if (outLen > BLOCK_MAXSIZE >>> alignof()) throw new Error(E_INVALIDLENGTH);\n var out = changetype>(__newArray(outLen, alignof(), idof>()));\n var outStart = out.dataStart;\n var thisSize = thisLen << alignof();\n if (isManaged()) {\n let thisStart = this.dataStart;\n for (let offset: usize = 0; offset < thisSize; offset += sizeof()) {\n let ref = load(thisStart + offset);\n store(outStart + offset, ref);\n __link(changetype(out), ref, true);\n }\n outStart += thisSize;\n let otherStart = other.dataStart;\n let otherSize = otherLen << alignof();\n for (let offset: usize = 0; offset < otherSize; offset += sizeof()) {\n let ref = load(otherStart + offset);\n store(outStart + offset, ref);\n __link(changetype(out), ref, true);\n }\n } else {\n memory.copy(outStart, this.dataStart, thisSize);\n memory.copy(outStart + thisSize, other.dataStart, otherLen << alignof());\n }\n return out;\n }\n\n copyWithin(target: i32, start: i32, end: i32 = i32.MAX_VALUE): Array {\n var ptr = this.dataStart;\n var len = this.length_;\n\n end = min(end, len);\n\n var to = target < 0 ? max(len + target, 0) : min(target, len);\n var from = start < 0 ? max(len + start, 0) : min(start, len);\n var last = end < 0 ? max(len + end, 0) : min(end, len);\n var count = min(last - from, len - to);\n\n memory.copy( // is memmove\n ptr + (to << alignof()),\n ptr + (from << alignof()),\n count << alignof()\n );\n return this;\n }\n\n pop(): T {\n var len = this.length_;\n if (len < 1) throw new RangeError(E_EMPTYARRAY);\n var val = load(this.dataStart + ((--len) << alignof()));\n this.length_ = len;\n return val;\n }\n\n forEach(fn: (value: T, index: i32, array: Array) => void): void {\n for (let i = 0, len = this.length_; i < min(len, this.length_); ++i) {\n fn(load(this.dataStart + (i << alignof())), i, this);\n }\n }\n\n map(fn: (value: T, index: i32, array: Array) => U): Array {\n var len = this.length_;\n var out = changetype>(__newArray(len, alignof(), idof>()));\n var outStart = out.dataStart;\n for (let i = 0; i < min(len, this.length_); ++i) {\n let result = fn(load(this.dataStart + (i << alignof())), i, this);\n store(outStart + (i << alignof()), result);\n if (isManaged()) {\n __link(changetype(out), changetype(result), true);\n }\n }\n return out;\n }\n\n filter(fn: (value: T, index: i32, array: Array) => bool): Array {\n var result = changetype>(__newArray(0, alignof(), idof>()));\n for (let i = 0, len = this.length_; i < min(len, this.length_); ++i) {\n let value = load(this.dataStart + (i << alignof()));\n if (fn(value, i, this)) result.push(value);\n }\n return result;\n }\n\n reduce(\n fn: (previousValue: U, currentValue: T, currentIndex: i32, array: Array) => U,\n initialValue: U\n ): U {\n var acc = initialValue;\n for (let i = 0, len = this.length_; i < min(len, this.length_); ++i) {\n acc = fn(acc, load(this.dataStart + (i << alignof())), i, this);\n }\n return acc;\n }\n\n reduceRight(\n fn: (previousValue: U, currentValue: T, currentIndex: i32, array: Array) => U,\n initialValue: U\n ): U {\n var acc = initialValue;\n for (let i = this.length_ - 1; i >= 0; --i) {\n acc = fn(acc, load(this.dataStart + (i << alignof())), i, this);\n }\n return acc;\n }\n\n shift(): T {\n var len = this.length_;\n if (len < 1) throw new RangeError(E_EMPTYARRAY);\n var base = this.dataStart;\n var element = load(base);\n var lastIndex = len - 1;\n memory.copy(\n base,\n base + sizeof(),\n lastIndex << alignof()\n );\n if (isReference()) {\n store(base + (lastIndex << alignof()), 0);\n } else {\n // @ts-ignore\n store(base + (lastIndex << alignof()), 0);\n }\n this.length_ = lastIndex;\n return element;\n }\n\n some(fn: (value: T, index: i32, array: Array) => bool): bool {\n for (let i = 0, len = this.length_; i < min(len, this.length_); ++i) {\n if (fn(load(this.dataStart + (i << alignof())), i, this)) return true;\n }\n return false;\n }\n\n unshift(value: T): i32 {\n var len = this.length_ + 1;\n ensureCapacity(changetype(this), len, alignof());\n var ptr = this.dataStart;\n memory.copy(\n ptr + sizeof(),\n ptr,\n (len - 1) << alignof()\n );\n store(ptr, value);\n if (isManaged()) {\n __link(changetype(this), changetype(value), true);\n }\n this.length_ = len;\n return len;\n }\n\n slice(start: i32 = 0, end: i32 = i32.MAX_VALUE): Array {\n var len = this.length_;\n start = start < 0 ? max(start + len, 0) : min(start, len);\n end = end < 0 ? max(end + len, 0) : min(end , len);\n len = max(end - start, 0);\n var slice = changetype>(__newArray(len, alignof(), idof>()));\n var sliceBase = slice.dataStart;\n var thisBase = this.dataStart + (start << alignof());\n if (isManaged()) {\n let off = 0;\n let end = len << alignof();\n while (off < end) {\n let ref = load(thisBase + off);\n store(sliceBase + off, ref);\n __link(changetype(slice), ref, true);\n off += sizeof();\n }\n } else {\n memory.copy(sliceBase, thisBase, len << alignof());\n }\n return slice;\n }\n\n splice(start: i32, deleteCount: i32 = i32.MAX_VALUE): Array {\n var len = this.length_;\n start = start < 0 ? max(len + start, 0) : min(start, len);\n deleteCount = max(min(deleteCount, len - start), 0);\n var result = changetype>(__newArray(deleteCount, alignof(), idof>()));\n var resultStart = result.dataStart;\n var thisStart = this.dataStart;\n var thisBase = thisStart + (start << alignof());\n memory.copy(\n resultStart,\n thisBase,\n deleteCount << alignof()\n );\n var offset = start + deleteCount;\n if (len != offset) {\n memory.copy(\n thisBase,\n thisStart + (offset << alignof()),\n (len - offset) << alignof()\n );\n }\n this.length_ = len - deleteCount;\n return result;\n }\n\n reverse(): Array {\n REVERSE(this.dataStart, this.length_);\n return this;\n }\n\n sort(comparator: (a: T, b: T) => i32 = COMPARATOR()): Array {\n SORT(this.dataStart, this.length_, comparator);\n return this;\n }\n\n join(separator: string = \",\"): string {\n var ptr = this.dataStart;\n var len = this.length_;\n if (isBoolean()) return joinBooleanArray(ptr, len, separator);\n if (isInteger()) return joinIntegerArray(ptr, len, separator);\n if (isFloat()) return joinFloatArray(ptr, len, separator);\n\n if (ASC_SHRINK_LEVEL < 1) {\n if (isString()) return joinStringArray(ptr, len, separator);\n }\n // For rest objects and arrays use general join routine\n if (isReference()) return joinReferenceArray(ptr, len, separator);\n ERROR(\"unspported element type\");\n return unreachable();\n }\n\n flat(): T {\n if (!isArray()) {\n ERROR(\"Cannot call flat() on Array where T is not an Array.\");\n }\n // Get the length and data start values\n var ptr = this.dataStart;\n var len = this.length_;\n\n // calculate the end size with an initial pass\n var size = 0;\n for (let i = 0; i < len; ++i) {\n let child = load(ptr + (i << alignof()));\n size += child == 0 ? 0 : load(child, offsetof(\"length_\"));\n }\n\n // calculate the byteLength of the resulting backing ArrayBuffer\n const align = alignof>();\n var byteLength = size << align;\n var outBuffer = changetype(__new(byteLength, idof()));\n\n // create the return value and initialize it\n var outArray = changetype(__new(offsetof(), idof()));\n store(changetype(outArray), size, offsetof(\"length_\"));\n\n // byteLength, dataStart, and buffer are all readonly\n store(changetype(outArray), byteLength, offsetof(\"byteLength\"));\n store(changetype(outArray), changetype(outBuffer), offsetof(\"dataStart\"));\n store(changetype(outArray), changetype(outBuffer), offsetof(\"buffer\"));\n __link(changetype(outArray), changetype(outBuffer), false);\n\n // set the elements\n var resultOffset: usize = 0;\n for (let i = 0; i < len; ++i) { // for each child\n let child = load(ptr + (i << alignof()));\n\n // ignore null arrays\n if (!child) continue;\n\n // copy the underlying buffer data to the result buffer\n let childDataLength = load(child, offsetof(\"length_\")) << align;\n memory.copy(\n changetype(outBuffer) + resultOffset,\n load(child, offsetof(\"dataStart\")),\n childDataLength\n );\n\n // advance the result length\n resultOffset += childDataLength;\n }\n\n // if the `valueof` type is managed, we must link each reference\n if (isManaged>()) {\n for (let i = 0; i < size; ++i) {\n let ref = load(changetype(outBuffer) + (i << usize(alignof>())));\n __link(changetype(outBuffer), ref, true);\n }\n }\n\n return outArray;\n }\n\n toString(): string {\n return this.join();\n }\n\n // RT integration\n\n @unsafe private __visit(cookie: u32): void {\n if (isManaged()) {\n let cur = this.dataStart;\n let end = cur + (this.length_ << alignof());\n while (cur < end) {\n let val = load(cur);\n if (val) __visit(val, cookie);\n cur += sizeof();\n }\n }\n __visit(changetype(this.buffer), cookie);\n }\n}\n","// Common error messages for use across the standard library. Keeping error messages compact\n// and reusing them where possible ensures minimal static data in binaries.\n\n// @ts-ignore: decorator\n@lazy @inline\nexport const E_INDEXOUTOFRANGE: string = \"Index out of range\";\n\n// @ts-ignore: decorator\n@lazy @inline\nexport const E_VALUEOUTOFRANGE: string = \"Value out of range\";\n\n// @ts-ignore: decorator\n@lazy @inline\nexport const E_INVALIDLENGTH: string = \"Invalid length\";\n\n// @ts-ignore: decorator\n@lazy @inline\nexport const E_EMPTYARRAY: string = \"Array is empty\";\n\n// @ts-ignore: decorator\n@lazy @inline\nexport const E_HOLEYARRAY: string = \"Element type must be nullable if array is holey\";\n\n// @ts-ignore: decorator\n@lazy @inline\nexport const E_NOTIMPLEMENTED: string = \"Not implemented\";\n\n// @ts-ignore: decorator\n@lazy @inline\nexport const E_KEYNOTFOUND: string = \"Key does not exist\";\n\n// @ts-ignore: decorator\n@lazy @inline\nexport const E_ALLOCATION_TOO_LARGE: string = \"Allocation too large\";\n\n// @ts-ignore: decorator\n@lazy @inline\nexport const E_ALREADY_PINNED: string = \"Object already pinned\";\n\n// @ts-ignore: decorator\n@lazy @inline\nexport const E_NOT_PINNED: string = \"Object is not pinned\";\n\n// @ts-ignore: decorator\n@lazy @inline\nexport const E_URI_MALFORMED: string = \"URI malformed\";\n\n// @ts-ignore: decorator\n@lazy @inline\nexport const E_INVALIDDATE: string = \"Invalid Date\";\n\n// @ts-ignore: decorator\n@lazy @inline\nexport const E_UNPAIRED_SURROGATE: string = \"Unpaired surrogate\";\n"]} \ No newline at end of file diff --git a/packages/noise/build/release.wat b/packages/noise/build/release.wat index 9063ae742b..b5e4b15e78 100644 --- a/packages/noise/build/release.wat +++ b/packages/noise/build/release.wat @@ -7,7 +7,7 @@ (global $~lib/memory/__stack_pointer (mut i32) (i32.const 19660)) (memory $0 1) (data (i32.const 1036) "\1c\08") - (data (i32.const 1053) "\08\00\00\97\00\00\00\a0\00\00\00\89\00\00\00[\00\00\00Z\00\00\00\0f\00\00\00\83\00\00\00\0d\00\00\00\c9\00\00\00_\00\00\00`\00\00\005\00\00\00\c2\00\00\00\e9\00\00\00\07\00\00\00\e1\00\00\00\8c\00\00\00$\00\00\00g\00\00\00\1e\00\00\00E\00\00\00\8e\00\00\00\08\00\00\00c\00\00\00%\00\00\00\f0\00\00\00\15\00\00\00\n\00\00\00\17\00\00\00\be\00\00\00\06\00\00\00\94\00\00\00\f7\00\00\00x\00\00\00\ea\00\00\00K\00\00\00\00\00\00\00\1a\00\00\00\c5\00\00\00>\00\00\00^\00\00\00\fc\00\00\00\db\00\00\00\cb\00\00\00u\00\00\00#\00\00\00\0b\00\00\00 \00\00\009\00\00\00\b1\00\00\00!\00\00\00X\00\00\00\ed\00\00\00\95\00\00\008\00\00\00W\00\00\00\ae\00\00\00\14\00\00\00}\00\00\00\88\00\00\00\ab\00\00\00\a8\00\00\00D\00\00\00\af\00\00\00J\00\00\00\a5\00\00\00G\00\00\00\86\00\00\00\8b\00\00\000\00\00\00\1b\00\00\00\a6\00\00\00M\00\00\00\92\00\00\00\9e\00\00\00\e7\00\00\00S\00\00\00o\00\00\00\e5\00\00\00z\00\00\00<\00\00\00\d3\00\00\00\85\00\00\00\e6\00\00\00\dc\00\00\00i\00\00\00\\\00\00\00)\00\00\007\00\00\00.\00\00\00\f5\00\00\00(\00\00\00\f4\00\00\00f\00\00\00\8f\00\00\006\00\00\00A\00\00\00\19\00\00\00?\00\00\00\a1\00\00\00\01\00\00\00\d8\00\00\00P\00\00\00I\00\00\00\d1\00\00\00L\00\00\00\84\00\00\00\bb\00\00\00\d0\00\00\00Y\00\00\00\12\00\00\00\a9\00\00\00\c8\00\00\00\c4\00\00\00\87\00\00\00\82\00\00\00t\00\00\00\bc\00\00\00\9f\00\00\00V\00\00\00\a4\00\00\00d\00\00\00m\00\00\00\c6\00\00\00\ad\00\00\00\ba\00\00\00\03\00\00\00@\00\00\004\00\00\00\d9\00\00\00\e2\00\00\00\fa\00\00\00|\00\00\00{\00\00\00\05\00\00\00\ca\00\00\00&\00\00\00\93\00\00\00v\00\00\00~\00\00\00\ff\00\00\00R\00\00\00U\00\00\00\d4\00\00\00\cf\00\00\00\ce\00\00\00;\00\00\00\e3\00\00\00/\00\00\00\10\00\00\00:\00\00\00\11\00\00\00\b6\00\00\00\bd\00\00\00\1c\00\00\00*\00\00\00\df\00\00\00\b7\00\00\00\aa\00\00\00\d5\00\00\00w\00\00\00\f8\00\00\00\98\00\00\00\02\00\00\00,\00\00\00\9a\00\00\00\a3\00\00\00F\00\00\00\dd\00\00\00\99\00\00\00e\00\00\00\9b\00\00\00\a7\00\00\00+\00\00\00\ac\00\00\00\t\00\00\00\81\00\00\00\16\00\00\00\'\00\00\00\fd\00\00\00\13\00\00\00b\00\00\00l\00\00\00n\00\00\00O\00\00\00q\00\00\00\e0\00\00\00\e8\00\00\00\b2\00\00\00\b9\00\00\00p\00\00\00h\00\00\00\da\00\00\00\f6\00\00\00a\00\00\00\e4\00\00\00\fb\00\00\00\"\00\00\00\f2\00\00\00\c1\00\00\00\ee\00\00\00\d2\00\00\00\90\00\00\00\0c\00\00\00\bf\00\00\00\b3\00\00\00\a2\00\00\00\f1\00\00\00Q\00\00\003\00\00\00\91\00\00\00\eb\00\00\00\f9\00\00\00\0e\00\00\00\ef\00\00\00k\00\00\001\00\00\00\c0\00\00\00\d6\00\00\00\1f\00\00\00\b5\00\00\00\c7\00\00\00j\00\00\00\9d\00\00\00\b8\00\00\00T\00\00\00\cc\00\00\00\b0\00\00\00s\00\00\00y\00\00\002\00\00\00-\00\00\00\7f\00\00\00\04\00\00\00\96\00\00\00\fe\00\00\00\8a\00\00\00\ec\00\00\00\cd\00\00\00]\00\00\00\de\00\00\00r\00\00\00C\00\00\00\1d\00\00\00\18\00\00\00H\00\00\00\f3\00\00\00\8d\00\00\00\80\00\00\00\c3\00\00\00N\00\00\00B\00\00\00\d7\00\00\00=\00\00\00\9c\00\00\00\b4\00\00\00\97\00\00\00\a0\00\00\00\89\00\00\00[\00\00\00Z\00\00\00\0f\00\00\00\83\00\00\00\0d\00\00\00\c9\00\00\00_\00\00\00`\00\00\005\00\00\00\c2\00\00\00\e9\00\00\00\07\00\00\00\e1\00\00\00\8c\00\00\00$\00\00\00g\00\00\00\1e\00\00\00E\00\00\00\8e\00\00\00\08\00\00\00c\00\00\00%\00\00\00\f0\00\00\00\15\00\00\00\n\00\00\00\17\00\00\00\be\00\00\00\06\00\00\00\94\00\00\00\f7\00\00\00x\00\00\00\ea\00\00\00K\00\00\00\00\00\00\00\1a\00\00\00\c5\00\00\00>\00\00\00^\00\00\00\fc\00\00\00\db\00\00\00\cb\00\00\00u\00\00\00#\00\00\00\0b\00\00\00 \00\00\009\00\00\00\b1\00\00\00!\00\00\00X\00\00\00\ed\00\00\00\95\00\00\008\00\00\00W\00\00\00\ae\00\00\00\14\00\00\00}\00\00\00\88\00\00\00\ab\00\00\00\a8\00\00\00D\00\00\00\af\00\00\00J\00\00\00\a5\00\00\00G\00\00\00\86\00\00\00\8b\00\00\000\00\00\00\1b\00\00\00\a6\00\00\00M\00\00\00\92\00\00\00\9e\00\00\00\e7\00\00\00S\00\00\00o\00\00\00\e5\00\00\00z\00\00\00<\00\00\00\d3\00\00\00\85\00\00\00\e6\00\00\00\dc\00\00\00i\00\00\00\\\00\00\00)\00\00\007\00\00\00.\00\00\00\f5\00\00\00(\00\00\00\f4\00\00\00f\00\00\00\8f\00\00\006\00\00\00A\00\00\00\19\00\00\00?\00\00\00\a1\00\00\00\01\00\00\00\d8\00\00\00P\00\00\00I\00\00\00\d1\00\00\00L\00\00\00\84\00\00\00\bb\00\00\00\d0\00\00\00Y\00\00\00\12\00\00\00\a9\00\00\00\c8\00\00\00\c4\00\00\00\87\00\00\00\82\00\00\00t\00\00\00\bc\00\00\00\9f\00\00\00V\00\00\00\a4\00\00\00d\00\00\00m\00\00\00\c6\00\00\00\ad\00\00\00\ba\00\00\00\03\00\00\00@\00\00\004\00\00\00\d9\00\00\00\e2\00\00\00\fa\00\00\00|\00\00\00{\00\00\00\05\00\00\00\ca\00\00\00&\00\00\00\93\00\00\00v\00\00\00~\00\00\00\ff\00\00\00R\00\00\00U\00\00\00\d4\00\00\00\cf\00\00\00\ce\00\00\00;\00\00\00\e3\00\00\00/\00\00\00\10\00\00\00:\00\00\00\11\00\00\00\b6\00\00\00\bd\00\00\00\1c\00\00\00*\00\00\00\df\00\00\00\b7\00\00\00\aa\00\00\00\d5\00\00\00w\00\00\00\f8\00\00\00\98\00\00\00\02\00\00\00,\00\00\00\9a\00\00\00\a3\00\00\00F\00\00\00\dd\00\00\00\99\00\00\00e\00\00\00\9b\00\00\00\a7\00\00\00+\00\00\00\ac\00\00\00\t\00\00\00\81\00\00\00\16\00\00\00\'\00\00\00\fd\00\00\00\13\00\00\00b\00\00\00l\00\00\00n\00\00\00O\00\00\00q\00\00\00\e0\00\00\00\e8\00\00\00\b2\00\00\00\b9\00\00\00p\00\00\00h\00\00\00\da\00\00\00\f6\00\00\00a\00\00\00\e4\00\00\00\fb\00\00\00\"\00\00\00\f2\00\00\00\c1\00\00\00\ee\00\00\00\d2\00\00\00\90\00\00\00\0c\00\00\00\bf\00\00\00\b3\00\00\00\a2\00\00\00\f1\00\00\00Q\00\00\003\00\00\00\91\00\00\00\eb\00\00\00\f9\00\00\00\0e\00\00\00\ef\00\00\00k\00\00\001\00\00\00\c0\00\00\00\d6\00\00\00\1f\00\00\00\b5\00\00\00\c7\00\00\00j\00\00\00\9d\00\00\00\b8\00\00\00T\00\00\00\cc\00\00\00\b0\00\00\00s\00\00\00y\00\00\002\00\00\00-\00\00\00\7f\00\00\00\04\00\00\00\96\00\00\00\fe\00\00\00\8a\00\00\00\ec\00\00\00\cd\00\00\00]\00\00\00\de\00\00\00r\00\00\00C\00\00\00\1d\00\00\00\18\00\00\00H\00\00\00\f3\00\00\00\8d\00\00\00\80\00\00\00\c3\00\00\00N\00\00\00B\00\00\00\d7\00\00\00=\00\00\00\9c\00\00\00\b4") + (data (i32.const 1053) "\08\00\00\97\00\00\00\a0\00\00\00\89\00\00\00[\00\00\00Z\00\00\00\0f\00\00\00\83\00\00\00\r\00\00\00\c9\00\00\00_\00\00\00`\00\00\005\00\00\00\c2\00\00\00\e9\00\00\00\07\00\00\00\e1\00\00\00\8c\00\00\00$\00\00\00g\00\00\00\1e\00\00\00E\00\00\00\8e\00\00\00\08\00\00\00c\00\00\00%\00\00\00\f0\00\00\00\15\00\00\00\n\00\00\00\17\00\00\00\be\00\00\00\06\00\00\00\94\00\00\00\f7\00\00\00x\00\00\00\ea\00\00\00K\00\00\00\00\00\00\00\1a\00\00\00\c5\00\00\00>\00\00\00^\00\00\00\fc\00\00\00\db\00\00\00\cb\00\00\00u\00\00\00#\00\00\00\0b\00\00\00 \00\00\009\00\00\00\b1\00\00\00!\00\00\00X\00\00\00\ed\00\00\00\95\00\00\008\00\00\00W\00\00\00\ae\00\00\00\14\00\00\00}\00\00\00\88\00\00\00\ab\00\00\00\a8\00\00\00D\00\00\00\af\00\00\00J\00\00\00\a5\00\00\00G\00\00\00\86\00\00\00\8b\00\00\000\00\00\00\1b\00\00\00\a6\00\00\00M\00\00\00\92\00\00\00\9e\00\00\00\e7\00\00\00S\00\00\00o\00\00\00\e5\00\00\00z\00\00\00<\00\00\00\d3\00\00\00\85\00\00\00\e6\00\00\00\dc\00\00\00i\00\00\00\\\00\00\00)\00\00\007\00\00\00.\00\00\00\f5\00\00\00(\00\00\00\f4\00\00\00f\00\00\00\8f\00\00\006\00\00\00A\00\00\00\19\00\00\00?\00\00\00\a1\00\00\00\01\00\00\00\d8\00\00\00P\00\00\00I\00\00\00\d1\00\00\00L\00\00\00\84\00\00\00\bb\00\00\00\d0\00\00\00Y\00\00\00\12\00\00\00\a9\00\00\00\c8\00\00\00\c4\00\00\00\87\00\00\00\82\00\00\00t\00\00\00\bc\00\00\00\9f\00\00\00V\00\00\00\a4\00\00\00d\00\00\00m\00\00\00\c6\00\00\00\ad\00\00\00\ba\00\00\00\03\00\00\00@\00\00\004\00\00\00\d9\00\00\00\e2\00\00\00\fa\00\00\00|\00\00\00{\00\00\00\05\00\00\00\ca\00\00\00&\00\00\00\93\00\00\00v\00\00\00~\00\00\00\ff\00\00\00R\00\00\00U\00\00\00\d4\00\00\00\cf\00\00\00\ce\00\00\00;\00\00\00\e3\00\00\00/\00\00\00\10\00\00\00:\00\00\00\11\00\00\00\b6\00\00\00\bd\00\00\00\1c\00\00\00*\00\00\00\df\00\00\00\b7\00\00\00\aa\00\00\00\d5\00\00\00w\00\00\00\f8\00\00\00\98\00\00\00\02\00\00\00,\00\00\00\9a\00\00\00\a3\00\00\00F\00\00\00\dd\00\00\00\99\00\00\00e\00\00\00\9b\00\00\00\a7\00\00\00+\00\00\00\ac\00\00\00\t\00\00\00\81\00\00\00\16\00\00\00\'\00\00\00\fd\00\00\00\13\00\00\00b\00\00\00l\00\00\00n\00\00\00O\00\00\00q\00\00\00\e0\00\00\00\e8\00\00\00\b2\00\00\00\b9\00\00\00p\00\00\00h\00\00\00\da\00\00\00\f6\00\00\00a\00\00\00\e4\00\00\00\fb\00\00\00\"\00\00\00\f2\00\00\00\c1\00\00\00\ee\00\00\00\d2\00\00\00\90\00\00\00\0c\00\00\00\bf\00\00\00\b3\00\00\00\a2\00\00\00\f1\00\00\00Q\00\00\003\00\00\00\91\00\00\00\eb\00\00\00\f9\00\00\00\0e\00\00\00\ef\00\00\00k\00\00\001\00\00\00\c0\00\00\00\d6\00\00\00\1f\00\00\00\b5\00\00\00\c7\00\00\00j\00\00\00\9d\00\00\00\b8\00\00\00T\00\00\00\cc\00\00\00\b0\00\00\00s\00\00\00y\00\00\002\00\00\00-\00\00\00\7f\00\00\00\04\00\00\00\96\00\00\00\fe\00\00\00\8a\00\00\00\ec\00\00\00\cd\00\00\00]\00\00\00\de\00\00\00r\00\00\00C\00\00\00\1d\00\00\00\18\00\00\00H\00\00\00\f3\00\00\00\8d\00\00\00\80\00\00\00\c3\00\00\00N\00\00\00B\00\00\00\d7\00\00\00=\00\00\00\9c\00\00\00\b4\00\00\00\97\00\00\00\a0\00\00\00\89\00\00\00[\00\00\00Z\00\00\00\0f\00\00\00\83\00\00\00\r\00\00\00\c9\00\00\00_\00\00\00`\00\00\005\00\00\00\c2\00\00\00\e9\00\00\00\07\00\00\00\e1\00\00\00\8c\00\00\00$\00\00\00g\00\00\00\1e\00\00\00E\00\00\00\8e\00\00\00\08\00\00\00c\00\00\00%\00\00\00\f0\00\00\00\15\00\00\00\n\00\00\00\17\00\00\00\be\00\00\00\06\00\00\00\94\00\00\00\f7\00\00\00x\00\00\00\ea\00\00\00K\00\00\00\00\00\00\00\1a\00\00\00\c5\00\00\00>\00\00\00^\00\00\00\fc\00\00\00\db\00\00\00\cb\00\00\00u\00\00\00#\00\00\00\0b\00\00\00 \00\00\009\00\00\00\b1\00\00\00!\00\00\00X\00\00\00\ed\00\00\00\95\00\00\008\00\00\00W\00\00\00\ae\00\00\00\14\00\00\00}\00\00\00\88\00\00\00\ab\00\00\00\a8\00\00\00D\00\00\00\af\00\00\00J\00\00\00\a5\00\00\00G\00\00\00\86\00\00\00\8b\00\00\000\00\00\00\1b\00\00\00\a6\00\00\00M\00\00\00\92\00\00\00\9e\00\00\00\e7\00\00\00S\00\00\00o\00\00\00\e5\00\00\00z\00\00\00<\00\00\00\d3\00\00\00\85\00\00\00\e6\00\00\00\dc\00\00\00i\00\00\00\\\00\00\00)\00\00\007\00\00\00.\00\00\00\f5\00\00\00(\00\00\00\f4\00\00\00f\00\00\00\8f\00\00\006\00\00\00A\00\00\00\19\00\00\00?\00\00\00\a1\00\00\00\01\00\00\00\d8\00\00\00P\00\00\00I\00\00\00\d1\00\00\00L\00\00\00\84\00\00\00\bb\00\00\00\d0\00\00\00Y\00\00\00\12\00\00\00\a9\00\00\00\c8\00\00\00\c4\00\00\00\87\00\00\00\82\00\00\00t\00\00\00\bc\00\00\00\9f\00\00\00V\00\00\00\a4\00\00\00d\00\00\00m\00\00\00\c6\00\00\00\ad\00\00\00\ba\00\00\00\03\00\00\00@\00\00\004\00\00\00\d9\00\00\00\e2\00\00\00\fa\00\00\00|\00\00\00{\00\00\00\05\00\00\00\ca\00\00\00&\00\00\00\93\00\00\00v\00\00\00~\00\00\00\ff\00\00\00R\00\00\00U\00\00\00\d4\00\00\00\cf\00\00\00\ce\00\00\00;\00\00\00\e3\00\00\00/\00\00\00\10\00\00\00:\00\00\00\11\00\00\00\b6\00\00\00\bd\00\00\00\1c\00\00\00*\00\00\00\df\00\00\00\b7\00\00\00\aa\00\00\00\d5\00\00\00w\00\00\00\f8\00\00\00\98\00\00\00\02\00\00\00,\00\00\00\9a\00\00\00\a3\00\00\00F\00\00\00\dd\00\00\00\99\00\00\00e\00\00\00\9b\00\00\00\a7\00\00\00+\00\00\00\ac\00\00\00\t\00\00\00\81\00\00\00\16\00\00\00\'\00\00\00\fd\00\00\00\13\00\00\00b\00\00\00l\00\00\00n\00\00\00O\00\00\00q\00\00\00\e0\00\00\00\e8\00\00\00\b2\00\00\00\b9\00\00\00p\00\00\00h\00\00\00\da\00\00\00\f6\00\00\00a\00\00\00\e4\00\00\00\fb\00\00\00\"\00\00\00\f2\00\00\00\c1\00\00\00\ee\00\00\00\d2\00\00\00\90\00\00\00\0c\00\00\00\bf\00\00\00\b3\00\00\00\a2\00\00\00\f1\00\00\00Q\00\00\003\00\00\00\91\00\00\00\eb\00\00\00\f9\00\00\00\0e\00\00\00\ef\00\00\00k\00\00\001\00\00\00\c0\00\00\00\d6\00\00\00\1f\00\00\00\b5\00\00\00\c7\00\00\00j\00\00\00\9d\00\00\00\b8\00\00\00T\00\00\00\cc\00\00\00\b0\00\00\00s\00\00\00y\00\00\002\00\00\00-\00\00\00\7f\00\00\00\04\00\00\00\96\00\00\00\fe\00\00\00\8a\00\00\00\ec\00\00\00\cd\00\00\00]\00\00\00\de\00\00\00r\00\00\00C\00\00\00\1d\00\00\00\18\00\00\00H\00\00\00\f3\00\00\00\8d\00\00\00\80\00\00\00\c3\00\00\00N\00\00\00B\00\00\00\d7\00\00\00=\00\00\00\9c\00\00\00\b4") (data (i32.const 3116) ",") (data (i32.const 3128) "\03\00\00\00\10\00\00\00 \04\00\00 \04\00\00\00\08\00\00\00\02") (data (i32.const 3164) "<") @@ -65,10 +65,9 @@ f64.add return end - local.get $1 - f64.neg local.get $2 - f64.add + local.get $1 + f64.sub return end local.get $1 @@ -87,10 +86,9 @@ f64.add return end - local.get $1 - f64.neg local.get $3 - f64.add + local.get $1 + f64.sub return end local.get $1 @@ -109,10 +107,9 @@ f64.add return end - local.get $2 - f64.neg local.get $3 - f64.add + local.get $2 + f64.sub return end local.get $2 @@ -131,10 +128,9 @@ f64.add return end - local.get $2 - f64.neg local.get $3 - f64.add + local.get $2 + f64.sub return end local.get $2 @@ -299,8 +295,8 @@ local.get $11 f64.const 6 f64.mul - f64.const 15 - f64.sub + f64.const -15 + f64.add f64.mul f64.const 10 f64.add @@ -309,8 +305,8 @@ local.get $1 call $~lib/array/Array#__get local.get $11 - f64.const 1 - f64.sub + f64.const -1 + f64.add local.tee $4 local.get $8 local.get $9 @@ -327,8 +323,8 @@ call $~lib/array/Array#__get local.get $11 local.get $8 - f64.const 1 - f64.sub + f64.const -1 + f64.add local.tee $5 local.get $9 call $assembly/perlin/grad @@ -346,8 +342,8 @@ local.get $8 f64.const 6 f64.mul - f64.const 15 - f64.sub + f64.const -15 + f64.add f64.mul f64.const 10 f64.add @@ -380,8 +376,8 @@ local.get $11 local.get $8 local.get $9 - f64.const 1 - f64.sub + f64.const -1 + f64.add local.tee $6 call $assembly/perlin/grad local.set $14 @@ -428,8 +424,8 @@ local.get $9 f64.const 6 f64.mul - f64.const 15 - f64.sub + f64.const -15 + f64.add f64.mul f64.const 10 f64.add diff --git a/packages/noise/package.json b/packages/noise/package.json index d09d623a97..da10af978c 100644 --- a/packages/noise/package.json +++ b/packages/noise/package.json @@ -2,7 +2,6 @@ "name": "@latticexyz/noise", "version": "2.0.0-next.17", "license": "MIT", - "type": "module", "exports": { ".": "./dist/index.js" }, diff --git a/packages/noise/tsup.config.ts b/packages/noise/tsup.config.ts index 5837375692..59f79395cc 100644 --- a/packages/noise/tsup.config.ts +++ b/packages/noise/tsup.config.ts @@ -3,7 +3,7 @@ import { defineConfig } from "tsup"; export default defineConfig({ entry: ["ts/index.ts"], target: "esnext", - format: ["esm"], + format: ["esm", "cjs"], dts: true, sourcemap: true, clean: true, diff --git a/packages/phaserx/package.json b/packages/phaserx/package.json index 8aac974e54..ee2e52ed84 100644 --- a/packages/phaserx/package.json +++ b/packages/phaserx/package.json @@ -7,7 +7,6 @@ "directory": "packages/phaserx" }, "license": "MIT", - "type": "module", "exports": { ".": "./dist/index.js" }, diff --git a/packages/phaserx/tsup.config.ts b/packages/phaserx/tsup.config.ts index 52bdfceee6..d139373ac6 100644 --- a/packages/phaserx/tsup.config.ts +++ b/packages/phaserx/tsup.config.ts @@ -3,7 +3,7 @@ import { defineConfig } from "tsup"; export default defineConfig({ entry: ["src/index.ts"], target: "esnext", - format: ["esm"], + format: ["esm", "cjs"], dts: true, sourcemap: true, clean: true, diff --git a/packages/protocol-parser/package.json b/packages/protocol-parser/package.json index 08ca13b9d8..83f9bc8924 100644 --- a/packages/protocol-parser/package.json +++ b/packages/protocol-parser/package.json @@ -8,7 +8,6 @@ "directory": "packages/protocol-parser" }, "license": "MIT", - "type": "module", "exports": { ".": "./dist/index.js" }, diff --git a/packages/protocol-parser/tsup.config.ts b/packages/protocol-parser/tsup.config.ts index 52bdfceee6..d139373ac6 100644 --- a/packages/protocol-parser/tsup.config.ts +++ b/packages/protocol-parser/tsup.config.ts @@ -3,7 +3,7 @@ import { defineConfig } from "tsup"; export default defineConfig({ entry: ["src/index.ts"], target: "esnext", - format: ["esm"], + format: ["esm", "cjs"], dts: true, sourcemap: true, clean: true, diff --git a/packages/react/package.json b/packages/react/package.json index c9f2be5006..366b83d44e 100644 --- a/packages/react/package.json +++ b/packages/react/package.json @@ -8,7 +8,6 @@ "directory": "packages/react" }, "license": "MIT", - "type": "module", "exports": { ".": "./dist/index.js" }, diff --git a/packages/react/tsup.config.ts b/packages/react/tsup.config.ts index 52bdfceee6..d139373ac6 100644 --- a/packages/react/tsup.config.ts +++ b/packages/react/tsup.config.ts @@ -3,7 +3,7 @@ import { defineConfig } from "tsup"; export default defineConfig({ entry: ["src/index.ts"], target: "esnext", - format: ["esm"], + format: ["esm", "cjs"], dts: true, sourcemap: true, clean: true, diff --git a/packages/recs/package.json b/packages/recs/package.json index 16d7c1b8b6..ffd2b0dd0e 100644 --- a/packages/recs/package.json +++ b/packages/recs/package.json @@ -7,7 +7,6 @@ "directory": "packages/recs" }, "license": "MIT", - "type": "module", "exports": { ".": "./dist/index.js", "./deprecated": "./dist/deprecated/index.js" diff --git a/packages/recs/tsup.config.ts b/packages/recs/tsup.config.ts index faf54cff78..5515d9d061 100644 --- a/packages/recs/tsup.config.ts +++ b/packages/recs/tsup.config.ts @@ -3,7 +3,7 @@ import { defineConfig } from "tsup"; export default defineConfig({ entry: ["src/index.ts", "src/deprecated/index.ts"], target: "esnext", - format: ["esm"], + format: ["esm", "cjs"], dts: true, sourcemap: true, clean: true, diff --git a/packages/schema-type/package.json b/packages/schema-type/package.json index caedfb79e0..d6fe50cd68 100644 --- a/packages/schema-type/package.json +++ b/packages/schema-type/package.json @@ -8,7 +8,6 @@ "directory": "packages/schema-type" }, "license": "MIT", - "type": "module", "exports": { ".": "./dist/typescript/index.js", "./deprecated": "./dist/typescript/deprecated/index.js" diff --git a/packages/schema-type/tsup.config.ts b/packages/schema-type/tsup.config.ts index 4ae11283a7..16f3d0ce8b 100644 --- a/packages/schema-type/tsup.config.ts +++ b/packages/schema-type/tsup.config.ts @@ -4,7 +4,7 @@ export default defineConfig({ entry: ["src/typescript/index.ts", "src/typescript/deprecated/index.ts"], outDir: "dist/typescript", target: "esnext", - format: ["esm"], + format: ["esm", "cjs"], dts: true, sourcemap: true, clean: true, diff --git a/packages/services/package.json b/packages/services/package.json index 96eccd36b8..11f3e77f85 100644 --- a/packages/services/package.json +++ b/packages/services/package.json @@ -8,7 +8,6 @@ "directory": "packages/services" }, "license": "MIT", - "type": "module", "exports": { "./faucet": "./dist/faucet.js" }, diff --git a/packages/services/tsup.config.ts b/packages/services/tsup.config.ts index ed5646e5d5..ebcdcc3ff8 100644 --- a/packages/services/tsup.config.ts +++ b/packages/services/tsup.config.ts @@ -5,7 +5,7 @@ export default defineConfig({ faucet: "ts/faucet/index.ts", }, target: "esnext", - format: ["esm"], + format: ["esm", "cjs"], dts: true, sourcemap: true, clean: true, diff --git a/packages/store-indexer/bin/postgres-decoded-indexer.ts b/packages/store-indexer/bin/postgres-decoded-indexer.ts index 6bad5ec347..7f434d9c55 100644 --- a/packages/store-indexer/bin/postgres-decoded-indexer.ts +++ b/packages/store-indexer/bin/postgres-decoded-indexer.ts @@ -14,101 +14,104 @@ import { sentry } from "../src/koa-middleware/sentry"; import { healthcheck } from "../src/koa-middleware/healthcheck"; import { helloWorld } from "../src/koa-middleware/helloWorld"; -const env = parseEnv( - z.intersection( - indexerEnvSchema, - z.object({ - DATABASE_URL: z.string(), - HEALTHCHECK_HOST: z.string().optional(), - HEALTHCHECK_PORT: z.coerce.number().optional(), - SENTRY_DSN: z.string().optional(), - }) - ) -); - -const transports: Transport[] = [ - // prefer WS when specified - env.RPC_WS_URL ? webSocket(env.RPC_WS_URL) : undefined, - // otherwise use or fallback to HTTP - env.RPC_HTTP_URL ? http(env.RPC_HTTP_URL) : undefined, -].filter(isDefined); - -const publicClient = createPublicClient({ - transport: fallback(transports), - pollingInterval: env.POLLING_INTERVAL, -}); - -const chainId = await publicClient.getChainId(); -const database = drizzle(postgres(env.DATABASE_URL, { prepare: false })); - -const { storageAdapter, tables } = await createStorageAdapter({ database, publicClient }); - -let startBlock = env.START_BLOCK; - -// Resume from latest block stored in DB. This will throw if the DB doesn't exist yet, so we wrap in a try/catch and ignore the error. -// TODO: query if the DB exists instead of try/catch -try { - const chainState = await database - .select() - .from(tables.configTable) - .where(eq(tables.configTable.chainId, chainId)) - .limit(1) - .execute() - // Get the first record in a way that returns a possible `undefined` - // TODO: move this to `.findFirst` after upgrading drizzle or `rows[0]` after enabling `noUncheckedIndexedAccess: true` - .then((rows) => rows.find(() => true)); - - if (chainState?.blockNumber != null) { - startBlock = chainState.blockNumber + 1n; - console.log("resuming from block number", startBlock); - } -} catch (error) { - // ignore errors for now -} - -const { latestBlockNumber$, storedBlockLogs$ } = await createStoreSync({ - storageAdapter, - publicClient, - startBlock, - maxBlockRange: env.MAX_BLOCK_RANGE, - address: env.STORE_ADDRESS, -}); - -storedBlockLogs$.subscribe(); - -let isCaughtUp = false; -combineLatest([latestBlockNumber$, storedBlockLogs$]) - .pipe( - filter( - ([latestBlockNumber, { blockNumber: lastBlockNumberProcessed }]) => latestBlockNumber === lastBlockNumberProcessed - ), - first() - ) - .subscribe(() => { - isCaughtUp = true; - console.log("all caught up"); - }); +(async (): Promise => { + const env = parseEnv( + z.intersection( + indexerEnvSchema, + z.object({ + DATABASE_URL: z.string(), + HEALTHCHECK_HOST: z.string().optional(), + HEALTHCHECK_PORT: z.coerce.number().optional(), + SENTRY_DSN: z.string().optional(), + }) + ) + ); -if (env.HEALTHCHECK_HOST != null || env.HEALTHCHECK_PORT != null) { - const { default: Koa } = await import("koa"); - const { default: cors } = await import("@koa/cors"); + const transports: Transport[] = [ + // prefer WS when specified + env.RPC_WS_URL ? webSocket(env.RPC_WS_URL) : undefined, + // otherwise use or fallback to HTTP + env.RPC_HTTP_URL ? http(env.RPC_HTTP_URL) : undefined, + ].filter(isDefined); - const server = new Koa(); + const publicClient = createPublicClient({ + transport: fallback(transports), + pollingInterval: env.POLLING_INTERVAL, + }); - if (env.SENTRY_DSN) { - server.use(sentry(env.SENTRY_DSN)); + const chainId = await publicClient.getChainId(); + const database = drizzle(postgres(env.DATABASE_URL, { prepare: false })); + + const { storageAdapter, tables } = await createStorageAdapter({ database, publicClient }); + + let startBlock = env.START_BLOCK; + + // Resume from latest block stored in DB. This will throw if the DB doesn't exist yet, so we wrap in a try/catch and ignore the error. + // TODO: query if the DB exists instead of try/catch + try { + const chainState = await database + .select() + .from(tables.configTable) + .where(eq(tables.configTable.chainId, chainId)) + .limit(1) + .execute() + // Get the first record in a way that returns a possible `undefined` + // TODO: move this to `.findFirst` after upgrading drizzle or `rows[0]` after enabling `noUncheckedIndexedAccess: true` + .then((rows) => rows.find(() => true)); + + if (chainState?.blockNumber != null) { + startBlock = chainState.blockNumber + 1n; + console.log("resuming from block number", startBlock); + } + } catch (error) { + // ignore errors for now } - server.use(cors()); - server.use( - healthcheck({ - isReady: () => isCaughtUp, - }) - ); - server.use(helloWorld()); + const { latestBlockNumber$, storedBlockLogs$ } = await createStoreSync({ + storageAdapter, + publicClient, + startBlock, + maxBlockRange: env.MAX_BLOCK_RANGE, + address: env.STORE_ADDRESS, + }); - server.listen({ host: env.HEALTHCHECK_HOST, port: env.HEALTHCHECK_PORT }); - console.log( - `postgres indexer healthcheck server listening on http://${env.HEALTHCHECK_HOST}:${env.HEALTHCHECK_PORT}` - ); -} + storedBlockLogs$.subscribe(); + + let isCaughtUp = false; + combineLatest([latestBlockNumber$, storedBlockLogs$]) + .pipe( + filter( + ([latestBlockNumber, { blockNumber: lastBlockNumberProcessed }]) => + latestBlockNumber === lastBlockNumberProcessed + ), + first() + ) + .subscribe(() => { + isCaughtUp = true; + console.log("all caught up"); + }); + + if (env.HEALTHCHECK_HOST != null || env.HEALTHCHECK_PORT != null) { + const { default: Koa } = await import("koa"); + const { default: cors } = await import("@koa/cors"); + + const server = new Koa(); + + if (env.SENTRY_DSN) { + server.use(sentry(env.SENTRY_DSN)); + } + + server.use(cors()); + server.use( + healthcheck({ + isReady: () => isCaughtUp, + }) + ); + server.use(helloWorld()); + + server.listen({ host: env.HEALTHCHECK_HOST, port: env.HEALTHCHECK_PORT }); + console.log( + `postgres indexer healthcheck server listening on http://${env.HEALTHCHECK_HOST}:${env.HEALTHCHECK_PORT}` + ); + } +})(); diff --git a/packages/store-indexer/bin/postgres-indexer.ts b/packages/store-indexer/bin/postgres-indexer.ts index 15cce32a1a..ecc461ce8e 100644 --- a/packages/store-indexer/bin/postgres-indexer.ts +++ b/packages/store-indexer/bin/postgres-indexer.ts @@ -11,103 +11,106 @@ import { cleanDatabase, createStorageAdapter, shouldCleanDatabase } from "@latti import { createStoreSync } from "@latticexyz/store-sync"; import { indexerEnvSchema, parseEnv } from "./parseEnv"; -const env = parseEnv( - z.intersection( - indexerEnvSchema, - z.object({ - DATABASE_URL: z.string(), - HEALTHCHECK_HOST: z.string().optional(), - HEALTHCHECK_PORT: z.coerce.number().optional(), - }) - ) -); - -const transports: Transport[] = [ - // prefer WS when specified - env.RPC_WS_URL ? webSocket(env.RPC_WS_URL) : undefined, - // otherwise use or fallback to HTTP - env.RPC_HTTP_URL ? http(env.RPC_HTTP_URL) : undefined, -].filter(isDefined); - -const publicClient = createPublicClient({ - transport: fallback(transports), - pollingInterval: env.POLLING_INTERVAL, -}); - -const chainId = await publicClient.getChainId(); -const database = drizzle(postgres(env.DATABASE_URL, { prepare: false })); - -if (await shouldCleanDatabase(database, chainId)) { - console.log("outdated database detected, clearing data to start fresh"); - await cleanDatabase(database); -} - -const { storageAdapter, tables } = await createStorageAdapter({ database, publicClient }); - -let startBlock = env.START_BLOCK; - -// Resume from latest block stored in DB. This will throw if the DB doesn't exist yet, so we wrap in a try/catch and ignore the error. -// TODO: query if the DB exists instead of try/catch -try { - const chainState = await database - .select() - .from(tables.configTable) - .where(eq(tables.configTable.chainId, chainId)) - .limit(1) - .execute() - // Get the first record in a way that returns a possible `undefined` - // TODO: move this to `.findFirst` after upgrading drizzle or `rows[0]` after enabling `noUncheckedIndexedAccess: true` - .then((rows) => rows.find(() => true)); - - if (chainState?.blockNumber != null) { - startBlock = chainState.blockNumber + 1n; - console.log("resuming from block number", startBlock); - } -} catch (error) { - // ignore errors for now -} - -const { latestBlockNumber$, storedBlockLogs$ } = await createStoreSync({ - storageAdapter, - publicClient, - startBlock, - maxBlockRange: env.MAX_BLOCK_RANGE, - address: env.STORE_ADDRESS, -}); - -storedBlockLogs$.subscribe(); - -let isCaughtUp = false; -combineLatest([latestBlockNumber$, storedBlockLogs$]) - .pipe( - filter( - ([latestBlockNumber, { blockNumber: lastBlockNumberProcessed }]) => latestBlockNumber === lastBlockNumberProcessed - ), - first() - ) - .subscribe(() => { - isCaughtUp = true; - console.log("all caught up"); +(async (): Promise => { + const env = parseEnv( + z.intersection( + indexerEnvSchema, + z.object({ + DATABASE_URL: z.string(), + HEALTHCHECK_HOST: z.string().optional(), + HEALTHCHECK_PORT: z.coerce.number().optional(), + }) + ) + ); + + const transports: Transport[] = [ + // prefer WS when specified + env.RPC_WS_URL ? webSocket(env.RPC_WS_URL) : undefined, + // otherwise use or fallback to HTTP + env.RPC_HTTP_URL ? http(env.RPC_HTTP_URL) : undefined, + ].filter(isDefined); + + const publicClient = createPublicClient({ + transport: fallback(transports), + pollingInterval: env.POLLING_INTERVAL, }); -if (env.HEALTHCHECK_HOST != null || env.HEALTHCHECK_PORT != null) { - const { default: Koa } = await import("koa"); - const { default: cors } = await import("@koa/cors"); - const { healthcheck } = await import("../src/koa-middleware/healthcheck"); - const { helloWorld } = await import("../src/koa-middleware/helloWorld"); + const chainId = await publicClient.getChainId(); + const database = drizzle(postgres(env.DATABASE_URL, { prepare: false })); - const server = new Koa(); + if (await shouldCleanDatabase(database, chainId)) { + console.log("outdated database detected, clearing data to start fresh"); + await cleanDatabase(database); + } - server.use(cors()); - server.use( - healthcheck({ - isReady: () => isCaughtUp, - }) - ); - server.use(helloWorld()); + const { storageAdapter, tables } = await createStorageAdapter({ database, publicClient }); + + let startBlock = env.START_BLOCK; + + // Resume from latest block stored in DB. This will throw if the DB doesn't exist yet, so we wrap in a try/catch and ignore the error. + // TODO: query if the DB exists instead of try/catch + try { + const chainState = await database + .select() + .from(tables.configTable) + .where(eq(tables.configTable.chainId, chainId)) + .limit(1) + .execute() + // Get the first record in a way that returns a possible `undefined` + // TODO: move this to `.findFirst` after upgrading drizzle or `rows[0]` after enabling `noUncheckedIndexedAccess: true` + .then((rows) => rows.find(() => true)); + + if (chainState?.blockNumber != null) { + startBlock = chainState.blockNumber + 1n; + console.log("resuming from block number", startBlock); + } + } catch (error) { + // ignore errors for now + } - server.listen({ host: env.HEALTHCHECK_HOST, port: env.HEALTHCHECK_PORT }); - console.log( - `postgres indexer healthcheck server listening on http://${env.HEALTHCHECK_HOST}:${env.HEALTHCHECK_PORT}` - ); -} + const { latestBlockNumber$, storedBlockLogs$ } = await createStoreSync({ + storageAdapter, + publicClient, + startBlock, + maxBlockRange: env.MAX_BLOCK_RANGE, + address: env.STORE_ADDRESS, + }); + + storedBlockLogs$.subscribe(); + + let isCaughtUp = false; + combineLatest([latestBlockNumber$, storedBlockLogs$]) + .pipe( + filter( + ([latestBlockNumber, { blockNumber: lastBlockNumberProcessed }]) => + latestBlockNumber === lastBlockNumberProcessed + ), + first() + ) + .subscribe(() => { + isCaughtUp = true; + console.log("all caught up"); + }); + + if (env.HEALTHCHECK_HOST != null || env.HEALTHCHECK_PORT != null) { + const { default: Koa } = await import("koa"); + const { default: cors } = await import("@koa/cors"); + const { healthcheck } = await import("../src/koa-middleware/healthcheck"); + const { helloWorld } = await import("../src/koa-middleware/helloWorld"); + + const server = new Koa(); + + server.use(cors()); + server.use( + healthcheck({ + isReady: () => isCaughtUp, + }) + ); + server.use(helloWorld()); + + server.listen({ host: env.HEALTHCHECK_HOST, port: env.HEALTHCHECK_PORT }); + console.log( + `postgres indexer healthcheck server listening on http://${env.HEALTHCHECK_HOST}:${env.HEALTHCHECK_PORT}` + ); + } +})(); diff --git a/packages/store-indexer/bin/sqlite-indexer.ts b/packages/store-indexer/bin/sqlite-indexer.ts index bfea5260bb..f399966888 100644 --- a/packages/store-indexer/bin/sqlite-indexer.ts +++ b/packages/store-indexer/bin/sqlite-indexer.ts @@ -20,103 +20,106 @@ import { helloWorld } from "../src/koa-middleware/helloWorld"; import { apiRoutes } from "../src/sqlite/apiRoutes"; import { sentry } from "../src/koa-middleware/sentry"; -const env = parseEnv( - z.intersection( - z.intersection(indexerEnvSchema, frontendEnvSchema), - z.object({ - SQLITE_FILENAME: z.string().default("indexer.db"), - SENTRY_DSN: z.string().optional(), - }) - ) -); +(async (): Promise => { + const env = parseEnv( + z.intersection( + z.intersection(indexerEnvSchema, frontendEnvSchema), + z.object({ + SQLITE_FILENAME: z.string().default("indexer.db"), + SENTRY_DSN: z.string().optional(), + }) + ) + ); -const transports: Transport[] = [ - // prefer WS when specified - env.RPC_WS_URL ? webSocket(env.RPC_WS_URL) : undefined, - // otherwise use or fallback to HTTP - env.RPC_HTTP_URL ? http(env.RPC_HTTP_URL) : undefined, -].filter(isDefined); + const transports: Transport[] = [ + // prefer WS when specified + env.RPC_WS_URL ? webSocket(env.RPC_WS_URL) : undefined, + // otherwise use or fallback to HTTP + env.RPC_HTTP_URL ? http(env.RPC_HTTP_URL) : undefined, + ].filter(isDefined); -const publicClient = createPublicClient({ - transport: fallback(transports), - pollingInterval: env.POLLING_INTERVAL, -}); + const publicClient = createPublicClient({ + transport: fallback(transports), + pollingInterval: env.POLLING_INTERVAL, + }); -const chainId = await publicClient.getChainId(); -const database = drizzle(new Database(env.SQLITE_FILENAME)); + const chainId = await publicClient.getChainId(); + const database = drizzle(new Database(env.SQLITE_FILENAME)); -let startBlock = env.START_BLOCK; + let startBlock = env.START_BLOCK; -// Resume from latest block stored in DB. This will throw if the DB doesn't exist yet, so we wrap in a try/catch and ignore the error. -try { - const currentChainStates = database.select().from(chainState).where(eq(chainState.chainId, chainId)).all(); - // TODO: replace this type workaround with `noUncheckedIndexedAccess: true` when we can fix all the issues related (https://github.com/latticexyz/mud/issues/1212) - const currentChainState: (typeof currentChainStates)[number] | undefined = currentChainStates[0]; + // Resume from latest block stored in DB. This will throw if the DB doesn't exist yet, so we wrap in a try/catch and ignore the error. + try { + const currentChainStates = database.select().from(chainState).where(eq(chainState.chainId, chainId)).all(); + // TODO: replace this type workaround with `noUncheckedIndexedAccess: true` when we can fix all the issues related (https://github.com/latticexyz/mud/issues/1212) + const currentChainState: (typeof currentChainStates)[number] | undefined = currentChainStates[0]; - if (currentChainState != null) { - if (currentChainState.schemaVersion != schemaVersion) { - console.log( - "schema version changed from", - currentChainState.schemaVersion, - "to", - schemaVersion, - "recreating database" - ); - fs.truncateSync(env.SQLITE_FILENAME); - } else if (currentChainState.lastUpdatedBlockNumber != null) { - console.log("resuming from block number", currentChainState.lastUpdatedBlockNumber + 1n); - startBlock = currentChainState.lastUpdatedBlockNumber + 1n; + if (currentChainState != null) { + if (currentChainState.schemaVersion != schemaVersion) { + console.log( + "schema version changed from", + currentChainState.schemaVersion, + "to", + schemaVersion, + "recreating database" + ); + fs.truncateSync(env.SQLITE_FILENAME); + } else if (currentChainState.lastUpdatedBlockNumber != null) { + console.log("resuming from block number", currentChainState.lastUpdatedBlockNumber + 1n); + startBlock = currentChainState.lastUpdatedBlockNumber + 1n; + } } + } catch (error) { + // ignore errors, this is optional } -} catch (error) { - // ignore errors, this is optional -} -const { latestBlockNumber$, storedBlockLogs$ } = await syncToSqlite({ - database, - publicClient, - startBlock, - maxBlockRange: env.MAX_BLOCK_RANGE, - address: env.STORE_ADDRESS, -}); - -let isCaughtUp = false; -combineLatest([latestBlockNumber$, storedBlockLogs$]) - .pipe( - filter( - ([latestBlockNumber, { blockNumber: lastBlockNumberProcessed }]) => latestBlockNumber === lastBlockNumberProcessed - ), - first() - ) - .subscribe(() => { - isCaughtUp = true; - console.log("all caught up"); + const { latestBlockNumber$, storedBlockLogs$ } = await syncToSqlite({ + database, + publicClient, + startBlock, + maxBlockRange: env.MAX_BLOCK_RANGE, + address: env.STORE_ADDRESS, }); -const server = new Koa(); + let isCaughtUp = false; + combineLatest([latestBlockNumber$, storedBlockLogs$]) + .pipe( + filter( + ([latestBlockNumber, { blockNumber: lastBlockNumberProcessed }]) => + latestBlockNumber === lastBlockNumberProcessed + ), + first() + ) + .subscribe(() => { + isCaughtUp = true; + console.log("all caught up"); + }); -if (env.SENTRY_DSN) { - server.use(sentry(env.SENTRY_DSN)); -} + const server = new Koa(); -server.use(cors()); -server.use( - healthcheck({ - isReady: () => isCaughtUp, - }) -); -server.use(helloWorld()); -server.use(apiRoutes(database)); + if (env.SENTRY_DSN) { + server.use(sentry(env.SENTRY_DSN)); + } -server.use( - createKoaMiddleware({ - prefix: "/trpc", - router: createAppRouter(), - createContext: async () => ({ - queryAdapter: await createQueryAdapter(database), - }), - }) -); + server.use(cors()); + server.use( + healthcheck({ + isReady: () => isCaughtUp, + }) + ); + server.use(helloWorld()); + server.use(apiRoutes(database)); + + server.use( + createKoaMiddleware({ + prefix: "/trpc", + router: createAppRouter(), + createContext: async () => ({ + queryAdapter: await createQueryAdapter(database), + }), + }) + ); -server.listen({ host: env.HOST, port: env.PORT }); -console.log(`sqlite indexer frontend listening on http://${env.HOST}:${env.PORT}`); + server.listen({ host: env.HOST, port: env.PORT }); + console.log(`sqlite indexer frontend listening on http://${env.HOST}:${env.PORT}`); +})(); diff --git a/packages/store-indexer/package.json b/packages/store-indexer/package.json index e8b79608f9..0054af7e6b 100644 --- a/packages/store-indexer/package.json +++ b/packages/store-indexer/package.json @@ -8,7 +8,6 @@ "directory": "packages/store-indexer" }, "license": "MIT", - "type": "module", "exports": { ".": "./dist/index.js" }, diff --git a/packages/store-indexer/tsup.config.ts b/packages/store-indexer/tsup.config.ts index 7ae6c030dd..70b57eceed 100644 --- a/packages/store-indexer/tsup.config.ts +++ b/packages/store-indexer/tsup.config.ts @@ -9,7 +9,7 @@ export default defineConfig({ "bin/sqlite-indexer.ts", ], target: "esnext", - format: ["esm"], + format: ["esm", "cjs"], dts: false, sourcemap: true, clean: true, diff --git a/packages/store-sync/package.json b/packages/store-sync/package.json index b6ce955f59..03b837fea6 100644 --- a/packages/store-sync/package.json +++ b/packages/store-sync/package.json @@ -8,7 +8,6 @@ "directory": "packages/store-sync" }, "license": "MIT", - "type": "module", "exports": { ".": "./dist/index.js", "./indexer-client": "./dist/indexer-client/index.js", diff --git a/packages/store-sync/tsup.config.ts b/packages/store-sync/tsup.config.ts index a6442c1a4a..986becc979 100644 --- a/packages/store-sync/tsup.config.ts +++ b/packages/store-sync/tsup.config.ts @@ -12,7 +12,7 @@ export default defineConfig({ "src/zustand/index.ts", ], target: "esnext", - format: ["esm"], + format: ["esm", "cjs"], dts: true, sourcemap: true, clean: true, diff --git a/packages/store/package.json b/packages/store/package.json index cef5a69075..8934496afc 100644 --- a/packages/store/package.json +++ b/packages/store/package.json @@ -8,7 +8,6 @@ "directory": "packages/store" }, "license": "MIT", - "type": "module", "exports": { ".": "./dist/ts/index.js", "./mud.config": "./dist/mud.config.js", diff --git a/packages/store/ts/scripts/generate-test-tables.ts b/packages/store/ts/scripts/generate-test-tables.ts index 7c0ea6926c..179350bb6c 100644 --- a/packages/store/ts/scripts/generate-test-tables.ts +++ b/packages/store/ts/scripts/generate-test-tables.ts @@ -40,7 +40,9 @@ const config = mudConfig({ }, }); -const srcDir = await getSrcDirectory(); -const remappings = await getRemappings(); +(async () => { + const srcDir = await getSrcDirectory(); + const remappings = await getRemappings(); -await tablegen(config, path.join(srcDir, config.codegenDirectory), remappings); + await tablegen(config, path.join(srcDir, config.codegenDirectory), remappings); +})(); diff --git a/packages/store/ts/scripts/generate-tightcoder.ts b/packages/store/ts/scripts/generate-tightcoder.ts index dd95ddb9bb..bc5b104c52 100644 --- a/packages/store/ts/scripts/generate-tightcoder.ts +++ b/packages/store/ts/scripts/generate-tightcoder.ts @@ -1,10 +1,12 @@ import { formatAndWriteSolidity } from "@latticexyz/common/codegen"; import { renderDecodeSlice, renderEncodeArray, renderTightCoderAutoTest } from "../codegen/tightcoder"; -await formatAndWriteSolidity(renderDecodeSlice(), "src/tightcoder/DecodeSlice.sol", "Generated DecodeSlice"); -await formatAndWriteSolidity(renderEncodeArray(), "src/tightcoder/EncodeArray.sol", "Generated EncodeArray"); -await formatAndWriteSolidity( - renderTightCoderAutoTest(), - "test/tightcoder/TightCoderAuto.t.sol", - "Generated TightCoderAutoTest" -); +(async () => { + await formatAndWriteSolidity(renderDecodeSlice(), "src/tightcoder/DecodeSlice.sol", "Generated DecodeSlice"); + await formatAndWriteSolidity(renderEncodeArray(), "src/tightcoder/EncodeArray.sol", "Generated EncodeArray"); + await formatAndWriteSolidity( + renderTightCoderAutoTest(), + "test/tightcoder/TightCoderAuto.t.sol", + "Generated TightCoderAutoTest" + ); +})(); diff --git a/packages/store/ts/scripts/tablegen.ts b/packages/store/ts/scripts/tablegen.ts index 6a1b7aaec3..362e28f4ae 100644 --- a/packages/store/ts/scripts/tablegen.ts +++ b/packages/store/ts/scripts/tablegen.ts @@ -4,8 +4,10 @@ import { getRemappings, getSrcDirectory } from "@latticexyz/common/foundry"; import { tablegen } from "../codegen"; import { StoreConfig } from ".."; -const config = (await loadConfig()) as StoreConfig; -const srcDir = await getSrcDirectory(); -const remappings = await getRemappings(); +(async () => { + const config = (await loadConfig()) as StoreConfig; + const srcDir = await getSrcDirectory(); + const remappings = await getRemappings(); -await tablegen(config, path.join(srcDir, config.codegenDirectory), remappings); + await tablegen(config, path.join(srcDir, config.codegenDirectory), remappings); +})(); diff --git a/packages/store/tsup.config.ts b/packages/store/tsup.config.ts index 031a8e4cb2..69e5b24fa4 100644 --- a/packages/store/tsup.config.ts +++ b/packages/store/tsup.config.ts @@ -3,7 +3,7 @@ import { defineConfig } from "tsup"; export default defineConfig({ entry: ["mud.config.ts", "ts/index.ts", "ts/codegen/index.ts", "ts/config/index.ts", "ts/register/index.ts"], target: "esnext", - format: ["esm"], + format: ["esm", "cjs"], dts: true, sourcemap: true, clean: true, diff --git a/packages/utils/package.json b/packages/utils/package.json index 8d5e0d0a30..7754cd3e28 100644 --- a/packages/utils/package.json +++ b/packages/utils/package.json @@ -7,7 +7,6 @@ "directory": "packages/utils" }, "license": "MIT", - "type": "module", "exports": { ".": "./dist/index.js" }, diff --git a/packages/utils/tsup.config.ts b/packages/utils/tsup.config.ts index 52bdfceee6..d139373ac6 100644 --- a/packages/utils/tsup.config.ts +++ b/packages/utils/tsup.config.ts @@ -3,7 +3,7 @@ import { defineConfig } from "tsup"; export default defineConfig({ entry: ["src/index.ts"], target: "esnext", - format: ["esm"], + format: ["esm", "cjs"], dts: true, sourcemap: true, clean: true, diff --git a/packages/world-modules/package.json b/packages/world-modules/package.json index c8d17bdd15..19281174a9 100644 --- a/packages/world-modules/package.json +++ b/packages/world-modules/package.json @@ -8,7 +8,6 @@ "directory": "packages/world-modules" }, "license": "MIT", - "type": "module", "exports": { "./out/*": "./out/*", "./*": "./dist/*" diff --git a/packages/world-modules/ts/scripts/tablegen.ts b/packages/world-modules/ts/scripts/tablegen.ts index 5a91d6d119..c1bf2df0cd 100644 --- a/packages/world-modules/ts/scripts/tablegen.ts +++ b/packages/world-modules/ts/scripts/tablegen.ts @@ -4,8 +4,10 @@ import { getRemappings, getSrcDirectory } from "@latticexyz/common/foundry"; import { StoreConfig } from "@latticexyz/store"; import { tablegen } from "@latticexyz/store/codegen"; -const config = (await loadConfig()) as StoreConfig; -const srcDir = await getSrcDirectory(); -const remappings = await getRemappings(); +(async () => { + const config = (await loadConfig()) as StoreConfig; + const srcDir = await getSrcDirectory(); + const remappings = await getRemappings(); -await tablegen(config, path.join(srcDir, config.codegenDirectory), remappings); + await tablegen(config, path.join(srcDir, config.codegenDirectory), remappings); +})(); diff --git a/packages/world-modules/ts/scripts/worldgen.ts b/packages/world-modules/ts/scripts/worldgen.ts index 09b2b09a2e..e83fe3b8e4 100644 --- a/packages/world-modules/ts/scripts/worldgen.ts +++ b/packages/world-modules/ts/scripts/worldgen.ts @@ -7,24 +7,26 @@ import { WorldConfig } from "@latticexyz/world"; import { worldgen } from "@latticexyz/world/node"; import { StoreConfig } from "@latticexyz/store"; -// TODO dedupe this and cli's worldgen command -const configPath = undefined; -const clean = false; -const srcDir = await getSrcDirectory(); +(async () => { + // TODO dedupe this and cli's worldgen command + const configPath = undefined; + const clean = false; + const srcDir = await getSrcDirectory(); -// Get a list of all contract names -const existingContracts = glob.sync(`${srcDir}/**/*.sol`).map((path) => ({ - path, - basename: basename(path, ".sol"), -})); + // Get a list of all contract names + const existingContracts = glob.sync(`${srcDir}/**/*.sol`).map((path) => ({ + path, + basename: basename(path, ".sol"), + })); -// Load and resolve the config -const mudConfig = (await loadConfig(configPath)) as StoreConfig & WorldConfig; + // Load and resolve the config + const mudConfig = (await loadConfig(configPath)) as StoreConfig & WorldConfig; -const outputBaseDirectory = path.join(srcDir, mudConfig.codegenDirectory); + const outputBaseDirectory = path.join(srcDir, mudConfig.codegenDirectory); -// clear the worldgen directory -if (clean) rmSync(path.join(outputBaseDirectory, mudConfig.worldgenDirectory), { recursive: true, force: true }); + // clear the worldgen directory + if (clean) rmSync(path.join(outputBaseDirectory, mudConfig.worldgenDirectory), { recursive: true, force: true }); -// generate new interfaces -await worldgen(mudConfig, existingContracts, outputBaseDirectory); + // generate new interfaces + await worldgen(mudConfig, existingContracts, outputBaseDirectory); +})(); diff --git a/packages/world-modules/tsup.config.ts b/packages/world-modules/tsup.config.ts index b9ae6d4212..bddda45543 100644 --- a/packages/world-modules/tsup.config.ts +++ b/packages/world-modules/tsup.config.ts @@ -3,7 +3,7 @@ import { defineConfig } from "tsup"; export default defineConfig({ entry: ["mud.config.ts"], target: "esnext", - format: ["esm"], + format: ["esm", "cjs"], dts: true, sourcemap: true, clean: true, diff --git a/packages/world/package.json b/packages/world/package.json index dd3d3369e9..148f71eeb1 100644 --- a/packages/world/package.json +++ b/packages/world/package.json @@ -8,7 +8,6 @@ "directory": "packages/world" }, "license": "MIT", - "type": "module", "exports": { ".": "./dist/ts/index.js", "./mud.config": "./dist/mud.config.js", diff --git a/packages/world/ts/scripts/generate-test-tables.ts b/packages/world/ts/scripts/generate-test-tables.ts index 1ae80c1ede..ce649d70ea 100644 --- a/packages/world/ts/scripts/generate-test-tables.ts +++ b/packages/world/ts/scripts/generate-test-tables.ts @@ -27,7 +27,10 @@ const config = mudConfig({ }, }, }); -const srcDir = await getSrcDirectory(); -const remappings = await getRemappings(); -await tablegen(config, path.join(srcDir, config.codegenDirectory), remappings); +(async () => { + const srcDir = await getSrcDirectory(); + const remappings = await getRemappings(); + + await tablegen(config, path.join(srcDir, config.codegenDirectory), remappings); +})(); diff --git a/packages/world/ts/scripts/tablegen.ts b/packages/world/ts/scripts/tablegen.ts index 5a91d6d119..c1bf2df0cd 100644 --- a/packages/world/ts/scripts/tablegen.ts +++ b/packages/world/ts/scripts/tablegen.ts @@ -4,8 +4,10 @@ import { getRemappings, getSrcDirectory } from "@latticexyz/common/foundry"; import { StoreConfig } from "@latticexyz/store"; import { tablegen } from "@latticexyz/store/codegen"; -const config = (await loadConfig()) as StoreConfig; -const srcDir = await getSrcDirectory(); -const remappings = await getRemappings(); +(async () => { + const config = (await loadConfig()) as StoreConfig; + const srcDir = await getSrcDirectory(); + const remappings = await getRemappings(); -await tablegen(config, path.join(srcDir, config.codegenDirectory), remappings); + await tablegen(config, path.join(srcDir, config.codegenDirectory), remappings); +})(); diff --git a/packages/world/ts/scripts/worldgen.ts b/packages/world/ts/scripts/worldgen.ts index 6eedbc3706..b1df783edd 100644 --- a/packages/world/ts/scripts/worldgen.ts +++ b/packages/world/ts/scripts/worldgen.ts @@ -7,26 +7,28 @@ import { worldgen } from "../node"; import { StoreConfig } from "@latticexyz/store"; import { WorldConfig } from "../config/types"; -// TODO dedupe this and cli's worldgen command -const configPath = undefined; -const clean = false; -const srcDir = await getSrcDirectory(); +(async () => { + // TODO dedupe this and cli's worldgen command + const configPath = undefined; + const clean = false; + const srcDir = await getSrcDirectory(); -// Get a list of all contract names -const existingContracts = glob.sync(`${srcDir}/**/*.sol`).map((path) => ({ - path, - basename: basename(path, ".sol"), -})); + // Get a list of all contract names + const existingContracts = glob.sync(`${srcDir}/**/*.sol`).map((path) => ({ + path, + basename: basename(path, ".sol"), + })); -// Load and resolve the config -const mudConfig = (await loadConfig(configPath)) as StoreConfig & WorldConfig; + // Load and resolve the config + const mudConfig = (await loadConfig(configPath)) as StoreConfig & WorldConfig; -const outputBaseDirectory = path.join(srcDir, mudConfig.codegenDirectory); + const outputBaseDirectory = path.join(srcDir, mudConfig.codegenDirectory); -// clear the worldgen directory -if (clean) rmSync(path.join(outputBaseDirectory, mudConfig.worldgenDirectory), { recursive: true, force: true }); + // clear the worldgen directory + if (clean) rmSync(path.join(outputBaseDirectory, mudConfig.worldgenDirectory), { recursive: true, force: true }); -// generate new interfaces -// override the namespace to be the root namespace for generating the core system interface -const rootMudConfig = { ...mudConfig, namespace: "" }; -await worldgen(rootMudConfig, existingContracts, outputBaseDirectory); + // generate new interfaces + // override the namespace to be the root namespace for generating the core system interface + const rootMudConfig = { ...mudConfig, namespace: "" }; + await worldgen(rootMudConfig, existingContracts, outputBaseDirectory); +})(); diff --git a/packages/world/tsup.config.ts b/packages/world/tsup.config.ts index d7d1d07098..866b8f35ec 100644 --- a/packages/world/tsup.config.ts +++ b/packages/world/tsup.config.ts @@ -3,7 +3,7 @@ import { defineConfig } from "tsup"; export default defineConfig({ entry: ["mud.config.ts", "ts/index.ts", "ts/register/index.ts", "ts/node/index.ts"], target: "esnext", - format: ["esm"], + format: ["esm", "cjs"], dts: true, sourcemap: true, clean: true, diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index ccb001cd7d..baef0a8a0a 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -10,10 +10,10 @@ importers: devDependencies: '@changesets/cli': specifier: ^2.26.1 - version: 2.26.1 + version: 2.27.1 '@types/node': specifier: ^18.15.11 - version: 18.15.11 + version: 18.19.21 '@typescript-eslint/eslint-plugin': specifier: 5.46.1 version: 5.46.1(@typescript-eslint/parser@5.46.1)(eslint@8.29.0)(typescript@5.1.6) @@ -22,34 +22,34 @@ importers: version: 5.46.1(eslint@8.29.0)(typescript@5.1.6) bun: specifier: ^1.0.11 - version: 1.0.11 + version: 1.0.29 chalk: - specifier: ^5.2.0 - version: 5.2.0 + specifier: 4.1.2 + version: 4.1.2 eslint: specifier: 8.29.0 version: 8.29.0 execa: - specifier: ^7.0.0 - version: 7.0.0 + specifier: ^5.1.1 + version: 5.1.1 husky: specifier: '>=6' - version: 6.0.0 + version: 9.0.11 lint-staged: specifier: '>=10' - version: 10.0.0 + version: 15.2.2 prettier: specifier: ^2.8.4 - version: 2.8.4 + version: 2.8.8 prettier-plugin-solidity: specifier: 1.1.3 - version: 1.1.3(prettier@2.8.4) + version: 1.1.3(prettier@2.8.8) rimraf: specifier: ^3.0.2 version: 3.0.2 turbo: specifier: ^1.9.3 - version: 1.9.3 + version: 1.12.4 typescript: specifier: 5.1.6 version: 5.1.6 @@ -57,36 +57,36 @@ importers: packages/abi-ts: dependencies: chalk: - specifier: ^5.3.0 - version: 5.3.0 + specifier: 4.1.2 + version: 4.1.2 debug: specifier: ^4.3.4 version: 4.3.4(supports-color@8.1.1) execa: - specifier: ^7.0.0 - version: 7.0.0 + specifier: ^5.1.1 + version: 5.1.1 glob: specifier: ^8.0.3 - version: 8.0.3 + version: 8.1.0 yargs: specifier: ^17.7.1 - version: 17.7.1 + version: 17.7.2 devDependencies: '@types/debug': specifier: ^4.1.7 - version: 4.1.7 + version: 4.1.12 '@types/glob': specifier: ^7.2.0 version: 7.2.0 '@types/node': specifier: ^18.15.11 - version: 18.15.11 + version: 18.19.21 '@types/yargs': specifier: ^17.0.10 - version: 17.0.23 + version: 17.0.32 tsup: specifier: ^6.7.0 - version: 6.7.0(postcss@8.4.23)(typescript@5.1.6) + version: 6.7.0(postcss@8.4.35)(typescript@5.1.6) vitest: specifier: 0.34.6 version: 0.34.6(jsdom@22.1.0) @@ -98,7 +98,7 @@ importers: version: link:../common abitype: specifier: 1.0.0 - version: 1.0.0(typescript@5.1.6)(zod@3.21.4) + version: 1.0.0(typescript@5.1.6)(zod@3.22.4) debug: specifier: ^4.3.4 version: 4.3.4(supports-color@8.1.1) @@ -107,14 +107,14 @@ importers: version: 7.5.5 viem: specifier: 2.7.12 - version: 2.7.12(typescript@5.1.6)(zod@3.21.4) + version: 2.7.12(typescript@5.1.6)(zod@3.22.4) devDependencies: '@types/debug': specifier: ^4.1.7 - version: 4.1.7 + version: 4.1.12 tsup: specifier: ^6.7.0 - version: 6.7.0(postcss@8.4.23)(typescript@5.1.6) + version: 6.7.0(postcss@8.4.35)(typescript@5.1.6) vitest: specifier: 0.34.6 version: 0.34.6(jsdom@22.1.0) @@ -167,38 +167,38 @@ importers: specifier: workspace:* version: link:../world-modules chalk: - specifier: ^5.0.1 - version: 5.2.0 + specifier: 4.1.2 + version: 4.1.2 chokidar: specifier: ^3.5.3 - version: 3.5.3 + version: 3.6.0 debug: specifier: ^4.3.4 version: 4.3.4(supports-color@8.1.1) dotenv: specifier: ^16.0.3 - version: 16.0.3 + version: 16.4.5 ejs: specifier: ^3.1.8 - version: 3.1.8 + version: 3.1.9 ethers: specifier: ^5.7.2 version: 5.7.2 execa: - specifier: ^7.0.0 - version: 7.0.0 + specifier: ^5.1.1 + version: 5.1.1 glob: specifier: ^8.0.3 - version: 8.0.3 + version: 8.1.0 nice-grpc-web: specifier: ^2.0.1 - version: 2.0.1(google-protobuf@3.21.2) + version: 2.0.2(google-protobuf@3.21.2) openurl: specifier: ^1.1.1 version: 1.1.1 p-retry: - specifier: ^5.1.2 - version: 5.1.2 + specifier: 4.6.2 + version: 4.6.2 path: specifier: ^0.12.7 version: 0.12.7 @@ -213,38 +213,38 @@ importers: version: 5.1.6 viem: specifier: 2.7.12 - version: 2.7.12(typescript@5.1.6)(zod@3.21.4) + version: 2.7.12(typescript@5.1.6)(zod@3.22.4) yargs: specifier: ^17.7.1 - version: 17.7.1 + version: 17.7.2 zod: specifier: ^3.21.4 - version: 3.21.4 + version: 3.22.4 zod-validation-error: specifier: ^1.3.0 - version: 1.3.0(zod@3.21.4) + version: 1.5.0(zod@3.22.4) devDependencies: '@types/debug': specifier: ^4.1.7 - version: 4.1.7 + version: 4.1.12 '@types/ejs': specifier: ^3.1.1 - version: 3.1.1 + version: 3.1.5 '@types/glob': specifier: ^7.2.0 version: 7.2.0 '@types/node': specifier: ^18.15.11 - version: 18.15.11 + version: 18.19.21 '@types/openurl': specifier: ^1.0.0 - version: 1.0.0 + version: 1.0.3 '@types/throttle-debounce': specifier: ^5.0.0 - version: 5.0.0 + version: 5.0.2 '@types/yargs': specifier: ^17.0.10 - version: 17.0.23 + version: 17.0.32 ds-test: specifier: https://github.com/dapphub/ds-test.git#e282159d5170298eb2455a6c05280ab5a73a4ef0 version: github.com/dapphub/ds-test/e282159d5170298eb2455a6c05280ab5a73a4ef0 @@ -253,10 +253,10 @@ importers: version: github.com/foundry-rs/forge-std/74cfb77e308dd188d2f58864aaf44963ae6b88b1 tsup: specifier: ^6.7.0 - version: 6.7.0(postcss@8.4.23)(typescript@5.1.6) + version: 6.7.0(postcss@8.4.35)(typescript@5.1.6) tsx: specifier: ^3.12.6 - version: 3.12.6 + version: 3.14.0 vitest: specifier: 0.34.6 version: 0.34.6(jsdom@22.1.0) @@ -268,38 +268,38 @@ importers: version: link:../schema-type '@solidity-parser/parser': specifier: ^0.16.0 - version: 0.16.0 + version: 0.16.2 debug: specifier: ^4.3.4 version: 4.3.4(supports-color@8.1.1) execa: - specifier: ^7.0.0 - version: 7.0.0 + specifier: ^5.1.1 + version: 5.1.1 p-queue: - specifier: ^7.4.1 - version: 7.4.1 + specifier: 6.6.2 + version: 6.6.2 p-retry: - specifier: ^5.1.2 - version: 5.1.2 + specifier: 4.6.2 + version: 4.6.2 prettier: - specifier: ^2.8.4 - version: 2.8.4 + specifier: ^3.2.5 + version: 3.2.5 prettier-plugin-solidity: specifier: 1.1.3 - version: 1.1.3(prettier@2.8.4) + version: 1.1.3(prettier@3.2.5) viem: specifier: 2.7.12 - version: 2.7.12(typescript@5.1.6)(zod@3.21.4) + version: 2.7.12(typescript@5.1.6)(zod@3.22.4) devDependencies: '@types/debug': specifier: ^4.1.7 - version: 4.1.7 + version: 4.1.12 '@types/node': specifier: ^18.15.11 - version: 18.15.11 + version: 18.19.21 tsup: specifier: ^6.7.0 - version: 6.7.0(postcss@8.4.23)(typescript@5.1.6) + version: 6.7.0(postcss@8.4.35)(typescript@5.1.6) vitest: specifier: 0.34.6 version: 0.34.6(jsdom@22.1.0) @@ -314,23 +314,23 @@ importers: version: link:../schema-type esbuild: specifier: ^0.17.15 - version: 0.17.15 + version: 0.17.19 find-up: - specifier: ^6.3.0 - version: 6.3.0 + specifier: 5.0.0 + version: 5.0.0 viem: specifier: 2.7.12 - version: 2.7.12(typescript@5.1.6)(zod@3.21.4) + version: 2.7.12(typescript@5.1.6)(zod@3.22.4) zod: specifier: ^3.21.4 - version: 3.21.4 + version: 3.22.4 zod-validation-error: specifier: ^1.3.0 - version: 1.3.0(zod@3.21.4) + version: 1.5.0(zod@3.22.4) devDependencies: tsup: specifier: ^6.7.0 - version: 6.7.0(postcss@8.4.23)(typescript@5.1.6) + version: 6.7.0(postcss@8.4.35)(typescript@5.1.6) packages/create-mud: dependencies: @@ -340,10 +340,10 @@ importers: devDependencies: '@types/node': specifier: ^18.15.11 - version: 18.15.11 + version: 18.19.21 tsup: specifier: ^6.7.0 - version: 6.7.0(postcss@8.4.23)(typescript@5.1.6) + version: 6.7.0(postcss@8.4.35)(typescript@5.1.6) packages/dev-tools: dependencies: @@ -379,22 +379,22 @@ importers: version: 18.2.0(react@18.2.0) react-router-dom: specifier: ^6.11.0 - version: 6.11.0(react-dom@18.2.0)(react@18.2.0) + version: 6.22.2(react-dom@18.2.0)(react@18.2.0) rxjs: specifier: 7.5.5 version: 7.5.5 tailwind-merge: specifier: ^1.12.0 - version: 1.12.0 + version: 1.14.0 use-local-storage-state: specifier: ^18.3.2 - version: 18.3.2(react-dom@18.2.0)(react@18.2.0) + version: 18.3.3(react-dom@18.2.0)(react@18.2.0) viem: specifier: 2.7.12 - version: 2.7.12(typescript@5.1.6)(zod@3.21.4) + version: 2.7.12(typescript@5.1.6)(zod@3.22.4) zustand: specifier: ^4.3.7 - version: 4.3.7(react@18.2.0) + version: 4.5.1(@types/react@18.2.22)(react@18.2.0) devDependencies: '@types/react': specifier: 18.2.22 @@ -404,19 +404,19 @@ importers: version: 18.2.7 '@types/ws': specifier: ^8.5.4 - version: 8.5.4 + version: 8.5.10 autoprefixer: specifier: ^10.4.14 - version: 10.4.14(postcss@8.4.23) + version: 10.4.17(postcss@8.4.35) postcss: specifier: ^8.4.23 - version: 8.4.23 + version: 8.4.35 tailwindcss: specifier: ^3.3.2 - version: 3.3.2 + version: 3.4.1 tsup: specifier: ^6.7.0 - version: 6.7.0(postcss@8.4.23)(typescript@5.1.6) + version: 6.7.0(postcss@8.4.35)(typescript@5.1.6) vitest: specifier: 0.34.6 version: 0.34.6(jsdom@22.1.0) @@ -430,7 +430,7 @@ importers: version: 6.5.0 '@fastify/cors': specifier: ^8.3.0 - version: 8.3.0 + version: 8.5.0 '@latticexyz/common': specifier: workspace:* version: link:../common @@ -445,26 +445,26 @@ importers: version: 4.3.4(supports-color@8.1.1) dotenv: specifier: ^16.0.3 - version: 16.0.3 + version: 16.4.5 fastify: specifier: ^4.21.0 - version: 4.21.0 + version: 4.26.1 viem: specifier: 2.7.12 - version: 2.7.12(typescript@5.1.6)(zod@3.21.4) + version: 2.7.12(typescript@5.1.6)(zod@3.22.4) zod: specifier: ^3.21.4 - version: 3.21.4 + version: 3.22.4 devDependencies: '@types/debug': specifier: ^4.1.7 - version: 4.1.7 + version: 4.1.12 tsup: specifier: ^6.7.0 - version: 6.7.0(postcss@8.4.23)(typescript@5.1.6) + version: 6.7.0(postcss@8.4.35)(typescript@5.1.6) tsx: specifier: ^3.12.6 - version: 3.12.6 + version: 3.14.0 vitest: specifier: 0.34.6 version: 0.34.6(jsdom@22.1.0) @@ -472,36 +472,33 @@ importers: packages/gas-report: dependencies: chalk: - specifier: ^5.3.0 - version: 5.3.0 + specifier: 4.1.2 + version: 4.1.2 dotenv: specifier: ^16.0.3 - version: 16.0.3 + version: 16.4.5 execa: - specifier: ^7.0.0 - version: 7.0.0 + specifier: ^5.1.1 + version: 5.1.1 stream-to-array: specifier: ^2.3.0 version: 2.3.0 - strip-ansi: - specifier: ^7.1.0 - version: 7.1.0 table: specifier: ^6.8.1 version: 6.8.1 yargs: specifier: ^17.7.1 - version: 17.7.1 + version: 17.7.2 devDependencies: '@types/node': specifier: ^18.15.11 - version: 18.15.11 + version: 18.19.21 '@types/stream-to-array': specifier: ^2.3.1 - version: 2.3.1 + version: 2.3.3 '@types/yargs': specifier: ^17.0.10 - version: 17.0.23 + version: 17.0.32 ds-test: specifier: https://github.com/dapphub/ds-test.git#e282159d5170298eb2455a6c05280ab5a73a4ef0 version: github.com/dapphub/ds-test/e282159d5170298eb2455a6c05280ab5a73a4ef0 @@ -510,7 +507,7 @@ importers: version: github.com/foundry-rs/forge-std/74cfb77e308dd188d2f58864aaf44963ae6b88b1 tsup: specifier: ^6.7.0 - version: 6.7.0(postcss@8.4.23)(typescript@5.1.6) + version: 6.7.0(postcss@8.4.35)(typescript@5.1.6) vitest: specifier: 0.34.6 version: 0.34.6(jsdom@22.1.0) @@ -521,7 +518,7 @@ importers: dependencies: abdk-libraries-solidity: specifier: ^3.0.0 - version: 3.0.0 + version: 3.2.0 ds-test: specifier: https://github.com/dapphub/ds-test.git#e282159d5170298eb2455a6c05280ab5a73a4ef0 version: github.com/dapphub/ds-test/e282159d5170298eb2455a6c05280ab5a73a4ef0 @@ -531,37 +528,37 @@ importers: devDependencies: '@nomicfoundation/hardhat-chai-matchers': specifier: ^1.0.3 - version: 1.0.3(@nomiclabs/hardhat-ethers@2.1.1)(chai@4.3.7)(ethers@5.7.2)(hardhat@2.10.2) + version: 1.0.6(@nomiclabs/hardhat-ethers@2.2.3)(chai@4.4.1)(ethers@5.7.2)(hardhat@2.20.1) '@nomiclabs/hardhat-ethers': specifier: ^2.1.1 - version: 2.1.1(ethers@5.7.2)(hardhat@2.10.2) + version: 2.2.3(ethers@5.7.2)(hardhat@2.20.1) '@types/chai': specifier: ^4.3.5 - version: 4.3.5 + version: 4.3.12 '@types/node-fetch': specifier: ^2.6.2 - version: 2.6.2 + version: 2.6.11 assemblyscript: specifier: ^0.21.2 - version: 0.21.2 + version: 0.21.7 chai: specifier: ^4.3.6 - version: 4.3.7 + version: 4.4.1 ethers: specifier: ^5.7.2 version: 5.7.2 hardhat: specifier: ^2.10.2 - version: 2.10.2(typescript@5.1.6) + version: 2.20.1(typescript@5.1.6) keccak-wasm: specifier: ^0.10.3 - version: 0.10.3(buffer-lite@1.0.0) + version: 0.10.3(buffer-lite@1.1.0) tsup: specifier: ^6.7.0 - version: 6.7.0(postcss@8.4.23)(typescript@5.1.6) + version: 6.7.0(postcss@8.4.35)(typescript@5.1.6) web3-utils: specifier: ^1.8.0 - version: 1.8.0 + version: 1.10.4 packages/phaserx: dependencies: @@ -573,7 +570,7 @@ importers: version: 10.2.9 mobx: specifier: ^6.7.0 - version: 6.9.0 + version: 6.12.0 phaser: specifier: 3.60.0-beta.14 version: 3.60.0-beta.14 @@ -583,7 +580,7 @@ importers: devDependencies: tsup: specifier: ^6.7.0 - version: 6.7.0(postcss@8.4.23)(typescript@5.1.6) + version: 6.7.0(postcss@8.4.35)(typescript@5.1.6) packages/protocol-parser: dependencies: @@ -595,14 +592,14 @@ importers: version: link:../schema-type abitype: specifier: 1.0.0 - version: 1.0.0(typescript@5.1.6)(zod@3.21.4) + version: 1.0.0(typescript@5.1.6)(zod@3.22.4) viem: specifier: 2.7.12 - version: 2.7.12(typescript@5.1.6)(zod@3.21.4) + version: 2.7.12(typescript@5.1.6)(zod@3.22.4) devDependencies: tsup: specifier: ^6.7.0 - version: 6.7.0(postcss@8.4.23)(typescript@5.1.6) + version: 6.7.0(postcss@8.4.35)(typescript@5.1.6) vitest: specifier: 0.34.6 version: 0.34.6(jsdom@22.1.0) @@ -620,7 +617,7 @@ importers: version: 3.1.3 mobx: specifier: ^6.7.0 - version: 6.9.0 + version: 6.12.0 react: specifier: ^18.2.0 version: 18.2.0 @@ -636,7 +633,7 @@ importers: version: 18.2.22 '@vitejs/plugin-react': specifier: ^4.0.0 - version: 4.0.0(vite@4.3.6) + version: 4.2.1(vite@4.5.2) eslint-plugin-react: specifier: 7.31.11 version: 7.31.11(eslint@8.29.0) @@ -651,10 +648,10 @@ importers: version: 18.2.0(react@18.2.0) tsup: specifier: ^6.7.0 - version: 6.7.0(postcss@8.4.23)(typescript@5.1.6) + version: 6.7.0(postcss@8.4.35)(typescript@5.1.6) vite: specifier: ^4.3.6 - version: 4.3.6(@types/node@18.15.11) + version: 4.5.2(@types/node@18.19.21) vitest: specifier: 0.34.6 version: 0.34.6(jsdom@22.1.0) @@ -669,38 +666,38 @@ importers: version: link:../utils mobx: specifier: ^6.7.0 - version: 6.9.0 + version: 6.12.0 rxjs: specifier: 7.5.5 version: 7.5.5 devDependencies: '@types/jest': specifier: ^27.4.1 - version: 27.4.1 + version: 27.5.2 '@types/uuid': specifier: ^8.3.4 version: 8.3.4 jest: specifier: ^29.3.1 - version: 29.5.0(@types/node@18.15.11) + version: 29.7.0(@types/node@18.19.21) ts-jest: specifier: ^29.0.5 - version: 29.0.5(@babel/core@7.21.4)(esbuild@0.17.17)(jest@29.5.0)(typescript@5.1.6) + version: 29.1.2(@babel/core@7.24.0)(esbuild@0.17.19)(jest@29.7.0)(typescript@5.1.6) tsup: specifier: ^6.7.0 - version: 6.7.0(postcss@8.4.23)(typescript@5.1.6) + version: 6.7.0(postcss@8.4.35)(typescript@5.1.6) type-fest: specifier: ^2.14.0 - version: 2.14.0 + version: 2.19.0 packages/schema-type: dependencies: abitype: specifier: 1.0.0 - version: 1.0.0(typescript@5.1.6)(zod@3.21.4) + version: 1.0.0(typescript@5.1.6)(zod@3.22.4) viem: specifier: 2.7.12 - version: 2.7.12(typescript@5.1.6)(zod@3.21.4) + version: 2.7.12(typescript@5.1.6)(zod@3.22.4) devDependencies: '@latticexyz/gas-report': specifier: workspace:* @@ -713,7 +710,7 @@ importers: version: github.com/foundry-rs/forge-std/74cfb77e308dd188d2f58864aaf44963ae6b88b1 tsup: specifier: ^6.7.0 - version: 6.7.0(postcss@8.4.23)(typescript@5.1.6) + version: 6.7.0(postcss@8.4.35)(typescript@5.1.6) vitest: specifier: 0.34.6 version: 0.34.6(jsdom@22.1.0) @@ -722,23 +719,23 @@ importers: dependencies: long: specifier: ^5.2.1 - version: 5.2.1 + version: 5.2.3 nice-grpc-common: specifier: ^2.0.2 version: 2.0.2 nice-grpc-web: specifier: ^2.0.1 - version: 2.0.1(google-protobuf@3.21.2) + version: 2.0.2(google-protobuf@3.21.2) protobufjs: specifier: ^7.2.3 - version: 7.2.3 + version: 7.2.6 devDependencies: ts-proto: specifier: ^1.146.0 - version: 1.146.0 + version: 1.167.9 tsup: specifier: ^6.7.0 - version: 6.7.0(postcss@8.4.23)(typescript@5.1.6) + version: 6.7.0(postcss@8.4.35)(typescript@5.1.6) packages/solecs: {} @@ -746,20 +743,20 @@ importers: devDependencies: tsup: specifier: ^6.7.0 - version: 6.7.0(postcss@8.4.23)(typescript@5.1.6) + version: 6.7.0(postcss@8.4.35)(typescript@5.1.6) packages/solhint-plugin-mud: dependencies: '@solidity-parser/parser': specifier: ^0.16.0 - version: 0.16.0 + version: 0.16.2 devDependencies: '@types/node': specifier: ^18.15.11 - version: 18.15.11 + version: 18.19.21 tsup: specifier: ^6.7.0 - version: 6.7.0(postcss@8.4.23)(typescript@5.1.6) + version: 6.7.0(postcss@8.4.35)(typescript@5.1.6) packages/std-client: {} @@ -778,13 +775,13 @@ importers: version: link:../schema-type abitype: specifier: 1.0.0 - version: 1.0.0(typescript@5.1.6)(zod@3.21.4) + version: 1.0.0(typescript@5.1.6)(zod@3.22.4) viem: specifier: 2.7.12 - version: 2.7.12(typescript@5.1.6)(zod@3.21.4) + version: 2.7.12(typescript@5.1.6)(zod@3.22.4) zod: specifier: ^3.21.4 - version: 3.21.4 + version: 3.22.4 devDependencies: '@latticexyz/abi-ts': specifier: workspace:* @@ -794,31 +791,31 @@ importers: version: link:../gas-report '@types/ejs': specifier: ^3.1.1 - version: 3.1.1 + version: 3.1.5 '@types/mocha': specifier: ^9.1.1 version: 9.1.1 '@types/node': specifier: ^18.15.11 - version: 18.15.11 + version: 18.19.21 ds-test: specifier: https://github.com/dapphub/ds-test.git#e282159d5170298eb2455a6c05280ab5a73a4ef0 version: github.com/dapphub/ds-test/e282159d5170298eb2455a6c05280ab5a73a4ef0 ejs: specifier: ^3.1.8 - version: 3.1.8 + version: 3.1.9 forge-std: specifier: https://github.com/foundry-rs/forge-std.git#74cfb77e308dd188d2f58864aaf44963ae6b88b1 version: github.com/foundry-rs/forge-std/74cfb77e308dd188d2f58864aaf44963ae6b88b1 solhint: specifier: ^3.3.7 - version: 3.3.7 + version: 3.6.2(typescript@5.1.6) tsup: specifier: ^6.7.0 - version: 6.7.0(postcss@8.4.23)(typescript@5.1.6) + version: 6.7.0(postcss@8.4.35)(typescript@5.1.6) tsx: specifier: ^3.12.6 - version: 3.12.6 + version: 3.14.0 vitest: specifier: 0.34.6 version: 0.34.6(jsdom@22.1.0) @@ -850,13 +847,13 @@ importers: version: link:../store-sync '@sentry/node': specifier: ^7.86.0 - version: 7.86.0 + version: 7.103.0 '@sentry/profiling-node': specifier: ^1.2.6 - version: 1.2.6 + version: 1.3.5(@sentry/node@7.103.0) '@sentry/utils': specifier: ^7.86.0 - version: 7.86.0 + version: 7.103.0 '@trpc/client': specifier: 10.34.0 version: 10.34.0(@trpc/server@10.34.0) @@ -868,19 +865,19 @@ importers: version: 1.3.8 better-sqlite3: specifier: ^8.6.0 - version: 8.6.0 + version: 8.7.0 debug: specifier: ^4.3.4 version: 4.3.4(supports-color@8.1.1) dotenv: specifier: ^16.0.3 - version: 16.0.3 + version: 16.4.5 drizzle-orm: specifier: ^0.28.5 - version: 0.28.5(@types/better-sqlite3@7.6.4)(better-sqlite3@8.6.0)(postgres@3.3.5) + version: 0.28.6(@types/better-sqlite3@7.6.9)(better-sqlite3@8.7.0)(postgres@3.3.5) koa: specifier: ^2.14.2 - version: 2.14.2 + version: 2.15.0 koa-compose: specifier: ^4.1.0 version: 4.1.0 @@ -892,29 +889,29 @@ importers: version: 7.5.5 superjson: specifier: ^1.12.4 - version: 1.12.4 + version: 1.13.3 trpc-koa-adapter: specifier: ^1.1.3 - version: 1.1.3(@trpc/server@10.34.0)(koa@2.14.2) + version: 1.1.3(@trpc/server@10.34.0)(koa@2.15.0) viem: specifier: 2.7.12 - version: 2.7.12(typescript@5.1.6)(zod@3.21.4) + version: 2.7.12(typescript@5.1.6)(zod@3.22.4) zod: specifier: ^3.21.4 - version: 3.21.4 + version: 3.22.4 devDependencies: '@types/accepts': specifier: ^1.3.7 version: 1.3.7 '@types/better-sqlite3': specifier: ^7.6.4 - version: 7.6.4 + version: 7.6.9 '@types/debug': specifier: ^4.1.7 - version: 4.1.7 + version: 4.1.12 '@types/koa': specifier: ^2.13.12 - version: 2.13.12 + version: 2.15.0 '@types/koa-compose': specifier: ^3.2.8 version: 3.2.8 @@ -929,10 +926,10 @@ importers: version: 8.2.2 tsup: specifier: ^6.7.0 - version: 6.7.0(postcss@8.4.23)(typescript@5.1.6) + version: 6.7.0(postcss@8.4.35)(typescript@5.1.6) tsx: specifier: ^3.12.6 - version: 3.12.6 + version: 3.14.0 vitest: specifier: 0.34.6 version: 0.34.6(jsdom@22.1.0) @@ -968,13 +965,13 @@ importers: version: 10.34.0 change-case: specifier: ^5.2.0 - version: 5.2.0 + version: 5.4.3 debug: specifier: ^4.3.4 version: 4.3.4(supports-color@8.1.1) drizzle-orm: specifier: ^0.28.5 - version: 0.28.5(@types/sql.js@1.4.4)(kysely@0.26.3)(postgres@3.3.5)(sql.js@1.8.0) + version: 0.28.6(@types/sql.js@1.4.9)(kysely@0.26.3)(postgres@3.3.5)(sql.js@1.10.2) kysely: specifier: ^0.26.3 version: 0.26.3 @@ -986,29 +983,29 @@ importers: version: 7.5.5 sql.js: specifier: ^1.8.0 - version: 1.8.0 + version: 1.10.2 superjson: specifier: ^1.12.4 - version: 1.12.4 + version: 1.13.3 viem: specifier: 2.7.12 - version: 2.7.12(typescript@5.1.6)(zod@3.21.4) + version: 2.7.12(typescript@5.1.6)(zod@3.22.4) zod: specifier: ^3.21.4 - version: 3.21.4 + version: 3.22.4 zustand: specifier: ^4.3.7 - version: 4.3.7(react@18.2.0) + version: 4.5.1(@types/react@18.2.22)(react@18.2.0) devDependencies: '@types/debug': specifier: ^4.1.7 - version: 4.1.7 + version: 4.1.12 '@types/sql.js': specifier: ^1.4.4 - version: 1.4.4 + version: 1.4.9 tsup: specifier: ^6.7.0 - version: 6.7.0(postcss@8.4.23)(typescript@5.1.6) + version: 6.7.0(postcss@8.4.35)(typescript@5.1.6) vitest: specifier: 0.34.6 version: 0.34.6(jsdom@22.1.0) @@ -1017,7 +1014,7 @@ importers: dependencies: mobx: specifier: ^6.7.0 - version: 6.9.0 + version: 6.12.0 proxy-deep: specifier: ^3.1.1 version: 3.1.1 @@ -1027,16 +1024,16 @@ importers: devDependencies: '@types/jest': specifier: ^27.4.1 - version: 27.4.1 + version: 27.5.2 jest: specifier: ^29.3.1 - version: 29.5.0(@types/node@18.15.11) + version: 29.7.0(@types/node@18.19.21) ts-jest: specifier: ^29.0.5 - version: 29.0.5(@babel/core@7.21.4)(esbuild@0.17.17)(jest@29.5.0)(typescript@5.1.6) + version: 29.1.2(@babel/core@7.24.0)(esbuild@0.17.19)(jest@29.7.0)(typescript@5.1.6) tsup: specifier: ^6.7.0 - version: 6.7.0(postcss@8.4.23)(typescript@5.1.6) + version: 6.7.0(postcss@8.4.35)(typescript@5.1.6) packages/world: dependencies: @@ -1054,13 +1051,13 @@ importers: version: link:../store abitype: specifier: 1.0.0 - version: 1.0.0(typescript@5.1.6)(zod@3.21.4) + version: 1.0.0(typescript@5.1.6)(zod@3.22.4) viem: specifier: 2.7.12 - version: 2.7.12(typescript@5.1.6)(zod@3.21.4) + version: 2.7.12(typescript@5.1.6)(zod@3.22.4) zod: specifier: ^3.21.4 - version: 3.21.4 + version: 3.22.4 devDependencies: '@latticexyz/abi-ts': specifier: workspace:* @@ -1070,7 +1067,7 @@ importers: version: link:../gas-report '@types/ejs': specifier: ^3.1.1 - version: 3.1.1 + version: 3.1.5 '@types/glob': specifier: ^7.2.0 version: 7.2.0 @@ -1079,28 +1076,28 @@ importers: version: 9.1.1 '@types/node': specifier: ^18.15.11 - version: 18.15.11 + version: 18.19.21 ds-test: specifier: https://github.com/dapphub/ds-test.git#e282159d5170298eb2455a6c05280ab5a73a4ef0 version: github.com/dapphub/ds-test/e282159d5170298eb2455a6c05280ab5a73a4ef0 ejs: specifier: ^3.1.8 - version: 3.1.8 + version: 3.1.9 forge-std: specifier: https://github.com/foundry-rs/forge-std.git#74cfb77e308dd188d2f58864aaf44963ae6b88b1 version: github.com/foundry-rs/forge-std/74cfb77e308dd188d2f58864aaf44963ae6b88b1 glob: specifier: ^8.0.3 - version: 8.0.3 + version: 8.1.0 solhint: specifier: ^3.3.7 - version: 3.3.7 + version: 3.6.2(typescript@5.1.6) tsup: specifier: ^6.7.0 - version: 6.7.0(postcss@8.4.23)(typescript@5.1.6) + version: 6.7.0(postcss@8.4.35)(typescript@5.1.6) tsx: specifier: ^3.12.6 - version: 3.12.6 + version: 3.14.0 vitest: specifier: 0.34.6 version: 0.34.6(jsdom@22.1.0) @@ -1124,7 +1121,7 @@ importers: version: link:../world zod: specifier: ^3.21.4 - version: 3.21.4 + version: 3.22.4 devDependencies: '@latticexyz/abi-ts': specifier: workspace:* @@ -1134,7 +1131,7 @@ importers: version: link:../gas-report '@types/ejs': specifier: ^3.1.1 - version: 3.1.1 + version: 3.1.5 '@types/glob': specifier: ^7.2.0 version: 7.2.0 @@ -1143,34 +1140,39 @@ importers: version: 9.1.1 '@types/node': specifier: ^18.15.11 - version: 18.15.11 + version: 18.19.21 ds-test: specifier: https://github.com/dapphub/ds-test.git#e282159d5170298eb2455a6c05280ab5a73a4ef0 version: github.com/dapphub/ds-test/e282159d5170298eb2455a6c05280ab5a73a4ef0 ejs: specifier: ^3.1.8 - version: 3.1.8 + version: 3.1.9 forge-std: specifier: https://github.com/foundry-rs/forge-std.git#74cfb77e308dd188d2f58864aaf44963ae6b88b1 version: github.com/foundry-rs/forge-std/74cfb77e308dd188d2f58864aaf44963ae6b88b1 glob: specifier: ^8.0.3 - version: 8.0.3 + version: 8.1.0 solhint: specifier: ^3.3.7 - version: 3.3.7 + version: 3.6.2(typescript@5.1.6) tsup: specifier: ^6.7.0 - version: 6.7.0(postcss@8.4.23)(typescript@5.1.6) + version: 6.7.0(postcss@8.4.35)(typescript@5.1.6) tsx: specifier: ^3.12.6 - version: 3.12.6 + version: 3.14.0 vitest: specifier: 0.34.6 version: 0.34.6(jsdom@22.1.0) packages: + /@aashutoshrathi/word-wrap@1.2.6: + resolution: {integrity: sha512-1Yjs2SvM8TflER/OD3cOjhWWOZb58A2t7wpE2S9XfBYTiIl+XFhQG2bjy4Pu1I+EAlCNUzRDYDdFwFYUKvXcIA==} + engines: {node: '>=0.10.0'} + dev: true + /@adraffy/ens-normalize@1.10.0: resolution: {integrity: sha512-nA9XHtlAkYfJxY7bce8DcN7eKxWWCWkU+1GR9d+U6MbNpfwQp8TI7vqOsBsMcHoT4mBu2kypKoSKnghEzOOq5Q==} dev: false @@ -1184,362 +1186,358 @@ packages: resolution: {integrity: sha512-lFMjJTrFL3j7L9yBxwYfCq2k6qqwHyzuUl/XBnif78PWTJYyL/dfowQHWE3sp6U6ZzqWiiIZnpTMO96zhkjwtg==} engines: {node: '>=6.0.0'} dependencies: - '@jridgewell/gen-mapping': 0.3.3 - '@jridgewell/trace-mapping': 0.3.18 + '@jridgewell/gen-mapping': 0.3.4 + '@jridgewell/trace-mapping': 0.3.23 dev: true - /@babel/code-frame@7.21.4: - resolution: {integrity: sha512-LYvhNKfwWSPpocw8GI7gpK2nq3HSDuEPC/uSYaALSJu9xjsalaaYFOq0Pwt5KmVqwEbZlDu81aLXwBOmD/Fv9g==} + /@babel/code-frame@7.23.5: + resolution: {integrity: sha512-CgH3s1a96LipHCmSUmYFPwY7MNx8C3avkq7i4Wl3cfa662ldtUe4VM1TPXX70pfmrlWTb6jLqTYrZyT2ZTJBgA==} engines: {node: '>=6.9.0'} dependencies: - '@babel/highlight': 7.18.6 + '@babel/highlight': 7.23.4 + chalk: 2.4.2 dev: true - /@babel/compat-data@7.21.4: - resolution: {integrity: sha512-/DYyDpeCfaVinT40FPGdkkb+lYSKvsVuMjDAG7jPOWWiM1ibOaB9CXJAlc4d1QpP/U2q2P9jbrSlClKSErd55g==} + /@babel/compat-data@7.23.5: + resolution: {integrity: sha512-uU27kfDRlhfKl+w1U6vp16IuvSLtjAxdArVXPa9BvLkrr7CYIsxH5adpHObeAGY/41+syctUWOZ140a2Rvkgjw==} engines: {node: '>=6.9.0'} dev: true - /@babel/core@7.21.4: - resolution: {integrity: sha512-qt/YV149Jman/6AfmlxJ04LMIu8bMoyl3RB91yTFrxQmgbrSvQMy7cI8Q62FHx1t8wJ8B5fu0UDoLwHAhUo1QA==} + /@babel/core@7.24.0: + resolution: {integrity: sha512-fQfkg0Gjkza3nf0c7/w6Xf34BW4YvzNfACRLmmb7XRLa6XHdR+K9AlJlxneFfWYf6uhOzuzZVTjF/8KfndZANw==} engines: {node: '>=6.9.0'} dependencies: '@ampproject/remapping': 2.2.1 - '@babel/code-frame': 7.21.4 - '@babel/generator': 7.21.4 - '@babel/helper-compilation-targets': 7.21.4(@babel/core@7.21.4) - '@babel/helper-module-transforms': 7.21.2 - '@babel/helpers': 7.21.0 - '@babel/parser': 7.21.4 - '@babel/template': 7.20.7 - '@babel/traverse': 7.21.4 - '@babel/types': 7.21.4 - convert-source-map: 1.9.0 + '@babel/code-frame': 7.23.5 + '@babel/generator': 7.23.6 + '@babel/helper-compilation-targets': 7.23.6 + '@babel/helper-module-transforms': 7.23.3(@babel/core@7.24.0) + '@babel/helpers': 7.24.0 + '@babel/parser': 7.24.0 + '@babel/template': 7.24.0 + '@babel/traverse': 7.24.0 + '@babel/types': 7.24.0 + convert-source-map: 2.0.0 debug: 4.3.4(supports-color@8.1.1) gensync: 1.0.0-beta.2 json5: 2.2.3 - semver: 6.3.0 + semver: 6.3.1 transitivePeerDependencies: - supports-color dev: true - /@babel/generator@7.21.4: - resolution: {integrity: sha512-NieM3pVIYW2SwGzKoqfPrQsf4xGs9M9AIG3ThppsSRmO+m7eQhmI6amajKMUeIO37wFfsvnvcxQFx6x6iqxDnA==} + /@babel/generator@7.23.6: + resolution: {integrity: sha512-qrSfCYxYQB5owCmGLbl8XRpX1ytXlpueOb0N0UmQwA073KZxejgQTzAmJezxvpwQD9uGtK2shHdi55QT+MbjIw==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.21.4 - '@jridgewell/gen-mapping': 0.3.3 - '@jridgewell/trace-mapping': 0.3.18 + '@babel/types': 7.24.0 + '@jridgewell/gen-mapping': 0.3.4 + '@jridgewell/trace-mapping': 0.3.23 jsesc: 2.5.2 dev: true - /@babel/helper-compilation-targets@7.21.4(@babel/core@7.21.4): - resolution: {integrity: sha512-Fa0tTuOXZ1iL8IeDFUWCzjZcn+sJGd9RZdH9esYVjEejGmzf+FFYQpMi/kZUk2kPy/q1H3/GPw7np8qar/stfg==} + /@babel/helper-compilation-targets@7.23.6: + resolution: {integrity: sha512-9JB548GZoQVmzrFgp8o7KxdgkTGm6xs9DW0o/Pim72UDjzr5ObUQ6ZzYPqA+g9OTS2bBQoctLJrky0RDCAWRgQ==} engines: {node: '>=6.9.0'} - peerDependencies: - '@babel/core': ^7.0.0 dependencies: - '@babel/compat-data': 7.21.4 - '@babel/core': 7.21.4 - '@babel/helper-validator-option': 7.21.0 - browserslist: 4.21.5 + '@babel/compat-data': 7.23.5 + '@babel/helper-validator-option': 7.23.5 + browserslist: 4.23.0 lru-cache: 5.1.1 - semver: 6.3.0 + semver: 6.3.1 dev: true - /@babel/helper-environment-visitor@7.18.9: - resolution: {integrity: sha512-3r/aACDJ3fhQ/EVgFy0hpj8oHyHpQc+LPtJoY9SzTThAsStm4Ptegq92vqKoE3vD706ZVFWITnMnxucw+S9Ipg==} + /@babel/helper-environment-visitor@7.22.20: + resolution: {integrity: sha512-zfedSIzFhat/gFhWfHtgWvlec0nqB9YEIVrpuwjruLlXfUSnA8cJB0miHKwqDnQ7d32aKo2xt88/xZptwxbfhA==} engines: {node: '>=6.9.0'} dev: true - /@babel/helper-function-name@7.21.0: - resolution: {integrity: sha512-HfK1aMRanKHpxemaY2gqBmL04iAPOPRj7DxtNbiDOrJK+gdwkiNRVpCpUJYbUT+aZyemKN8brqTOxzCaG6ExRg==} + /@babel/helper-function-name@7.23.0: + resolution: {integrity: sha512-OErEqsrxjZTJciZ4Oo+eoZqeW9UIiOcuYKRJA4ZAgV9myA+pOXhhmpfNCKjEH/auVfEYVFJ6y1Tc4r0eIApqiw==} engines: {node: '>=6.9.0'} dependencies: - '@babel/template': 7.20.7 - '@babel/types': 7.21.4 + '@babel/template': 7.24.0 + '@babel/types': 7.24.0 dev: true - /@babel/helper-hoist-variables@7.18.6: - resolution: {integrity: sha512-UlJQPkFqFULIcyW5sbzgbkxn2FKRgwWiRexcuaR8RNJRy8+LLveqPjwZV/bwrLZCN0eUHD/x8D0heK1ozuoo6Q==} + /@babel/helper-hoist-variables@7.22.5: + resolution: {integrity: sha512-wGjk9QZVzvknA6yKIUURb8zY3grXCcOZt+/7Wcy8O2uctxhplmUPkOdlgoNhmdVee2c92JXbf1xpMtVNbfoxRw==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.21.4 + '@babel/types': 7.24.0 dev: true - /@babel/helper-module-imports@7.18.6: - resolution: {integrity: sha512-0NFvs3VkuSYbFi1x2Vd6tKrywq+z/cLeYC/RJNFrIX/30Bf5aiGYbtvGXolEktzJH8o5E5KJ3tT+nkxuuZFVlA==} + /@babel/helper-module-imports@7.22.15: + resolution: {integrity: sha512-0pYVBnDKZO2fnSPCrgM/6WMc7eS20Fbok+0r88fp+YtWVLZrp4CkafFGIp+W0VKw4a22sgebPT99y+FDNMdP4w==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.21.4 + '@babel/types': 7.24.0 dev: true - /@babel/helper-module-transforms@7.21.2: - resolution: {integrity: sha512-79yj2AR4U/Oqq/WOV7Lx6hUjau1Zfo4cI+JLAVYeMV5XIlbOhmjEk5ulbTc9fMpmlojzZHkUUxAiK+UKn+hNQQ==} + /@babel/helper-module-transforms@7.23.3(@babel/core@7.24.0): + resolution: {integrity: sha512-7bBs4ED9OmswdfDzpz4MpWgSrV7FXlc3zIagvLFjS5H+Mk7Snr21vQ6QwrsoCGMfNC4e4LQPdoULEt4ykz0SRQ==} engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0 dependencies: - '@babel/helper-environment-visitor': 7.18.9 - '@babel/helper-module-imports': 7.18.6 - '@babel/helper-simple-access': 7.20.2 - '@babel/helper-split-export-declaration': 7.18.6 - '@babel/helper-validator-identifier': 7.19.1 - '@babel/template': 7.20.7 - '@babel/traverse': 7.21.4 - '@babel/types': 7.21.4 - transitivePeerDependencies: - - supports-color + '@babel/core': 7.24.0 + '@babel/helper-environment-visitor': 7.22.20 + '@babel/helper-module-imports': 7.22.15 + '@babel/helper-simple-access': 7.22.5 + '@babel/helper-split-export-declaration': 7.22.6 + '@babel/helper-validator-identifier': 7.22.20 dev: true - /@babel/helper-plugin-utils@7.20.2: - resolution: {integrity: sha512-8RvlJG2mj4huQ4pZ+rU9lqKi9ZKiRmuvGuM2HlWmkmgOhbs6zEAw6IEiJ5cQqGbDzGZOhwuOQNtZMi/ENLjZoQ==} + /@babel/helper-plugin-utils@7.24.0: + resolution: {integrity: sha512-9cUznXMG0+FxRuJfvL82QlTqIzhVW9sL0KjMPHhAOOvpQGL8QtdxnBKILjBqxlHyliz0yCa1G903ZXI/FuHy2w==} engines: {node: '>=6.9.0'} dev: true - /@babel/helper-simple-access@7.20.2: - resolution: {integrity: sha512-+0woI/WPq59IrqDYbVGfshjT5Dmk/nnbdpcF8SnMhhXObpTq2KNBdLFRFrkVdbDOyUmHBCxzm5FHV1rACIkIbA==} + /@babel/helper-simple-access@7.22.5: + resolution: {integrity: sha512-n0H99E/K+Bika3++WNL17POvo4rKWZ7lZEp1Q+fStVbUi8nxPQEBOlTmCOxW/0JsS56SKKQ+ojAe2pHKJHN35w==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.21.4 + '@babel/types': 7.24.0 dev: true - /@babel/helper-split-export-declaration@7.18.6: - resolution: {integrity: sha512-bde1etTx6ZyTmobl9LLMMQsaizFVZrquTEHOqKeQESMKo4PlObf+8+JA25ZsIpZhT/WEd39+vOdLXAFG/nELpA==} + /@babel/helper-split-export-declaration@7.22.6: + resolution: {integrity: sha512-AsUnxuLhRYsisFiaJwvp1QF+I3KjD5FOxut14q/GzovUe6orHLesW2C7d754kRm53h5gqrz6sFl6sxc4BVtE/g==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.21.4 + '@babel/types': 7.24.0 dev: true - /@babel/helper-string-parser@7.19.4: - resolution: {integrity: sha512-nHtDoQcuqFmwYNYPz3Rah5ph2p8PFeFCsZk9A/48dPc/rGocJ5J3hAAZ7pb76VWX3fZKu+uEr/FhH5jLx7umrw==} + /@babel/helper-string-parser@7.23.4: + resolution: {integrity: sha512-803gmbQdqwdf4olxrX4AJyFBV/RTr3rSmOj0rKwesmzlfhYNDEs+/iOcznzpNWlJlIlTJC2QfPFcHB6DlzdVLQ==} engines: {node: '>=6.9.0'} dev: true - /@babel/helper-validator-identifier@7.19.1: - resolution: {integrity: sha512-awrNfaMtnHUr653GgGEs++LlAvW6w+DcPrOliSMXWCKo597CwL5Acf/wWdNkf/tfEQE3mjkeD1YOVZOUV/od1w==} + /@babel/helper-validator-identifier@7.22.20: + resolution: {integrity: sha512-Y4OZ+ytlatR8AI+8KZfKuL5urKp7qey08ha31L8b3BwewJAoJamTzyvxPR/5D+KkdJCGPq/+8TukHBlY10FX9A==} engines: {node: '>=6.9.0'} dev: true - /@babel/helper-validator-option@7.21.0: - resolution: {integrity: sha512-rmL/B8/f0mKS2baE9ZpyTcTavvEuWhTTW8amjzXNvYG4AwBsqTLikfXsEofsJEfKHf+HQVQbFOHy6o+4cnC/fQ==} + /@babel/helper-validator-option@7.23.5: + resolution: {integrity: sha512-85ttAOMLsr53VgXkTbkx8oA6YTfT4q7/HzXSLEYmjcSTJPMPQtvq1BD79Byep5xMUYbGRzEpDsjUf3dyp54IKw==} engines: {node: '>=6.9.0'} dev: true - /@babel/helpers@7.21.0: - resolution: {integrity: sha512-XXve0CBtOW0pd7MRzzmoyuSj0e3SEzj8pgyFxnTT1NJZL38BD1MK7yYrm8yefRPIDvNNe14xR4FdbHwpInD4rA==} + /@babel/helpers@7.24.0: + resolution: {integrity: sha512-ulDZdc0Aj5uLc5nETsa7EPx2L7rM0YJM8r7ck7U73AXi7qOV44IHHRAYZHY6iU1rr3C5N4NtTmMRUJP6kwCWeA==} engines: {node: '>=6.9.0'} dependencies: - '@babel/template': 7.20.7 - '@babel/traverse': 7.21.4 - '@babel/types': 7.21.4 + '@babel/template': 7.24.0 + '@babel/traverse': 7.24.0 + '@babel/types': 7.24.0 transitivePeerDependencies: - supports-color dev: true - /@babel/highlight@7.18.6: - resolution: {integrity: sha512-u7stbOuYjaPezCuLj29hNW1v64M2Md2qupEKP1fHc7WdOA3DgLh37suiSrZYY7haUB7iBeQZ9P1uiRF359do3g==} + /@babel/highlight@7.23.4: + resolution: {integrity: sha512-acGdbYSfp2WheJoJm/EBBBLh/ID8KDc64ISZ9DYtBmC8/Q204PZJLHyzeB5qMzJ5trcOkybd78M4x2KWsUq++A==} engines: {node: '>=6.9.0'} dependencies: - '@babel/helper-validator-identifier': 7.19.1 + '@babel/helper-validator-identifier': 7.22.20 chalk: 2.4.2 js-tokens: 4.0.0 dev: true - /@babel/parser@7.21.4: - resolution: {integrity: sha512-alVJj7k7zIxqBZ7BTRhz0IqJFxW1VJbm6N8JbcYhQ186df9ZBPbZBmWSqAMXwHGsCJdYks7z/voa3ibiS5bCIw==} + /@babel/parser@7.24.0: + resolution: {integrity: sha512-QuP/FxEAzMSjXygs8v4N9dvdXzEHN4W1oF3PxuWAtPo08UdM17u89RDMgjLn/mlc56iM0HlLmVkO/wgR+rDgHg==} engines: {node: '>=6.0.0'} hasBin: true dependencies: - '@babel/types': 7.21.4 + '@babel/types': 7.24.0 dev: true - /@babel/plugin-syntax-async-generators@7.8.4(@babel/core@7.21.4): + /@babel/plugin-syntax-async-generators@7.8.4(@babel/core@7.24.0): resolution: {integrity: sha512-tycmZxkGfZaxhMRbXlPXuVFpdWlXpir2W4AMhSJgRKzk/eDlIXOhb2LHWoLpDF7TEHylV5zNhykX6KAgHJmTNw==} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.21.4 - '@babel/helper-plugin-utils': 7.20.2 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-syntax-bigint@7.8.3(@babel/core@7.21.4): + /@babel/plugin-syntax-bigint@7.8.3(@babel/core@7.24.0): resolution: {integrity: sha512-wnTnFlG+YxQm3vDxpGE57Pj0srRU4sHE/mDkt1qv2YJJSeUAec2ma4WLUnUPeKjyrfntVwe/N6dCXpU+zL3Npg==} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.21.4 - '@babel/helper-plugin-utils': 7.20.2 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-syntax-class-properties@7.12.13(@babel/core@7.21.4): + /@babel/plugin-syntax-class-properties@7.12.13(@babel/core@7.24.0): resolution: {integrity: sha512-fm4idjKla0YahUNgFNLCB0qySdsoPiZP3iQE3rky0mBUtMZ23yDJ9SJdg6dXTSDnulOVqiF3Hgr9nbXvXTQZYA==} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.21.4 - '@babel/helper-plugin-utils': 7.20.2 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-syntax-import-meta@7.10.4(@babel/core@7.21.4): + /@babel/plugin-syntax-import-meta@7.10.4(@babel/core@7.24.0): resolution: {integrity: sha512-Yqfm+XDx0+Prh3VSeEQCPU81yC+JWZ2pDPFSS4ZdpfZhp4MkFMaDC1UqseovEKwSUpnIL7+vK+Clp7bfh0iD7g==} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.21.4 - '@babel/helper-plugin-utils': 7.20.2 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-syntax-json-strings@7.8.3(@babel/core@7.21.4): + /@babel/plugin-syntax-json-strings@7.8.3(@babel/core@7.24.0): resolution: {integrity: sha512-lY6kdGpWHvjoe2vk4WrAapEuBR69EMxZl+RoGRhrFGNYVK8mOPAW8VfbT/ZgrFbXlDNiiaxQnAtgVCZ6jv30EA==} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.21.4 - '@babel/helper-plugin-utils': 7.20.2 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-syntax-jsx@7.18.6(@babel/core@7.21.4): - resolution: {integrity: sha512-6mmljtAedFGTWu2p/8WIORGwy+61PLgOMPOdazc7YoJ9ZCWUyFy3A6CpPkRKLKD1ToAesxX8KGEViAiLo9N+7Q==} + /@babel/plugin-syntax-jsx@7.23.3(@babel/core@7.24.0): + resolution: {integrity: sha512-EB2MELswq55OHUoRZLGg/zC7QWUKfNLpE57m/S2yr1uEneIgsTgrSzXP3NXEsMkVn76OlaVVnzN+ugObuYGwhg==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.21.4 - '@babel/helper-plugin-utils': 7.20.2 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-syntax-logical-assignment-operators@7.10.4(@babel/core@7.21.4): + /@babel/plugin-syntax-logical-assignment-operators@7.10.4(@babel/core@7.24.0): resolution: {integrity: sha512-d8waShlpFDinQ5MtvGU9xDAOzKH47+FFoney2baFIoMr952hKOLp1HR7VszoZvOsV/4+RRszNY7D17ba0te0ig==} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.21.4 - '@babel/helper-plugin-utils': 7.20.2 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-syntax-nullish-coalescing-operator@7.8.3(@babel/core@7.21.4): + /@babel/plugin-syntax-nullish-coalescing-operator@7.8.3(@babel/core@7.24.0): resolution: {integrity: sha512-aSff4zPII1u2QD7y+F8oDsz19ew4IGEJg9SVW+bqwpwtfFleiQDMdzA/R+UlWDzfnHFCxxleFT0PMIrR36XLNQ==} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.21.4 - '@babel/helper-plugin-utils': 7.20.2 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-syntax-numeric-separator@7.10.4(@babel/core@7.21.4): + /@babel/plugin-syntax-numeric-separator@7.10.4(@babel/core@7.24.0): resolution: {integrity: sha512-9H6YdfkcK/uOnY/K7/aA2xpzaAgkQn37yzWUMRK7OaPOqOpGS1+n0H5hxT9AUw9EsSjPW8SVyMJwYRtWs3X3ug==} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.21.4 - '@babel/helper-plugin-utils': 7.20.2 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-syntax-object-rest-spread@7.8.3(@babel/core@7.21.4): + /@babel/plugin-syntax-object-rest-spread@7.8.3(@babel/core@7.24.0): resolution: {integrity: sha512-XoqMijGZb9y3y2XskN+P1wUGiVwWZ5JmoDRwx5+3GmEplNyVM2s2Dg8ILFQm8rWM48orGy5YpI5Bl8U1y7ydlA==} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.21.4 - '@babel/helper-plugin-utils': 7.20.2 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-syntax-optional-catch-binding@7.8.3(@babel/core@7.21.4): + /@babel/plugin-syntax-optional-catch-binding@7.8.3(@babel/core@7.24.0): resolution: {integrity: sha512-6VPD0Pc1lpTqw0aKoeRTMiB+kWhAoT24PA+ksWSBrFtl5SIRVpZlwN3NNPQjehA2E/91FV3RjLWoVTglWcSV3Q==} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.21.4 - '@babel/helper-plugin-utils': 7.20.2 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-syntax-optional-chaining@7.8.3(@babel/core@7.21.4): + /@babel/plugin-syntax-optional-chaining@7.8.3(@babel/core@7.24.0): resolution: {integrity: sha512-KoK9ErH1MBlCPxV0VANkXW2/dw4vlbGDrFgz8bmUsBGYkFRcbRwMh6cIJubdPrkxRwuGdtCk0v/wPTKbQgBjkg==} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.21.4 - '@babel/helper-plugin-utils': 7.20.2 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-syntax-top-level-await@7.14.5(@babel/core@7.21.4): + /@babel/plugin-syntax-top-level-await@7.14.5(@babel/core@7.24.0): resolution: {integrity: sha512-hx++upLv5U1rgYfwe1xBQUhRmU41NEvpUvrp8jkrSCdvGSnM5/qdRMtylJ6PG5OFkBaHkbTAKTnd3/YyESRHFw==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.21.4 - '@babel/helper-plugin-utils': 7.20.2 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-syntax-typescript@7.20.0(@babel/core@7.21.4): - resolution: {integrity: sha512-rd9TkG+u1CExzS4SM1BlMEhMXwFLKVjOAFFCDx9PbX5ycJWDoWMcwdJH9RhkPu1dOgn5TrxLot/Gx6lWFuAUNQ==} + /@babel/plugin-syntax-typescript@7.23.3(@babel/core@7.24.0): + resolution: {integrity: sha512-9EiNjVJOMwCO+43TqoTrgQ8jMwcAd0sWyXi9RPfIsLTj4R2MADDDQXELhffaUx/uJv2AYcxBgPwH6j4TIA4ytQ==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.21.4 - '@babel/helper-plugin-utils': 7.20.2 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-transform-react-jsx-self@7.21.0(@babel/core@7.21.4): - resolution: {integrity: sha512-f/Eq+79JEu+KUANFks9UZCcvydOOGMgF7jBrcwjHa5jTZD8JivnhCJYvmlhR/WTXBWonDExPoW0eO/CR4QJirA==} + /@babel/plugin-transform-react-jsx-self@7.23.3(@babel/core@7.24.0): + resolution: {integrity: sha512-qXRvbeKDSfwnlJnanVRp0SfuWE5DQhwQr5xtLBzp56Wabyo+4CMosF6Kfp+eOD/4FYpql64XVJ2W0pVLlJZxOQ==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.21.4 - '@babel/helper-plugin-utils': 7.20.2 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-transform-react-jsx-source@7.19.6(@babel/core@7.21.4): - resolution: {integrity: sha512-RpAi004QyMNisst/pvSanoRdJ4q+jMCWyk9zdw/CyLB9j8RXEahodR6l2GyttDRyEVWZtbN+TpLiHJ3t34LbsQ==} + /@babel/plugin-transform-react-jsx-source@7.23.3(@babel/core@7.24.0): + resolution: {integrity: sha512-91RS0MDnAWDNvGC6Wio5XYkyWI39FMFO+JK9+4AlgaTH+yWwVTsw7/sn6LK0lH7c5F+TFkpv/3LfCJ1Ydwof/g==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.21.4 - '@babel/helper-plugin-utils': 7.20.2 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/runtime@7.21.0: - resolution: {integrity: sha512-xwII0//EObnq89Ji5AKYQaRYiW/nZ3llSv29d49IuxPhKbtJoLP+9QUUZ4nVragQVtaVGeZrpB+ZtG/Pdy/POw==} + /@babel/runtime@7.24.0: + resolution: {integrity: sha512-Chk32uHMg6TnQdvw2e9IlqPpFX/6NLuK0Ys2PqLb7/gL5uFn9mXvK715FGLlOLQrcO4qIkNHkvPGktzzXexsFw==} engines: {node: '>=6.9.0'} dependencies: - regenerator-runtime: 0.13.11 + regenerator-runtime: 0.14.1 - /@babel/template@7.20.7: - resolution: {integrity: sha512-8SegXApWe6VoNw0r9JHpSteLKTpTiLZ4rMlGIm9JQ18KiCtyQiAMEazujAHrUS5flrcqYZa75ukev3P6QmUwUw==} + /@babel/template@7.24.0: + resolution: {integrity: sha512-Bkf2q8lMB0AFpX0NFEqSbx1OkTHf0f+0j82mkw+ZpzBnkk7e9Ql0891vlfgi+kHwOk8tQjiQHpqh4LaSa0fKEA==} engines: {node: '>=6.9.0'} dependencies: - '@babel/code-frame': 7.21.4 - '@babel/parser': 7.21.4 - '@babel/types': 7.21.4 + '@babel/code-frame': 7.23.5 + '@babel/parser': 7.24.0 + '@babel/types': 7.24.0 dev: true - /@babel/traverse@7.21.4: - resolution: {integrity: sha512-eyKrRHKdyZxqDm+fV1iqL9UAHMoIg0nDaGqfIOd8rKH17m5snv7Gn4qgjBoFfLz9APvjFU/ICT00NVCv1Epp8Q==} + /@babel/traverse@7.24.0: + resolution: {integrity: sha512-HfuJlI8qq3dEDmNU5ChzzpZRWq+oxCZQyMzIMEqLho+AQnhMnKQUzH6ydo3RBl/YjPCuk68Y6s0Gx0AeyULiWw==} engines: {node: '>=6.9.0'} dependencies: - '@babel/code-frame': 7.21.4 - '@babel/generator': 7.21.4 - '@babel/helper-environment-visitor': 7.18.9 - '@babel/helper-function-name': 7.21.0 - '@babel/helper-hoist-variables': 7.18.6 - '@babel/helper-split-export-declaration': 7.18.6 - '@babel/parser': 7.21.4 - '@babel/types': 7.21.4 + '@babel/code-frame': 7.23.5 + '@babel/generator': 7.23.6 + '@babel/helper-environment-visitor': 7.22.20 + '@babel/helper-function-name': 7.23.0 + '@babel/helper-hoist-variables': 7.22.5 + '@babel/helper-split-export-declaration': 7.22.6 + '@babel/parser': 7.24.0 + '@babel/types': 7.24.0 debug: 4.3.4(supports-color@8.1.1) globals: 11.12.0 transitivePeerDependencies: - supports-color dev: true - /@babel/types@7.21.4: - resolution: {integrity: sha512-rU2oY501qDxE8Pyo7i/Orqma4ziCOrby0/9mvbDUGEfvZjb279Nk9k19e2fiCxHbRRpY2ZyrgW1eq22mvmOIzA==} + /@babel/types@7.24.0: + resolution: {integrity: sha512-+j7a5c253RfKh8iABBhywc8NSfP5LURe7Uh4qpsh6jc+aLJguvmIUBdjSdEMQv2bENrCR5MfRdjGo7vzS/ob7w==} engines: {node: '>=6.9.0'} dependencies: - '@babel/helper-string-parser': 7.19.4 - '@babel/helper-validator-identifier': 7.19.1 + '@babel/helper-string-parser': 7.23.4 + '@babel/helper-validator-identifier': 7.22.20 to-fast-properties: 2.0.0 dev: true @@ -1547,167 +1545,166 @@ packages: resolution: {integrity: sha512-0hYQ8SB4Db5zvZB4axdMHGwEaQjkZzFjQiN9LVYvIFB2nSUHW9tYpxWriPrWDASIxiaXax83REcLxuSdnGPZtw==} dev: true - /@changesets/apply-release-plan@6.1.3: - resolution: {integrity: sha512-ECDNeoc3nfeAe1jqJb5aFQX7CqzQhD2klXRez2JDb/aVpGUbX673HgKrnrgJRuQR/9f2TtLoYIzrGB9qwD77mg==} + /@changesets/apply-release-plan@7.0.0: + resolution: {integrity: sha512-vfi69JR416qC9hWmFGSxj7N6wA5J222XNBmezSVATPWDVPIF7gkd4d8CpbEbXmRWbVrkoli3oerGS6dcL/BGsQ==} dependencies: - '@babel/runtime': 7.21.0 - '@changesets/config': 2.3.0 - '@changesets/get-version-range-type': 0.3.2 - '@changesets/git': 2.0.0 - '@changesets/types': 5.2.1 + '@babel/runtime': 7.24.0 + '@changesets/config': 3.0.0 + '@changesets/get-version-range-type': 0.4.0 + '@changesets/git': 3.0.0 + '@changesets/types': 6.0.0 '@manypkg/get-packages': 1.1.3 detect-indent: 6.1.0 fs-extra: 7.0.1 lodash.startcase: 4.4.0 outdent: 0.5.0 - prettier: 2.8.4 + prettier: 2.8.8 resolve-from: 5.0.0 - semver: 5.7.1 + semver: 7.6.0 dev: true - /@changesets/assemble-release-plan@5.2.3: - resolution: {integrity: sha512-g7EVZCmnWz3zMBAdrcKhid4hkHT+Ft1n0mLussFMcB1dE2zCuwcvGoy9ec3yOgPGF4hoMtgHaMIk3T3TBdvU9g==} + /@changesets/assemble-release-plan@6.0.0: + resolution: {integrity: sha512-4QG7NuisAjisbW4hkLCmGW2lRYdPrKzro+fCtZaILX+3zdUELSvYjpL4GTv0E4aM9Mef3PuIQp89VmHJ4y2bfw==} dependencies: - '@babel/runtime': 7.21.0 - '@changesets/errors': 0.1.4 - '@changesets/get-dependents-graph': 1.3.5 - '@changesets/types': 5.2.1 + '@babel/runtime': 7.24.0 + '@changesets/errors': 0.2.0 + '@changesets/get-dependents-graph': 2.0.0 + '@changesets/types': 6.0.0 '@manypkg/get-packages': 1.1.3 - semver: 5.7.1 + semver: 7.6.0 dev: true - /@changesets/changelog-git@0.1.14: - resolution: {integrity: sha512-+vRfnKtXVWsDDxGctOfzJsPhaCdXRYoe+KyWYoq5X/GqoISREiat0l3L8B0a453B2B4dfHGcZaGyowHbp9BSaA==} + /@changesets/changelog-git@0.2.0: + resolution: {integrity: sha512-bHOx97iFI4OClIT35Lok3sJAwM31VbUM++gnMBV16fdbtBhgYu4dxsphBF/0AZZsyAHMrnM0yFcj5gZM1py6uQ==} dependencies: - '@changesets/types': 5.2.1 + '@changesets/types': 6.0.0 dev: true - /@changesets/cli@2.26.1: - resolution: {integrity: sha512-XnTa+b51vt057fyAudvDKGB0Sh72xutQZNAdXkCqPBKO2zvs2yYZx5hFZj1u9cbtpwM6Sxtcr02/FQJfZOzemQ==} + /@changesets/cli@2.27.1: + resolution: {integrity: sha512-iJ91xlvRnnrJnELTp4eJJEOPjgpF3NOh4qeQehM6Ugiz9gJPRZ2t+TsXun6E3AMN4hScZKjqVXl0TX+C7AB3ZQ==} hasBin: true dependencies: - '@babel/runtime': 7.21.0 - '@changesets/apply-release-plan': 6.1.3 - '@changesets/assemble-release-plan': 5.2.3 - '@changesets/changelog-git': 0.1.14 - '@changesets/config': 2.3.0 - '@changesets/errors': 0.1.4 - '@changesets/get-dependents-graph': 1.3.5 - '@changesets/get-release-plan': 3.0.16 - '@changesets/git': 2.0.0 - '@changesets/logger': 0.0.5 - '@changesets/pre': 1.0.14 - '@changesets/read': 0.5.9 - '@changesets/types': 5.2.1 - '@changesets/write': 0.2.3 + '@babel/runtime': 7.24.0 + '@changesets/apply-release-plan': 7.0.0 + '@changesets/assemble-release-plan': 6.0.0 + '@changesets/changelog-git': 0.2.0 + '@changesets/config': 3.0.0 + '@changesets/errors': 0.2.0 + '@changesets/get-dependents-graph': 2.0.0 + '@changesets/get-release-plan': 4.0.0 + '@changesets/git': 3.0.0 + '@changesets/logger': 0.1.0 + '@changesets/pre': 2.0.0 + '@changesets/read': 0.6.0 + '@changesets/types': 6.0.0 + '@changesets/write': 0.3.0 '@manypkg/get-packages': 1.1.3 - '@types/is-ci': 3.0.0 - '@types/semver': 6.2.3 + '@types/semver': 7.5.8 ansi-colors: 4.1.3 chalk: 2.4.2 - enquirer: 2.3.6 + ci-info: 3.9.0 + enquirer: 2.4.1 external-editor: 3.1.0 fs-extra: 7.0.1 human-id: 1.0.2 - is-ci: 3.0.1 meow: 6.1.1 outdent: 0.5.0 p-limit: 2.3.0 - preferred-pm: 3.0.3 + preferred-pm: 3.1.3 resolve-from: 5.0.0 - semver: 5.7.1 + semver: 7.6.0 spawndamnit: 2.0.0 term-size: 2.2.1 - tty-table: 4.2.1 + tty-table: 4.2.3 dev: true - /@changesets/config@2.3.0: - resolution: {integrity: sha512-EgP/px6mhCx8QeaMAvWtRrgyxW08k/Bx2tpGT+M84jEdX37v3VKfh4Cz1BkwrYKuMV2HZKeHOh8sHvja/HcXfQ==} + /@changesets/config@3.0.0: + resolution: {integrity: sha512-o/rwLNnAo/+j9Yvw9mkBQOZySDYyOr/q+wptRLcAVGlU6djOeP9v1nlalbL9MFsobuBVQbZCTp+dIzdq+CLQUA==} dependencies: - '@changesets/errors': 0.1.4 - '@changesets/get-dependents-graph': 1.3.5 - '@changesets/logger': 0.0.5 - '@changesets/types': 5.2.1 + '@changesets/errors': 0.2.0 + '@changesets/get-dependents-graph': 2.0.0 + '@changesets/logger': 0.1.0 + '@changesets/types': 6.0.0 '@manypkg/get-packages': 1.1.3 fs-extra: 7.0.1 micromatch: 4.0.5 dev: true - /@changesets/errors@0.1.4: - resolution: {integrity: sha512-HAcqPF7snsUJ/QzkWoKfRfXushHTu+K5KZLJWPb34s4eCZShIf8BFO3fwq6KU8+G7L5KdtN2BzQAXOSXEyiY9Q==} + /@changesets/errors@0.2.0: + resolution: {integrity: sha512-6BLOQUscTpZeGljvyQXlWOItQyU71kCdGz7Pi8H8zdw6BI0g3m43iL4xKUVPWtG+qrrL9DTjpdn8eYuCQSRpow==} dependencies: extendable-error: 0.1.7 dev: true - /@changesets/get-dependents-graph@1.3.5: - resolution: {integrity: sha512-w1eEvnWlbVDIY8mWXqWuYE9oKhvIaBhzqzo4ITSJY9hgoqQ3RoBqwlcAzg11qHxv/b8ReDWnMrpjpKrW6m1ZTA==} + /@changesets/get-dependents-graph@2.0.0: + resolution: {integrity: sha512-cafUXponivK4vBgZ3yLu944mTvam06XEn2IZGjjKc0antpenkYANXiiE6GExV/yKdsCnE8dXVZ25yGqLYZmScA==} dependencies: - '@changesets/types': 5.2.1 + '@changesets/types': 6.0.0 '@manypkg/get-packages': 1.1.3 chalk: 2.4.2 fs-extra: 7.0.1 - semver: 5.7.1 + semver: 7.6.0 dev: true - /@changesets/get-release-plan@3.0.16: - resolution: {integrity: sha512-OpP9QILpBp1bY2YNIKFzwigKh7Qe9KizRsZomzLe6pK8IUo8onkAAVUD8+JRKSr8R7d4+JRuQrfSSNlEwKyPYg==} + /@changesets/get-release-plan@4.0.0: + resolution: {integrity: sha512-9L9xCUeD/Tb6L/oKmpm8nyzsOzhdNBBbt/ZNcjynbHC07WW4E1eX8NMGC5g5SbM5z/V+MOrYsJ4lRW41GCbg3w==} dependencies: - '@babel/runtime': 7.21.0 - '@changesets/assemble-release-plan': 5.2.3 - '@changesets/config': 2.3.0 - '@changesets/pre': 1.0.14 - '@changesets/read': 0.5.9 - '@changesets/types': 5.2.1 + '@babel/runtime': 7.24.0 + '@changesets/assemble-release-plan': 6.0.0 + '@changesets/config': 3.0.0 + '@changesets/pre': 2.0.0 + '@changesets/read': 0.6.0 + '@changesets/types': 6.0.0 '@manypkg/get-packages': 1.1.3 dev: true - /@changesets/get-version-range-type@0.3.2: - resolution: {integrity: sha512-SVqwYs5pULYjYT4op21F2pVbcrca4qA/bAA3FmFXKMN7Y+HcO8sbZUTx3TAy2VXulP2FACd1aC7f2nTuqSPbqg==} + /@changesets/get-version-range-type@0.4.0: + resolution: {integrity: sha512-hwawtob9DryoGTpixy1D3ZXbGgJu1Rhr+ySH2PvTLHvkZuQ7sRT4oQwMh0hbqZH1weAooedEjRsbrWcGLCeyVQ==} dev: true - /@changesets/git@2.0.0: - resolution: {integrity: sha512-enUVEWbiqUTxqSnmesyJGWfzd51PY4H7mH9yUw0hPVpZBJ6tQZFMU3F3mT/t9OJ/GjyiM4770i+sehAn6ymx6A==} + /@changesets/git@3.0.0: + resolution: {integrity: sha512-vvhnZDHe2eiBNRFHEgMiGd2CT+164dfYyrJDhwwxTVD/OW0FUD6G7+4DIx1dNwkwjHyzisxGAU96q0sVNBns0w==} dependencies: - '@babel/runtime': 7.21.0 - '@changesets/errors': 0.1.4 - '@changesets/types': 5.2.1 + '@babel/runtime': 7.24.0 + '@changesets/errors': 0.2.0 + '@changesets/types': 6.0.0 '@manypkg/get-packages': 1.1.3 is-subdir: 1.2.0 micromatch: 4.0.5 spawndamnit: 2.0.0 dev: true - /@changesets/logger@0.0.5: - resolution: {integrity: sha512-gJyZHomu8nASHpaANzc6bkQMO9gU/ib20lqew1rVx753FOxffnCrJlGIeQVxNWCqM+o6OOleCo/ivL8UAO5iFw==} + /@changesets/logger@0.1.0: + resolution: {integrity: sha512-pBrJm4CQm9VqFVwWnSqKEfsS2ESnwqwH+xR7jETxIErZcfd1u2zBSqrHbRHR7xjhSgep9x2PSKFKY//FAshA3g==} dependencies: chalk: 2.4.2 dev: true - /@changesets/parse@0.3.16: - resolution: {integrity: sha512-127JKNd167ayAuBjUggZBkmDS5fIKsthnr9jr6bdnuUljroiERW7FBTDNnNVyJ4l69PzR57pk6mXQdtJyBCJKg==} + /@changesets/parse@0.4.0: + resolution: {integrity: sha512-TS/9KG2CdGXS27S+QxbZXgr8uPsP4yNJYb4BC2/NeFUj80Rni3TeD2qwWmabymxmrLo7JEsytXH1FbpKTbvivw==} dependencies: - '@changesets/types': 5.2.1 + '@changesets/types': 6.0.0 js-yaml: 3.14.1 dev: true - /@changesets/pre@1.0.14: - resolution: {integrity: sha512-dTsHmxQWEQekHYHbg+M1mDVYFvegDh9j/kySNuDKdylwfMEevTeDouR7IfHNyVodxZXu17sXoJuf2D0vi55FHQ==} + /@changesets/pre@2.0.0: + resolution: {integrity: sha512-HLTNYX/A4jZxc+Sq8D1AMBsv+1qD6rmmJtjsCJa/9MSRybdxh0mjbTvE6JYZQ/ZiQ0mMlDOlGPXTm9KLTU3jyw==} dependencies: - '@babel/runtime': 7.21.0 - '@changesets/errors': 0.1.4 - '@changesets/types': 5.2.1 + '@babel/runtime': 7.24.0 + '@changesets/errors': 0.2.0 + '@changesets/types': 6.0.0 '@manypkg/get-packages': 1.1.3 fs-extra: 7.0.1 dev: true - /@changesets/read@0.5.9: - resolution: {integrity: sha512-T8BJ6JS6j1gfO1HFq50kU3qawYxa4NTbI/ASNVVCBTsKquy2HYwM9r7ZnzkiMe8IEObAJtUVGSrePCOxAK2haQ==} + /@changesets/read@0.6.0: + resolution: {integrity: sha512-ZypqX8+/im1Fm98K4YcZtmLKgjs1kDQ5zHpc2U1qdtNBmZZfo/IBiG162RoP0CUF05tvp2y4IspH11PLnPxuuw==} dependencies: - '@babel/runtime': 7.21.0 - '@changesets/git': 2.0.0 - '@changesets/logger': 0.0.5 - '@changesets/parse': 0.3.16 - '@changesets/types': 5.2.1 + '@babel/runtime': 7.24.0 + '@changesets/git': 3.0.0 + '@changesets/logger': 0.1.0 + '@changesets/parse': 0.4.0 + '@changesets/types': 6.0.0 chalk: 2.4.2 fs-extra: 7.0.1 p-filter: 2.1.0 @@ -1717,52 +1714,30 @@ packages: resolution: {integrity: sha512-LDQvVDv5Kb50ny2s25Fhm3d9QSZimsoUGBsUioj6MC3qbMUCuC8GPIvk/M6IvXx3lYhAs0lwWUQLb+VIEUCECw==} dev: true - /@changesets/types@5.2.1: - resolution: {integrity: sha512-myLfHbVOqaq9UtUKqR/nZA/OY7xFjQMdfgfqeZIBK4d0hA6pgxArvdv8M+6NUzzBsjWLOtvApv8YHr4qM+Kpfg==} + /@changesets/types@6.0.0: + resolution: {integrity: sha512-b1UkfNulgKoWfqyHtzKS5fOZYSJO+77adgL7DLRDr+/7jhChN+QcHnbjiQVOz/U+Ts3PGNySq7diAItzDgugfQ==} dev: true - /@changesets/write@0.2.3: - resolution: {integrity: sha512-Dbamr7AIMvslKnNYsLFafaVORx4H0pvCA2MHqgtNCySMe1blImEyAEOzDmcgKAkgz4+uwoLz7demIrX+JBr/Xw==} + /@changesets/write@0.3.0: + resolution: {integrity: sha512-slGLb21fxZVUYbyea+94uFiD6ntQW0M2hIKNznFizDhZPDgn2c/fv1UzzlW43RVzh1BEDuIqW6hzlJ1OflNmcw==} dependencies: - '@babel/runtime': 7.21.0 - '@changesets/types': 5.2.1 + '@babel/runtime': 7.24.0 + '@changesets/types': 6.0.0 fs-extra: 7.0.1 human-id: 1.0.2 - prettier: 2.8.4 - dev: true - - /@esbuild-kit/cjs-loader@2.4.2: - resolution: {integrity: sha512-BDXFbYOJzT/NBEtp71cvsrGPwGAMGRB/349rwKuoxNSiKjPraNNnlK6MIIabViCjqZugu6j+xeMDlEkWdHHJSg==} - dependencies: - '@esbuild-kit/core-utils': 3.1.0 - get-tsconfig: 4.5.0 - dev: true - - /@esbuild-kit/core-utils@3.1.0: - resolution: {integrity: sha512-Uuk8RpCg/7fdHSceR1M6XbSZFSuMrxcePFuGgyvsBn+u339dk5OeL4jv2EojwTN2st/unJGsVm4qHWjWNmJ/tw==} - dependencies: - esbuild: 0.17.17 - source-map-support: 0.5.21 - dev: true - - /@esbuild-kit/esm-loader@2.5.5: - resolution: {integrity: sha512-Qwfvj/qoPbClxCRNuac1Du01r9gvNOT+pMYtJDapfB1eoGN1YlJ1BixLyL9WVENRx5RXgNLdfYdx/CuswlGhMw==} - dependencies: - '@esbuild-kit/core-utils': 3.1.0 - get-tsconfig: 4.5.0 + prettier: 2.8.8 dev: true - /@esbuild/android-arm64@0.17.15: - resolution: {integrity: sha512-0kOB6Y7Br3KDVgHeg8PRcvfLkq+AccreK///B4Z6fNZGr/tNHX0z2VywCc7PTeWp+bPvjA5WMvNXltHw5QjAIA==} + /@esbuild/android-arm64@0.17.19: + resolution: {integrity: sha512-KBMWvEZooR7+kzY0BtbTQn0OAYY7CsiydT63pVEaPtVYF0hXbUaOyZog37DKxK7NF3XacBJOpYT4adIJh+avxA==} engines: {node: '>=12'} cpu: [arm64] os: [android] requiresBuild: true - dev: false optional: true - /@esbuild/android-arm64@0.17.17: - resolution: {integrity: sha512-jaJ5IlmaDLFPNttv0ofcwy/cfeY4bh/n705Tgh+eLObbGtQBK3EPAu+CzL95JVE4nFAliyrnEu0d32Q5foavqg==} + /@esbuild/android-arm64@0.18.20: + resolution: {integrity: sha512-Nz4rJcchGDtENV0eMKUNa6L12zz2zBDXuhj/Vjh18zGqB44Bi7MBMSXjgunJgjRhCmKOjnPuZp4Mb6OKqtMHLQ==} engines: {node: '>=12'} cpu: [arm64] os: [android] @@ -1770,17 +1745,16 @@ packages: dev: true optional: true - /@esbuild/android-arm@0.17.15: - resolution: {integrity: sha512-sRSOVlLawAktpMvDyJIkdLI/c/kdRTOqo8t6ImVxg8yT7LQDUYV5Rp2FKeEosLr6ZCja9UjYAzyRSxGteSJPYg==} + /@esbuild/android-arm@0.17.19: + resolution: {integrity: sha512-rIKddzqhmav7MSmoFCmDIb6e2W57geRsM94gV2l38fzhXMwq7hZoClug9USI2pFRGL06f4IOPHHpFNOkWieR8A==} engines: {node: '>=12'} cpu: [arm] os: [android] requiresBuild: true - dev: false optional: true - /@esbuild/android-arm@0.17.17: - resolution: {integrity: sha512-E6VAZwN7diCa3labs0GYvhEPL2M94WLF8A+czO8hfjREXxba8Ng7nM5VxV+9ihNXIY1iQO1XxUU4P7hbqbICxg==} + /@esbuild/android-arm@0.18.20: + resolution: {integrity: sha512-fyi7TDI/ijKKNZTUJAQqiG5T7YjJXgnzkURqmGj13C6dCqckZBLdl4h7bkhHt/t0WP+zO9/zwroDvANaOqO5Sw==} engines: {node: '>=12'} cpu: [arm] os: [android] @@ -1788,17 +1762,16 @@ packages: dev: true optional: true - /@esbuild/android-x64@0.17.15: - resolution: {integrity: sha512-MzDqnNajQZ63YkaUWVl9uuhcWyEyh69HGpMIrf+acR4otMkfLJ4sUCxqwbCyPGicE9dVlrysI3lMcDBjGiBBcQ==} + /@esbuild/android-x64@0.17.19: + resolution: {integrity: sha512-uUTTc4xGNDT7YSArp/zbtmbhO0uEEK9/ETW29Wk1thYUJBz3IVnvgEiEwEa9IeLyvnpKrWK64Utw2bgUmDveww==} engines: {node: '>=12'} cpu: [x64] os: [android] requiresBuild: true - dev: false optional: true - /@esbuild/android-x64@0.17.17: - resolution: {integrity: sha512-446zpfJ3nioMC7ASvJB1pszHVskkw4u/9Eu8s5yvvsSDTzYh4p4ZIRj0DznSl3FBF0Z/mZfrKXTtt0QCoFmoHA==} + /@esbuild/android-x64@0.18.20: + resolution: {integrity: sha512-8GDdlePJA8D6zlZYJV/jnrRAi6rOiNaCC/JclcXpB+KIuvfBN4owLtgzY2bsxnx666XjJx2kDPUmnTtR8qKQUg==} engines: {node: '>=12'} cpu: [x64] os: [android] @@ -1806,17 +1779,16 @@ packages: dev: true optional: true - /@esbuild/darwin-arm64@0.17.15: - resolution: {integrity: sha512-7siLjBc88Z4+6qkMDxPT2juf2e8SJxmsbNVKFY2ifWCDT72v5YJz9arlvBw5oB4W/e61H1+HDB/jnu8nNg0rLA==} + /@esbuild/darwin-arm64@0.17.19: + resolution: {integrity: sha512-80wEoCfF/hFKM6WE1FyBHc9SfUblloAWx6FJkFWTWiCoht9Mc0ARGEM47e67W9rI09YoUxJL68WHfDRYEAvOhg==} engines: {node: '>=12'} cpu: [arm64] os: [darwin] requiresBuild: true - dev: false optional: true - /@esbuild/darwin-arm64@0.17.17: - resolution: {integrity: sha512-m/gwyiBwH3jqfUabtq3GH31otL/0sE0l34XKpSIqR7NjQ/XHQ3lpmQHLHbG8AHTGCw8Ao059GvV08MS0bhFIJQ==} + /@esbuild/darwin-arm64@0.18.20: + resolution: {integrity: sha512-bxRHW5kHU38zS2lPTPOyuyTm+S+eobPUnTNkdJEfAddYgEcll4xkT8DB9d2008DtTbl7uJag2HuE5NZAZgnNEA==} engines: {node: '>=12'} cpu: [arm64] os: [darwin] @@ -1824,17 +1796,16 @@ packages: dev: true optional: true - /@esbuild/darwin-x64@0.17.15: - resolution: {integrity: sha512-NbImBas2rXwYI52BOKTW342Tm3LTeVlaOQ4QPZ7XuWNKiO226DisFk/RyPk3T0CKZkKMuU69yOvlapJEmax7cg==} + /@esbuild/darwin-x64@0.17.19: + resolution: {integrity: sha512-IJM4JJsLhRYr9xdtLytPLSH9k/oxR3boaUIYiHkAawtwNOXKE8KoU8tMvryogdcT8AU+Bflmh81Xn6Q0vTZbQw==} engines: {node: '>=12'} cpu: [x64] os: [darwin] requiresBuild: true - dev: false optional: true - /@esbuild/darwin-x64@0.17.17: - resolution: {integrity: sha512-4utIrsX9IykrqYaXR8ob9Ha2hAY2qLc6ohJ8c0CN1DR8yWeMrTgYFjgdeQ9LIoTOfLetXjuCu5TRPHT9yKYJVg==} + /@esbuild/darwin-x64@0.18.20: + resolution: {integrity: sha512-pc5gxlMDxzm513qPGbCbDukOdsGtKhfxD1zJKXjCCcU7ju50O7MeAZ8c4krSJcOIJGFR+qx21yMMVYwiQvyTyQ==} engines: {node: '>=12'} cpu: [x64] os: [darwin] @@ -1842,17 +1813,16 @@ packages: dev: true optional: true - /@esbuild/freebsd-arm64@0.17.15: - resolution: {integrity: sha512-Xk9xMDjBVG6CfgoqlVczHAdJnCs0/oeFOspFap5NkYAmRCT2qTn1vJWA2f419iMtsHSLm+O8B6SLV/HlY5cYKg==} + /@esbuild/freebsd-arm64@0.17.19: + resolution: {integrity: sha512-pBwbc7DufluUeGdjSU5Si+P3SoMF5DQ/F/UmTSb8HXO80ZEAJmrykPyzo1IfNbAoaqw48YRpv8shwd1NoI0jcQ==} engines: {node: '>=12'} cpu: [arm64] os: [freebsd] requiresBuild: true - dev: false optional: true - /@esbuild/freebsd-arm64@0.17.17: - resolution: {integrity: sha512-4PxjQII/9ppOrpEwzQ1b0pXCsFLqy77i0GaHodrmzH9zq2/NEhHMAMJkJ635Ns4fyJPFOlHMz4AsklIyRqFZWA==} + /@esbuild/freebsd-arm64@0.18.20: + resolution: {integrity: sha512-yqDQHy4QHevpMAaxhhIwYPMv1NECwOvIpGCZkECn8w2WFHXjEwrBn3CeNIYsibZ/iZEUemj++M26W3cNR5h+Tw==} engines: {node: '>=12'} cpu: [arm64] os: [freebsd] @@ -1860,17 +1830,16 @@ packages: dev: true optional: true - /@esbuild/freebsd-x64@0.17.15: - resolution: {integrity: sha512-3TWAnnEOdclvb2pnfsTWtdwthPfOz7qAfcwDLcfZyGJwm1SRZIMOeB5FODVhnM93mFSPsHB9b/PmxNNbSnd0RQ==} + /@esbuild/freebsd-x64@0.17.19: + resolution: {integrity: sha512-4lu+n8Wk0XlajEhbEffdy2xy53dpR06SlzvhGByyg36qJw6Kpfk7cp45DR/62aPH9mtJRmIyrXAS5UWBrJT6TQ==} engines: {node: '>=12'} cpu: [x64] os: [freebsd] requiresBuild: true - dev: false optional: true - /@esbuild/freebsd-x64@0.17.17: - resolution: {integrity: sha512-lQRS+4sW5S3P1sv0z2Ym807qMDfkmdhUYX30GRBURtLTrJOPDpoU0kI6pVz1hz3U0+YQ0tXGS9YWveQjUewAJw==} + /@esbuild/freebsd-x64@0.18.20: + resolution: {integrity: sha512-tgWRPPuQsd3RmBZwarGVHZQvtzfEBOreNuxEMKFcd5DaDn2PbBxfwLcj4+aenoh7ctXcbXmOQIn8HI6mCSw5MQ==} engines: {node: '>=12'} cpu: [x64] os: [freebsd] @@ -1878,17 +1847,16 @@ packages: dev: true optional: true - /@esbuild/linux-arm64@0.17.15: - resolution: {integrity: sha512-T0MVnYw9KT6b83/SqyznTs/3Jg2ODWrZfNccg11XjDehIved2oQfrX/wVuev9N936BpMRaTR9I1J0tdGgUgpJA==} + /@esbuild/linux-arm64@0.17.19: + resolution: {integrity: sha512-ct1Tg3WGwd3P+oZYqic+YZF4snNl2bsnMKRkb3ozHmnM0dGWuxcPTTntAF6bOP0Sp4x0PjSF+4uHQ1xvxfRKqg==} engines: {node: '>=12'} cpu: [arm64] os: [linux] requiresBuild: true - dev: false optional: true - /@esbuild/linux-arm64@0.17.17: - resolution: {integrity: sha512-2+pwLx0whKY1/Vqt8lyzStyda1v0qjJ5INWIe+d8+1onqQxHLLi3yr5bAa4gvbzhZqBztifYEu8hh1La5+7sUw==} + /@esbuild/linux-arm64@0.18.20: + resolution: {integrity: sha512-2YbscF+UL7SQAVIpnWvYwM+3LskyDmPhe31pE7/aoTMFKKzIc9lLbyGUpmmb8a8AixOL61sQ/mFh3jEjHYFvdA==} engines: {node: '>=12'} cpu: [arm64] os: [linux] @@ -1896,17 +1864,16 @@ packages: dev: true optional: true - /@esbuild/linux-arm@0.17.15: - resolution: {integrity: sha512-MLTgiXWEMAMr8nmS9Gigx43zPRmEfeBfGCwxFQEMgJ5MC53QKajaclW6XDPjwJvhbebv+RzK05TQjvH3/aM4Xw==} + /@esbuild/linux-arm@0.17.19: + resolution: {integrity: sha512-cdmT3KxjlOQ/gZ2cjfrQOtmhG4HJs6hhvm3mWSRDPtZ/lP5oe8FWceS10JaSJC13GBd4eH/haHnqf7hhGNLerA==} engines: {node: '>=12'} cpu: [arm] os: [linux] requiresBuild: true - dev: false optional: true - /@esbuild/linux-arm@0.17.17: - resolution: {integrity: sha512-biDs7bjGdOdcmIk6xU426VgdRUpGg39Yz6sT9Xp23aq+IEHDb/u5cbmu/pAANpDB4rZpY/2USPhCA+w9t3roQg==} + /@esbuild/linux-arm@0.18.20: + resolution: {integrity: sha512-/5bHkMWnq1EgKr1V+Ybz3s1hWXok7mDFUMQ4cG10AfW3wL02PSZi5kFpYKrptDsgb2WAJIvRcDm+qIvXf/apvg==} engines: {node: '>=12'} cpu: [arm] os: [linux] @@ -1914,17 +1881,16 @@ packages: dev: true optional: true - /@esbuild/linux-ia32@0.17.15: - resolution: {integrity: sha512-wp02sHs015T23zsQtU4Cj57WiteiuASHlD7rXjKUyAGYzlOKDAjqK6bk5dMi2QEl/KVOcsjwL36kD+WW7vJt8Q==} + /@esbuild/linux-ia32@0.17.19: + resolution: {integrity: sha512-w4IRhSy1VbsNxHRQpeGCHEmibqdTUx61Vc38APcsRbuVgK0OPEnQ0YD39Brymn96mOx48Y2laBQGqgZ0j9w6SQ==} engines: {node: '>=12'} cpu: [ia32] os: [linux] requiresBuild: true - dev: false optional: true - /@esbuild/linux-ia32@0.17.17: - resolution: {integrity: sha512-IBTTv8X60dYo6P2t23sSUYym8fGfMAiuv7PzJ+0LcdAndZRzvke+wTVxJeCq4WgjppkOpndL04gMZIFvwoU34Q==} + /@esbuild/linux-ia32@0.18.20: + resolution: {integrity: sha512-P4etWwq6IsReT0E1KHU40bOnzMHoH73aXp96Fs8TIT6z9Hu8G6+0SHSw9i2isWrD2nbx2qo5yUqACgdfVGx7TA==} engines: {node: '>=12'} cpu: [ia32] os: [linux] @@ -1932,17 +1898,16 @@ packages: dev: true optional: true - /@esbuild/linux-loong64@0.17.15: - resolution: {integrity: sha512-k7FsUJjGGSxwnBmMh8d7IbObWu+sF/qbwc+xKZkBe/lTAF16RqxRCnNHA7QTd3oS2AfGBAnHlXL67shV5bBThQ==} + /@esbuild/linux-loong64@0.17.19: + resolution: {integrity: sha512-2iAngUbBPMq439a+z//gE+9WBldoMp1s5GWsUSgqHLzLJ9WoZLZhpwWuym0u0u/4XmZ3gpHmzV84PonE+9IIdQ==} engines: {node: '>=12'} cpu: [loong64] os: [linux] requiresBuild: true - dev: false optional: true - /@esbuild/linux-loong64@0.17.17: - resolution: {integrity: sha512-WVMBtcDpATjaGfWfp6u9dANIqmU9r37SY8wgAivuKmgKHE+bWSuv0qXEFt/p3qXQYxJIGXQQv6hHcm7iWhWjiw==} + /@esbuild/linux-loong64@0.18.20: + resolution: {integrity: sha512-nXW8nqBTrOpDLPgPY9uV+/1DjxoQ7DoB2N8eocyq8I9XuqJ7BiAMDMf9n1xZM9TgW0J8zrquIb/A7s3BJv7rjg==} engines: {node: '>=12'} cpu: [loong64] os: [linux] @@ -1950,17 +1915,16 @@ packages: dev: true optional: true - /@esbuild/linux-mips64el@0.17.15: - resolution: {integrity: sha512-ZLWk6czDdog+Q9kE/Jfbilu24vEe/iW/Sj2d8EVsmiixQ1rM2RKH2n36qfxK4e8tVcaXkvuV3mU5zTZviE+NVQ==} + /@esbuild/linux-mips64el@0.17.19: + resolution: {integrity: sha512-LKJltc4LVdMKHsrFe4MGNPp0hqDFA1Wpt3jE1gEyM3nKUvOiO//9PheZZHfYRfYl6AwdTH4aTcXSqBerX0ml4A==} engines: {node: '>=12'} cpu: [mips64el] os: [linux] requiresBuild: true - dev: false optional: true - /@esbuild/linux-mips64el@0.17.17: - resolution: {integrity: sha512-2kYCGh8589ZYnY031FgMLy0kmE4VoGdvfJkxLdxP4HJvWNXpyLhjOvxVsYjYZ6awqY4bgLR9tpdYyStgZZhi2A==} + /@esbuild/linux-mips64el@0.18.20: + resolution: {integrity: sha512-d5NeaXZcHp8PzYy5VnXV3VSd2D328Zb+9dEq5HE6bw6+N86JVPExrA6O68OPwobntbNJ0pzCpUFZTo3w0GyetQ==} engines: {node: '>=12'} cpu: [mips64el] os: [linux] @@ -1968,17 +1932,16 @@ packages: dev: true optional: true - /@esbuild/linux-ppc64@0.17.15: - resolution: {integrity: sha512-mY6dPkIRAiFHRsGfOYZC8Q9rmr8vOBZBme0/j15zFUKM99d4ILY4WpOC7i/LqoY+RE7KaMaSfvY8CqjJtuO4xg==} + /@esbuild/linux-ppc64@0.17.19: + resolution: {integrity: sha512-/c/DGybs95WXNS8y3Ti/ytqETiW7EU44MEKuCAcpPto3YjQbyK3IQVKfF6nbghD7EcLUGl0NbiL5Rt5DMhn5tg==} engines: {node: '>=12'} cpu: [ppc64] os: [linux] requiresBuild: true - dev: false optional: true - /@esbuild/linux-ppc64@0.17.17: - resolution: {integrity: sha512-KIdG5jdAEeAKogfyMTcszRxy3OPbZhq0PPsW4iKKcdlbk3YE4miKznxV2YOSmiK/hfOZ+lqHri3v8eecT2ATwQ==} + /@esbuild/linux-ppc64@0.18.20: + resolution: {integrity: sha512-WHPyeScRNcmANnLQkq6AfyXRFr5D6N2sKgkFo2FqguP44Nw2eyDlbTdZwd9GYk98DZG9QItIiTlFLHJHjxP3FA==} engines: {node: '>=12'} cpu: [ppc64] os: [linux] @@ -1986,17 +1949,16 @@ packages: dev: true optional: true - /@esbuild/linux-riscv64@0.17.15: - resolution: {integrity: sha512-EcyUtxffdDtWjjwIH8sKzpDRLcVtqANooMNASO59y+xmqqRYBBM7xVLQhqF7nksIbm2yHABptoioS9RAbVMWVA==} + /@esbuild/linux-riscv64@0.17.19: + resolution: {integrity: sha512-FC3nUAWhvFoutlhAkgHf8f5HwFWUL6bYdvLc/TTuxKlvLi3+pPzdZiFKSWz/PF30TB1K19SuCxDTI5KcqASJqA==} engines: {node: '>=12'} cpu: [riscv64] os: [linux] requiresBuild: true - dev: false optional: true - /@esbuild/linux-riscv64@0.17.17: - resolution: {integrity: sha512-Cj6uWLBR5LWhcD/2Lkfg2NrkVsNb2sFM5aVEfumKB2vYetkA/9Uyc1jVoxLZ0a38sUhFk4JOVKH0aVdPbjZQeA==} + /@esbuild/linux-riscv64@0.18.20: + resolution: {integrity: sha512-WSxo6h5ecI5XH34KC7w5veNnKkju3zBRLEQNY7mv5mtBmrP/MjNBCAlsM2u5hDBlS3NGcTQpoBvRzqBcRtpq1A==} engines: {node: '>=12'} cpu: [riscv64] os: [linux] @@ -2004,17 +1966,16 @@ packages: dev: true optional: true - /@esbuild/linux-s390x@0.17.15: - resolution: {integrity: sha512-BuS6Jx/ezxFuHxgsfvz7T4g4YlVrmCmg7UAwboeyNNg0OzNzKsIZXpr3Sb/ZREDXWgt48RO4UQRDBxJN3B9Rbg==} + /@esbuild/linux-s390x@0.17.19: + resolution: {integrity: sha512-IbFsFbxMWLuKEbH+7sTkKzL6NJmG2vRyy6K7JJo55w+8xDk7RElYn6xvXtDW8HCfoKBFK69f3pgBJSUSQPr+4Q==} engines: {node: '>=12'} cpu: [s390x] os: [linux] requiresBuild: true - dev: false optional: true - /@esbuild/linux-s390x@0.17.17: - resolution: {integrity: sha512-lK+SffWIr0XsFf7E0srBjhpkdFVJf3HEgXCwzkm69kNbRar8MhezFpkIwpk0qo2IOQL4JE4mJPJI8AbRPLbuOQ==} + /@esbuild/linux-s390x@0.18.20: + resolution: {integrity: sha512-+8231GMs3mAEth6Ja1iK0a1sQ3ohfcpzpRLH8uuc5/KVDFneH6jtAJLFGafpzpMRO6DzJ6AvXKze9LfFMrIHVQ==} engines: {node: '>=12'} cpu: [s390x] os: [linux] @@ -2022,17 +1983,16 @@ packages: dev: true optional: true - /@esbuild/linux-x64@0.17.15: - resolution: {integrity: sha512-JsdS0EgEViwuKsw5tiJQo9UdQdUJYuB+Mf6HxtJSPN35vez1hlrNb1KajvKWF5Sa35j17+rW1ECEO9iNrIXbNg==} + /@esbuild/linux-x64@0.17.19: + resolution: {integrity: sha512-68ngA9lg2H6zkZcyp22tsVt38mlhWde8l3eJLWkyLrp4HwMUr3c1s/M2t7+kHIhvMjglIBrFpncX1SzMckomGw==} engines: {node: '>=12'} cpu: [x64] os: [linux] requiresBuild: true - dev: false optional: true - /@esbuild/linux-x64@0.17.17: - resolution: {integrity: sha512-XcSGTQcWFQS2jx3lZtQi7cQmDYLrpLRyz1Ns1DzZCtn898cWfm5Icx/DEWNcTU+T+tyPV89RQtDnI7qL2PObPg==} + /@esbuild/linux-x64@0.18.20: + resolution: {integrity: sha512-UYqiqemphJcNsFEskc73jQ7B9jgwjWrSayxawS6UVFZGWrAAtkzjxSqnoclCXxWtfwLdzU+vTpcNYhpn43uP1w==} engines: {node: '>=12'} cpu: [x64] os: [linux] @@ -2040,17 +2000,16 @@ packages: dev: true optional: true - /@esbuild/netbsd-x64@0.17.15: - resolution: {integrity: sha512-R6fKjtUysYGym6uXf6qyNephVUQAGtf3n2RCsOST/neIwPqRWcnc3ogcielOd6pT+J0RDR1RGcy0ZY7d3uHVLA==} + /@esbuild/netbsd-x64@0.17.19: + resolution: {integrity: sha512-CwFq42rXCR8TYIjIfpXCbRX0rp1jo6cPIUPSaWwzbVI4aOfX96OXY8M6KNmtPcg7QjYeDmN+DD0Wp3LaBOLf4Q==} engines: {node: '>=12'} cpu: [x64] os: [netbsd] requiresBuild: true - dev: false optional: true - /@esbuild/netbsd-x64@0.17.17: - resolution: {integrity: sha512-RNLCDmLP5kCWAJR+ItLM3cHxzXRTe4N00TQyQiimq+lyqVqZWGPAvcyfUBM0isE79eEZhIuGN09rAz8EL5KdLA==} + /@esbuild/netbsd-x64@0.18.20: + resolution: {integrity: sha512-iO1c++VP6xUBUmltHZoMtCUdPlnPGdBom6IrO4gyKPFFVBKioIImVooR5I83nTew5UOYrk3gIJhbZh8X44y06A==} engines: {node: '>=12'} cpu: [x64] os: [netbsd] @@ -2058,17 +2017,16 @@ packages: dev: true optional: true - /@esbuild/openbsd-x64@0.17.15: - resolution: {integrity: sha512-mVD4PGc26b8PI60QaPUltYKeSX0wxuy0AltC+WCTFwvKCq2+OgLP4+fFd+hZXzO2xW1HPKcytZBdjqL6FQFa7w==} + /@esbuild/openbsd-x64@0.17.19: + resolution: {integrity: sha512-cnq5brJYrSZ2CF6c35eCmviIN3k3RczmHz8eYaVlNasVqsNY+JKohZU5MKmaOI+KkllCdzOKKdPs762VCPC20g==} engines: {node: '>=12'} cpu: [x64] os: [openbsd] requiresBuild: true - dev: false optional: true - /@esbuild/openbsd-x64@0.17.17: - resolution: {integrity: sha512-PAXswI5+cQq3Pann7FNdcpSUrhrql3wKjj3gVkmuz6OHhqqYxKvi6GgRBoaHjaG22HV/ZZEgF9TlS+9ftHVigA==} + /@esbuild/openbsd-x64@0.18.20: + resolution: {integrity: sha512-e5e4YSsuQfX4cxcygw/UCPIEP6wbIL+se3sxPdCiMbFLBWu0eiZOJ7WoD+ptCLrmjZBK1Wk7I6D/I3NglUGOxg==} engines: {node: '>=12'} cpu: [x64] os: [openbsd] @@ -2076,17 +2034,16 @@ packages: dev: true optional: true - /@esbuild/sunos-x64@0.17.15: - resolution: {integrity: sha512-U6tYPovOkw3459t2CBwGcFYfFRjivcJJc1WC8Q3funIwX8x4fP+R6xL/QuTPNGOblbq/EUDxj9GU+dWKX0oWlQ==} + /@esbuild/sunos-x64@0.17.19: + resolution: {integrity: sha512-vCRT7yP3zX+bKWFeP/zdS6SqdWB8OIpaRq/mbXQxTGHnIxspRtigpkUcDMlSCOejlHowLqII7K2JKevwyRP2rg==} engines: {node: '>=12'} cpu: [x64] os: [sunos] requiresBuild: true - dev: false optional: true - /@esbuild/sunos-x64@0.17.17: - resolution: {integrity: sha512-V63egsWKnx/4V0FMYkr9NXWrKTB5qFftKGKuZKFIrAkO/7EWLFnbBZNM1CvJ6Sis+XBdPws2YQSHF1Gqf1oj/Q==} + /@esbuild/sunos-x64@0.18.20: + resolution: {integrity: sha512-kDbFRFp0YpTQVVrqUd5FTYmWo45zGaXe0X8E1G/LKFC0v8x0vWrhOWSLITcCn63lmZIxfOMXtCfti/RxN/0wnQ==} engines: {node: '>=12'} cpu: [x64] os: [sunos] @@ -2094,17 +2051,16 @@ packages: dev: true optional: true - /@esbuild/win32-arm64@0.17.15: - resolution: {integrity: sha512-W+Z5F++wgKAleDABemiyXVnzXgvRFs+GVKThSI+mGgleLWluv0D7Diz4oQpgdpNzh4i2nNDzQtWbjJiqutRp6Q==} + /@esbuild/win32-arm64@0.17.19: + resolution: {integrity: sha512-yYx+8jwowUstVdorcMdNlzklLYhPxjniHWFKgRqH7IFlUEa0Umu3KuYplf1HUZZ422e3NU9F4LGb+4O0Kdcaag==} engines: {node: '>=12'} cpu: [arm64] os: [win32] requiresBuild: true - dev: false optional: true - /@esbuild/win32-arm64@0.17.17: - resolution: {integrity: sha512-YtUXLdVnd6YBSYlZODjWzH+KzbaubV0YVd6UxSfoFfa5PtNJNaW+1i+Hcmjpg2nEe0YXUCNF5bkKy1NnBv1y7Q==} + /@esbuild/win32-arm64@0.18.20: + resolution: {integrity: sha512-ddYFR6ItYgoaq4v4JmQQaAI5s7npztfV4Ag6NrhiaW0RrnOXqBkgwZLofVTlq1daVTQNhtI5oieTvkRPfZrePg==} engines: {node: '>=12'} cpu: [arm64] os: [win32] @@ -2112,17 +2068,16 @@ packages: dev: true optional: true - /@esbuild/win32-ia32@0.17.15: - resolution: {integrity: sha512-Muz/+uGgheShKGqSVS1KsHtCyEzcdOn/W/Xbh6H91Etm+wiIfwZaBn1W58MeGtfI8WA961YMHFYTthBdQs4t+w==} + /@esbuild/win32-ia32@0.17.19: + resolution: {integrity: sha512-eggDKanJszUtCdlVs0RB+h35wNlb5v4TWEkq4vZcmVt5u/HiDZrTXe2bWFQUez3RgNHwx/x4sk5++4NSSicKkw==} engines: {node: '>=12'} cpu: [ia32] os: [win32] requiresBuild: true - dev: false optional: true - /@esbuild/win32-ia32@0.17.17: - resolution: {integrity: sha512-yczSLRbDdReCO74Yfc5tKG0izzm+lPMYyO1fFTcn0QNwnKmc3K+HdxZWLGKg4pZVte7XVgcFku7TIZNbWEJdeQ==} + /@esbuild/win32-ia32@0.18.20: + resolution: {integrity: sha512-Wv7QBi3ID/rROT08SABTS7eV4hX26sVduqDOTe1MvGMjNd3EjOz4b7zeexIR62GTIEKrfJXKL9LFxTYgkyeu7g==} engines: {node: '>=12'} cpu: [ia32] os: [win32] @@ -2130,17 +2085,16 @@ packages: dev: true optional: true - /@esbuild/win32-x64@0.17.15: - resolution: {integrity: sha512-DjDa9ywLUUmjhV2Y9wUTIF+1XsmuFGvZoCmOWkli1XcNAh5t25cc7fgsCx4Zi/Uurep3TTLyDiKATgGEg61pkA==} + /@esbuild/win32-x64@0.17.19: + resolution: {integrity: sha512-lAhycmKnVOuRYNtRtatQR1LPQf2oYCkRGkSFnseDAKPl8lu5SOsK/e1sXe5a0Pc5kHIHe6P2I/ilntNv2xf3cA==} engines: {node: '>=12'} cpu: [x64] os: [win32] requiresBuild: true - dev: false optional: true - /@esbuild/win32-x64@0.17.17: - resolution: {integrity: sha512-FNZw7H3aqhF9OyRQbDDnzUApDXfC1N6fgBhkqEO2jvYCJ+DxMTfZVqg3AX0R1khg1wHTBRD5SdcibSJ+XF6bFg==} + /@esbuild/win32-x64@0.18.20: + resolution: {integrity: sha512-kTdfRcSiDfQca/y9QIkng02avJ+NCaQvrMejlsB3RRv5sE9rRoeBPISaZpKxHELzRxZyLvNts1P27W3wV+8geQ==} engines: {node: '>=12'} cpu: [x64] os: [win32] @@ -2154,9 +2108,9 @@ packages: dependencies: ajv: 6.12.6 debug: 4.3.4(supports-color@8.1.1) - espree: 9.5.1 - globals: 13.20.0 - ignore: 5.2.4 + espree: 9.6.1 + globals: 13.24.0 + ignore: 5.3.1 import-fresh: 3.3.0 js-yaml: 4.1.0 minimatch: 3.1.2 @@ -2165,71 +2119,19 @@ packages: - supports-color dev: true - /@ethereumjs/block@3.6.3: - resolution: {integrity: sha512-CegDeryc2DVKnDkg5COQrE0bJfw/p0v3GBk2W5/Dj5dOVfEmb50Ux0GLnSPypooLnfqjwFaorGuT9FokWB3GRg==} - dependencies: - '@ethereumjs/common': 2.6.5 - '@ethereumjs/tx': 3.5.2 - ethereumjs-util: 7.1.5 - merkle-patricia-tree: 4.2.4 - dev: true - - /@ethereumjs/blockchain@5.5.3: - resolution: {integrity: sha512-bi0wuNJ1gw4ByNCV56H0Z4Q7D+SxUbwyG12Wxzbvqc89PXLRNR20LBcSUZRKpN0+YCPo6m0XZL/JLio3B52LTw==} - dependencies: - '@ethereumjs/block': 3.6.3 - '@ethereumjs/common': 2.6.5 - '@ethereumjs/ethash': 1.1.0 - debug: 4.3.4(supports-color@8.1.1) - ethereumjs-util: 7.1.5 - level-mem: 5.0.1 - lru-cache: 5.1.1 - semaphore-async-await: 1.5.1 - transitivePeerDependencies: - - supports-color - dev: true - - /@ethereumjs/common@2.6.5: - resolution: {integrity: sha512-lRyVQOeCDaIVtgfbowla32pzeDv2Obr8oR8Put5RdUBNRGr1VGPGQNGP6elWIpgK3YdpzqTOh4GyUGOureVeeA==} - dependencies: - crc-32: 1.2.2 - ethereumjs-util: 7.1.5 - dev: true - - /@ethereumjs/ethash@1.1.0: - resolution: {integrity: sha512-/U7UOKW6BzpA+Vt+kISAoeDie1vAvY4Zy2KF5JJb+So7+1yKmJeJEHOGSnQIj330e9Zyl3L5Nae6VZyh2TJnAA==} - dependencies: - '@ethereumjs/block': 3.6.3 - '@types/levelup': 4.3.3 - buffer-xor: 2.0.2 - ethereumjs-util: 7.1.5 - miller-rabin: 4.0.1 - dev: true - - /@ethereumjs/tx@3.5.2: - resolution: {integrity: sha512-gQDNJWKrSDGu2w7w0PzVXVBNMzb7wwdDOmOqczmhNjqFxFuIbhVJDwiGEnxFNC2/b8ifcZzY7MLcluizohRzNw==} - dependencies: - '@ethereumjs/common': 2.6.5 - ethereumjs-util: 7.1.5 + /@ethereumjs/rlp@4.0.1: + resolution: {integrity: sha512-tqsQiBQDQdmPWE1xkkBq4rlSW5QZpLOUJ5RJh2/9fug+q9tnUhuZoVLk7s0scUIKTOzEtR72DFBXI4WiZcMpvw==} + engines: {node: '>=14'} + hasBin: true dev: true - /@ethereumjs/vm@5.9.3: - resolution: {integrity: sha512-Ha04TeF8goEglr8eL7hkkYyjhzdZS0PsoRURzYlTF6I0VVId5KjKb0N7MrA8GMgheN+UeTncfTgYx52D/WhEmg==} + /@ethereumjs/util@8.1.0: + resolution: {integrity: sha512-zQ0IqbdX8FZ9aw11vP+dZkKDkS+kgIvQPHnSAXzP9pLu+Rfu3D3XEeLbicvoXJTYnhZiPmsZUxgdzXwNKxRPbA==} + engines: {node: '>=14'} dependencies: - '@ethereumjs/block': 3.6.3 - '@ethereumjs/blockchain': 5.5.3 - '@ethereumjs/common': 2.6.5 - '@ethereumjs/tx': 3.5.2 - async-eventemitter: 0.2.4 - core-js-pure: 3.30.0 - debug: 4.3.4(supports-color@8.1.1) - ethereumjs-util: 7.1.5 - functional-red-black-tree: 1.0.1 - mcl-wasm: 0.7.9 - merkle-patricia-tree: 4.2.4 - rustbn.js: 0.2.0 - transitivePeerDependencies: - - supports-color + '@ethereumjs/rlp': 4.0.1 + ethereum-cryptography: 2.1.3 + micro-ftch: 0.3.1 dev: true /@ethersproject/abi@5.7.0: @@ -2527,9 +2429,14 @@ packages: dependencies: ajv: 8.12.0 ajv-formats: 2.1.1(ajv@8.12.0) - fast-uri: 2.2.0 + fast-uri: 2.3.0 dev: false + /@fastify/busboy@2.1.1: + resolution: {integrity: sha512-vBZP4NlzfOlerQTnba4aqZoMhE/a9HY7HRqoOPaETQcSQuWEIyZMHGfVu6w9wGtGK5fED5qRs2DteVCjOH60sA==} + engines: {node: '>=14'} + dev: true + /@fastify/compress@6.5.0: resolution: {integrity: sha512-AqUOK714jY7qkzbQbS4zyI4yNFgnRoOJ3eH/oV1T9f5fFdPDRdrFxm5de1ya5n+as4bvitjwU9EY7zvtT9pI2A==} dependencies: @@ -2543,36 +2450,34 @@ packages: pumpify: 2.0.1 dev: false - /@fastify/cors@8.3.0: - resolution: {integrity: sha512-oj9xkka2Tg0MrwuKhsSUumcAkfp2YCnKxmFEusi01pjk1YrdDsuSYTHXEelWNW+ilSy/ApZq0c2SvhKrLX0H1g==} + /@fastify/cors@8.5.0: + resolution: {integrity: sha512-/oZ1QSb02XjP0IK1U0IXktEsw/dUBTxJOW7IpIeO8c/tNalw/KjoNSJv1Sf6eqoBPO+TDGkifq6ynFK3v68HFQ==} dependencies: fastify-plugin: 4.5.1 - mnemonist: 0.39.5 + mnemonist: 0.39.6 dev: false - /@fastify/deepmerge@1.3.0: - resolution: {integrity: sha512-J8TOSBq3SoZbDhM9+R/u77hP93gz/rajSA+K2kGyijPpORPWUXHUpTaleoj+92As0S9uPRP7Oi8IqMf0u+ro6A==} - dev: false - - /@fastify/error@3.3.0: - resolution: {integrity: sha512-dj7vjIn1Ar8sVXj2yAXiMNCJDmS9MQ9XMlIecX2dIzzhjSHCyKo4DdXjXMs7wKW2kj6yvVRSpuQjOZ3YLrh56w==} + /@fastify/error@3.4.1: + resolution: {integrity: sha512-wWSvph+29GR783IhmvdwWnN4bUxTD01Vm5Xad4i7i1VuAOItLvbPAb69sb0IQ2N57yprvhNIwAP5B6xfKTmjmQ==} dev: false /@fastify/fast-json-stringify-compiler@4.3.0: resolution: {integrity: sha512-aZAXGYo6m22Fk1zZzEUKBvut/CIIQe/BapEORnxiD5Qr0kPHqqI69NtEMCme74h+at72sPhbkb4ZrLd1W3KRLA==} dependencies: - fast-json-stringify: 5.8.0 + fast-json-stringify: 5.12.0 dev: false - /@gar/promisify@1.1.3: - resolution: {integrity: sha512-k2Ty1JcVojjJFwrg/ThKi2ujJ7XNLYaFGNB/bWT9wGR+oSMJHMa5w+CUq6p/pVrKeNNgA7pCqEcjSnHVoqJQFw==} + /@fastify/merge-json-schemas@0.1.1: + resolution: {integrity: sha512-fERDVz7topgNjtXsJTTW1JKLy0rhuLRcquYqNR9rF7OcVpCa2OVW49ZPDIhaRRCaUuvVxI+N416xUoF76HNSXA==} + dependencies: + fast-deep-equal: 3.1.3 dev: false - /@humanwhocodes/config-array@0.11.8: - resolution: {integrity: sha512-UybHIJzJnR5Qc/MsD9Kr+RpO2h+/P1GhOwdiLPXK5TWk5sgTdu88bTD9UP+CKbPPh5Rni1u0GjAdYQLemG8g+g==} + /@humanwhocodes/config-array@0.11.14: + resolution: {integrity: sha512-3T8LkOmg45BV5FICb15QQMsyUSWrQ8AygVfC7ZG32zOalnqrilm018ZVCw0eapXux8FtA33q8PSRSstjee3jSg==} engines: {node: '>=10.10.0'} dependencies: - '@humanwhocodes/object-schema': 1.2.1 + '@humanwhocodes/object-schema': 2.0.2 debug: 4.3.4(supports-color@8.1.1) minimatch: 3.1.2 transitivePeerDependencies: @@ -2584,8 +2489,8 @@ packages: engines: {node: '>=12.22'} dev: true - /@humanwhocodes/object-schema@1.2.1: - resolution: {integrity: sha512-ZnQMnLV4e7hDlUvw8H+U8ASL02SS2Gn6+9Ac3wGGLIe7+je2AeAOxPY+izIPJDfFDb7eDjev0Us8MO1iFRN8hA==} + /@humanwhocodes/object-schema@2.0.2: + resolution: {integrity: sha512-6EwiSjwWYP7pTckG6I5eyFANjPhmPjUX9JRLUSfNPC7FX7zK9gyZAfUEaECL6ALTpGX5AjnBq3C9XmVWPitNpw==} dev: true /@improbable-eng/grpc-web-node-http-transport@0.15.0(@improbable-eng/grpc-web@0.15.0): @@ -2605,6 +2510,18 @@ packages: google-protobuf: 3.21.2 dev: false + /@isaacs/cliui@8.0.2: + resolution: {integrity: sha512-O8jcjabXaleOG9DQ0+ARXWZBTfnP4WNAqzuiJK7ll44AmxGKv/J2M4TPjxjY3znBCfvBXFzucm1twdyFybFqEA==} + engines: {node: '>=12'} + dependencies: + string-width: 5.1.2 + string-width-cjs: /string-width@4.2.3 + strip-ansi: 7.1.0 + strip-ansi-cjs: /strip-ansi@6.0.1 + wrap-ansi: 8.1.0 + wrap-ansi-cjs: /wrap-ansi@7.0.0 + dev: true + /@istanbuljs/load-nyc-config@1.1.0: resolution: {integrity: sha512-VjeHSlIzpv/NyD3N0YuHfXOPDIixcA1q2ZV98wsMqcYlPmv2n3Yb2lYP9XMElnaFVXg5A7YLTeLu6V84uQDjmQ==} engines: {node: '>=8'} @@ -2621,20 +2538,20 @@ packages: engines: {node: '>=8'} dev: true - /@jest/console@29.5.0: - resolution: {integrity: sha512-NEpkObxPwyw/XxZVLPmAGKE89IQRp4puc6IQRPru6JKd1M3fW9v1xM1AnzIJE65hbCkzQAdnL8P47e9hzhiYLQ==} + /@jest/console@29.7.0: + resolution: {integrity: sha512-5Ni4CU7XHQi32IJ398EEP4RrB8eV09sXP2ROqD4bksHrnTree52PsxvX8tpL8LvTZ3pFzXyPbNQReSN41CAhOg==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} dependencies: - '@jest/types': 29.5.0 - '@types/node': 18.15.11 + '@jest/types': 29.6.3 + '@types/node': 18.19.21 chalk: 4.1.2 - jest-message-util: 29.5.0 - jest-util: 29.5.0 + jest-message-util: 29.7.0 + jest-util: 29.7.0 slash: 3.0.0 dev: true - /@jest/core@29.5.0: - resolution: {integrity: sha512-28UzQc7ulUrOQw1IsN/kv1QES3q2kkbl/wGslyhAclqZ/8cMdB5M68BffkIdSJgKBUt50d3hbwJ92XESlE7LiQ==} + /@jest/core@29.7.0: + resolution: {integrity: sha512-n7aeXWKMnGtDA48y8TLWJPJmLmmZ642Ceo78cYWEpiD7FzDgmNDV/GCVRorPABdXLJZ/9wzzgZAlHjXjxDHGsg==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} peerDependencies: node-notifier: ^8.0.1 || ^9.0.0 || ^10.0.0 @@ -2642,92 +2559,93 @@ packages: node-notifier: optional: true dependencies: - '@jest/console': 29.5.0 - '@jest/reporters': 29.5.0 - '@jest/test-result': 29.5.0 - '@jest/transform': 29.5.0 - '@jest/types': 29.5.0 - '@types/node': 18.15.11 + '@jest/console': 29.7.0 + '@jest/reporters': 29.7.0 + '@jest/test-result': 29.7.0 + '@jest/transform': 29.7.0 + '@jest/types': 29.6.3 + '@types/node': 18.19.21 ansi-escapes: 4.3.2 chalk: 4.1.2 - ci-info: 3.8.0 + ci-info: 3.9.0 exit: 0.1.2 graceful-fs: 4.2.11 - jest-changed-files: 29.5.0 - jest-config: 29.5.0(@types/node@18.15.11) - jest-haste-map: 29.5.0 - jest-message-util: 29.5.0 - jest-regex-util: 29.4.3 - jest-resolve: 29.5.0 - jest-resolve-dependencies: 29.5.0 - jest-runner: 29.5.0 - jest-runtime: 29.5.0 - jest-snapshot: 29.5.0 - jest-util: 29.5.0 - jest-validate: 29.5.0 - jest-watcher: 29.5.0 + jest-changed-files: 29.7.0 + jest-config: 29.7.0(@types/node@18.19.21) + jest-haste-map: 29.7.0 + jest-message-util: 29.7.0 + jest-regex-util: 29.6.3 + jest-resolve: 29.7.0 + jest-resolve-dependencies: 29.7.0 + jest-runner: 29.7.0 + jest-runtime: 29.7.0 + jest-snapshot: 29.7.0 + jest-util: 29.7.0 + jest-validate: 29.7.0 + jest-watcher: 29.7.0 micromatch: 4.0.5 - pretty-format: 29.5.0 + pretty-format: 29.7.0 slash: 3.0.0 strip-ansi: 6.0.1 transitivePeerDependencies: + - babel-plugin-macros - supports-color - ts-node dev: true - /@jest/environment@29.5.0: - resolution: {integrity: sha512-5FXw2+wD29YU1d4I2htpRX7jYnAyTRjP2CsXQdo9SAM8g3ifxWPSV0HnClSn71xwctr0U3oZIIH+dtbfmnbXVQ==} + /@jest/environment@29.7.0: + resolution: {integrity: sha512-aQIfHDq33ExsN4jP1NWGXhxgQ/wixs60gDiKO+XVMd8Mn0NWPWgc34ZQDTb2jKaUWQ7MuwoitXAsN2XVXNMpAw==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} dependencies: - '@jest/fake-timers': 29.5.0 - '@jest/types': 29.5.0 - '@types/node': 18.15.11 - jest-mock: 29.5.0 + '@jest/fake-timers': 29.7.0 + '@jest/types': 29.6.3 + '@types/node': 18.19.21 + jest-mock: 29.7.0 dev: true - /@jest/expect-utils@29.5.0: - resolution: {integrity: sha512-fmKzsidoXQT2KwnrwE0SQq3uj8Z763vzR8LnLBwC2qYWEFpjX8daRsk6rHUM1QvNlEW/UJXNXm59ztmJJWs2Mg==} + /@jest/expect-utils@29.7.0: + resolution: {integrity: sha512-GlsNBWiFQFCVi9QVSx7f5AgMeLxe9YCCs5PuP2O2LdjDAA8Jh9eX7lA1Jq/xdXw3Wb3hyvlFNfZIfcRetSzYcA==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} dependencies: - jest-get-type: 29.4.3 + jest-get-type: 29.6.3 dev: true - /@jest/expect@29.5.0: - resolution: {integrity: sha512-PueDR2HGihN3ciUNGr4uelropW7rqUfTiOn+8u0leg/42UhblPxHkfoh0Ruu3I9Y1962P3u2DY4+h7GVTSVU6g==} + /@jest/expect@29.7.0: + resolution: {integrity: sha512-8uMeAMycttpva3P1lBHB8VciS9V0XAr3GymPpipdyQXbBcuhkLQOSe8E/p92RyAdToS6ZD1tFkX+CkhoECE0dQ==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} dependencies: - expect: 29.5.0 - jest-snapshot: 29.5.0 + expect: 29.7.0 + jest-snapshot: 29.7.0 transitivePeerDependencies: - supports-color dev: true - /@jest/fake-timers@29.5.0: - resolution: {integrity: sha512-9ARvuAAQcBwDAqOnglWq2zwNIRUDtk/SCkp/ToGEhFv5r86K21l+VEs0qNTaXtyiY0lEePl3kylijSYJQqdbDg==} + /@jest/fake-timers@29.7.0: + resolution: {integrity: sha512-q4DH1Ha4TTFPdxLsqDXK1d3+ioSL7yL5oCMJZgDYm6i+6CygW5E5xVr/D1HdsGxjt1ZWSfUAs9OxSB/BNelWrQ==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} dependencies: - '@jest/types': 29.5.0 - '@sinonjs/fake-timers': 10.0.2 - '@types/node': 18.15.11 - jest-message-util: 29.5.0 - jest-mock: 29.5.0 - jest-util: 29.5.0 + '@jest/types': 29.6.3 + '@sinonjs/fake-timers': 10.3.0 + '@types/node': 18.19.21 + jest-message-util: 29.7.0 + jest-mock: 29.7.0 + jest-util: 29.7.0 dev: true - /@jest/globals@29.5.0: - resolution: {integrity: sha512-S02y0qMWGihdzNbUiqSAiKSpSozSuHX5UYc7QbnHP+D9Lyw8DgGGCinrN9uSuHPeKgSSzvPom2q1nAtBvUsvPQ==} + /@jest/globals@29.7.0: + resolution: {integrity: sha512-mpiz3dutLbkW2MNFubUGUEVLkTGiqW6yLVTA+JbP6fI6J5iL9Y0Nlg8k95pcF8ctKwCS7WVxteBs29hhfAotzQ==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} dependencies: - '@jest/environment': 29.5.0 - '@jest/expect': 29.5.0 - '@jest/types': 29.5.0 - jest-mock: 29.5.0 + '@jest/environment': 29.7.0 + '@jest/expect': 29.7.0 + '@jest/types': 29.6.3 + jest-mock: 29.7.0 transitivePeerDependencies: - supports-color dev: true - /@jest/reporters@29.5.0: - resolution: {integrity: sha512-D05STXqj/M8bP9hQNSICtPqz97u7ffGzZu+9XLucXhkOFBqKcXe04JLZOgIekOxdb73MAoBUFnqvf7MCpKk5OA==} + /@jest/reporters@29.7.0: + resolution: {integrity: sha512-DApq0KJbJOEzAFYjHADNNxAE3KbhxQB1y5Kplb5Waqw6zVbuWatSnMjE5gs8FUgEPmNsnZA3NCWl9NG0ia04Pg==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} peerDependencies: node-notifier: ^8.0.1 || ^9.0.0 || ^10.0.0 @@ -2736,136 +2654,132 @@ packages: optional: true dependencies: '@bcoe/v8-coverage': 0.2.3 - '@jest/console': 29.5.0 - '@jest/test-result': 29.5.0 - '@jest/transform': 29.5.0 - '@jest/types': 29.5.0 - '@jridgewell/trace-mapping': 0.3.18 - '@types/node': 18.15.11 + '@jest/console': 29.7.0 + '@jest/test-result': 29.7.0 + '@jest/transform': 29.7.0 + '@jest/types': 29.6.3 + '@jridgewell/trace-mapping': 0.3.23 + '@types/node': 18.19.21 chalk: 4.1.2 - collect-v8-coverage: 1.0.1 + collect-v8-coverage: 1.0.2 exit: 0.1.2 glob: 7.2.3 graceful-fs: 4.2.11 - istanbul-lib-coverage: 3.2.0 - istanbul-lib-instrument: 5.2.1 - istanbul-lib-report: 3.0.0 + istanbul-lib-coverage: 3.2.2 + istanbul-lib-instrument: 6.0.2 + istanbul-lib-report: 3.0.1 istanbul-lib-source-maps: 4.0.1 - istanbul-reports: 3.1.5 - jest-message-util: 29.5.0 - jest-util: 29.5.0 - jest-worker: 29.5.0 + istanbul-reports: 3.1.7 + jest-message-util: 29.7.0 + jest-util: 29.7.0 + jest-worker: 29.7.0 slash: 3.0.0 string-length: 4.0.2 strip-ansi: 6.0.1 - v8-to-istanbul: 9.1.0 + v8-to-istanbul: 9.2.0 transitivePeerDependencies: - supports-color dev: true - /@jest/schemas@29.4.3: - resolution: {integrity: sha512-VLYKXQmtmuEz6IxJsrZwzG9NvtkQsWNnWMsKxqWNu3+CnfzJQhp0WDDKWLVV9hLKr0l3SLLFRqcYHjhtyuDVxg==} + /@jest/schemas@29.6.3: + resolution: {integrity: sha512-mo5j5X+jIZmJQveBKeS/clAueipV7KgiX1vMgCxam1RNYiqE1w62n0/tJJnHtjW8ZHcQco5gY85jA3mi0L+nSA==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} dependencies: - '@sinclair/typebox': 0.25.24 + '@sinclair/typebox': 0.27.8 dev: true - /@jest/source-map@29.4.3: - resolution: {integrity: sha512-qyt/mb6rLyd9j1jUts4EQncvS6Yy3PM9HghnNv86QBlV+zdL2inCdK1tuVlL+J+lpiw2BI67qXOrX3UurBqQ1w==} + /@jest/source-map@29.6.3: + resolution: {integrity: sha512-MHjT95QuipcPrpLM+8JMSzFx6eHp5Bm+4XeFDJlwsvVBjmKNiIAvasGK2fxz2WbGRlnvqehFbh07MMa7n3YJnw==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} dependencies: - '@jridgewell/trace-mapping': 0.3.18 + '@jridgewell/trace-mapping': 0.3.23 callsites: 3.1.0 graceful-fs: 4.2.11 dev: true - /@jest/test-result@29.5.0: - resolution: {integrity: sha512-fGl4rfitnbfLsrfx1uUpDEESS7zM8JdgZgOCQuxQvL1Sn/I6ijeAVQWGfXI9zb1i9Mzo495cIpVZhA0yr60PkQ==} + /@jest/test-result@29.7.0: + resolution: {integrity: sha512-Fdx+tv6x1zlkJPcWXmMDAG2HBnaR9XPSd5aDWQVsfrZmLVT3lU1cwyxLgRmXR9yrq4NBoEm9BMsfgFzTQAbJYA==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} dependencies: - '@jest/console': 29.5.0 - '@jest/types': 29.5.0 - '@types/istanbul-lib-coverage': 2.0.4 - collect-v8-coverage: 1.0.1 + '@jest/console': 29.7.0 + '@jest/types': 29.6.3 + '@types/istanbul-lib-coverage': 2.0.6 + collect-v8-coverage: 1.0.2 dev: true - /@jest/test-sequencer@29.5.0: - resolution: {integrity: sha512-yPafQEcKjkSfDXyvtgiV4pevSeyuA6MQr6ZIdVkWJly9vkqjnFfcfhRQqpD5whjoU8EORki752xQmjaqoFjzMQ==} + /@jest/test-sequencer@29.7.0: + resolution: {integrity: sha512-GQwJ5WZVrKnOJuiYiAF52UNUJXgTZx1NHjFSEB0qEMmSZKAkdMoIzw/Cj6x6NF4AvV23AUqDpFzQkN/eYCYTxw==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} dependencies: - '@jest/test-result': 29.5.0 + '@jest/test-result': 29.7.0 graceful-fs: 4.2.11 - jest-haste-map: 29.5.0 + jest-haste-map: 29.7.0 slash: 3.0.0 dev: true - /@jest/transform@29.5.0: - resolution: {integrity: sha512-8vbeZWqLJOvHaDfeMuoHITGKSz5qWc9u04lnWrQE3VyuSw604PzQM824ZeX9XSjUCeDiE3GuxZe5UKa8J61NQw==} + /@jest/transform@29.7.0: + resolution: {integrity: sha512-ok/BTPFzFKVMwO5eOHRrvnBVHdRy9IrsrW1GpMaQ9MCnilNLXQKmAX8s1YXDFaai9xJpac2ySzV0YeRRECr2Vw==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} dependencies: - '@babel/core': 7.21.4 - '@jest/types': 29.5.0 - '@jridgewell/trace-mapping': 0.3.18 + '@babel/core': 7.24.0 + '@jest/types': 29.6.3 + '@jridgewell/trace-mapping': 0.3.23 babel-plugin-istanbul: 6.1.1 chalk: 4.1.2 convert-source-map: 2.0.0 fast-json-stable-stringify: 2.1.0 graceful-fs: 4.2.11 - jest-haste-map: 29.5.0 - jest-regex-util: 29.4.3 - jest-util: 29.5.0 + jest-haste-map: 29.7.0 + jest-regex-util: 29.6.3 + jest-util: 29.7.0 micromatch: 4.0.5 - pirates: 4.0.5 + pirates: 4.0.6 slash: 3.0.0 write-file-atomic: 4.0.2 transitivePeerDependencies: - supports-color dev: true - /@jest/types@29.5.0: - resolution: {integrity: sha512-qbu7kN6czmVRc3xWFQcAN03RAUamgppVUdXrvl1Wr3jlNF93o9mJbGcDWrwGB6ht44u7efB1qCFgVQmca24Uog==} + /@jest/types@29.6.3: + resolution: {integrity: sha512-u3UPsIilWKOM3F9CXtrG8LEJmNxwoCQC/XVj4IKYXvvpx7QIi/Kg1LI5uDmDpKlac62NUtX7eLjRh+jVZcLOzw==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} dependencies: - '@jest/schemas': 29.4.3 - '@types/istanbul-lib-coverage': 2.0.4 - '@types/istanbul-reports': 3.0.1 - '@types/node': 18.15.11 - '@types/yargs': 17.0.24 + '@jest/schemas': 29.6.3 + '@types/istanbul-lib-coverage': 2.0.6 + '@types/istanbul-reports': 3.0.4 + '@types/node': 18.19.21 + '@types/yargs': 17.0.32 chalk: 4.1.2 dev: true - /@jridgewell/gen-mapping@0.3.3: - resolution: {integrity: sha512-HLhSWOLRi875zjjMG/r+Nv0oCW8umGb0BgEhyX3dDX3egwZtB8PqLnjz3yedt8R5StBrzcg4aBpnh8UA9D1BoQ==} + /@jridgewell/gen-mapping@0.3.4: + resolution: {integrity: sha512-Oud2QPM5dHviZNn4y/WhhYKSXksv+1xLEIsNrAbGcFzUN3ubqWRFT5gwPchNc5NuzILOU4tPBDTZ4VwhL8Y7cw==} engines: {node: '>=6.0.0'} dependencies: - '@jridgewell/set-array': 1.1.2 + '@jridgewell/set-array': 1.2.1 '@jridgewell/sourcemap-codec': 1.4.15 - '@jridgewell/trace-mapping': 0.3.18 + '@jridgewell/trace-mapping': 0.3.23 dev: true - /@jridgewell/resolve-uri@3.1.0: - resolution: {integrity: sha512-F2msla3tad+Mfht5cJq7LSXcdudKTWCVYUgw6pLFOOHSTtZlj6SWNYAp+AhuqLmWdBO2X5hPrLcu8cVP8fy28w==} + /@jridgewell/resolve-uri@3.1.2: + resolution: {integrity: sha512-bRISgCIjP20/tbWSPWMEi54QVPRZExkuD9lJL+UIxUKtwVJA8wW1Trb1jMs1RFXo1CBTNZ/5hpC9QvmKWdopKw==} engines: {node: '>=6.0.0'} dev: true - /@jridgewell/set-array@1.1.2: - resolution: {integrity: sha512-xnkseuNADM0gt2bs+BvhO0p78Mk762YnZdsuzFV018NoG1Sj1SCQvpSqa7XUaTam5vAGasABV9qXASMKnFMwMw==} + /@jridgewell/set-array@1.2.1: + resolution: {integrity: sha512-R8gLRTZeyp03ymzP/6Lil/28tGeGEzhx1q2k703KGWRAI1VdvPIXdG70VJc2pAMw3NA6JKL5hhFu1sJX0Mnn/A==} engines: {node: '>=6.0.0'} dev: true - /@jridgewell/sourcemap-codec@1.4.14: - resolution: {integrity: sha512-XPSJHWmi394fuUuzDnGz1wiKqWfo1yXecHQMRf2l6hztTO+nPru658AyDngaBe7isIxEkRsPR3FZh+s7iVa4Uw==} - dev: true - /@jridgewell/sourcemap-codec@1.4.15: resolution: {integrity: sha512-eF2rxCRulEKXHTRiDrDy6erMYWqNw4LPdQ8UQA4huuxaQsVeRPFl2oM8oDGxMFhJUWZf9McpLtJasDDZb/Bpeg==} dev: true - /@jridgewell/trace-mapping@0.3.18: - resolution: {integrity: sha512-w+niJYzMHdd7USdiH2U6869nqhD2nbfZXND5Yp93qIbEmnDNk7PD48o+YchRVpzMU7M6jVCbenTR7PA1FLQ9pA==} + /@jridgewell/trace-mapping@0.3.23: + resolution: {integrity: sha512-9/4foRoUKp8s96tSkh8DlAAc5A0Ty8vLXld+l9gjKKY6ckwI8G15f0hskGmuLZu78ZlGa1vtsfOa+lnB4vG6Jg==} dependencies: - '@jridgewell/resolve-uri': 3.1.0 - '@jridgewell/sourcemap-codec': 1.4.14 + '@jridgewell/resolve-uri': 3.1.2 + '@jridgewell/sourcemap-codec': 1.4.15 dev: true /@koa/cors@4.0.0: @@ -2891,7 +2805,7 @@ packages: /@manypkg/find-root@1.1.0: resolution: {integrity: sha512-mki5uBvhHzO8kYYix/WRy2WX8S3B5wdVSc9D6KcU5lQNglP2yt58/VfLuAK49glRXChosY8ap2oJ1qgma3GUVA==} dependencies: - '@babel/runtime': 7.21.0 + '@babel/runtime': 7.24.0 '@types/node': 12.20.55 find-up: 4.1.0 fs-extra: 8.1.0 @@ -2900,7 +2814,7 @@ packages: /@manypkg/get-packages@1.1.3: resolution: {integrity: sha512-fo+QhuU3qE/2TQMQmbVMqaQ6EWbMhi4ABWP+O4AM1NqPBuy0OrApV5LO6BrrgnhtAHS2NH6RrVk9OL181tTi8A==} dependencies: - '@babel/runtime': 7.21.0 + '@babel/runtime': 7.24.0 '@changesets/types': 4.1.0 '@manypkg/find-root': 1.1.0 fs-extra: 8.1.0 @@ -2925,6 +2839,12 @@ packages: '@noble/hashes': 1.3.2 dev: false + /@noble/curves@1.3.0: + resolution: {integrity: sha512-t01iSXPuN+Eqzb4eBX0S5oubSqXbK/xXa1Ne18Hj8f9pStxztHCE2gfboSp/dZRLSqfuLpRK2nDXDK+W9puocA==} + dependencies: + '@noble/hashes': 1.3.3 + dev: true + /@noble/hashes@1.2.0: resolution: {integrity: sha512-FZfhjEDbT5GRswV3C6uvLPHMiVD6lQBmpoX5+eSiPaMTXte/IKqI5dykDxzZB/WBeK/CDuQRBWarPdi3FNY2zQ==} dev: true @@ -2934,6 +2854,11 @@ packages: engines: {node: '>= 16'} dev: false + /@noble/hashes@1.3.3: + resolution: {integrity: sha512-V7/fPHgl+jsVPXqqeOzT8egNj2iBIVt+ECeMMG8TdcnTikP3oaBtUVqpT/gYCR68aEBJSF+XbYUxStjbFMqIIA==} + engines: {node: '>= 16'} + dev: true + /@noble/secp256k1@1.7.1: resolution: {integrity: sha512-hOUk6AyBFmqVrv7k5WAw/LpszxVbj9gGN4JRkIX52fdFAj1UA61KXmZDvqVEm+pOyec3+fIeZB02LYa/pWOArw==} dev: true @@ -2954,10 +2879,185 @@ packages: engines: {node: '>= 8'} dependencies: '@nodelib/fs.scandir': 2.1.5 - fastq: 1.15.0 + fastq: 1.17.1 + + /@nomicfoundation/ethereumjs-block@5.0.4: + resolution: {integrity: sha512-AcyacJ9eX/uPEvqsPiB+WO1ymE+kyH48qGGiGV+YTojdtas8itUTW5dehDSOXEEItWGbbzEJ4PRqnQZlWaPvDw==} + engines: {node: '>=18'} + dependencies: + '@nomicfoundation/ethereumjs-common': 4.0.4 + '@nomicfoundation/ethereumjs-rlp': 5.0.4 + '@nomicfoundation/ethereumjs-trie': 6.0.4 + '@nomicfoundation/ethereumjs-tx': 5.0.4 + '@nomicfoundation/ethereumjs-util': 9.0.4 + ethereum-cryptography: 0.1.3 + transitivePeerDependencies: + - c-kzg + dev: true + + /@nomicfoundation/ethereumjs-blockchain@7.0.4: + resolution: {integrity: sha512-jYsd/kwzbmpnxx86tXsYV8wZ5xGvFL+7/P0c6OlzpClHsbFzeF41KrYA9scON8Rg6bZu3ZTv6JOAgj3t7USUfg==} + engines: {node: '>=18'} + dependencies: + '@nomicfoundation/ethereumjs-block': 5.0.4 + '@nomicfoundation/ethereumjs-common': 4.0.4 + '@nomicfoundation/ethereumjs-ethash': 3.0.4 + '@nomicfoundation/ethereumjs-rlp': 5.0.4 + '@nomicfoundation/ethereumjs-trie': 6.0.4 + '@nomicfoundation/ethereumjs-tx': 5.0.4 + '@nomicfoundation/ethereumjs-util': 9.0.4 + debug: 4.3.4(supports-color@8.1.1) + ethereum-cryptography: 0.1.3 + lru-cache: 10.2.0 + transitivePeerDependencies: + - c-kzg + - supports-color + dev: true + + /@nomicfoundation/ethereumjs-common@4.0.4: + resolution: {integrity: sha512-9Rgb658lcWsjiicr5GzNCjI1llow/7r0k50dLL95OJ+6iZJcVbi15r3Y0xh2cIO+zgX0WIHcbzIu6FeQf9KPrg==} + dependencies: + '@nomicfoundation/ethereumjs-util': 9.0.4 + transitivePeerDependencies: + - c-kzg + dev: true + + /@nomicfoundation/ethereumjs-ethash@3.0.4: + resolution: {integrity: sha512-xvIrwIMl9sSaiYKRem68+O7vYdj7Q2XWv5P7JXiIkn83918QzWHvqbswTRsH7+r6X1UEvdsURRnZbvZszEjAaQ==} + engines: {node: '>=18'} + dependencies: + '@nomicfoundation/ethereumjs-block': 5.0.4 + '@nomicfoundation/ethereumjs-rlp': 5.0.4 + '@nomicfoundation/ethereumjs-util': 9.0.4 + bigint-crypto-utils: 3.3.0 + ethereum-cryptography: 0.1.3 + transitivePeerDependencies: + - c-kzg + dev: true + + /@nomicfoundation/ethereumjs-evm@2.0.4(@nomicfoundation/ethereumjs-verkle@0.0.2): + resolution: {integrity: sha512-lTyZZi1KpeMHzaO6cSVisR2tjiTTedjo7PcmhI/+GNFo9BmyY6QYzGeSti0sFttmjbEMioHgXxl5yrLNRg6+1w==} + engines: {node: '>=18'} + dependencies: + '@nomicfoundation/ethereumjs-common': 4.0.4 + '@nomicfoundation/ethereumjs-statemanager': 2.0.4(@nomicfoundation/ethereumjs-verkle@0.0.2) + '@nomicfoundation/ethereumjs-tx': 5.0.4 + '@nomicfoundation/ethereumjs-util': 9.0.4 + '@types/debug': 4.1.12 + debug: 4.3.4(supports-color@8.1.1) + ethereum-cryptography: 0.1.3 + rustbn-wasm: 0.2.0 + transitivePeerDependencies: + - '@nomicfoundation/ethereumjs-verkle' + - c-kzg + - supports-color + dev: true + + /@nomicfoundation/ethereumjs-rlp@5.0.4: + resolution: {integrity: sha512-8H1S3s8F6QueOc/X92SdrA4RDenpiAEqMg5vJH99kcQaCy/a3Q6fgseo75mgWlbanGJXSlAPtnCeG9jvfTYXlw==} + engines: {node: '>=18'} + hasBin: true + dev: true + + /@nomicfoundation/ethereumjs-statemanager@2.0.4(@nomicfoundation/ethereumjs-verkle@0.0.2): + resolution: {integrity: sha512-HPDjeFrxw6llEi+BzqXkZ+KkvFnTOPczuHBtk21hRlDiuKuZz32dPzlhpRsDBGV1b5JTmRDUVqCS1lp3Gghw4Q==} + peerDependencies: + '@nomicfoundation/ethereumjs-verkle': 0.0.2 + peerDependenciesMeta: + '@nomicfoundation/ethereumjs-verkle': + optional: true + dependencies: + '@nomicfoundation/ethereumjs-common': 4.0.4 + '@nomicfoundation/ethereumjs-rlp': 5.0.4 + '@nomicfoundation/ethereumjs-trie': 6.0.4 + '@nomicfoundation/ethereumjs-util': 9.0.4 + '@nomicfoundation/ethereumjs-verkle': 0.0.2 + debug: 4.3.4(supports-color@8.1.1) + ethereum-cryptography: 0.1.3 + js-sdsl: 4.4.2 + lru-cache: 10.2.0 + transitivePeerDependencies: + - c-kzg + - supports-color + dev: true + + /@nomicfoundation/ethereumjs-trie@6.0.4: + resolution: {integrity: sha512-3nSwQiFMvr2VFe/aZUyinuohYvtytUqZCUCvIWcPJ/BwJH6oQdZRB42aNFBJ/8nAh2s3OcroWpBLskzW01mFKA==} + engines: {node: '>=18'} + dependencies: + '@nomicfoundation/ethereumjs-rlp': 5.0.4 + '@nomicfoundation/ethereumjs-util': 9.0.4 + '@types/readable-stream': 2.3.15 + ethereum-cryptography: 0.1.3 + lru-cache: 10.2.0 + readable-stream: 3.6.2 + transitivePeerDependencies: + - c-kzg + dev: true + + /@nomicfoundation/ethereumjs-tx@5.0.4: + resolution: {integrity: sha512-Xjv8wAKJGMrP1f0n2PeyfFCCojHd7iS3s/Ab7qzF1S64kxZ8Z22LCMynArYsVqiFx6rzYy548HNVEyI+AYN/kw==} + engines: {node: '>=18'} + peerDependencies: + c-kzg: ^2.1.2 + peerDependenciesMeta: + c-kzg: + optional: true + dependencies: + '@nomicfoundation/ethereumjs-common': 4.0.4 + '@nomicfoundation/ethereumjs-rlp': 5.0.4 + '@nomicfoundation/ethereumjs-util': 9.0.4 + ethereum-cryptography: 0.1.3 + dev: true + + /@nomicfoundation/ethereumjs-util@9.0.4: + resolution: {integrity: sha512-sLOzjnSrlx9Bb9EFNtHzK/FJFsfg2re6bsGqinFinH1gCqVfz9YYlXiMWwDM4C/L4ywuHFCYwfKTVr/QHQcU0Q==} + engines: {node: '>=18'} + peerDependencies: + c-kzg: ^2.1.2 + peerDependenciesMeta: + c-kzg: + optional: true + dependencies: + '@nomicfoundation/ethereumjs-rlp': 5.0.4 + ethereum-cryptography: 0.1.3 + dev: true + + /@nomicfoundation/ethereumjs-verkle@0.0.2: + resolution: {integrity: sha512-bjnfZElpYGK/XuuVRmLS3yDvr+cDs85D9oonZ0YUa5A3lgFgokWMp76zXrxX2jVQ0BfHaw12y860n1+iOi6yFQ==} + engines: {node: '>=18'} + dependencies: + '@nomicfoundation/ethereumjs-rlp': 5.0.4 + '@nomicfoundation/ethereumjs-util': 9.0.4 + lru-cache: 10.2.0 + rust-verkle-wasm: 0.0.1 + transitivePeerDependencies: + - c-kzg + dev: true + + /@nomicfoundation/ethereumjs-vm@7.0.4(@nomicfoundation/ethereumjs-verkle@0.0.2): + resolution: {integrity: sha512-gsA4IhmtWHI4BofKy3kio9W+dqZQs5Ji5mLjLYxHCkat+JQBUt5szjRKra2F9nGDJ2XcI/wWb0YWUFNgln4zRQ==} + engines: {node: '>=18'} + dependencies: + '@nomicfoundation/ethereumjs-block': 5.0.4 + '@nomicfoundation/ethereumjs-blockchain': 7.0.4 + '@nomicfoundation/ethereumjs-common': 4.0.4 + '@nomicfoundation/ethereumjs-evm': 2.0.4(@nomicfoundation/ethereumjs-verkle@0.0.2) + '@nomicfoundation/ethereumjs-rlp': 5.0.4 + '@nomicfoundation/ethereumjs-statemanager': 2.0.4(@nomicfoundation/ethereumjs-verkle@0.0.2) + '@nomicfoundation/ethereumjs-trie': 6.0.4 + '@nomicfoundation/ethereumjs-tx': 5.0.4 + '@nomicfoundation/ethereumjs-util': 9.0.4 + debug: 4.3.4(supports-color@8.1.1) + ethereum-cryptography: 0.1.3 + transitivePeerDependencies: + - '@nomicfoundation/ethereumjs-verkle' + - c-kzg + - supports-color + dev: true - /@nomicfoundation/hardhat-chai-matchers@1.0.3(@nomiclabs/hardhat-ethers@2.1.1)(chai@4.3.7)(ethers@5.7.2)(hardhat@2.10.2): - resolution: {integrity: sha512-qEE7Drs2HSY+krH09TXm6P9LFogs0BqbUq6wPD7nQRhmJ+p5zoDaIZjM5WL1pHqU5MpGqya3y+BdwmTYBfU5UA==} + /@nomicfoundation/hardhat-chai-matchers@1.0.6(@nomiclabs/hardhat-ethers@2.2.3)(chai@4.4.1)(ethers@5.7.2)(hardhat@2.20.1): + resolution: {integrity: sha512-f5ZMNmabZeZegEfuxn/0kW+mm7+yV7VNDxLpMOMGXWFJ2l/Ct3QShujzDRF9cOkK9Ui/hbDeOWGZqyQALDXVCQ==} peerDependencies: '@nomiclabs/hardhat-ethers': ^2.0.0 chai: ^4.2.0 @@ -2965,92 +3065,187 @@ packages: hardhat: ^2.9.4 dependencies: '@ethersproject/abi': 5.7.0 - '@nomiclabs/hardhat-ethers': 2.1.1(ethers@5.7.2)(hardhat@2.10.2) - '@types/chai-as-promised': 7.1.5 - chai: 4.3.7 - chai-as-promised: 7.1.1(chai@4.3.7) - chalk: 2.4.2 + '@nomiclabs/hardhat-ethers': 2.2.3(ethers@5.7.2)(hardhat@2.20.1) + '@types/chai-as-promised': 7.1.8 + chai: 4.4.1 + chai-as-promised: 7.1.1(chai@4.4.1) deep-eql: 4.1.3 ethers: 5.7.2 - hardhat: 2.10.2(typescript@5.1.6) + hardhat: 2.20.1(typescript@5.1.6) ordinal: 1.0.3 dev: true - /@nomiclabs/hardhat-ethers@2.1.1(ethers@5.7.2)(hardhat@2.10.2): - resolution: {integrity: sha512-Gg0IFkT/DW3vOpih4/kMjeZCLYqtfgECLeLXTs7ZDPzcK0cfoc5wKk4nq5n/izCUzdhidO/Utd6ptF9JrWwWVA==} + /@nomicfoundation/solidity-analyzer-darwin-arm64@0.1.1: + resolution: {integrity: sha512-KcTodaQw8ivDZyF+D76FokN/HdpgGpfjc/gFCImdLUyqB6eSWVaZPazMbeAjmfhx3R0zm/NYVzxwAokFKgrc0w==} + engines: {node: '>= 10'} + cpu: [arm64] + os: [darwin] + requiresBuild: true + dev: true + optional: true + + /@nomicfoundation/solidity-analyzer-darwin-x64@0.1.1: + resolution: {integrity: sha512-XhQG4BaJE6cIbjAVtzGOGbK3sn1BO9W29uhk9J8y8fZF1DYz0Doj8QDMfpMu+A6TjPDs61lbsmeYodIDnfveSA==} + engines: {node: '>= 10'} + cpu: [x64] + os: [darwin] + requiresBuild: true + dev: true + optional: true + + /@nomicfoundation/solidity-analyzer-freebsd-x64@0.1.1: + resolution: {integrity: sha512-GHF1VKRdHW3G8CndkwdaeLkVBi5A9u2jwtlS7SLhBc8b5U/GcoL39Q+1CSO3hYqePNP+eV5YI7Zgm0ea6kMHoA==} + engines: {node: '>= 10'} + cpu: [x64] + os: [freebsd] + requiresBuild: true + dev: true + optional: true + + /@nomicfoundation/solidity-analyzer-linux-arm64-gnu@0.1.1: + resolution: {integrity: sha512-g4Cv2fO37ZsUENQ2vwPnZc2zRenHyAxHcyBjKcjaSmmkKrFr64yvzeNO8S3GBFCo90rfochLs99wFVGT/0owpg==} + engines: {node: '>= 10'} + cpu: [arm64] + os: [linux] + requiresBuild: true + dev: true + optional: true + + /@nomicfoundation/solidity-analyzer-linux-arm64-musl@0.1.1: + resolution: {integrity: sha512-WJ3CE5Oek25OGE3WwzK7oaopY8xMw9Lhb0mlYuJl/maZVo+WtP36XoQTb7bW/i8aAdHW5Z+BqrHMux23pvxG3w==} + engines: {node: '>= 10'} + cpu: [arm64] + os: [linux] + requiresBuild: true + dev: true + optional: true + + /@nomicfoundation/solidity-analyzer-linux-x64-gnu@0.1.1: + resolution: {integrity: sha512-5WN7leSr5fkUBBjE4f3wKENUy9HQStu7HmWqbtknfXkkil+eNWiBV275IOlpXku7v3uLsXTOKpnnGHJYI2qsdA==} + engines: {node: '>= 10'} + cpu: [x64] + os: [linux] + requiresBuild: true + dev: true + optional: true + + /@nomicfoundation/solidity-analyzer-linux-x64-musl@0.1.1: + resolution: {integrity: sha512-KdYMkJOq0SYPQMmErv/63CwGwMm5XHenEna9X9aB8mQmhDBrYrlAOSsIPgFCUSL0hjxE3xHP65/EPXR/InD2+w==} + engines: {node: '>= 10'} + cpu: [x64] + os: [linux] + requiresBuild: true + dev: true + optional: true + + /@nomicfoundation/solidity-analyzer-win32-arm64-msvc@0.1.1: + resolution: {integrity: sha512-VFZASBfl4qiBYwW5xeY20exWhmv6ww9sWu/krWSesv3q5hA0o1JuzmPHR4LPN6SUZj5vcqci0O6JOL8BPw+APg==} + engines: {node: '>= 10'} + cpu: [arm64] + os: [win32] + requiresBuild: true + dev: true + optional: true + + /@nomicfoundation/solidity-analyzer-win32-ia32-msvc@0.1.1: + resolution: {integrity: sha512-JnFkYuyCSA70j6Si6cS1A9Gh1aHTEb8kOTBApp/c7NRTFGNMH8eaInKlyuuiIbvYFhlXW4LicqyYuWNNq9hkpQ==} + engines: {node: '>= 10'} + cpu: [ia32] + os: [win32] + requiresBuild: true + dev: true + optional: true + + /@nomicfoundation/solidity-analyzer-win32-x64-msvc@0.1.1: + resolution: {integrity: sha512-HrVJr6+WjIXGnw3Q9u6KQcbZCtk0caVWhCdFADySvRyUxJ8PnzlaP+MhwNE8oyT8OZ6ejHBRrrgjSqDCFXGirw==} + engines: {node: '>= 10'} + cpu: [x64] + os: [win32] + requiresBuild: true + dev: true + optional: true + + /@nomicfoundation/solidity-analyzer@0.1.1: + resolution: {integrity: sha512-1LMtXj1puAxyFusBgUIy5pZk3073cNXYnXUpuNKFghHbIit/xZgbk0AokpUADbNm3gyD6bFWl3LRFh3dhVdREg==} + engines: {node: '>= 12'} + optionalDependencies: + '@nomicfoundation/solidity-analyzer-darwin-arm64': 0.1.1 + '@nomicfoundation/solidity-analyzer-darwin-x64': 0.1.1 + '@nomicfoundation/solidity-analyzer-freebsd-x64': 0.1.1 + '@nomicfoundation/solidity-analyzer-linux-arm64-gnu': 0.1.1 + '@nomicfoundation/solidity-analyzer-linux-arm64-musl': 0.1.1 + '@nomicfoundation/solidity-analyzer-linux-x64-gnu': 0.1.1 + '@nomicfoundation/solidity-analyzer-linux-x64-musl': 0.1.1 + '@nomicfoundation/solidity-analyzer-win32-arm64-msvc': 0.1.1 + '@nomicfoundation/solidity-analyzer-win32-ia32-msvc': 0.1.1 + '@nomicfoundation/solidity-analyzer-win32-x64-msvc': 0.1.1 + dev: true + + /@nomiclabs/hardhat-ethers@2.2.3(ethers@5.7.2)(hardhat@2.20.1): + resolution: {integrity: sha512-YhzPdzb612X591FOe68q+qXVXGG2ANZRvDo0RRUtimev85rCrAlv/TLMEZw5c+kq9AbzocLTVX/h2jVIFPL9Xg==} peerDependencies: ethers: ^5.0.0 hardhat: ^2.0.0 dependencies: ethers: 5.7.2 - hardhat: 2.10.2(typescript@5.1.6) + hardhat: 2.20.1(typescript@5.1.6) dev: true - /@npmcli/fs@2.1.2: - resolution: {integrity: sha512-yOJKRvohFOaLqipNtwYB9WugyZKhC/DZC4VYPmpaCzDBrA8YpK3qHZ8/HGscMnE4GqbkLNuVcCnxkeQEdGt6LQ==} - engines: {node: ^12.13.0 || ^14.15.0 || >=16.0.0} - dependencies: - '@gar/promisify': 1.1.3 - semver: 7.5.0 - dev: false - - /@npmcli/move-file@2.0.1: - resolution: {integrity: sha512-mJd2Z5TjYWq/ttPLLGqArdtnC74J6bOzg4rMDnN+p1xTacZ2yPRCk2y0oSWQtygLR9YVQXgOcONrwtnk3JupxQ==} - engines: {node: ^12.13.0 || ^14.15.0 || >=16.0.0} - deprecated: This functionality has been moved to @npmcli/fs - dependencies: - mkdirp: 1.0.4 - rimraf: 3.0.2 - dev: false - - /@oven/bun-darwin-aarch64@1.0.11: - resolution: {integrity: sha512-6wCO37lyGNcqefEDQ7IJp4LW7ElKMH50/hlvW5agIBN/XbTwwtv3788dJ9NczEV7RQSlkOI6J3dUoQJ6Pgav6w==} + /@oven/bun-darwin-aarch64@1.0.29: + resolution: {integrity: sha512-OhlPQO0zE7rgZ2LpkLr3A3cOoS6V+V3QvkPtlwB5TLlnrbcs78rnRBse/ibl46GAA1HnEn1ugxbsjAJkZ31WVA==} cpu: [arm64] os: [darwin] requiresBuild: true dev: true optional: true - /@oven/bun-darwin-x64-baseline@1.0.11: - resolution: {integrity: sha512-is9liFB10GUN/UsSZVkO5tfMIJcBkiDqRvVzNkDHix/i5aXyaBb0vX+uOdJTlHDZyNGi+vHhbRMq3c3ezjJKPA==} + /@oven/bun-darwin-x64-baseline@1.0.29: + resolution: {integrity: sha512-/4RLSFIO+a0wVBR6/OZqEZJX3lGjPKK30V1Nce+ziceuk2Hmm+MsmzK/704UDi9MWWtXdRhe9Ayd4yZ+C0kZww==} cpu: [x64] os: [darwin] requiresBuild: true dev: true optional: true - /@oven/bun-darwin-x64@1.0.11: - resolution: {integrity: sha512-5eCtrlOfMuhg7es/6p/rZw5+4khBao/hhGKCPHl9LBok1Mrf5QQjGbXj9OoA2RC2Lxm9av4nrAZG/5nMM01B2g==} + /@oven/bun-darwin-x64@1.0.29: + resolution: {integrity: sha512-y7zjOWdUl7rtzt900XTYPwaSL0qBZpkGmHJNqEMmhVuqUclMwmQmqUnBDMoKwgW84nLQXkzcKyBZlOBNohpQZw==} cpu: [x64] os: [darwin] requiresBuild: true dev: true optional: true - /@oven/bun-linux-aarch64@1.0.11: - resolution: {integrity: sha512-P8hI+vQ+8ffsMLRi2TNzkxsHukrNQD8G2luWo/ndJ55+1uuAMScWZooxm9rgWL6baoB/TL9/Hvi/6INGoE8UlQ==} + /@oven/bun-linux-aarch64@1.0.29: + resolution: {integrity: sha512-X8czxV2WBKSO4tctlmgImhYeWIuD4Abd2gvwUqwDliMsMhkNL/AiLcbgS3M7TCG+YFsqyIkOj2uf7nixs3hIPA==} cpu: [arm64] os: [linux] requiresBuild: true dev: true optional: true - /@oven/bun-linux-x64-baseline@1.0.11: - resolution: {integrity: sha512-Asx4pEMDXfmu9Sa0jX4PE1Wijtg1oCfUx8o4FeQEvnVz2+cGG+VoqZXuITmoQC6A4IzAZuJ1tcWOZ8jQCDtvJA==} + /@oven/bun-linux-x64-baseline@1.0.29: + resolution: {integrity: sha512-mZTBwBi94dU9229M2z24euFIMHbeHbMrrlzl3f+CKPzZxKPe5FG6EOudr8xRCoiuvZGgbvbkqZeRFJQjpVdOfg==} cpu: [x64] os: [linux] requiresBuild: true dev: true optional: true - /@oven/bun-linux-x64@1.0.11: - resolution: {integrity: sha512-F9ZcgVHsPQk6ooHXIeydiLcVcMwhGRjSlOVeHBuHEJ+bI24e/dCY73UKEEz8/hLNA32ocDMmkAGE79qv0ccEIA==} + /@oven/bun-linux-x64@1.0.29: + resolution: {integrity: sha512-i9YbwQ2sh+IiruNq3nhKvZx0piZkMf/b58jkxbjxW+WfgNFpo0EMuj+ZwNDjF9VC6SMbsI9CoC6lmP4+CCM3nQ==} cpu: [x64] os: [linux] requiresBuild: true dev: true optional: true + /@pkgjs/parseargs@0.11.0: + resolution: {integrity: sha512-+1VkjdD0QBLPodGrJUeqarH8VAIvQODIbwh9XpP5Syisf7YoQgsJKPNFoqqLQlu+VQ/tVSshMR6loPMn8U+dPg==} + engines: {node: '>=14'} + requiresBuild: true + dev: true + optional: true + /@protobufjs/aspromise@1.1.2: resolution: {integrity: sha512-j+gKExEuLmKwvz3OgROXtrJ2UG2x8Ch2YZUxahh+s1F2HZ+wAceUNLkvy6zKCPVRkU++ZWQrdxsUeQXmcg4uoQ==} @@ -3084,38 +3279,20 @@ packages: /@protobufjs/utf8@1.1.0: resolution: {integrity: sha512-Vvn3zZrhQZkkBE8LSuW3em98c0FwgO4nxzv6OdSxPKJIEKY2bGbHn+mhGIPerzI4twdxaP8/0+06HBpwf345Lw==} - /@remix-run/router@1.6.0: - resolution: {integrity: sha512-N13NRw3T2+6Xi9J//3CGLsK2OqC8NMme3d/YX+nh05K9YHWGcv8DycHJrqGScSP4T75o8IN6nqIMhVFU8ohg8w==} - engines: {node: '>=14'} + /@remix-run/router@1.15.2: + resolution: {integrity: sha512-+Rnav+CaoTE5QJc4Jcwh5toUpnVLKYbpU6Ys0zqbakqbaLQHeglLVHPfxOiQqdNmUy5C2lXz5dwC6tQNX2JW2Q==} + engines: {node: '>=14.0.0'} dev: false - /@samverschueren/stream-to-observable@0.3.1(rxjs@6.6.7): - resolution: {integrity: sha512-c/qwwcHyafOQuVQJj0IlBjf5yYgBI7YPJ77k4fOJYesb41jio65eaJODRUmfYKhTOFBrIZ66kgvGPlNbjuoRdQ==} - engines: {node: '>=6'} - peerDependencies: - rxjs: '*' - zen-observable: '*' - peerDependenciesMeta: - rxjs: - optional: true - zen-observable: - optional: true - dependencies: - any-observable: 0.3.0(rxjs@6.6.7) - rxjs: 6.6.7 - transitivePeerDependencies: - - zenObservable - dev: true - - /@scure/base@1.1.3: - resolution: {integrity: sha512-/+SgoRjLq7Xlf0CWuLHq2LUZeL/w65kfzAPG5NH9pcmBhs+nunQTn4gvdwgMTIXnt9b2C/1SeL2XiysZEyIC9Q==} + /@scure/base@1.1.5: + resolution: {integrity: sha512-Brj9FiG2W1MRQSTB212YVPRrcbjkv48FoZi/u4l/zds/ieRrqsh7aUf6CLwkAq61oKXr/ZlTzlY66gLIj3TFTQ==} /@scure/bip32@1.1.5: resolution: {integrity: sha512-XyNh1rB0SkEqd3tXcXMi+Xe1fvg+kUIcoRIEujP1Jgv7DqW2r9lg3Ah0NkFaCs9sTkQAQA8kw7xiRXzENi9Rtw==} dependencies: '@noble/hashes': 1.2.0 '@noble/secp256k1': 1.7.1 - '@scure/base': 1.1.3 + '@scure/base': 1.1.5 dev: true /@scure/bip32@1.3.2: @@ -3123,30 +3300,45 @@ packages: dependencies: '@noble/curves': 1.2.0 '@noble/hashes': 1.3.2 - '@scure/base': 1.1.3 + '@scure/base': 1.1.5 dev: false + /@scure/bip32@1.3.3: + resolution: {integrity: sha512-LJaN3HwRbfQK0X1xFSi0Q9amqOgzQnnDngIt+ZlsBC3Bm7/nE7K0kwshZHyaru79yIVRv/e1mQAjZyuZG6jOFQ==} + dependencies: + '@noble/curves': 1.3.0 + '@noble/hashes': 1.3.3 + '@scure/base': 1.1.5 + dev: true + /@scure/bip39@1.1.1: resolution: {integrity: sha512-t+wDck2rVkh65Hmv280fYdVdY25J9YeEUIgn2LG1WM6gxFkGzcksoDiUkWVpVp3Oex9xGC68JU2dSbUfwZ2jPg==} dependencies: '@noble/hashes': 1.2.0 - '@scure/base': 1.1.3 + '@scure/base': 1.1.5 dev: true /@scure/bip39@1.2.1: resolution: {integrity: sha512-Z3/Fsz1yr904dduJD0NpiyRHhRYHdcnyh73FZWiV+/qhWi83wNJ3NWolYqCEN+ZWsUz2TWwajJggcRE9r1zUYg==} dependencies: '@noble/hashes': 1.3.2 - '@scure/base': 1.1.3 + '@scure/base': 1.1.5 dev: false - /@sentry-internal/tracing@7.86.0: - resolution: {integrity: sha512-b4dUsNWlPWRwakGwR7bhOkqiFlqQszH1hhVFwrm/8s3kqEBZ+E4CeIfCvuHBHQ1cM/fx55xpXX/BU163cy+3iQ==} + /@scure/bip39@1.2.2: + resolution: {integrity: sha512-HYf9TUXG80beW+hGAt3TRM8wU6pQoYur9iNypTROm42dorCGmLnFe3eWjz3gOq6G62H2WRh0FCzAR1PI+29zIA==} + dependencies: + '@noble/hashes': 1.3.3 + '@scure/base': 1.1.5 + dev: true + + /@sentry-internal/tracing@7.103.0: + resolution: {integrity: sha512-sZ/Wao8HOvGaBs7WlOdflMpHGAFkOBWL6hBiirHaOy5d+IDm7n7et5U6zhvcfiyYBO4nY36gy1Tg5mw+aNO0Vw==} engines: {node: '>=8'} dependencies: - '@sentry/core': 7.86.0 - '@sentry/types': 7.86.0 - '@sentry/utils': 7.86.0 + '@sentry/core': 7.103.0 + '@sentry/types': 7.103.0 + '@sentry/utils': 7.103.0 dev: false /@sentry/core@5.30.0: @@ -3160,12 +3352,12 @@ packages: tslib: 1.14.1 dev: true - /@sentry/core@7.86.0: - resolution: {integrity: sha512-SbLvqd1bRYzhDS42u7GMnmbDMfth/zRiLElQWbLK/shmuZzTcfQSwNNdF4Yj+VfjOkqPFgGmICHSHVUc9dh01g==} + /@sentry/core@7.103.0: + resolution: {integrity: sha512-LCI+PIDoF/RLqN41fNXum3ilmS6ukni6L7t38vSdibbe2G0804EbPLtOIpv2PkS8E6CFuRW5zOb+8OwEAAtZWw==} engines: {node: '>=8'} dependencies: - '@sentry/types': 7.86.0 - '@sentry/utils': 7.86.0 + '@sentry/types': 7.103.0 + '@sentry/utils': 7.103.0 dev: false /@sentry/hub@5.30.0: @@ -3177,15 +3369,6 @@ packages: tslib: 1.14.1 dev: true - /@sentry/hub@7.86.0: - resolution: {integrity: sha512-tS9g+yoD/Zs4OS/gCO4/ccT0m90o3brkCIm/gRzPqI5dq2hEE1qn8bF7HM/vLQARM+bsmTEzPzZy19104U5Btg==} - engines: {node: '>=8'} - dependencies: - '@sentry/core': 7.86.0 - '@sentry/types': 7.86.0 - '@sentry/utils': 7.86.0 - dev: false - /@sentry/minimal@5.30.0: resolution: {integrity: sha512-BwWb/owZKtkDX+Sc4zCSTNcvZUq7YcH3uAVlmh/gtR9rmUvbzAA3ewLuB3myi4wWRAMEtny6+J/FN/x+2wn9Xw==} engines: {node: '>=6'} @@ -3212,36 +3395,27 @@ packages: - supports-color dev: true - /@sentry/node@7.86.0: - resolution: {integrity: sha512-cB1bn/LMn2Km97Y3hv63xwWxT50/G5ixGuSxTZ3dCQM6VDhmZoCuC5NGT3itVvaRd6upQXRZa5W0Zgyh0HXKig==} + /@sentry/node@7.103.0: + resolution: {integrity: sha512-/bS/WNeO+PEd0r3o3LN0XGJV+l7hLNy1dTcn61VRgWGVs8SqMBb3uAvXAibZ9zGTCkaX/Ky3JumMcOOoxmNCtg==} engines: {node: '>=8'} dependencies: - '@sentry-internal/tracing': 7.86.0 - '@sentry/core': 7.86.0 - '@sentry/types': 7.86.0 - '@sentry/utils': 7.86.0 - https-proxy-agent: 5.0.1 - transitivePeerDependencies: - - supports-color + '@sentry-internal/tracing': 7.103.0 + '@sentry/core': 7.103.0 + '@sentry/types': 7.103.0 + '@sentry/utils': 7.103.0 dev: false - /@sentry/profiling-node@1.2.6: - resolution: {integrity: sha512-WsXO7VmLze5wPWHpvoRZFTtN+wHw9lYWKZs4T2FwPmvfNVaScGJey/+Wp51aM47Yy12Gj9n/BpqFYDsUXRLMvw==} + /@sentry/profiling-node@1.3.5(@sentry/node@7.103.0): + resolution: {integrity: sha512-n2bfEbtLW3WuIMQGyxKJKzBNZOb1JYfMeJQ2WQn/42F++69m+u7T0S3EDGRN0Y//fbt5+r0any+4r3kChRXZkQ==} engines: {node: '>=8.0.0'} hasBin: true requiresBuild: true + peerDependencies: + '@sentry/node': ^7.44.1 dependencies: - '@sentry/core': 7.86.0 - '@sentry/hub': 7.86.0 - '@sentry/node': 7.86.0 - '@sentry/types': 7.86.0 - '@sentry/utils': 7.86.0 + '@sentry/node': 7.103.0 detect-libc: 2.0.2 - node-abi: 3.52.0 - node-gyp: 9.4.1 - transitivePeerDependencies: - - bluebird - - supports-color + node-abi: 3.56.0 dev: false /@sentry/tracing@5.30.0: @@ -3260,8 +3434,8 @@ packages: engines: {node: '>=6'} dev: true - /@sentry/types@7.86.0: - resolution: {integrity: sha512-pGAt0+bMfWgo0KG2epthfNV4Wae03tURpoxNjGo5Fr4cXxvLTSijSAQ6rmmO4bXBJ7+rErEjX30g30o/eEdP9g==} + /@sentry/types@7.103.0: + resolution: {integrity: sha512-NCvKyx8d2AGBQKPARrJemZmZ16DiMo688OEikZg4BbvFNDUzK5Egm2BH0vfLDhbNkU19o3maJowrYo42m8r9Zw==} engines: {node: '>=8'} dev: false @@ -3273,37 +3447,31 @@ packages: tslib: 1.14.1 dev: true - /@sentry/utils@7.86.0: - resolution: {integrity: sha512-6PejFtw9VTFFy5vu0ks+U7Ozkqz+eMt+HN8AZKBKErYzX5/xs0kpkOcSRpu3ETdTYcZf8VAmLVgFgE2BE+3WuQ==} + /@sentry/utils@7.103.0: + resolution: {integrity: sha512-phkUJt3F0UOkVq+M4GfdAh2ewI3ASrNiJddx9aO7GnT0aDwwVBHZltnqt95qgAB8W+BipTSt1dAh8yUbbq1Ceg==} engines: {node: '>=8'} dependencies: - '@sentry/types': 7.86.0 + '@sentry/types': 7.103.0 dev: false - /@sinclair/typebox@0.25.24: - resolution: {integrity: sha512-XJfwUVUKDHF5ugKwIcxEgc9k8b7HbznCp6eUfWgu710hMPNIO4aw4/zB5RogDQz8nd6gyCDpU9O/m6qYEWY6yQ==} + /@sinclair/typebox@0.27.8: + resolution: {integrity: sha512-+Fj43pSMwJs4KRrH/938Uf+uAELIgVBmQzg/q1YG10djyfA3TnrU8N8XzqCh/okZdszqBQTZf96idMfE5lnwTA==} dev: true - /@sinonjs/commons@2.0.0: - resolution: {integrity: sha512-uLa0j859mMrg2slwQYdO/AkrOfmH+X6LTVmNTS9CqexuE2IvVORIkSpJLqePAbEnKJ77aMmCwr1NUZ57120Xcg==} + /@sinonjs/commons@3.0.1: + resolution: {integrity: sha512-K3mCHKQ9sVh8o1C9cxkwxaOmXoAMlDxC1mYyHrjqOWEcBjYr76t96zL2zlj5dUGZ3HSw240X1qgH3Mjf1yJWpQ==} dependencies: type-detect: 4.0.8 dev: true - /@sinonjs/fake-timers@10.0.2: - resolution: {integrity: sha512-SwUDyjWnah1AaNl7kxsa7cfLhlTYoiyhDAIgyh+El30YvXs/o7OLXpYH88Zdhyx9JExKrmHDJ+10bwIcY80Jmw==} - dependencies: - '@sinonjs/commons': 2.0.0 - dev: true - - /@solidity-parser/parser@0.14.5: - resolution: {integrity: sha512-6dKnHZn7fg/iQATVEzqyUOyEidbn05q7YA2mQ9hC0MMXhhV3/JrsxmFSYZAcr7j1yUP700LLhTruvJ3MiQmjJg==} + /@sinonjs/fake-timers@10.3.0: + resolution: {integrity: sha512-V4BG07kuYSUkTCSBHG8G8TNhM+F19jXFWnQtzj+we8DrkpSBCee9Z3Ms8yiGer/dlmhe35/Xdgyo3/0rQKg7YA==} dependencies: - antlr4ts: 0.5.0-alpha.4 + '@sinonjs/commons': 3.0.1 dev: true - /@solidity-parser/parser@0.16.0: - resolution: {integrity: sha512-ESipEcHyRHg4Np4SqBCfcXwyxxna1DgFVz69bgpLV8vzl/NP1DtcKsJ4dJZXWQhY/Z4J2LeKBiOkOVZn9ct33Q==} + /@solidity-parser/parser@0.16.2: + resolution: {integrity: sha512-PI9NfoA3P8XK2VBkK5oIfRgKDsicwDZfkVq9ZTBCQYGOP1N2owgY2dyLGyU5/J/hQs8KRk55kdmvTLjy3Mu3vg==} dependencies: antlr4ts: 0.5.0-alpha.4 @@ -3323,7 +3491,7 @@ packages: react-test-renderer: optional: true dependencies: - '@babel/runtime': 7.21.0 + '@babel/runtime': 7.24.0 '@types/react': 18.2.22 react: 18.2.0 react-error-boundary: 3.1.4(react@18.2.0) @@ -3333,6 +3501,7 @@ packages: /@tootallnate/once@2.0.0: resolution: {integrity: sha512-XCuKFP5PS55gnMVu3dty8KPatLqUoy/ZYzDzAGCQ8JNFCkLXzmI7vNHCR+XpbZaMWQK/vQubr7PkYq8g470J/A==} engines: {node: '>= 10'} + dev: true /@trpc/client@10.34.0(@trpc/server@10.34.0): resolution: {integrity: sha512-nqtDTIqSY/9syo2EjSy4WWWXPU9GsamEh9Tsg698gLAh1nhgFc5+/YYeb+Ne1pbvWGZ5/3t9Dcz3h4wMyyJ9gQ==} @@ -3346,122 +3515,118 @@ packages: resolution: {integrity: sha512-2VMW44Fpaoyqb50dBtzdSWMhqt8lmoJiocEyBBeDb03R0W+XrzbVD5kU/wqKPlcp1DWeNCkOEIMtetMZCfo1hA==} dev: false - /@types/abstract-leveldown@7.2.1: - resolution: {integrity: sha512-YK8irIC+eMrrmtGx0H4ISn9GgzLd9dojZWJaMbjp1YHLl2VqqNFBNrL5Q3KjGf4VE3sf/4hmq6EhQZ7kZp1NoQ==} - dev: true - /@types/accepts@1.3.7: resolution: {integrity: sha512-Pay9fq2lM2wXPWbteBsRAGiWH2hig4ZE2asK+mm7kUzlxRTfL961rj89I6zV/E3PcIkDqyuBEcMxFT7rccugeQ==} dependencies: - '@types/node': 18.15.11 + '@types/node': 18.19.21 dev: true - /@types/babel__core@7.20.0: - resolution: {integrity: sha512-+n8dL/9GWblDO0iU6eZAwEIJVr5DWigtle+Q6HLOrh/pdbXOhOtqzq8VPPE2zvNJzSKY4vH/z3iT3tn0A3ypiQ==} + /@types/babel__core@7.20.5: + resolution: {integrity: sha512-qoQprZvz5wQFJwMDqeseRXWv3rqMvhgpbXFfVyWhbx9X47POIA6i/+dXefEmZKoAgOaTdaIgNSMqMIU61yRyzA==} dependencies: - '@babel/parser': 7.21.4 - '@babel/types': 7.21.4 - '@types/babel__generator': 7.6.4 - '@types/babel__template': 7.4.1 - '@types/babel__traverse': 7.18.3 + '@babel/parser': 7.24.0 + '@babel/types': 7.24.0 + '@types/babel__generator': 7.6.8 + '@types/babel__template': 7.4.4 + '@types/babel__traverse': 7.20.5 dev: true - /@types/babel__generator@7.6.4: - resolution: {integrity: sha512-tFkciB9j2K755yrTALxD44McOrk+gfpIpvC3sxHjRawj6PfnQxrse4Clq5y/Rq+G3mrBurMax/lG8Qn2t9mSsg==} + /@types/babel__generator@7.6.8: + resolution: {integrity: sha512-ASsj+tpEDsEiFr1arWrlN6V3mdfjRMZt6LtK/Vp/kreFLnr5QH5+DhvD5nINYZXzwJvXeGq+05iUXcAzVrqWtw==} dependencies: - '@babel/types': 7.21.4 + '@babel/types': 7.24.0 dev: true - /@types/babel__template@7.4.1: - resolution: {integrity: sha512-azBFKemX6kMg5Io+/rdGT0dkGreboUVR0Cdm3fz9QJWpaQGJRQXl7C+6hOTCZcMll7KFyEQpgbYI2lHdsS4U7g==} + /@types/babel__template@7.4.4: + resolution: {integrity: sha512-h/NUaSyG5EyxBIp8YRxo4RMe2/qQgvyowRwVMzhYhBCONbW8PUsg4lkFMrhgZhUe5z3L3MiLDuvyJ/CaPa2A8A==} dependencies: - '@babel/parser': 7.21.4 - '@babel/types': 7.21.4 + '@babel/parser': 7.24.0 + '@babel/types': 7.24.0 dev: true - /@types/babel__traverse@7.18.3: - resolution: {integrity: sha512-1kbcJ40lLB7MHsj39U4Sh1uTd2E7rLEa79kmDpI6cy+XiXsteB3POdQomoq4FxszMrO3ZYchkhYJw7A2862b3w==} + /@types/babel__traverse@7.20.5: + resolution: {integrity: sha512-WXCyOcRtH37HAUkpXhUduaxdm82b4GSlyTqajXviN4EfiuPgNYR109xMCKvpl6zPIpua0DGlMEDCq+g8EdoheQ==} dependencies: - '@babel/types': 7.21.4 + '@babel/types': 7.24.0 dev: true - /@types/better-sqlite3@7.6.4: - resolution: {integrity: sha512-dzrRZCYPXIXfSR1/surNbJ/grU3scTaygS0OMzjlGf71i9sc2fGyHPXXiXmEvNIoE0cGwsanEFMVJxPXmco9Eg==} + /@types/better-sqlite3@7.6.9: + resolution: {integrity: sha512-FvktcujPDj9XKMJQWFcl2vVl7OdRIqsSRX9b0acWwTmwLK9CF2eqo/FRcmMLNpugKoX/avA6pb7TorDLmpgTnQ==} dependencies: - '@types/node': 18.15.11 + '@types/node': 18.19.21 /@types/bn.js@4.11.6: resolution: {integrity: sha512-pqr857jrp2kPuO9uRjZ3PwnJTjoQy+fcdxvBTvHm6dkmEL9q+hDD/2j/0ELOBPtPnS8LjCX0gI9nbl8lVkadpg==} dependencies: - '@types/node': 18.15.11 + '@types/node': 18.19.21 dev: true - /@types/bn.js@5.1.1: - resolution: {integrity: sha512-qNrYbZqMx0uJAfKnKclPh+dTwK33KfLHYqtyODwd5HnXOjnkhc4qgn3BrK6RWyGZm5+sIFE7Q7Vz6QQtJB7w7g==} + /@types/bn.js@5.1.5: + resolution: {integrity: sha512-V46N0zwKRF5Q00AZ6hWtN0T8gGmDUaUzLWQvHFo5yThtVwK/VCenFY3wXVbOvNfajEpsTfQM4IN9k/d6gUVX3A==} dependencies: - '@types/node': 18.15.11 + '@types/node': 18.19.21 dev: true /@types/body-parser@1.19.5: resolution: {integrity: sha512-fB3Zu92ucau0iQ0JMCFQE7b/dv8Ot07NI3KaZIkIUNXq82k4eBAqUaneXfleGY9JWskeS9y+u0nXMyspcuQrCg==} dependencies: '@types/connect': 3.4.38 - '@types/node': 18.15.11 + '@types/node': 18.19.21 dev: true - /@types/chai-as-promised@7.1.5: - resolution: {integrity: sha512-jStwss93SITGBwt/niYrkf2C+/1KTeZCZl1LaeezTlqppAKeoQC7jxyqYuP72sxBGKCIbw7oHgbYssIRzT5FCQ==} + /@types/chai-as-promised@7.1.8: + resolution: {integrity: sha512-ThlRVIJhr69FLlh6IctTXFkmhtP3NpMZ2QGq69StYLyKZFp/HOp1VdKZj7RvfNWYYcJ1xlbLGLLWj1UvP5u/Gw==} dependencies: - '@types/chai': 4.3.5 + '@types/chai': 4.3.12 dev: true - /@types/chai-subset@1.3.3: - resolution: {integrity: sha512-frBecisrNGz+F4T6bcc+NLeolfiojh5FxW2klu669+8BARtyQv2C/GkNW6FUodVe4BroGMP/wER/YDGc7rEllw==} + /@types/chai-subset@1.3.5: + resolution: {integrity: sha512-c2mPnw+xHtXDoHmdtcCXGwyLMiauiAyxWMzhGpqHC4nqI/Y5G2XhTampslK2rb59kpcuHon03UH8W6iYUzw88A==} dependencies: - '@types/chai': 4.3.5 + '@types/chai': 4.3.12 dev: true - /@types/chai@4.3.5: - resolution: {integrity: sha512-mEo1sAde+UCE6b2hxn332f1g1E8WfYRu6p5SvTKr2ZKC1f7gFJXk4h5PyGP9Dt6gCaG8y8XhwnXWC6Iy2cmBng==} + /@types/chai@4.3.12: + resolution: {integrity: sha512-zNKDHG/1yxm8Il6uCCVsm+dRdEsJlFoDu73X17y09bId6UwoYww+vFBsAcRzl8knM1sab3Dp1VRikFQwDOtDDw==} dev: true /@types/connect@3.4.38: resolution: {integrity: sha512-K6uROf1LD88uDQqJCktA4yzL1YYAK6NgfsI0v/mTgyPKWsX1CnJ0XPSDhViejru1GcRkLWb8RlzFYJRqGUbaug==} dependencies: - '@types/node': 18.15.11 + '@types/node': 18.19.21 dev: true /@types/content-disposition@0.5.8: resolution: {integrity: sha512-QVSSvno3dE0MgO76pJhmv4Qyi/j0Yk9pBp0Y7TJ2Tlj+KCgJWY6qX7nnxCOLkZ3VYRSIk1WTxCvwUSdx6CCLdg==} dev: true - /@types/cookies@0.7.10: - resolution: {integrity: sha512-hmUCjAk2fwZVPPkkPBcI7jGLIR5mg4OVoNMBwU6aVsMm/iNPY7z9/R+x2fSwLt/ZXoGua6C5Zy2k5xOo9jUyhQ==} + /@types/cookies@0.9.0: + resolution: {integrity: sha512-40Zk8qR147RABiQ7NQnBzWzDcjKzNrntB5BAmeGCb2p/MIyOE+4BVvc17wumsUqUw00bJYqoXFHYygQnEFh4/Q==} dependencies: '@types/connect': 3.4.38 '@types/express': 4.17.21 '@types/keygrip': 1.0.6 - '@types/node': 18.15.11 + '@types/node': 18.19.21 dev: true - /@types/debug@4.1.7: - resolution: {integrity: sha512-9AonUzyTjXXhEOa0DnqpzZi6VHlqKMswga9EXjpXnnqxwLtdvPPtlO8evrI5D9S6asFRCQ6v+wpiUKbw+vKqyg==} + /@types/debug@4.1.12: + resolution: {integrity: sha512-vIChWdVG3LG1SMxEvI/AK+FWJthlrqlTu7fbrlywTkkaONwk/UAGaULXRlf8vkzFBLVm0zkMdCquhL5aOjhXPQ==} dependencies: - '@types/ms': 0.7.31 + '@types/ms': 0.7.34 dev: true - /@types/ejs@3.1.1: - resolution: {integrity: sha512-RQul5wEfY7BjWm0sYY86cmUN/pcXWGyVxWX93DFFJvcrxax5zKlieLwA3T77xJGwNcZW0YW6CYG70p1m8xPFmA==} + /@types/ejs@3.1.5: + resolution: {integrity: sha512-nv+GSx77ZtXiJzwKdsASqi+YQ5Z7vwHsTP0JY2SiQgjGckkBRKZnk8nIM+7oUZ1VCtuTz0+By4qVR7fqzp/Dfg==} dev: true - /@types/emscripten@1.39.6: - resolution: {integrity: sha512-H90aoynNhhkQP6DRweEjJp5vfUVdIj7tdPLsu7pq89vODD/lcugKfZOsfgwpvM6XUewEp2N5dCg1Uf3Qe55Dcg==} + /@types/emscripten@1.39.10: + resolution: {integrity: sha512-TB/6hBkYQJxsZHSqyeuO1Jt0AB/bW6G7rHt9g7lML7SOF6lbgcHvw/Lr+69iqN0qxgXLhWKScAon73JNnptuDw==} - /@types/express-serve-static-core@4.17.41: - resolution: {integrity: sha512-OaJ7XLaelTgrvlZD8/aa0vvvxZdUmlCn6MtWeB7TkiKW70BQLc9XEPpDLPdbo52ZhXUCrznlWdCHWxJWtdyajA==} + /@types/express-serve-static-core@4.17.43: + resolution: {integrity: sha512-oaYtiBirUOPQGSWNGPWnzyAFJ0BP3cwvN4oWZQY+zUBwpVIGsKUkpBpSztp74drYcjavs7SKFZ4DX1V2QeN8rg==} dependencies: - '@types/node': 18.15.11 - '@types/qs': 6.9.10 + '@types/node': 18.19.21 + '@types/qs': 6.9.12 '@types/range-parser': 1.2.7 '@types/send': 0.17.4 dev: true @@ -3470,22 +3635,22 @@ packages: resolution: {integrity: sha512-ejlPM315qwLpaQlQDTjPdsUFSc6ZsP4AN6AlWnogPjQ7CVi7PYF3YVz+CY3jE2pwYf7E/7HlDAN0rV2GxTG0HQ==} dependencies: '@types/body-parser': 1.19.5 - '@types/express-serve-static-core': 4.17.41 - '@types/qs': 6.9.10 + '@types/express-serve-static-core': 4.17.43 + '@types/qs': 6.9.12 '@types/serve-static': 1.15.5 dev: true /@types/glob@7.2.0: resolution: {integrity: sha512-ZUxbzKl0IfJILTS6t7ip5fQQM/J3TJYubDm3nMbgubNNYS62eXeUpoLUC8/7fJNiFYHTrGPQn7hspDUzIHX3UA==} dependencies: - '@types/minimatch': 3.0.5 - '@types/node': 18.15.11 + '@types/minimatch': 5.1.2 + '@types/node': 18.19.21 dev: true - /@types/graceful-fs@4.1.6: - resolution: {integrity: sha512-Sig0SNORX9fdW+bQuTEovKj3uHcUL6LQKbCrrqb1X7J6/ReAbhCXRAhc+SMejhLELFj2QcyuxmUooZ4bt5ReSw==} + /@types/graceful-fs@4.1.9: + resolution: {integrity: sha512-olP3sd1qOEe5dXTSaFvQG+02VdRXcdytWLAZsAq1PecU8uqQAhkrnbli7DagjtXKW/Bl7YJbUsa8MPcuc8LHEQ==} dependencies: - '@types/node': 18.15.11 + '@types/node': 18.19.21 dev: true /@types/http-assert@1.5.5: @@ -3496,37 +3661,31 @@ packages: resolution: {integrity: sha512-D0CFMMtydbJAegzOyHjtiKPLlvnm3iTZyZRSZoLq2mRhDdmLfIWOCYPfQJ4cu2erKghU++QvjcUjp/5h7hESpA==} dev: true - /@types/is-ci@3.0.0: - resolution: {integrity: sha512-Q0Op0hdWbYd1iahB+IFNQcWXFq4O0Q5MwQP7uN0souuQ4rPg1vEYcnIOfr1gY+M+6rc8FGoRaBO1mOOvL29sEQ==} - dependencies: - ci-info: 3.8.0 - dev: true - - /@types/istanbul-lib-coverage@2.0.4: - resolution: {integrity: sha512-z/QT1XN4K4KYuslS23k62yDIDLwLFkzxOuMplDtObz0+y7VqJCaO2o+SPwHCvLFZh7xazvvoor2tA/hPz9ee7g==} + /@types/istanbul-lib-coverage@2.0.6: + resolution: {integrity: sha512-2QF/t/auWm0lsy8XtKVPG19v3sSOQlJe/YHZgfjb/KBBHOGSV+J2q/S671rcq9uTBrLAXmZpqJiaQbMT+zNU1w==} dev: true - /@types/istanbul-lib-report@3.0.0: - resolution: {integrity: sha512-plGgXAPfVKFoYfa9NpYDAkseG+g6Jr294RqeqcqDixSbU34MZVJRi/P+7Y8GDpzkEwLaGZZOpKIEmeVZNtKsrg==} + /@types/istanbul-lib-report@3.0.3: + resolution: {integrity: sha512-NQn7AHQnk/RSLOxrBbGyJM/aVQ+pjj5HCgasFxc0K/KhoATfQ/47AyUl15I2yBUpihjmas+a+VJBOqecrFH+uA==} dependencies: - '@types/istanbul-lib-coverage': 2.0.4 + '@types/istanbul-lib-coverage': 2.0.6 dev: true - /@types/istanbul-reports@3.0.1: - resolution: {integrity: sha512-c3mAZEuK0lvBp8tmuL74XRKn1+y2dcwOUpH7x4WrF6gk1GIgiluDRgMYQtw2OFcBvAJWlt6ASU3tSqxp0Uu0Aw==} + /@types/istanbul-reports@3.0.4: + resolution: {integrity: sha512-pk2B1NWalF9toCRu6gjBzR69syFjP4Od8WRAX+0mmf9lAjCRicLOWc+ZrxZHx/0XRjotgkF9t6iaMJ+aXcOdZQ==} dependencies: - '@types/istanbul-lib-report': 3.0.0 + '@types/istanbul-lib-report': 3.0.3 dev: true - /@types/jest@27.4.1: - resolution: {integrity: sha512-23iPJADSmicDVrWk+HT58LMJtzLAnB2AgIzplQuq/bSrGaxCrlvRFjGbXmamnnk/mAmCdLStiGqggu28ocUyiw==} + /@types/jest@27.5.2: + resolution: {integrity: sha512-mpT8LJJ4CMeeahobofYWIjFo0xonRS/HfxnVEPMPFSQdGUt1uHCnoPT7Zhb+sjDU2wz0oKV0OLUR0WzrHNgfeA==} dependencies: jest-matcher-utils: 27.5.1 pretty-format: 27.5.1 dev: true - /@types/json-schema@7.0.11: - resolution: {integrity: sha512-wOuvG1SN4Us4rez+tylwwwCV1psiNVOkJeM3AUWUNWg/jDQY2+HE/444y5gc+jBmRqASOm2Oeh5c1axHobwRKQ==} + /@types/json-schema@7.0.15: + resolution: {integrity: sha512-5+fP8P8MFNC+AyZCDxrB2pkZFPGzqQWUzpSeuuVLvm8VMcorNYavBqoFcxK8bQz4Qsbn4oUEEem4wDLfcysGHA==} dev: true /@types/keygrip@1.0.6: @@ -3536,48 +3695,32 @@ packages: /@types/koa-compose@3.2.8: resolution: {integrity: sha512-4Olc63RY+MKvxMwVknCUDhRQX1pFQoBZ/lXcRLP69PQkEpze/0cr8LNqJQe5NFb/b19DWi2a5bTi2VAlQzhJuA==} dependencies: - '@types/koa': 2.13.12 + '@types/koa': 2.15.0 dev: true - /@types/koa@2.13.12: - resolution: {integrity: sha512-vAo1KuDSYWFDB4Cs80CHvfmzSQWeUb909aQib0C0aFx4sw0K9UZFz2m5jaEP+b3X1+yr904iQiruS0hXi31jbw==} + /@types/koa@2.15.0: + resolution: {integrity: sha512-7QFsywoE5URbuVnG3loe03QXuGajrnotr3gQkXcEBShORai23MePfFYdhz90FEtBBpkyIYQbVD+evKtloCgX3g==} dependencies: '@types/accepts': 1.3.7 '@types/content-disposition': 0.5.8 - '@types/cookies': 0.7.10 + '@types/cookies': 0.9.0 '@types/http-assert': 1.5.5 '@types/http-errors': 2.0.4 '@types/keygrip': 1.0.6 '@types/koa-compose': 3.2.8 - '@types/node': 18.15.11 + '@types/node': 18.19.21 dev: true /@types/koa__cors@4.0.3: resolution: {integrity: sha512-zj+1sQO/6GGRGINRXlMmoiFwHibKVcjNGdh+p2SpqHDMLyvC+ce0LMHX6UBi1rdpnPZ/+osUwWdGKF945ffrzA==} dependencies: - '@types/koa': 2.13.12 + '@types/koa': 2.15.0 dev: true /@types/koa__router@12.0.4: resolution: {integrity: sha512-Y7YBbSmfXZpa/m5UGGzb7XadJIRBRnwNY9cdAojZGp65Cpe5MAP3mOZE7e3bImt8dfKS4UFcR16SLH8L/z7PBw==} dependencies: - '@types/koa': 2.13.12 - dev: true - - /@types/level-errors@3.0.0: - resolution: {integrity: sha512-/lMtoq/Cf/2DVOm6zE6ORyOM+3ZVm/BvzEZVxUhf6bgh8ZHglXlBqxbxSlJeVp8FCbD3IVvk/VbsaNmDjrQvqQ==} - dev: true - - /@types/levelup@4.3.3: - resolution: {integrity: sha512-K+OTIjJcZHVlZQN1HmU64VtrC0jC3dXWQozuEIR9zVvltIk90zaGPM2AgT+fIkChpzHhFE3YnvFLCbLtzAmexA==} - dependencies: - '@types/abstract-leveldown': 7.2.1 - '@types/level-errors': 3.0.0 - '@types/node': 18.15.11 - dev: true - - /@types/long@4.0.2: - resolution: {integrity: sha512-MqTGEo5bj5t157U6fA/BiDynNkn0YknVdh48CMPkTSpFTVmvao5UQmm7uEF6xBEo7qIMAlY/JSleYaE6VOdpaA==} + '@types/koa': 2.15.0 dev: true /@types/lru-cache@5.1.1: @@ -3592,70 +3735,59 @@ packages: resolution: {integrity: sha512-iJt33IQnVRkqeqC7PzBHPTC6fDlRNRW8vjrgqtScAhrmMwe8c4Eo7+fUGTa+XdWrpEgpyKWMYmi2dIwMAYRzPw==} dev: true - /@types/minimatch@3.0.5: - resolution: {integrity: sha512-Klz949h02Gz2uZCMGwDUSDS1YBlTdDDgbWHi+81l29tQALUtvz4rAYi5uoVhE5Lagoq6DeqAUlbrHvW/mXDgdQ==} + /@types/minimatch@5.1.2: + resolution: {integrity: sha512-K0VQKziLUWkVKiRVrx4a40iPaxTUefQmjtkQofBkYRcoaaL/8rhwDWww9qWbrgicNOgnpIsMxyNIUM4+n6dUIA==} dev: true - /@types/minimist@1.2.2: - resolution: {integrity: sha512-jhuKLIRrhvCPLqwPcx6INqmKeiA5EWrsCOPhrlFSrbrmU4ZMPjj5Ul/oLCMDO98XRUIwVm78xICz4EPCektzeQ==} + /@types/minimist@1.2.5: + resolution: {integrity: sha512-hov8bUuiLiyFPGyFPE1lwWhmzYbirOXQNNo40+y3zow8aFVTeyn3VWL0VFFfdNddA8S4Vf0Tc062rzyNr7Paag==} dev: true /@types/mocha@9.1.1: resolution: {integrity: sha512-Z61JK7DKDtdKTWwLeElSEBcWGRLY8g95ic5FoQqI9CMx0ns/Ghep3B4DfcEimiKMvtamNVULVNKEsiwV3aQmXw==} dev: true - /@types/ms@0.7.31: - resolution: {integrity: sha512-iiUgKzV9AuaEkZqkOLDIvlQiL6ltuZd9tGcW3gwpnX8JbuiuhFlEGmmFXEXkN50Cvq7Os88IY2v0dkDqXYWVgA==} + /@types/ms@0.7.34: + resolution: {integrity: sha512-nG96G3Wp6acyAgJqGasjODb+acrI7KltPiRxzHPXnP3NgI28bpQDRv53olbqGXbfcgF5aiiHmO3xpwEpS5Ld9g==} dev: true - /@types/node-fetch@2.6.2: - resolution: {integrity: sha512-DHqhlq5jeESLy19TYhLakJ07kNumXWjcDdxXsLUMJZ6ue8VZJj4kLPQVE/2mdHh3xZziNF1xppu5lwmS53HR+A==} + /@types/node-fetch@2.6.11: + resolution: {integrity: sha512-24xFj9R5+rfQJLRyM56qh+wnVSYhyXC2tkoBndtY0U+vubqNsYXGjufB2nn8Q6gt0LrARwL6UBtMCSVCwl4B1g==} dependencies: - '@types/node': 18.15.11 - form-data: 3.0.1 + '@types/node': 18.19.21 + form-data: 4.0.0 dev: true /@types/node@12.20.55: resolution: {integrity: sha512-J8xLz7q2OFulZ2cyGTLE1TbbZcjpno7FaN6zdJNrgAdrJ+DZzh/uFR6YrTb4C+nXakvud8Q4+rbhoIWlYQbUFQ==} dev: true - /@types/node@18.15.11: - resolution: {integrity: sha512-E5Kwq2n4SbMzQOn6wnmBjuK9ouqlURrcZDVfbo9ftDDTFt3nk7ZKK4GMOzoYgnpQJKcxwQw+lGaBvvlMo0qN/Q==} - - /@types/normalize-package-data@2.4.1: - resolution: {integrity: sha512-Gj7cI7z+98M282Tqmp2K5EIsoouUEzbBJhQQzDE3jSIRk6r9gsz0oUokqIUR4u1R3dMHo0pDHM7sNOHyhulypw==} - dev: true - - /@types/object-hash@1.3.4: - resolution: {integrity: sha512-xFdpkAkikBgqBdG9vIlsqffDV8GpvnPEzs0IUtr1v3BEB97ijsFQ4RXVbUZwjFThhB4MDSTUfvmxUD5PGx0wXA==} - dev: true - - /@types/openurl@1.0.0: - resolution: {integrity: sha512-fUHH4T8FmEl3NBtGbUYYzMo1Ev47uVCVEGVjVNjorOMzgjls6zH82yr/zqkkcEOHY2HUC5PZ8dRFwGed/NR7wQ==} + /@types/node@18.19.21: + resolution: {integrity: sha512-2Q2NeB6BmiTFQi4DHBzncSoq/cJMLDdhPaAoJFnFCyD9a8VPZRf7a1GAwp1Edb7ROaZc5Jz/tnZyL6EsWMRaqw==} dependencies: - '@types/node': 18.15.11 - dev: true + undici-types: 5.26.5 - /@types/parse-json@4.0.0: - resolution: {integrity: sha512-//oorEZjL6sbPcKUaCdIGlIUeH26mgzimjBB77G6XRgnDl/L5wOnpyBGRe/Mmf5CVW3PwEBE1NjiMZ/ssFh4wA==} + /@types/normalize-package-data@2.4.4: + resolution: {integrity: sha512-37i+OaWTh9qeK4LSHPsyRC7NahnGotNuZvjLSgcPzblpHB3rrCJxAOgI5gCdKm7coonsaX1Of0ILiTcnZjbfxA==} dev: true - /@types/pbkdf2@3.1.0: - resolution: {integrity: sha512-Cf63Rv7jCQ0LaL8tNXmEyqTHuIJxRdlS5vMh1mj5voN4+QFhVZnlZruezqpWYDiJ8UTzhP0VmeLXCmBk66YrMQ==} + /@types/openurl@1.0.3: + resolution: {integrity: sha512-rdWpxNve8iUBizep3BwjGzcdfk2XeXeeFiMwIgLN6dAKxCusfFC6H9XVvfPeNObRFpSgqI+HVmoG7UOB9HEnBQ==} dependencies: - '@types/node': 18.15.11 + '@types/node': 18.19.21 dev: true - /@types/prettier@2.7.2: - resolution: {integrity: sha512-KufADq8uQqo1pYKVIYzfKbJfBAc0sOeXqGbFaSpv8MRmC/zXgowNZmFcbngndGk922QDmOASEXUZCaY48gs4cg==} + /@types/pbkdf2@3.1.2: + resolution: {integrity: sha512-uRwJqmiXmh9++aSu1VNEn3iIxWOhd8AHXNSdlaLfdAAdSTY9jYVeGWnzejM3dvrkbqE3/hyQkQQ29IFATEGlew==} + dependencies: + '@types/node': 18.19.21 dev: true - /@types/prop-types@15.7.5: - resolution: {integrity: sha512-JCB8C6SnDoQf0cNycqd/35A7MjcnK+ZTqE7judS6o7utxUCg6imJg3QK2qzHKszlTjcj2cn+NwMB2i96ubpj7w==} - dev: true + /@types/prop-types@15.7.11: + resolution: {integrity: sha512-ga8y9v9uyeiLdpKddhxYQkxNDrfvuPrlFb0N1qnZZByvcElJaXthF1UhvCh9TLWJBEHeNtdnbysW7Y6Uq8CVng==} - /@types/qs@6.9.10: - resolution: {integrity: sha512-3Gnx08Ns1sEoCrWssEgTSJs/rsT2vhGP+Ja9cnnk9k4ALxinORlQneLXFeFKOTJMOeZUFD1s7w+w2AphTpvzZw==} + /@types/qs@6.9.12: + resolution: {integrity: sha512-bZcOkJ6uWrL0Qb2NAWKa7TBU+mJHPzhx9jjLL1KHF+XpzEcR7EXHvjbHlGtR/IsP1vyPrehuS6XqkmaePy//mg==} dev: true /@types/range-parser@1.2.7: @@ -3671,38 +3803,39 @@ packages: /@types/react@18.2.22: resolution: {integrity: sha512-60fLTOLqzarLED2O3UQImc/lsNRgG0jE/a1mPW9KjMemY0LMITWEsbS4VvZ4p6rorEHd5YKxxmMKSDK505GHpA==} dependencies: - '@types/prop-types': 15.7.5 - '@types/scheduler': 0.16.3 - csstype: 3.1.2 + '@types/prop-types': 15.7.11 + '@types/scheduler': 0.16.8 + csstype: 3.1.3 + + /@types/readable-stream@2.3.15: + resolution: {integrity: sha512-oM5JSKQCcICF1wvGgmecmHldZ48OZamtMxcGGVICOJA8o8cahXC1zEVAif8iwoc5j8etxFaRFnf095+CDsuoFQ==} + dependencies: + '@types/node': 18.19.21 + safe-buffer: 5.1.2 dev: true - /@types/retry@0.12.1: - resolution: {integrity: sha512-xoDlM2S4ortawSWORYqsdU+2rxdh4LRW9ytc3zmT37RIKQh6IHyKwwtKhKis9ah8ol07DCkZxPt8BBvPjC6v4g==} + /@types/retry@0.12.0: + resolution: {integrity: sha512-wWKOClTTiizcZhXnPY4wikVAwmdYHp8q6DmC+EJUzAMsycb7HB32Kh9RN4+0gExjmPmZSAQjgURXIGATPegAvA==} dev: false - /@types/scheduler@0.16.3: - resolution: {integrity: sha512-5cJ8CB4yAx7BH1oMvdU0Jh9lrEXyPkar6F9G/ERswkCuvP4KQZfZkSjcMbAICCpQTN4OuZn8tz0HiKv9TGZgrQ==} - dev: true + /@types/scheduler@0.16.8: + resolution: {integrity: sha512-WZLiwShhwLRmeV6zH+GkbOFT6Z6VklCItrDioxUnv+u4Ll+8vKeFySoFyK/0ctcRpOmwAicELfmys1sDc/Rw+A==} - /@types/secp256k1@4.0.3: - resolution: {integrity: sha512-Da66lEIFeIz9ltsdMZcpQvmrmmoqrfju8pm1BH8WbYjZSwUgCwXLb9C+9XYogwBITnbsSaMdVPb2ekf7TV+03w==} + /@types/secp256k1@4.0.6: + resolution: {integrity: sha512-hHxJU6PAEUn0TP4S/ZOzuTUvJWuZ6eIKeNKb5RBpODvSl6hp1Wrw4s7ATY50rklRCScUDpHzVA/DQdSjJ3UoYQ==} dependencies: - '@types/node': 18.15.11 - dev: true - - /@types/semver@6.2.3: - resolution: {integrity: sha512-KQf+QAMWKMrtBMsB8/24w53tEsxllMj6TuA80TT/5igJalLI/zm0L3oXRbIAl4Ohfc85gyHX/jhMwsVkmhLU4A==} + '@types/node': 18.19.21 dev: true - /@types/semver@7.3.13: - resolution: {integrity: sha512-21cFJr9z3g5dW8B0CVI9g2O9beqaThGQ6ZFBqHfwhzLDKUxaqTIy3vnfah/UPkfOiF2pLq+tGz+W8RyCskuslw==} + /@types/semver@7.5.8: + resolution: {integrity: sha512-I8EUhyrgfLrcTkzV3TSsGyl1tSuPrEDzr0yd5m90UgNxQkyDXULk3b6MlQqTCpZpNtWe1K0hzclnZkTcLBe2UQ==} dev: true /@types/send@0.17.4: resolution: {integrity: sha512-x2EM6TJOybec7c52BX0ZspPodMsQUd5L6PRwOunVyVUhXiBSKf3AezDL8Dgvgt5o0UfKNfuA0eMLr2wLT4AiBA==} dependencies: '@types/mime': 1.3.5 - '@types/node': 18.15.11 + '@types/node': 18.19.21 dev: true /@types/serve-static@1.15.5: @@ -3710,58 +3843,52 @@ packages: dependencies: '@types/http-errors': 2.0.4 '@types/mime': 3.0.4 - '@types/node': 18.15.11 + '@types/node': 18.19.21 dev: true - /@types/sql.js@1.4.4: - resolution: {integrity: sha512-6EWU2wfiBtzgTy18WQoXZAGTreBjhZcBCfD8CDvyI1Nj0a4KNDDt41IYeAZ40cRUdfqWHb7VGx7t6nK0yBOI5A==} + /@types/sql.js@1.4.9: + resolution: {integrity: sha512-ep8b36RKHlgWPqjNG9ToUrPiwkhwh0AEzy883mO5Xnd+cL6VBH1EvSjBAAuxLUFF2Vn/moE3Me6v9E1Lo+48GQ==} dependencies: - '@types/emscripten': 1.39.6 - '@types/node': 18.15.11 + '@types/emscripten': 1.39.10 + '@types/node': 18.19.21 - /@types/stack-utils@2.0.1: - resolution: {integrity: sha512-Hl219/BT5fLAaz6NDkSuhzasy49dwQS/DSdu4MdggFB8zcXv7vflBI3xp7FEmkmdDkBUI2bPUNeMttp2knYdxw==} + /@types/stack-utils@2.0.3: + resolution: {integrity: sha512-9aEbYZ3TbYMznPdcdr3SmIrLXwC/AKZXQeCf9Pgao5CKb8CyHuEX5jzWPTkvregvhRJHcpRO6BFoGW9ycaOkYw==} dev: true - /@types/stream-to-array@2.3.1: - resolution: {integrity: sha512-OqV/DIumEm5pT+m4LYGpDFRRLZ0VJRvrz58C8q8rjLGVgP5gRHxThG8eLZfhmK3GVAq9iq3eSvZ0vkZJ5ZH/Pg==} + /@types/stream-to-array@2.3.3: + resolution: {integrity: sha512-fWXKc6enNlT2l0nXZcxHNQvNSg9IIBgHQR1bHfAVjcJD+zlx9F0o6W+qGWerB1eGBszV4+dsge3id4PEp6SptA==} dependencies: - '@types/node': 18.15.11 + '@types/node': 18.19.21 dev: true - /@types/throttle-debounce@5.0.0: - resolution: {integrity: sha512-Pb7k35iCGFcGPECoNE4DYp3Oyf2xcTd3FbFQxXUI9hEYKUl6YX+KLf7HrBmgVcD05nl50LIH6i+80js4iYmWbw==} + /@types/throttle-debounce@5.0.2: + resolution: {integrity: sha512-pDzSNulqooSKvSNcksnV72nk8p7gRqN8As71Sp28nov1IgmPKWbOEIwAWvBME5pPTtaXJAvG3O4oc76HlQ4kqQ==} dev: true /@types/uuid@8.3.4: resolution: {integrity: sha512-c/I8ZRb51j+pYGAu5CrFMRxqZ2ke4y2grEBO5AUjgSkSk+qT2Ea+OdWElz/OiMf5MNpn2b17kuVBwZLQJXzihw==} dev: true - /@types/ws@8.5.4: - resolution: {integrity: sha512-zdQDHKUgcX/zBc4GrwsE/7dVdAD8JR4EuiAXiiUhhfyIJXXb2+PrGshFyeXWQPMmmZ2XxgaqclgpIC7eTXc1mg==} + /@types/ws@8.5.10: + resolution: {integrity: sha512-vmQSUcfalpIq0R9q7uTo2lXs6eGIpt9wtnLdMv9LVpIjCA/+ufZRozlVoVelIYixx1ugCBKDhn89vnsEGOCx9A==} dependencies: - '@types/node': 18.15.11 + '@types/node': 18.19.21 dev: true - /@types/yargs-interactive@2.1.3: - resolution: {integrity: sha512-bYB8ah0JPR6/lpHlxUzeHsrb3RK5OW7N8Hnth2nefnr6zQ5KFoDQ6wM5x58dTLEDYrwikFy3EPTf/O0HKLNaIg==} + /@types/yargs-interactive@2.1.6: + resolution: {integrity: sha512-Gh6BwFnz2YEmojzg/hkiGzSZDJ0TlU4v5Ea+sBP9pQVRfeSC+lCXmqB4Zk0KNwM01Cx54IZ1vssAJoRs+p8k+A==} dependencies: - '@types/yargs': 17.0.24 + '@types/yargs': 17.0.32 dev: false - /@types/yargs-parser@21.0.0: - resolution: {integrity: sha512-iO9ZQHkZxHn4mSakYV0vFHAVDyEOIJQrV2uZ06HxEPcx+mt8swXoZHIbaaJ2crJYFfErySgktuTZ3BeLz+XmFA==} - - /@types/yargs@17.0.23: - resolution: {integrity: sha512-yuogunc04OnzGQCrfHx+Kk883Q4X0aSwmYZhKjI21m+SVYzjIbrWl8dOOwSv5hf2Um2pdCOXWo9isteZTNXUZQ==} - dependencies: - '@types/yargs-parser': 21.0.0 - dev: true + /@types/yargs-parser@21.0.3: + resolution: {integrity: sha512-I4q9QU9MQv4oEOz4tAHJtNz1cwuLxn2F3xcc2iV5WdqLPpUnj30aUuxt1mAxYTG+oe8CZMV/+6rU4S4gRDzqtQ==} - /@types/yargs@17.0.24: - resolution: {integrity: sha512-6i0aC7jV6QzQB8ne1joVZ0eSFIstHsCrobmOtghM11yGlH0j43FKL2UhWdELkyps0zuf7qVTUVCCR+tgSlyLLw==} + /@types/yargs@17.0.32: + resolution: {integrity: sha512-xQ67Yc/laOG5uMfX/093MRlGGCIBzZMarVa+gfNKJxWAIgykYpVGkBdbqEzGDDfCrVUj6Hiff4mTZ5BA6TmAog==} dependencies: - '@types/yargs-parser': 21.0.0 + '@types/yargs-parser': 21.0.3 /@typescript-eslint/eslint-plugin@5.46.1(@typescript-eslint/parser@5.46.1)(eslint@8.29.0)(typescript@5.1.6): resolution: {integrity: sha512-YpzNv3aayRBwjs4J3oz65eVLXc9xx0PDbIRisHj+dYhvBn02MjYOD96P8YGiWEIFBrojaUjxvkaUpakD82phsA==} @@ -3780,10 +3907,10 @@ packages: '@typescript-eslint/utils': 5.46.1(eslint@8.29.0)(typescript@5.1.6) debug: 4.3.4(supports-color@8.1.1) eslint: 8.29.0 - ignore: 5.2.4 + ignore: 5.3.1 natural-compare-lite: 1.4.0 regexpp: 3.2.0 - semver: 7.5.0 + semver: 7.6.0 tsutils: 3.21.0(typescript@5.1.6) typescript: 5.1.6 transitivePeerDependencies: @@ -3857,7 +3984,7 @@ packages: debug: 4.3.4(supports-color@8.1.1) globby: 11.1.0 is-glob: 4.0.3 - semver: 7.5.0 + semver: 7.6.0 tsutils: 3.21.0(typescript@5.1.6) typescript: 5.1.6 transitivePeerDependencies: @@ -3870,15 +3997,15 @@ packages: peerDependencies: eslint: ^6.0.0 || ^7.0.0 || ^8.0.0 dependencies: - '@types/json-schema': 7.0.11 - '@types/semver': 7.3.13 + '@types/json-schema': 7.0.15 + '@types/semver': 7.5.8 '@typescript-eslint/scope-manager': 5.46.1 '@typescript-eslint/types': 5.46.1 '@typescript-eslint/typescript-estree': 5.46.1(typescript@5.1.6) eslint: 8.29.0 eslint-scope: 5.1.1 eslint-utils: 3.0.0(eslint@8.29.0) - semver: 7.5.0 + semver: 7.6.0 transitivePeerDependencies: - supports-color - typescript @@ -3889,11 +4016,7 @@ packages: engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} dependencies: '@typescript-eslint/types': 5.46.1 - eslint-visitor-keys: 3.4.0 - dev: true - - /@ungap/promise-all-settled@1.1.2: - resolution: {integrity: sha512-sL/cEvJWAnClXw0wHk85/2L0G6Sj8UB0Ctc1TEMbKSsmpRosqhwj9gWgFRZSrBr2f9tiXISwNhCPmlfqUqyb9Q==} + eslint-visitor-keys: 3.4.3 dev: true /@use-gesture/core@10.2.9: @@ -3906,17 +4029,18 @@ packages: '@use-gesture/core': 10.2.9 dev: false - /@vitejs/plugin-react@4.0.0(vite@4.3.6): - resolution: {integrity: sha512-HX0XzMjL3hhOYm+0s95pb0Z7F8O81G7joUHgfDd/9J/ZZf5k4xX6QAMFkKsHFxaHlf6X7GD7+XuaZ66ULiJuhQ==} + /@vitejs/plugin-react@4.2.1(vite@4.5.2): + resolution: {integrity: sha512-oojO9IDc4nCUUi8qIR11KoQm0XFFLIwsRBwHRR4d/88IWghn1y6ckz/bJ8GHDCsYEJee8mDzqtJxh15/cisJNQ==} engines: {node: ^14.18.0 || >=16.0.0} peerDependencies: - vite: ^4.2.0 + vite: ^4.2.0 || ^5.0.0 dependencies: - '@babel/core': 7.21.4 - '@babel/plugin-transform-react-jsx-self': 7.21.0(@babel/core@7.21.4) - '@babel/plugin-transform-react-jsx-source': 7.19.6(@babel/core@7.21.4) + '@babel/core': 7.24.0 + '@babel/plugin-transform-react-jsx-self': 7.23.3(@babel/core@7.24.0) + '@babel/plugin-transform-react-jsx-source': 7.23.3(@babel/core@7.24.0) + '@types/babel__core': 7.20.5 react-refresh: 0.14.0 - vite: 4.3.6(@types/node@18.15.11) + vite: 4.5.2(@types/node@18.19.21) transitivePeerDependencies: - supports-color dev: true @@ -3940,35 +4064,32 @@ packages: /@vitest/snapshot@0.34.6: resolution: {integrity: sha512-B3OZqYn6k4VaN011D+ve+AA4whM4QkcwcrwaKwAbyyvS/NB1hCWjFIBQxAQQSQir9/RtyAAGuq+4RJmbn2dH4w==} dependencies: - magic-string: 0.30.5 + magic-string: 0.30.7 pathe: 1.1.2 - pretty-format: 29.5.0 + pretty-format: 29.7.0 dev: true /@vitest/spy@0.34.6: resolution: {integrity: sha512-xaCvneSaeBw/cz8ySmF7ZwGvL0lBjfvqc1LpQ/vcdHEvpLn3Ff1vAvjw+CoGn0802l++5L/pxb7whwcWAw+DUQ==} dependencies: - tinyspy: 2.2.0 + tinyspy: 2.2.1 dev: true /@vitest/utils@0.34.6: resolution: {integrity: sha512-IG5aDD8S6zlvloDsnzHw0Ut5xczlF+kv2BOTo+iXfPr54Yhi5qbVOgGB1hZaVq4iJ4C/MZ2J0y15IlsV/ZcI0A==} dependencies: diff-sequences: 29.6.3 - loupe: 2.3.6 - pretty-format: 29.5.0 + loupe: 2.3.7 + pretty-format: 29.7.0 dev: true /abab@2.0.6: resolution: {integrity: sha512-j2afSsaIENvHZN2B8GOpF566vZ5WVk5opAiMTvWgaQT8DkbOqsTfvNAvHoRGU2zzP8cPoqys+xHTRDWW8L+/BA==} + deprecated: Use your platform's native atob() and btoa() methods instead dev: true - /abbrev@1.1.1: - resolution: {integrity: sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==} - dev: false - - /abdk-libraries-solidity@3.0.0: - resolution: {integrity: sha512-oKBj/1wK6hIXxYjX7b2vCzJPHs9GDu49EBpNfUOw2FpA/nu1oV7V598MgAbB1+R1u7vuUhL6DYqolV+GMWaLvA==} + /abdk-libraries-solidity@3.2.0: + resolution: {integrity: sha512-JyedKxyqsszb9qCTX+YCOQHA4m0YAq9p77Qvumiy8LJLLrm1FfA9D3pdSAZN5wrmi3PSv0y3Svy8c/C+8S9K8g==} dev: false /abind@1.0.5: @@ -3976,7 +4097,7 @@ packages: engines: {node: '>=6', npm: '>=3'} dev: false - /abitype@1.0.0(typescript@5.1.6)(zod@3.21.4): + /abitype@1.0.0(typescript@5.1.6)(zod@3.22.4): resolution: {integrity: sha512-NMeMah//6bJ56H5XRj8QCV4AwuW6hB6zqz2LnhhLdcWVQOsXki6/Pn3APeqxCma62nXIcmZWdu1DlHWS74umVQ==} peerDependencies: typescript: '>=5.0.4' @@ -3988,11 +4109,11 @@ packages: optional: true dependencies: typescript: 5.1.6 - zod: 3.21.4 + zod: 3.22.4 dev: false - /abort-controller-x@0.4.1: - resolution: {integrity: sha512-lJ2ssrl3FoTK3cX/g15lRCkXFWKiwRTRtBjfwounO2EM/Q65rI/MEZsfsch1juWU2pH2aLSaq0HGowlDP/imrw==} + /abort-controller-x@0.4.3: + resolution: {integrity: sha512-VtUwTNU8fpMwvWGn4xE93ywbogTYsuT+AUxAXOeelbXuQVIwNmC5YLeho9sH4vZ4ITW8414TTAOG1nW6uIVHCA==} dev: false /abort-controller@3.0.0: @@ -4000,28 +4121,7 @@ packages: engines: {node: '>=6.5'} dependencies: event-target-shim: 5.0.1 - - /abstract-leveldown@6.2.3: - resolution: {integrity: sha512-BsLm5vFMRUrrLeCcRc+G0t2qOaTzpoJQLOubq2XM72eNpjF5UdU5o/5NvlNhx95XHcAvcl8OMXr4mlg/fRgUXQ==} - engines: {node: '>=6'} - dependencies: - buffer: 5.7.1 - immediate: 3.3.0 - level-concat-iterator: 2.0.1 - level-supports: 1.0.1 - xtend: 4.0.2 - dev: true - - /abstract-leveldown@6.3.0: - resolution: {integrity: sha512-TU5nlYgta8YrBMNpc9FwQzRbiXsj49gsALsXadbGHt9CROPzX5fB0rWDR5mtdpOOKa5XqRFpbj1QroPAoPzVjQ==} - engines: {node: '>=6'} - dependencies: - buffer: 5.7.1 - immediate: 3.3.0 - level-concat-iterator: 2.0.1 - level-supports: 1.0.1 - xtend: 4.0.2 - dev: true + dev: false /abstract-logging@2.0.1: resolution: {integrity: sha512-2BjRTZxTPvheOvGbBslFSYOUkr+SjPtOnrLP33f+VIWLzezQpZcqVg7ja3L4dBXmzzgwT+a029jRx5PCi3JuiA==} @@ -4035,20 +4135,12 @@ packages: negotiator: 0.6.3 dev: false - /acorn-jsx@5.3.2(acorn@6.4.2): - resolution: {integrity: sha512-rq9s+JNhf0IChjtDXxllJ7g41oZk5SlXtp0LHwyA5cejwn7vKmKp4pPri6YEePv2PU65sAsegbXtIinmDFDXgQ==} - peerDependencies: - acorn: ^6.0.0 || ^7.0.0 || ^8.0.0 - dependencies: - acorn: 6.4.2 - dev: true - - /acorn-jsx@5.3.2(acorn@8.8.2): + /acorn-jsx@5.3.2(acorn@8.11.3): resolution: {integrity: sha512-rq9s+JNhf0IChjtDXxllJ7g41oZk5SlXtp0LHwyA5cejwn7vKmKp4pPri6YEePv2PU65sAsegbXtIinmDFDXgQ==} peerDependencies: acorn: ^6.0.0 || ^7.0.0 || ^8.0.0 dependencies: - acorn: 8.8.2 + acorn: 8.11.3 dev: true /acorn-walk@8.3.2: @@ -4056,24 +4148,12 @@ packages: engines: {node: '>=0.4.0'} dev: true - /acorn@6.4.2: - resolution: {integrity: sha512-XtGIhXwF8YM8bJhGxG5kXgjkEuNGLTkoYqVE+KMR+aspr4KGYmKYg7yUe3KghyQ9yheNwLnjmzh/7+gfDBmHCQ==} - engines: {node: '>=0.4.0'} - hasBin: true - dev: true - /acorn@8.11.3: resolution: {integrity: sha512-Y9rRfJG5jcKOE0CLisYbojUjIrIEE7AGMzA/Sm4BslANhbS+cDMpgBdcPT91oJ7OuJ9hYJBx59RjbhxVnrF8Xg==} engines: {node: '>=0.4.0'} hasBin: true dev: true - /acorn@8.8.2: - resolution: {integrity: sha512-xjIYgE8HBrkpd/sJqOGNspf8uHG+NOHGOw6a/Urj8taM2EXfdNAH2oFcPeIFfsv3+kz/mJrS5VuMqbNLjCa2vw==} - engines: {node: '>=0.4.0'} - hasBin: true - dev: true - /adm-zip@0.4.16: resolution: {integrity: sha512-TFi4HBKSGfIKsK5YCkKaaFG2m4PEDyViZmEwof3MTIgzimHLto6muaHVpbrljdIvIrFZzEq/p4nafOeLcYegrg==} engines: {node: '>=0.3.0'} @@ -4089,13 +4169,7 @@ packages: debug: 4.3.4(supports-color@8.1.1) transitivePeerDependencies: - supports-color - - /agentkeepalive@4.5.0: - resolution: {integrity: sha512-5GG/5IbQQpC9FpkRGsSvZI5QYeSCzlJHdpBQntCsuTOxhKD8lqKhrleg2Yi7yvMIf82Ycmmqln9U8V9qwEiJew==} - engines: {node: '>= 8.0.0'} - dependencies: - humanize-ms: 1.2.1 - dev: false + dev: true /aggregate-error@3.1.0: resolution: {integrity: sha512-4I7Td01quW/RpocfNayFdFVk1qSuoh0E7JrbRJ16nH01HhKFQ88INq9Sd+nd72zqRySlr9BmDA8xlEJ6vJMrYA==} @@ -4103,6 +4177,7 @@ packages: dependencies: clean-stack: 2.2.0 indent-string: 4.0.0 + dev: true /ajv-formats@2.1.1(ajv@8.12.0): resolution: {integrity: sha512-Wx0Kx52hxE7C18hkMEggYlEifqWZtYaRgouJor+WMdPnQyEK13vgEWyVNup7SoeeoLMsr4kf5h6dOW11I15MUA==} @@ -4131,7 +4206,12 @@ packages: json-schema-traverse: 1.0.0 require-from-string: 2.0.2 uri-js: 4.4.1 - dev: false + + /ansi-align@3.0.1: + resolution: {integrity: sha512-IOfwwBF5iczOjp/WeY4YxyjqAFMQoZufdQWDd19SEExbVLNXqvpzSJ/M7Za4/sCPmQ0+GRquoA7bGcINcxew6w==} + dependencies: + string-width: 4.2.3 + dev: true /ansi-colors@4.1.1: resolution: {integrity: sha512-JoX0apGbHaUJBNl6yF+p6JAFYZ666/hhCGKN5t9QFjbJQKUU/g8MNbFDbvfrgKXvI1QpZplPOnwIo99lX/AAmA==} @@ -4143,29 +4223,28 @@ packages: engines: {node: '>=6'} dev: true - /ansi-escapes@3.2.0: - resolution: {integrity: sha512-cBhpre4ma+U0T1oM5fXg7Dy1Jw7zzwv7lt/GoCpr+hDQJoYnKVPLL4dCvSEFMmQurOQvSrwT7SL/DAlhBI97RQ==} - engines: {node: '>=4'} - dev: true - /ansi-escapes@4.3.2: resolution: {integrity: sha512-gKXj5ALrKWQLsYG9jlTRmR/xKluxHV+Z9QEwNIgCfM1/uwPMCuzVVnh5mwTd+OuBZcwSIMbqssNWRm1lE51QaQ==} engines: {node: '>=8'} dependencies: type-fest: 0.21.3 + /ansi-escapes@6.2.0: + resolution: {integrity: sha512-kzRaCqXnpzWs+3z5ABPQiVke+iq0KXkHo8xiWV4RPTi5Yli0l97BEQuhXV1s7+aSU/fu1kUuxgS4MsQ0fRuygw==} + engines: {node: '>=14.16'} + dependencies: + type-fest: 3.13.1 + dev: true + /ansi-regex@2.1.1: resolution: {integrity: sha512-TIGnTpdo+E3+pCyAluZvtED5p5wCqLdezCyhPZzKPcxvFplEt4i+W7OONCKgeZFT3+y5NZZfOOS/Bdcanm1MYA==} engines: {node: '>=0.10.0'} - - /ansi-regex@3.0.1: - resolution: {integrity: sha512-+O9Jct8wf++lXxxFc4hc8LsjaSq0HFzzL7cVsw8pRDIPdjKD2mT4ytDZlLuSBZ4cLKZFXIrMGO7DbQCtMJJMKw==} - engines: {node: '>=4'} - dev: true + dev: false /ansi-regex@4.1.1: resolution: {integrity: sha512-ILlv4k/3f6vfQ4OoP2AGvirOktlQ98ZEL1k9FaQjxa3L1abBgbuTDAdPOpvbGncC0BTVQrl+OM8xZGK6tWXt7g==} engines: {node: '>=6'} + dev: false /ansi-regex@5.0.1: resolution: {integrity: sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==} @@ -4174,11 +4253,6 @@ packages: /ansi-regex@6.0.1: resolution: {integrity: sha512-n5M855fKb2SsfMIiFFoVrABHJC8QtHwVx+mHWP3QcEqBHYienj5dHSgjbxtC0WEZXYt4wcD6zrQElDPhFuZgfA==} engines: {node: '>=12'} - dev: false - - /ansi-styles@2.2.1: - resolution: {integrity: sha512-kmCevFghRiWM7HB5zTPULl4r9bVFSWjz62MhqizDGUrq2NWuNMQyuv4tHHoKJHs69M/MF64lEcHdYIocrdWQYA==} - engines: {node: '>=0.10.0'} dev: true /ansi-styles@3.2.1: @@ -4198,28 +4272,19 @@ packages: engines: {node: '>=10'} dev: true - /antlr4@4.7.1: - resolution: {integrity: sha512-haHyTW7Y9joE5MVs37P2lNYfU2RWBLfcRDD8OWldcdZm5TiCE91B5Xl1oWSwiDUSd4rlExpt2pu1fksYQjRBYQ==} + /ansi-styles@6.2.1: + resolution: {integrity: sha512-bN798gFfQX+viw3R7yrGWRqnrN2oRkEkUjjl4JNn4E8GxxbjtG3FbrEIIY3l8/hrwUwIeCZvi4QuOTP4MErVug==} + engines: {node: '>=12'} + dev: true + + /antlr4@4.13.1: + resolution: {integrity: sha512-kiXTspaRYvnIArgE97z5YVVf/cDVQABr3abFRR6mE7yesLMkgu4ujuyV/sgxafQ8wgve0DJQUJ38Z8tkgA2izA==} + engines: {node: '>=16'} dev: true /antlr4ts@0.5.0-alpha.4: resolution: {integrity: sha512-WPQDt1B74OfPv/IMS2ekXAKkTZIHl88uMetg6q3OTqgFxZ/dxDXI0EWLyZid/1Pe6hTftyg5N7gel5wNAGxXyQ==} - /any-observable@0.3.0(rxjs@6.6.7): - resolution: {integrity: sha512-/FQM1EDkTsf63Ub2C6O7GuYFDsSXUwsaZDurV0np41ocwq0jthUAYCmhBX9f+KwlaCgIuWyr/4WlUQUBfKfZog==} - engines: {node: '>=6'} - peerDependencies: - rxjs: '*' - zenObservable: '*' - peerDependenciesMeta: - rxjs: - optional: true - zenObservable: - optional: true - dependencies: - rxjs: 6.6.7 - dev: true - /any-promise@1.3.0: resolution: {integrity: sha512-7UvmKalWRt1wgjL1RrGxoSJW/0QZFIegpeGvZG9kjp8vrRu55XTHbwnqq2GpXm9uLbcuhxm3IqX9OB4MZR1b2A==} @@ -4230,22 +4295,10 @@ packages: normalize-path: 3.0.0 picomatch: 2.3.1 - /aproba@2.0.0: - resolution: {integrity: sha512-lYe4Gx7QT+MKGbDsA+Z+he/Wtef0BiwDOlK/XkBrdfsh9J/jPPXbX0tE9x9cl27Tmu5gg3QUbUrQYa/y+KOHPQ==} - dev: false - /archy@1.0.0: resolution: {integrity: sha512-Xg+9RwCg/0p32teKdGMPTPnVXKD0w3DfHnFTficozsAgsvq2XenPJq/MYpzzQ/v8zrOyJn6Ds39VA4JIDwFfqw==} dev: false - /are-we-there-yet@3.0.1: - resolution: {integrity: sha512-QZW4EDmGwlYur0Yyf/b2uGucHQMa8aFUP7eu9ddR73vvhFyt4V0Vl3QHPcTNJ8l6qYOBdxgXdnBXQrHilfRQBg==} - engines: {node: ^12.13.0 || ^14.15.0 || >=16.0.0} - dependencies: - delegates: 1.0.0 - readable-stream: 3.6.0 - dev: false - /arg@5.0.2: resolution: {integrity: sha512-PYjyFOLKQ9y57JvQ6QLo8dAgNqswh8M1RMJYdQduT6xbWSgK36P/Z/v+p888pM69jMMfS8Xd8F6I1kQ/I9HUGg==} dev: true @@ -4274,14 +4327,22 @@ packages: iftype: 4.0.9 dev: false - /array-includes@3.1.6: - resolution: {integrity: sha512-sgTbLvL6cNnw24FnbaDyjmvddQ2ML8arZsgaJhoABMoplz/4QRhtrYS+alr1BUM1Bwp6dhx8vVCBSLG+StwOFw==} + /array-buffer-byte-length@1.0.1: + resolution: {integrity: sha512-ahC5W1xgou+KTXix4sAO8Ki12Q+jf4i0+tmk3sC+zgcynshkHxzpXdImBehiUYKKKDwvfFiJl1tZt6ewscS1Mg==} + engines: {node: '>= 0.4'} + dependencies: + call-bind: 1.0.7 + is-array-buffer: 3.0.4 + dev: true + + /array-includes@3.1.7: + resolution: {integrity: sha512-dlcsNBIiWhPkHdOEEKnehA+RNUWDc4UqFtnIXU4uuYDPtA4LDkr7qip2p0VvFAEXNDr0yWZ9PJyIRiGjRLQzwQ==} engines: {node: '>= 0.4'} dependencies: - call-bind: 1.0.2 - define-properties: 1.1.4 - es-abstract: 1.20.5 - get-intrinsic: 1.1.3 + call-bind: 1.0.7 + define-properties: 1.2.1 + es-abstract: 1.22.5 + get-intrinsic: 1.2.4 is-string: 1.0.7 dev: true @@ -4289,34 +4350,48 @@ packages: resolution: {integrity: sha512-HGyxoOTYUyCM6stUe6EJgnd4EoewAI7zMdfqO+kGjnlZmBDz/cR5pf8r/cR4Wq60sL/p0IkcjUEEPwS3GFrIyw==} engines: {node: '>=8'} - /array.prototype.flat@1.3.1: - resolution: {integrity: sha512-roTU0KWIOmJ4DRLmwKd19Otg0/mT3qPNt0Qb3GWW8iObuZXxrjB/pzn0R3hqpRSWg4HCwqx+0vwOnWnvlOyeIA==} + /array.prototype.flat@1.3.2: + resolution: {integrity: sha512-djYB+Zx2vLewY8RWlNCUdHjDXs2XOgm602S9E7P/UpHgfeHL00cRiIF+IN/G/aUJ7kGPb6yO/ErDI5V2s8iycA==} engines: {node: '>= 0.4'} dependencies: - call-bind: 1.0.2 - define-properties: 1.1.4 - es-abstract: 1.20.5 - es-shim-unscopables: 1.0.0 + call-bind: 1.0.7 + define-properties: 1.2.1 + es-abstract: 1.22.5 + es-shim-unscopables: 1.0.2 dev: true - /array.prototype.flatmap@1.3.1: - resolution: {integrity: sha512-8UGn9O1FDVvMNB0UlLv4voxRMze7+FpHyF5mSMRjWHUMlpoDViniy05870VlxhfgTnLbpuwTzvD76MTtWxB/mQ==} + /array.prototype.flatmap@1.3.2: + resolution: {integrity: sha512-Ewyx0c9PmpcsByhSW4r+9zDU7sGjFc86qf/kKtuSCRdhfbk0SNLLkaT5qvcHnRGgc5NP/ly/y+qkXkqONX54CQ==} engines: {node: '>= 0.4'} dependencies: - call-bind: 1.0.2 - define-properties: 1.1.4 - es-abstract: 1.20.5 - es-shim-unscopables: 1.0.0 + call-bind: 1.0.7 + define-properties: 1.2.1 + es-abstract: 1.22.5 + es-shim-unscopables: 1.0.2 dev: true - /array.prototype.tosorted@1.1.1: - resolution: {integrity: sha512-pZYPXPRl2PqWcsUs6LOMn+1f1532nEoPTYowBtqLwAW+W8vSVhkIGnmOX1t/UQjD6YGI0vcD2B1U7ZFGQH9jnQ==} + /array.prototype.tosorted@1.1.3: + resolution: {integrity: sha512-/DdH4TiTmOKzyQbp/eadcCVexiCb36xJg7HshYOYJnNZFDj33GEv0P7GxsynpShhq4OLYJzbGcBDkLsDt7MnNg==} dependencies: - call-bind: 1.0.2 - define-properties: 1.1.4 - es-abstract: 1.20.5 - es-shim-unscopables: 1.0.0 - get-intrinsic: 1.1.3 + call-bind: 1.0.7 + define-properties: 1.2.1 + es-abstract: 1.22.5 + es-errors: 1.3.0 + es-shim-unscopables: 1.0.2 + dev: true + + /arraybuffer.prototype.slice@1.0.3: + resolution: {integrity: sha512-bMxMKAjg13EBSVscxTaYA4mRc5t1UAXa2kXiGTNfZ079HIWXEkKmkgFrh/nJqamaLSrXO5H4WFFkPEaLJWbs3A==} + engines: {node: '>= 0.4'} + dependencies: + array-buffer-byte-length: 1.0.1 + call-bind: 1.0.7 + define-properties: 1.2.1 + es-abstract: 1.22.5 + es-errors: 1.3.0 + get-intrinsic: 1.2.4 + is-array-buffer: 3.0.4 + is-shared-array-buffer: 1.0.3 dev: true /arrayreduce@2.1.0: @@ -4338,13 +4413,13 @@ packages: objnest: 5.1.1 dev: false - /assemblyscript@0.21.2: - resolution: {integrity: sha512-p8XhdkxQxggJbA8O95iu0yUjOqIX1iy9T6D+BABzT0PUHOZbKrNgES/0aC+DgnmTN0V6EQ6XajRM2uiJ9Nt2Xw==} + /assemblyscript@0.21.7: + resolution: {integrity: sha512-GPKavCMUVZbrU31KTBMtnsRZa9pPN10ApfkPGNdL70Qpu/rORbTCte/37dnIUnQdXHm+5vHmG+iGRWmwJO5hvA==} engines: {node: '>=16.0.0', npm: '>=7.0.0'} hasBin: true dependencies: - binaryen: 109.0.0-nightly.20220826 - long: 5.2.1 + binaryen: 110.0.0-nightly.20221006 + long: 5.2.3 dev: true /assertion-error@1.1.0: @@ -4355,34 +4430,16 @@ packages: resolution: {integrity: sha512-XHusKxKz3zoYk1ic8Un640joHbFMhbqneyoZfoKnEGtf2ey9Uh/IdpcQplODdO/kENaMIWsD0nJm4+wX3UNLHA==} dev: true - /astral-regex@1.0.0: - resolution: {integrity: sha512-+Ryf6g3BKoRc7jfp7ad8tM4TtMiaWvbF/1/sQcZPkkS7ag3D5nMBCe2UfOTONtAkaG0tO0ij3C5Lwmf1EiyjHg==} - engines: {node: '>=4'} - dev: true - /astral-regex@2.0.0: resolution: {integrity: sha512-Z7tMw1ytTXt5jqMcOP+OQteU1VuNK9Y02uuJtKQ1Sv69jXQKKg5cibLwGJow8yzZP+eAc18EmLGPal0bp36rvQ==} engines: {node: '>=8'} - dev: false - - /async-eventemitter@0.2.4: - resolution: {integrity: sha512-pd20BwL7Yt1zwDFy+8MX8F1+WCT8aQeKj0kQnTrH9WaeRETlRamVhD0JtRPmrV4GfOJ2F9CvdQkZeZhnh2TuHw==} - dependencies: - async: 2.6.4 - dev: true /async@1.5.2: resolution: {integrity: sha512-nSVgobk4rv61R9PUSDtYt7mPVB2olxNR5RWJcAsH676/ef11bUZwvu7+RGYrYauVdDPcO519v68wRhXQtxsV9w==} dev: false - /async@2.6.4: - resolution: {integrity: sha512-mzo5dfJYwAn29PeiJ0zvwTo04zj8HDJj0Mn8TD7sno7q12prdbnasKJHhkm2c1LgrhlJ0teaea8860oxi51mGA==} - dependencies: - lodash: 4.17.21 - dev: true - - /async@3.2.4: - resolution: {integrity: sha512-iAB+JbDEGXhyIUavoDl9WP/Jj106Kz9DEn1DPgYw5ruDn0e3Wgi3sKFm55sASdGBNOQB8F59d9qQ7deqrHA8wQ==} + /async@3.2.5: + resolution: {integrity: sha512-baNZyqaaLhyLVKm/DlvdW051MSgO6b8eVfIezl9E5PqWxFgzLm/wQntEW4zOytVburDEr0JlALEpdOFwvErLsg==} /asynckit@0.4.0: resolution: {integrity: sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q==} @@ -4393,43 +4450,51 @@ packages: engines: {node: '>=8.0.0'} dev: false - /autoprefixer@10.4.14(postcss@8.4.23): - resolution: {integrity: sha512-FQzyfOsTlwVzjHxKEqRIAdJx9niO6VCBCoEwax/VLSoQF29ggECcPuBqUMZ+u8jCZOPSy8b8/8KnuFbp0SaFZQ==} + /autoprefixer@10.4.17(postcss@8.4.35): + resolution: {integrity: sha512-/cpVNRLSfhOtcGflT13P2794gVSgmPgTR+erw5ifnMLZb0UnSlkK4tquLmkd3BhA+nLo5tX8Cu0upUsGKvKbmg==} engines: {node: ^10 || ^12 || >=14} hasBin: true peerDependencies: postcss: ^8.1.0 dependencies: - browserslist: 4.21.5 - caniuse-lite: 1.0.30001470 - fraction.js: 4.2.0 + browserslist: 4.23.0 + caniuse-lite: 1.0.30001591 + fraction.js: 4.3.7 normalize-range: 0.1.2 picocolors: 1.0.0 - postcss: 8.4.23 + postcss: 8.4.35 postcss-value-parser: 4.2.0 dev: true - /avvio@8.2.1: - resolution: {integrity: sha512-TAlMYvOuwGyLK3PfBb5WKBXZmXz2fVCgv23d6zZFdle/q3gPjmxBaeuC0pY0Dzs5PWMSgfqqEZkrye19GlDTgw==} + /available-typed-arrays@1.0.7: + resolution: {integrity: sha512-wvUjBtSGN7+7SjNpq/9M2Tg350UZD3q62IFZLbRAR1bSMlCo1ZaeW+BJ+D090e4hIIZLBcTDWe4Mh4jvUDajzQ==} + engines: {node: '>= 0.4'} + dependencies: + possible-typed-array-names: 1.0.0 + dev: true + + /avvio@8.3.0: + resolution: {integrity: sha512-VBVH0jubFr9LdFASy/vNtm5giTrnbVquWBhT0fyizuNK2rQ7e7ONU2plZQWUNqtE1EmxFEb+kbSkFRkstiaS9Q==} dependencies: + '@fastify/error': 3.4.1 archy: 1.0.0 debug: 4.3.4(supports-color@8.1.1) - fastq: 1.15.0 + fastq: 1.17.1 transitivePeerDependencies: - supports-color dev: false - /babel-jest@29.5.0(@babel/core@7.21.4): - resolution: {integrity: sha512-mA4eCDh5mSo2EcA9xQjVTpmbbNk32Zb3Q3QFQsNhaK56Q+yoXowzFodLux30HRgyOho5rsQ6B0P9QpMkvvnJ0Q==} + /babel-jest@29.7.0(@babel/core@7.24.0): + resolution: {integrity: sha512-BrvGY3xZSwEcCzKvKsCi2GgHqDqsYkOP4/by5xCgIwGXQxIEh+8ew3gmrE1y7XRR6LHZIj6yLYnUi/mm2KXKBg==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} peerDependencies: '@babel/core': ^7.8.0 dependencies: - '@babel/core': 7.21.4 - '@jest/transform': 29.5.0 - '@types/babel__core': 7.20.0 + '@babel/core': 7.24.0 + '@jest/transform': 29.7.0 + '@types/babel__core': 7.20.5 babel-plugin-istanbul: 6.1.1 - babel-preset-jest: 29.5.0(@babel/core@7.21.4) + babel-preset-jest: 29.6.3(@babel/core@7.24.0) chalk: 4.1.2 graceful-fs: 4.2.11 slash: 3.0.0 @@ -4441,7 +4506,7 @@ packages: resolution: {integrity: sha512-Y1IQok9821cC9onCx5otgFfRm7Lm+I+wwxOx738M/WLPZ9Q42m4IG5W0FNX8WLL2gYMZo3JkuXIH2DOpWM+qwA==} engines: {node: '>=8'} dependencies: - '@babel/helper-plugin-utils': 7.20.2 + '@babel/helper-plugin-utils': 7.24.0 '@istanbuljs/load-nyc-config': 1.1.0 '@istanbuljs/schema': 0.1.3 istanbul-lib-instrument: 5.2.1 @@ -4450,45 +4515,45 @@ packages: - supports-color dev: true - /babel-plugin-jest-hoist@29.5.0: - resolution: {integrity: sha512-zSuuuAlTMT4mzLj2nPnUm6fsE6270vdOfnpbJ+RmruU75UhLFvL0N2NgI7xpeS7NaB6hGqmd5pVpGTDYvi4Q3w==} + /babel-plugin-jest-hoist@29.6.3: + resolution: {integrity: sha512-ESAc/RJvGTFEzRwOTT4+lNDk/GNHMkKbNzsvT0qKRfDyyYTskxB5rnU2njIDYVxXCBHHEI1c0YwHob3WaYujOg==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} dependencies: - '@babel/template': 7.20.7 - '@babel/types': 7.21.4 - '@types/babel__core': 7.20.0 - '@types/babel__traverse': 7.18.3 + '@babel/template': 7.24.0 + '@babel/types': 7.24.0 + '@types/babel__core': 7.20.5 + '@types/babel__traverse': 7.20.5 dev: true - /babel-preset-current-node-syntax@1.0.1(@babel/core@7.21.4): + /babel-preset-current-node-syntax@1.0.1(@babel/core@7.24.0): resolution: {integrity: sha512-M7LQ0bxarkxQoN+vz5aJPsLBn77n8QgTFmo8WK0/44auK2xlCXrYcUxHFxgU7qW5Yzw/CjmLRK2uJzaCd7LvqQ==} peerDependencies: '@babel/core': ^7.0.0 dependencies: - '@babel/core': 7.21.4 - '@babel/plugin-syntax-async-generators': 7.8.4(@babel/core@7.21.4) - '@babel/plugin-syntax-bigint': 7.8.3(@babel/core@7.21.4) - '@babel/plugin-syntax-class-properties': 7.12.13(@babel/core@7.21.4) - '@babel/plugin-syntax-import-meta': 7.10.4(@babel/core@7.21.4) - '@babel/plugin-syntax-json-strings': 7.8.3(@babel/core@7.21.4) - '@babel/plugin-syntax-logical-assignment-operators': 7.10.4(@babel/core@7.21.4) - '@babel/plugin-syntax-nullish-coalescing-operator': 7.8.3(@babel/core@7.21.4) - '@babel/plugin-syntax-numeric-separator': 7.10.4(@babel/core@7.21.4) - '@babel/plugin-syntax-object-rest-spread': 7.8.3(@babel/core@7.21.4) - '@babel/plugin-syntax-optional-catch-binding': 7.8.3(@babel/core@7.21.4) - '@babel/plugin-syntax-optional-chaining': 7.8.3(@babel/core@7.21.4) - '@babel/plugin-syntax-top-level-await': 7.14.5(@babel/core@7.21.4) - dev: true - - /babel-preset-jest@29.5.0(@babel/core@7.21.4): - resolution: {integrity: sha512-JOMloxOqdiBSxMAzjRaH023/vvcaSaec49zvg+2LmNsktC7ei39LTJGw02J+9uUtTZUq6xbLyJ4dxe9sSmIuAg==} + '@babel/core': 7.24.0 + '@babel/plugin-syntax-async-generators': 7.8.4(@babel/core@7.24.0) + '@babel/plugin-syntax-bigint': 7.8.3(@babel/core@7.24.0) + '@babel/plugin-syntax-class-properties': 7.12.13(@babel/core@7.24.0) + '@babel/plugin-syntax-import-meta': 7.10.4(@babel/core@7.24.0) + '@babel/plugin-syntax-json-strings': 7.8.3(@babel/core@7.24.0) + '@babel/plugin-syntax-logical-assignment-operators': 7.10.4(@babel/core@7.24.0) + '@babel/plugin-syntax-nullish-coalescing-operator': 7.8.3(@babel/core@7.24.0) + '@babel/plugin-syntax-numeric-separator': 7.10.4(@babel/core@7.24.0) + '@babel/plugin-syntax-object-rest-spread': 7.8.3(@babel/core@7.24.0) + '@babel/plugin-syntax-optional-catch-binding': 7.8.3(@babel/core@7.24.0) + '@babel/plugin-syntax-optional-chaining': 7.8.3(@babel/core@7.24.0) + '@babel/plugin-syntax-top-level-await': 7.14.5(@babel/core@7.24.0) + dev: true + + /babel-preset-jest@29.6.3(@babel/core@7.24.0): + resolution: {integrity: sha512-0B3bhxR6snWXJZtR/RliHTDPRgn1sNHOR0yVtq/IiQFyuOVjFS+wuio/R4gSNkyYmKmJB4wGZv2NZanmKmTnNA==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} peerDependencies: '@babel/core': ^7.0.0 dependencies: - '@babel/core': 7.21.4 - babel-plugin-jest-hoist: 29.5.0 - babel-preset-current-node-syntax: 1.0.1(@babel/core@7.21.4) + '@babel/core': 7.24.0 + babel-plugin-jest-hoist: 29.6.3 + babel-preset-current-node-syntax: 1.0.1(@babel/core@7.24.0) dev: true /babel-runtime@6.26.0: @@ -4509,6 +4574,7 @@ packages: /base64-js@1.5.1: resolution: {integrity: sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA==} + dev: false /bech32@1.1.4: resolution: {integrity: sha512-s0IrSOzLlbvX7yp4WBfPITzpAU8sqQcpsmwXDiKwrG4r491vwCO/XpejasRNl0piBMe/DvP4Tz0mIS/X1DPJBQ==} @@ -4520,20 +4586,25 @@ packages: is-windows: 1.0.2 dev: true - /better-sqlite3@8.6.0: - resolution: {integrity: sha512-jwAudeiTMTSyby+/SfbHDebShbmC2MCH8mU2+DXi0WJfv13ypEJm47cd3kljmy/H130CazEvkf2Li//ewcMJ1g==} + /better-sqlite3@8.7.0: + resolution: {integrity: sha512-99jZU4le+f3G6aIl6PmmV0cxUIWqKieHxsiF7G34CVFiE+/UabpYqkU0NJIkY/96mQKikHeBjtR27vFfs5JpEw==} requiresBuild: true dependencies: bindings: 1.5.0 - prebuild-install: 7.1.1 + prebuild-install: 7.1.2 dev: false + /bigint-crypto-utils@3.3.0: + resolution: {integrity: sha512-jOTSb+drvEDxEq6OuUybOAv/xxoh3cuYRUIPyu8sSHQNKM303UQ2R1DAo45o1AkcIXw6fzbaFI1+xGGdaXs2lg==} + engines: {node: '>=14.0.0'} + dev: true + /binary-extensions@2.2.0: resolution: {integrity: sha512-jDctJ/IVQbZoJykoeHbhXpOlNBqGNcwXJKJog42E5HDPUwQTSdjCHdihjj0DlnheQ7blbT6dHOafNAiS8ooQKA==} engines: {node: '>=8'} - /binaryen@109.0.0-nightly.20220826: - resolution: {integrity: sha512-c4I7HTm0yn+CO54Imt2sRHct2bEwlTDRGtIAJCwFyLssfUvb4FH3DaaRHNrcB8T1llvw1oWfYzBhO6tgIo2Grg==} + /binaryen@110.0.0-nightly.20221006: + resolution: {integrity: sha512-yC7ZLoaZmXhm5cB0+g3rZkz5ujPSlhX+FEQtgaQHVxcL78D8cTXdRSdajhgQD345BVPsooOrSxqhX6tnULgBWg==} hasBin: true dev: true @@ -4548,7 +4619,7 @@ packages: dependencies: buffer: 5.7.1 inherits: 2.0.4 - readable-stream: 3.6.0 + readable-stream: 3.6.2 dev: false /blakejs@1.2.1: @@ -4565,6 +4636,20 @@ packages: /bn.js@5.2.1: resolution: {integrity: sha512-eXRvHzWyYPBuB4NBy0cmYQjGitUrtqwbvlzP3G6VFnNRbsZQIxQ10PbKKHt8gZ/HW/D/747aDl+QkDqg3KQLMQ==} + /boxen@5.1.2: + resolution: {integrity: sha512-9gYgQKXx+1nP8mP7CzFyaUARhg7D3n1dF/FnErWmu9l6JvGpNUN278h0aSb+QjoiKSWG+iZ3uHrcqk0qrY9RQQ==} + engines: {node: '>=10'} + dependencies: + ansi-align: 3.0.1 + camelcase: 6.3.0 + chalk: 4.1.2 + cli-boxes: 2.2.1 + string-width: 4.2.3 + type-fest: 0.20.2 + widest-line: 3.1.0 + wrap-ansi: 7.0.0 + dev: true + /brace-expansion@1.1.11: resolution: {integrity: sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==} dependencies: @@ -4610,15 +4695,15 @@ packages: safe-buffer: 5.2.1 dev: true - /browserslist@4.21.5: - resolution: {integrity: sha512-tUkiguQGW7S3IhB7N+c2MV/HZPSCPAAiYBZXLsBhFB/PCy6ZKKsZrmBayHV9fdGV/ARIfJ14NkxKzRDjvp7L6w==} + /browserslist@4.23.0: + resolution: {integrity: sha512-QW8HiM1shhT2GuzkvklfjcKDiWFXHOeFCIA/huJPwHsslwcydgk7X+z2zXpEijP98UCY7HbubZt5J2Zgvf0CaQ==} engines: {node: ^6 || ^7 || ^8 || ^9 || ^10 || ^11 || ^12 || >=13.7} hasBin: true dependencies: - caniuse-lite: 1.0.30001470 - electron-to-chromium: 1.4.340 - node-releases: 2.0.10 - update-browserslist-db: 1.0.10(browserslist@4.21.5) + caniuse-lite: 1.0.30001591 + electron-to-chromium: 1.4.688 + node-releases: 2.0.14 + update-browserslist-db: 1.0.13(browserslist@4.23.0) dev: true /bs-logger@0.2.6: @@ -4651,25 +4736,20 @@ packages: /buffer-from@1.1.2: resolution: {integrity: sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ==} - /buffer-lite@1.0.0: - resolution: {integrity: sha512-PGWl2OKxX317hJJaQpLW6Gikg4bEyyyMqJKlIH0NY56ePbqCATg02OctB/CWkvjtJG/kWxvM1ObEkNQFx8xJnA==} + /buffer-lite@1.1.0: + resolution: {integrity: sha512-oU0QAzHknj4a3PNzTznNUN61r6OdAqqJJdzTm422yyIM3QyK5/7zi8wPVFooCwoPKk90ybCm9qnvkk+tsQt5sg==} dev: true /buffer-xor@1.0.3: resolution: {integrity: sha512-571s0T7nZWK6vB67HI5dyUF7wXiNcfaPPPTl6zYCNApANjIvYJTg7hlud/+cJpdAhS7dVzqMLmfhfHR3rAcOjQ==} dev: true - /buffer-xor@2.0.2: - resolution: {integrity: sha512-eHslX0bin3GB+Lx2p7lEYRShRewuNZL3fUl4qlVJGGiwoPGftmt8JQgk2Y9Ji5/01TnVDo33E5b5O3vUB1HdqQ==} - dependencies: - safe-buffer: 5.2.1 - dev: true - /buffer@5.7.1: resolution: {integrity: sha512-EHcyIPBQ4BSGlvjB16k5KgAJ27CIsHY/2JBmCRReo48y9rQ3MaUzWX3KVlBa4U7MyX02HdVj0K7C3WaB3ju7FQ==} dependencies: base64-js: 1.5.1 ieee754: 1.2.1 + dev: false /buffer@6.0.3: resolution: {integrity: sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA==} @@ -4678,38 +4758,31 @@ packages: ieee754: 1.2.1 dev: false - /bun@1.0.11: - resolution: {integrity: sha512-cKyQAQOfWNIP511UpQjkABUp7z/5+1ci2kXfhjL9PozHoCaCtnYFtVjeqU1LovpqEP1agAsMiDpGNKbJP89RIw==} + /bun@1.0.29: + resolution: {integrity: sha512-OQfMWb+UxgBA5Fnne/6GPmk3kh9HmECOIGG2P/m97QYmCthKMJlFBF8Q5TC+ayL5TvfVEXZxw7V4yHr1cqGK6w==} cpu: [arm64, x64] os: [darwin, linux] hasBin: true requiresBuild: true optionalDependencies: - '@oven/bun-darwin-aarch64': 1.0.11 - '@oven/bun-darwin-x64': 1.0.11 - '@oven/bun-darwin-x64-baseline': 1.0.11 - '@oven/bun-linux-aarch64': 1.0.11 - '@oven/bun-linux-x64': 1.0.11 - '@oven/bun-linux-x64-baseline': 1.0.11 + '@oven/bun-darwin-aarch64': 1.0.29 + '@oven/bun-darwin-x64': 1.0.29 + '@oven/bun-darwin-x64-baseline': 1.0.29 + '@oven/bun-linux-aarch64': 1.0.29 + '@oven/bun-linux-x64': 1.0.29 + '@oven/bun-linux-x64-baseline': 1.0.29 dev: true - /bundle-require@4.0.1(esbuild@0.17.17): - resolution: {integrity: sha512-9NQkRHlNdNpDBGmLpngF3EFDcwodhMUuLz9PaWYciVcQF9SE4LFjM2DB/xV1Li5JiuDMv7ZUWuC3rGbqR0MAXQ==} + /bundle-require@4.0.2(esbuild@0.17.19): + resolution: {integrity: sha512-jwzPOChofl67PSTW2SGubV9HBQAhhR2i6nskiOThauo9dzwDUgOWQScFVaJkjEfYX+UXiD+LEx8EblQMc2wIag==} engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} peerDependencies: esbuild: '>=0.17' dependencies: - esbuild: 0.17.17 + esbuild: 0.17.19 load-tsconfig: 0.2.5 dev: true - /busboy@1.6.0: - resolution: {integrity: sha512-8SFQbg/0hQ9xy3UNTB0YEnsNBbWfhf7RtnzpL7TkBiTBRfrQ9Fxcnz7VJsleJpyp6rVLvXiuORqjlHi5q+PYuA==} - engines: {node: '>=10.16.0'} - dependencies: - streamsearch: 1.1.0 - dev: true - /bytes@3.1.2: resolution: {integrity: sha512-/Nf7TyzTx6S3yRJObOAV7956r8cr2+Oj8AC5dt8wSP3BQAoeX58NoHyCU8P8zGkNXStjTSi6fzO6F0pBdcYbEg==} engines: {node: '>= 0.8'} @@ -4720,32 +4793,6 @@ packages: engines: {node: '>=8'} dev: true - /cacache@16.1.3: - resolution: {integrity: sha512-/+Emcj9DAXxX4cwlLmRI9c166RuL3w30zp4R7Joiv2cQTtTtA+jeuCAjH3ZlGnYS3tKENSrKhAzVVP9GVyzeYQ==} - engines: {node: ^12.13.0 || ^14.15.0 || >=16.0.0} - dependencies: - '@npmcli/fs': 2.1.2 - '@npmcli/move-file': 2.0.1 - chownr: 2.0.0 - fs-minipass: 2.1.0 - glob: 8.0.3 - infer-owner: 1.0.4 - lru-cache: 7.18.3 - minipass: 3.3.6 - minipass-collect: 1.0.2 - minipass-flush: 1.0.5 - minipass-pipeline: 1.2.4 - mkdirp: 1.0.4 - p-map: 4.0.0 - promise-inflight: 1.0.1 - rimraf: 3.0.2 - ssri: 9.0.1 - tar: 6.2.0 - unique-filename: 2.0.1 - transitivePeerDependencies: - - bluebird - dev: false - /cache-content-type@1.0.1: resolution: {integrity: sha512-IKufZ1o4Ut42YUrZSo8+qnMTrFuKkvyoLXUywKz9GJ5BrhOFGhLdkx9sG4KAnVvbY6kEcSFjLQul+DVmBm2bgA==} engines: {node: '>= 6.0.0'} @@ -4754,30 +4801,15 @@ packages: ylru: 1.3.2 dev: false - /call-bind@1.0.2: - resolution: {integrity: sha512-7O+FbCihrB5WGbFYesctwmTKae6rOiIzmz1icreWJ+0aA7LJfuqhEso2T9ncpcFtzMQtzXf2QGGueWJGTYsqrA==} - dependencies: - function-bind: 1.1.1 - get-intrinsic: 1.1.3 - dev: true - - /caller-callsite@2.0.0: - resolution: {integrity: sha512-JuG3qI4QOftFsZyOn1qq87fq5grLIyk1JYd5lJmdA+fG7aQ9pA/i3JIJGcO3q0MrRcHlOt1U+ZeHW8Dq9axALQ==} - engines: {node: '>=4'} - dependencies: - callsites: 2.0.0 - dev: true - - /caller-path@2.0.0: - resolution: {integrity: sha512-MCL3sf6nCSXOwCTzvPKhN18TU7AHTvdtam8DAogxcrJ8Rjfbbg7Lgng64H9Iy+vUV6VGFClN/TyxBkAebLRR4A==} - engines: {node: '>=4'} + /call-bind@1.0.7: + resolution: {integrity: sha512-GHTSNSYICQ7scH7sZ+M2rFopRoLh8t2bLSW6BbgrtLsahOIB5iyAVJf9GjWK3cYTDaMj4XdBpM1cA6pIS0Kv2w==} + engines: {node: '>= 0.4'} dependencies: - caller-callsite: 2.0.0 - dev: true - - /callsites@2.0.0: - resolution: {integrity: sha512-ksWePWBloaWPxJYQ8TL0JHvtci6G5QTKwQ95RcWAa/lzoAKuAOflGdAK92hpHXjkwb8zLxoLNUoNYZgVsaJzvQ==} - engines: {node: '>=4'} + es-define-property: 1.0.0 + es-errors: 1.3.0 + function-bind: 1.1.2 + get-intrinsic: 1.2.4 + set-function-length: 1.2.1 dev: true /callsites@3.1.0: @@ -4808,35 +4840,22 @@ packages: engines: {node: '>=10'} dev: true - /caniuse-lite@1.0.30001470: - resolution: {integrity: sha512-065uNwY6QtHCBOExzbV6m236DDhYCCtPmQUCoQtwkVqzud8v5QPidoMr6CoMkC2nfp6nksjttqWQRRh75LqUmA==} + /caniuse-lite@1.0.30001591: + resolution: {integrity: sha512-PCzRMei/vXjJyL5mJtzNiUCKP59dm8Apqc3PH8gJkMnMXZGox93RbE76jHsmLwmIo6/3nsYIpJtx0O7u5PqFuQ==} dev: true - /case-anything@2.1.10: - resolution: {integrity: sha512-JczJwVrCP0jPKh05McyVsuOg6AYosrB9XWZKbQzXeDAm2ClE/PJE/BcrrQrVyGYH7Jg8V/LDupmyL4kFlVsVFQ==} + /case-anything@2.1.13: + resolution: {integrity: sha512-zlOQ80VrQ2Ue+ymH5OuM/DlDq64mEm+B9UTdHULv5osUMD6HalNTblf2b1u/m6QecjsnOkBpqVZ+XPwIVsy7Ng==} engines: {node: '>=12.13'} dev: true - /chai-as-promised@7.1.1(chai@4.3.7): + /chai-as-promised@7.1.1(chai@4.4.1): resolution: {integrity: sha512-azL6xMoi+uxu6z4rhWQ1jbdUhOMhis2PvscD/xjLqNMkv3BPPp2JyyuTHOrf9BOosGpNQ11v6BKv/g57RXbiaA==} peerDependencies: chai: '>= 2.1.2 < 5' dependencies: - chai: 4.3.7 - check-error: 1.0.2 - dev: true - - /chai@4.3.7: - resolution: {integrity: sha512-HLnAzZ2iupm25PlN0xFreAlBA5zaBSv3og0DdeGA4Ar6h6rJ3A0rolRUKJhSF2V10GZKDgWF/VmAEsNWjCRB+A==} - engines: {node: '>=4'} - dependencies: - assertion-error: 1.1.0 - check-error: 1.0.2 - deep-eql: 4.1.3 - get-func-name: 2.0.0 - loupe: 2.3.6 - pathval: 1.1.1 - type-detect: 4.0.8 + chai: 4.4.1 + check-error: 1.0.3 dev: true /chai@4.4.1: @@ -4847,22 +4866,11 @@ packages: check-error: 1.0.3 deep-eql: 4.1.3 get-func-name: 2.0.2 - loupe: 2.3.6 + loupe: 2.3.7 pathval: 1.1.1 type-detect: 4.0.8 dev: true - /chalk@1.1.3: - resolution: {integrity: sha512-U3lRVLMSlsCfjqYPbLyVv11M9CPW4I728d6TCKMAOJueEeB9/8o+eSsMnxPJD+Q+K909sdESg7C+tIkoH6on1A==} - engines: {node: '>=0.10.0'} - dependencies: - ansi-styles: 2.2.1 - escape-string-regexp: 1.0.5 - has-ansi: 2.0.0 - strip-ansi: 3.0.1 - supports-color: 2.0.0 - dev: true - /chalk@2.4.2: resolution: {integrity: sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==} engines: {node: '>=4'} @@ -4872,14 +4880,6 @@ packages: supports-color: 5.5.0 dev: true - /chalk@3.0.0: - resolution: {integrity: sha512-4D3B6Wf41KOYRFdszmDqMCGq5VV/uMAB273JILmO+3jAlh8X4qDtdtgCR3fxtbLEMzSx22QdhnDcJvu2u1fVwg==} - engines: {node: '>=8'} - dependencies: - ansi-styles: 4.3.0 - supports-color: 7.2.0 - dev: true - /chalk@4.1.2: resolution: {integrity: sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==} engines: {node: '>=10'} @@ -4887,17 +4887,13 @@ packages: ansi-styles: 4.3.0 supports-color: 7.2.0 - /chalk@5.2.0: - resolution: {integrity: sha512-ree3Gqw/nazQAPuJJEy+avdl7QfZMcUvmHIKgEZkGL+xOBzRvup5Hxo6LHuMceSxOabuJLJm5Yp/92R9eMmMvA==} - engines: {node: ^12.17.0 || ^14.13 || >=16.0.0} - /chalk@5.3.0: resolution: {integrity: sha512-dLitG79d+GV1Nb/VYcCDFivJeK1hiukt9QjRNVOsUtTy1rR1YJsmpGGTZ3qJos+uw7WmWF4wUwBd9jxjocFC2w==} engines: {node: ^12.17.0 || ^14.13 || >=16.0.0} - dev: false + dev: true - /change-case@5.2.0: - resolution: {integrity: sha512-L6VzznESnMIKKdKhVzCG+KPz4+x1FWbjOs1AdhoHStV3qo8aySMRGPUoqC0aL1ThKaQNGhAu6ZfHL/QAyQRuiw==} + /change-case@5.4.3: + resolution: {integrity: sha512-4cdyvorTy/lViZlVzw2O8/hHCLUuHqp4KpSSP3DlauhFCf3LdnfF+p5s0EAhjKsU7bqrMzu7iQArYfoPiHO2nw==} dev: false /char-regex@1.0.2: @@ -4908,10 +4904,6 @@ packages: /chardet@0.7.0: resolution: {integrity: sha512-mT8iDcrh03qDGRRmoA2hmBJnxpllMR+0/0qlzjqZES6NdiWDcZkCNAk4rPFZ9Q85r27unkiNNg8ZOiwZXBHwcA==} - /check-error@1.0.2: - resolution: {integrity: sha512-BrgHpW9NURQgzoNyjfq0Wu6VFO6D7IZEmJNdtgNqpzGG8RuNFHt2jQxWlAs4HMe119chBnv+34syEZtc6IhLtA==} - dev: true - /check-error@1.0.3: resolution: {integrity: sha512-iKEoDYaRmd1mxM90a2OEfWhjsjPpYPuQ+lMYsoxB126+t8fw7ySEO48nmDg5COTjxDI65/Y2OWpeEHk3ZOe8zg==} dependencies: @@ -4931,22 +4923,32 @@ packages: readdirp: 3.6.0 optionalDependencies: fsevents: 2.3.3 + dev: true + + /chokidar@3.6.0: + resolution: {integrity: sha512-7VT13fmjotKpGipCW9JEQAusEPE+Ei8nl6/g4FBAmIm0GOOLMua9NDDo/DWp0ZAxCr3cPq5ZpBqmPAQgDda2Pw==} + engines: {node: '>= 8.10.0'} + dependencies: + anymatch: 3.1.3 + braces: 3.0.2 + glob-parent: 5.1.2 + is-binary-path: 2.1.0 + is-glob: 4.0.3 + normalize-path: 3.0.0 + readdirp: 3.6.0 + optionalDependencies: + fsevents: 2.3.3 /chownr@1.1.4: resolution: {integrity: sha512-jJ0bqzaylmJtVnNgzTeSOs8DPavpbYgEr/b0YL8/2GO3xJEhInFmhKMUnEJQjZumK7KXGFhUy89PrsJWlakBVg==} dev: false - /chownr@2.0.0: - resolution: {integrity: sha512-bIomtDF5KGpdogkLd9VspvFzk9KfpyyGlS8YFVZl7TGPBHL5snIOnxeshwVgPteQ9b4Eydl+pVbIyE1DcvCWgQ==} - engines: {node: '>=10'} - dev: false - /ci-info@2.0.0: resolution: {integrity: sha512-5tK7EtrZ0N+OLFMthtqOj4fI2Jeb88C4CAZPu25LDVUgXJ0A3Js4PMGqrn0JU1W0Mh1/Z8wZzYPxqUrXeBboCQ==} dev: true - /ci-info@3.8.0: - resolution: {integrity: sha512-eXTggHWSooYhq49F2opQhuHWgzucfF2YgODK4e1566GQs5BIfP30B0oenwBJHfWxAs2fyPB1s7Mg949zLf61Yw==} + /ci-info@3.9.0: + resolution: {integrity: sha512-NIxF55hv4nSqQswkAeiOi1r83xy8JldOFDTWiug55KBu9Jnblncd2U6ViHmYgHf01TPZS77NJBhBMKdWj9HQMQ==} engines: {node: '>=8'} dev: true @@ -4957,32 +4959,31 @@ packages: safe-buffer: 5.2.1 dev: true - /cjs-module-lexer@1.2.2: - resolution: {integrity: sha512-cOU9usZw8/dXIXKtwa8pM0OTJQuJkxMN6w30csNRUerHfeQ5R6U3kkU/FtJeIf3M202OHfY2U8ccInBG7/xogA==} + /cjs-module-lexer@1.2.3: + resolution: {integrity: sha512-0TNiGstbQmCFwt4akjjBg5pLRTSyj/PkWQ1ZoO2zntmg9yLqSRxwEa4iCfQLGjqhiqBfOJa7W/E8wfGrTDmlZQ==} dev: true /clean-stack@2.2.0: resolution: {integrity: sha512-4diC9HaTE+KRAMWhDhrGOECgWZxoevMc5TlkObMqNSsVU62PYzXZ/SMTjzyGAFF1YusgxGcSWTEXBhp0CPwQ1A==} engines: {node: '>=6'} + dev: true + + /cli-boxes@2.2.1: + resolution: {integrity: sha512-y4coMcylgSCdVinjiDBuR8PCC2bLjyGTwEmPb9NHR/QaNU6EUOXcTY/s6VjGMD6ENSEaeQYHCY0GNGS5jfMwPw==} + engines: {node: '>=6'} + dev: true /cli-color@1.4.0: resolution: {integrity: sha512-xu6RvQqqrWEo6MPR1eixqGPywhYBHRs653F9jfXB2Hx4jdM/3WxiNE1vppRmxtMIfl16SFYTpYlrnqH/HsK/2w==} dependencies: ansi-regex: 2.1.1 d: 1.0.1 - es5-ext: 0.10.62 + es5-ext: 0.10.64 es6-iterator: 2.0.3 memoizee: 0.4.15 timers-ext: 0.1.7 dev: false - /cli-cursor@2.1.0: - resolution: {integrity: sha512-8lgKz8LmCRYZZQDpRyT2m5rKJ08TnU4tR9FFFW2rxpxR1FzWi4PQ/NfyODchAatHaUgnSPVcx/R5w6NuTBzFiw==} - engines: {node: '>=4'} - dependencies: - restore-cursor: 2.0.0 - dev: true - /cli-cursor@3.1.0: resolution: {integrity: sha512-I/zHAwsKf9FqGoXM4WWRACob9+SNukZTd94DWF57E4toouRulbCxcUh6RKUEOQlYTHJnzkPMySvPNaaSLNfLZw==} engines: {node: '>=8'} @@ -4990,16 +4991,19 @@ packages: restore-cursor: 3.1.0 dev: false - /cli-truncate@0.2.1: - resolution: {integrity: sha512-f4r4yJnbT++qUPI9NR4XLDLq41gQ+uqnPItWG0F5ZkehuNiTTa3EY0S4AqTSUOeJ7/zU41oWPQSNkW5BqPL9bg==} - engines: {node: '>=0.10.0'} + /cli-cursor@4.0.0: + resolution: {integrity: sha512-VGtlMu3x/4DOtIUwEkRezxUZ2lBacNJCHash0N0WeZDBS+7Ux1dm3XWAgWYxLJFMMdOeXMHXorshEFhbMSGelg==} + engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} dependencies: - slice-ansi: 0.0.4 - string-width: 1.0.2 + restore-cursor: 4.0.0 dev: true - /cli-width@2.2.1: - resolution: {integrity: sha512-GRMWDxpOB6Dgk2E5Uo+3eEBvtOOlimMmpbFiKuLFnQzYDavtLFY3K5ona41jgN/WdRZtG7utuVSVTL4HbZHGkw==} + /cli-truncate@4.0.0: + resolution: {integrity: sha512-nPdaFdQ0h/GEigbPClz11D0v/ZJEwxmeVZGeMo3Z5StPtUTkA9o1lD6QwoirYiSDzbcwn2XcjwmCp68W1IS4TA==} + engines: {node: '>=18'} + dependencies: + slice-ansi: 5.0.0 + string-width: 7.1.0 dev: true /cli-width@3.0.0: @@ -5048,13 +5052,8 @@ packages: resolution: {integrity: sha512-QVb0dM5HvG+uaxitm8wONl7jltx8dqhfU33DcqtOZcLSVIKSDDLDi7+0LbAKiyI8hD9u42m2YxXSkMGWThaecQ==} engines: {iojs: '>= 1.0.0', node: '>= 0.12.0'} - /code-point-at@1.1.0: - resolution: {integrity: sha512-RpAVKQA5T63xEj6/giIbUEtZwJ4UFIc3ZtvEkiaUERylqe8xb5IvqcgOurZLahv93CLKfxcw5YI+DZcUBRyLXA==} - engines: {node: '>=0.10.0'} - dev: true - - /collect-v8-coverage@1.0.1: - resolution: {integrity: sha512-iBPtljfCNcTKNAto0KEtDfZ3qzjJvqE3aTGZsbhjSBlorqpXJlaWWtPO35D+ZImoC3KWejX64o+yPGxhWSTzfg==} + /collect-v8-coverage@1.0.2: + resolution: {integrity: sha512-lHl4d5/ONEbLlJvaJNtsF/Lz+WvB07u2ycqTYbdrq7UypDXailES4valYb2eWiJFxZlVmpGekfqoxQhzyFdT4Q==} dev: true /color-convert@1.9.3: @@ -5074,10 +5073,9 @@ packages: /color-name@1.1.4: resolution: {integrity: sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==} - /color-support@1.1.3: - resolution: {integrity: sha512-qiBjkpbMLO/HL68y+lh4q0/O1MZFj2RX6X/KmMa3+gJD3z+WwI1ZzDHysvqHGS3mP6mznPckpXmw1nI9cJjyRg==} - hasBin: true - dev: false + /colorette@2.0.20: + resolution: {integrity: sha512-IfEDxwoWIjkeXL1eXcDiow4UbKjhLdq6/EuSVR9GMN7KVH3r9gQ83e73hsz1Nd1T3ijd5xv1wcWRYO+D6kCI2w==} + dev: true /combined-stream@1.0.8: resolution: {integrity: sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==} @@ -5090,8 +5088,14 @@ packages: resolution: {integrity: sha512-LTQ/SGc+s0Xc0Fu5WaKnR0YiygZkm9eKFvyS+fRsU7/ZWFF8ykFM6Pc9aCVf1+xasOOZpO3BAVgVrKvsqKHV7w==} dev: true - /commander@2.18.0: - resolution: {integrity: sha512-6CYPa+JP2ftfRU2qkDK+UTVeQYosOg/2GbcjIcKPHfinyOLPVGXu/ovN86RP49Re5ndJK1N0kuiidFFuepc4ZQ==} + /commander@10.0.1: + resolution: {integrity: sha512-y4Mg2tXshplEbSGzx7amzPwKKOCGuoSRP/CjEdwwk0FOGlUbq6lKuoyDZTNZkmxHdJtp54hdfY/JUrdL7Xfdug==} + engines: {node: '>=14'} + dev: true + + /commander@11.1.0: + resolution: {integrity: sha512-yPVavfyCcRhmorC7rWlkHn15b4wDVgVmBA7kV4QVBsF7kv/9TKJAbAXVTxvTnwP8HHKjRCJDClKbciiYS7p0DQ==} + engines: {node: '>=16'} dev: true /commander@3.0.2: @@ -5122,10 +5126,6 @@ packages: yargs: 17.7.2 dev: true - /console-control-strings@1.1.0: - resolution: {integrity: sha512-ty/fTekppD2fIwRvnZAVdeOiGd1c7YXEixbgJTNzqcxJWKQnjJ/V1bNEEE6hygpM3WjwHFUVK6HTjWSzV4a8sQ==} - dev: false - /content-disposition@0.5.4: resolution: {integrity: sha512-FveZTNuGw04cxlAiWbzi6zTAL/lhehaWbTtgluJh4/E95DqMwTmha3KZN1aAWA8cFIhHzMZUvLevkw5Rqk+tSQ==} engines: {node: '>= 0.6'} @@ -5138,10 +5138,6 @@ packages: engines: {node: '>= 0.6'} dev: false - /convert-source-map@1.9.0: - resolution: {integrity: sha512-ASFBup0Mz1uyiIjANan1jzLQami9z1PoYSZCiiYW2FczPbenXc45FZdBZLzOT+r6+iciuEModtmCti+hjaAk0A==} - dev: true - /convert-source-map@2.0.0: resolution: {integrity: sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg==} dev: true @@ -5151,13 +5147,13 @@ packages: engines: {node: '>= 0.6'} dev: true - /cookie@0.5.0: - resolution: {integrity: sha512-YZ3GUyn/o8gfKJlnlX7g7xq4gyO6OSuhGPKaaGssGB2qgDUS0gPgtTvoyZLTt9Ab6dC4hfc9dV5arkvc/OCmrw==} + /cookie@0.6.0: + resolution: {integrity: sha512-U71cyTamuh1CRNCfpGY6to28lxvNwPG4Guz/EVjgf3Jmzv0vlDp1atT9eS5dDjMYHucpHbWns6Lwf3BKz6svdw==} engines: {node: '>= 0.6'} dev: false - /cookies@0.8.0: - resolution: {integrity: sha512-8aPsApQfebXnuI+537McwYsDtjVxGm8gTIzQI3FDW6t5t/DAhERxtnbEPN/8RX+uZthoz4eCOgloXaE5cYyNow==} + /cookies@0.9.1: + resolution: {integrity: sha512-TG2hpqe4ELx54QER/S3HQ9SRVnQnGBtKUz5bLQWtYAQ+o6GpgMs6sYUvaiJjVxb+UXwhRhAEP3m7LbsIZ77Hmw==} engines: {node: '>= 0.8'} dependencies: depd: 2.0.0 @@ -5168,14 +5164,9 @@ packages: resolution: {integrity: sha512-yCEafptTtb4bk7GLEQoM8KVJpxAfdBJYaXyzQEgQQQgYrZiDp8SJmGKlYza6CYjEDNstAdNdKA3UuoULlEbS6w==} engines: {node: '>=12.13'} dependencies: - is-what: 4.1.15 + is-what: 4.1.16 dev: false - /core-js-pure@3.30.0: - resolution: {integrity: sha512-+2KbMFGeBU0ln/csoPqTe0i/yfHbrd2EUhNMObsGtXMKS/RTtlkYyi+/3twLcevbgNR0yM/r0Psa3TEoQRpFMQ==} - requiresBuild: true - dev: true - /core-js@2.6.12: resolution: {integrity: sha512-Kb2wC0fvsWfQrgk8HU5lW6U/Lcs8+9aaYcy4ZFc6DDlo4nZ7n70dEgE5rtR0oG6ufKDUnrwfWL1mXR5ljDatrQ==} deprecated: core-js@<3.23.3 is no longer maintained and not recommended for usage due to the number of issues. Because of the V8 engine whims, feature detection in old core-js versions could cause a slowdown up to 100x even if nothing is polyfilled. Some versions have web compatibility issues. Please, upgrade your dependencies to the actual version of core-js. @@ -5186,31 +5177,20 @@ packages: resolution: {integrity: sha512-ZQBvi1DcpJ4GDqanjucZ2Hj3wEO5pZDS89BWbkcrvdxksJorwUDDZamX9ldFkp9aw2lmBDLgkObEA4DWNJ9FYQ==} dev: false - /cosmiconfig@5.2.1: - resolution: {integrity: sha512-H65gsXo1SKjf8zmrJ67eJk8aIRKV5ff2D4uKZIBZShbhGSpEmsQOPW/SKMKYhSTrqR7ufy6RP69rPogdaPh/kA==} - engines: {node: '>=4'} - dependencies: - import-fresh: 2.0.0 - is-directory: 0.3.1 - js-yaml: 3.14.1 - parse-json: 4.0.0 - dev: true - - /cosmiconfig@6.0.0: - resolution: {integrity: sha512-xb3ZL6+L8b9JLLCx3ZdoZy4+2ECphCMo2PwqgP1tlfVq6M6YReyzBJtvWWtbDSpNr9hn96pkCiZqUcFEc+54Qg==} - engines: {node: '>=8'} + /cosmiconfig@8.3.6(typescript@5.1.6): + resolution: {integrity: sha512-kcZ6+W5QzcJ3P1Mt+83OUv/oHFqZHIx8DuxG6eZ5RGMERoLqp4BuGjhHLYGK+Kf5XVkQvqBSmAy/nGWN3qDgEA==} + engines: {node: '>=14'} + peerDependencies: + typescript: '>=4.9.5' + peerDependenciesMeta: + typescript: + optional: true dependencies: - '@types/parse-json': 4.0.0 import-fresh: 3.3.0 + js-yaml: 4.1.0 parse-json: 5.2.0 path-type: 4.0.0 - yaml: 1.10.2 - dev: true - - /crc-32@1.2.2: - resolution: {integrity: sha512-ROmzCKrTnOwybPcJApAA6WBWij23HVfGVNKqqrZpuyZOHqK2CwHSvpGuyt/UNNvaIjEd8X5IFGp4Mh+Ie1IHJQ==} - engines: {node: '>=0.8'} - hasBin: true + typescript: 5.1.6 dev: true /create-hash@1.2.0: @@ -5234,21 +5214,29 @@ packages: sha.js: 2.4.11 dev: true - /cross-spawn@5.1.0: - resolution: {integrity: sha512-pTgQJ5KC0d2hcY8eyL1IzlBPYjTkyH72XRZPnLyKus2mBfNjQs3klqbJU2VILqZryAZUt9JOb3h/mWMy23/f5A==} + /create-jest@29.7.0(@types/node@18.19.21): + resolution: {integrity: sha512-Adz2bdH0Vq3F53KEMJOoftQFutWCukm6J24wbPWRO4k1kMY7gS7ds/uoJkNuV8wDCtWWnuwGcJwpWcih+zEW1Q==} + engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} + hasBin: true dependencies: - lru-cache: 4.1.5 - shebang-command: 1.2.0 - which: 1.3.1 + '@jest/types': 29.6.3 + chalk: 4.1.2 + exit: 0.1.2 + graceful-fs: 4.2.11 + jest-config: 29.7.0(@types/node@18.19.21) + jest-util: 29.7.0 + prompts: 2.4.2 + transitivePeerDependencies: + - '@types/node' + - babel-plugin-macros + - supports-color + - ts-node dev: true - /cross-spawn@6.0.5: - resolution: {integrity: sha512-eTVLrBSt7fjbDygz805pMnstIs2VTBNkRm0qxZd+M7A5XDdxVRWO5MxGBXZhjY4cqLYLdtrGqRf8mBPmzwSpWQ==} - engines: {node: '>=4.8'} + /cross-spawn@5.1.0: + resolution: {integrity: sha512-pTgQJ5KC0d2hcY8eyL1IzlBPYjTkyH72XRZPnLyKus2mBfNjQs3klqbJU2VILqZryAZUt9JOb3h/mWMy23/f5A==} dependencies: - nice-try: 1.0.5 - path-key: 2.0.1 - semver: 5.7.1 + lru-cache: 4.1.5 shebang-command: 1.2.0 which: 1.3.1 dev: true @@ -5274,9 +5262,8 @@ packages: rrweb-cssom: 0.6.0 dev: true - /csstype@3.1.2: - resolution: {integrity: sha512-I7K1Uu0MBPzaFKg4nI5Q7Vs2t+3gWWW648spaF+Rg7pI9ds18Ugn+lvg4SHczUdKlHI5LWBXyqfS8+DufyBsgQ==} - dev: true + /csstype@3.1.3: + resolution: {integrity: sha512-M1uQkMl8rQK/szD0LNhtqxIPLpimGm8sOBwU7lLnCpSbTyY3yeU1Vc7l4KT5zT4s/yOxHH5O7tIuuLOCnLADRw==} /csv-generate@3.4.3: resolution: {integrity: sha512-w/T+rqR0vwvHqWs/1ZyMDWtHHSJaN06klRqJXBEpDJaM/+dZkso0OKh1VcuuYvK3XM53KysVNq8Ko/epCK8wOw==} @@ -5303,7 +5290,7 @@ packages: /d@1.0.1: resolution: {integrity: sha512-m62ShEObQ39CfralilEQRjH6oAMtNCV1xJyEx5LpRYUVN+EviphDgUc/F3hnYbADmkiNs67Y+3ylmlG7Lnu+FA==} dependencies: - es5-ext: 0.10.62 + es5-ext: 0.10.64 type: 1.2.0 dev: false @@ -5316,19 +5303,11 @@ packages: whatwg-url: 12.0.1 dev: true - /dataloader@1.4.0: - resolution: {integrity: sha512-68s5jYdlvasItOJnCuI2Q9s4q98g0pCyL3HrcKJu8KNugUl8ahgmZYg38ysLTgQjjXX3H8CJLkAvWrclWfcalw==} - dev: true - - /date-fns@1.30.1: - resolution: {integrity: sha512-hBSVCvSmWC+QypYObzwGOd9wqdDpOt+0wl0KbU+R+uuZBS1jN8VsD1ss3irQDknRj5NvxiTF6oj/nDRnN/UQNw==} - dev: true - /date-fns@2.30.0: resolution: {integrity: sha512-fnULvOpxnC5/Vg3NCiWelDsLiUc9bRwAPs/+LfTLNvetFCtCTN+yQz15C/fs4AwX1R9K5GLtLfn8QW+dWisaAw==} engines: {node: '>=0.11'} dependencies: - '@babel/runtime': 7.21.0 + '@babel/runtime': 7.24.0 dev: true /debug@4.3.4(supports-color@8.1.1): @@ -5371,8 +5350,13 @@ packages: mimic-response: 3.1.0 dev: false - /dedent@0.7.0: - resolution: {integrity: sha512-Q6fKUPqnAHAyhiUgFU7BUzLiv0kd8saH9al7tnu5Q/okj6dnupxyTgFIBjVzJATdfIAm9NAsvXNzjaKa+bxVyA==} + /dedent@1.5.1: + resolution: {integrity: sha512-+LxW+KLWxu3HW3M2w2ympwtqPrqYRzU8fqi6Fhd18fBALe15blJPI/I4+UHveMVG6lJqB4JNd4UG0S5cnVHwIg==} + peerDependencies: + babel-plugin-macros: ^3.1.0 + peerDependenciesMeta: + babel-plugin-macros: + optional: true dev: true /deep-eql@4.1.3: @@ -5406,19 +5390,21 @@ packages: clone: 1.0.4 dev: true - /deferred-leveldown@5.3.0: - resolution: {integrity: sha512-a59VOT+oDy7vtAbLRCZwWgxu2BaCfd5Hk7wxJd48ei7I+nsg8Orlb9CLG0PMZienk9BSUKgeAqkO2+Lw+1+Ukw==} - engines: {node: '>=6'} + /define-data-property@1.1.4: + resolution: {integrity: sha512-rBMvIzlpA8v6E+SJZoo++HAYqsLrkg7MSfIinMPFhmkorw7X+dOXVJQs+QT69zGkzMyfDnIMN2Wid1+NbL3T+A==} + engines: {node: '>= 0.4'} dependencies: - abstract-leveldown: 6.2.3 - inherits: 2.0.4 + es-define-property: 1.0.0 + es-errors: 1.3.0 + gopd: 1.0.1 dev: true - /define-properties@1.1.4: - resolution: {integrity: sha512-uckOqKcfaVvtBdsVkdPv3XjveQJsNQqmhXgRi8uhvWWuPYZCNlzT8qAyblUgNoXdHdjMTzAqeGjAoli8f+bzPA==} + /define-properties@1.2.1: + resolution: {integrity: sha512-8QmQKqEASLd5nx0U1B1okLElbUuuttJ/AnYmRXbbbGDWh6uS208EjD4Xqq/I9wK7u0v6O08XhTWnt5XtEbR6Dg==} engines: {node: '>= 0.4'} dependencies: - has-property-descriptors: 1.0.0 + define-data-property: 1.1.4 + has-property-descriptors: 1.0.2 object-keys: 1.1.1 dev: true @@ -5512,23 +5498,24 @@ packages: /domexception@4.0.0: resolution: {integrity: sha512-A2is4PLG+eeSfoTMA95/s4pvAoSo2mKtiM5jlHkAVewmiO8ISFTFKZjH7UAM1Atli/OT/7JHOrJRJiMKUZKYBw==} engines: {node: '>=12'} + deprecated: Use your platform's native DOMException instead dependencies: webidl-conversions: 7.0.0 dev: true - /dotenv@16.0.3: - resolution: {integrity: sha512-7GO6HghkA5fYG9TYnNxi14/7K9f5occMlp3zXAuSxn7CKCxt9xbNWG7yF8hTCSUchlfWSe3uLmlPfigevRItzQ==} + /dotenv@16.4.5: + resolution: {integrity: sha512-ZmdL2rui+eB2YwhsWzjInR8LldtZHGDoQ1ugH85ppHKwpUHL7j7rN0Ti9NCnGiQbhaZ11FpR+7ao1dNsmduNUg==} engines: {node: '>=12'} dev: false - /dprint-node@1.0.7: - resolution: {integrity: sha512-NTZOW9A7ipb0n7z7nC3wftvsbceircwVHSgzobJsEQa+7RnOMbhrfX5IflA6CtC4GA63DSAiHYXa4JKEy9F7cA==} + /dprint-node@1.0.8: + resolution: {integrity: sha512-iVKnUtYfGrYcW1ZAlfR/F59cUVL8QIhWoBJoSjkkdua/dkWIgjZfiLMeTjiB06X0ZLkQ0M2C1VbUj/CxkIf1zg==} dependencies: detect-libc: 1.0.3 dev: true - /drizzle-orm@0.28.5(@types/better-sqlite3@7.6.4)(better-sqlite3@8.6.0)(postgres@3.3.5): - resolution: {integrity: sha512-6r6Iw4c38NAmW6TiKH3TUpGUQ1YdlEoLJOQptn8XPx3Z63+vFNKfAiANqrIiYZiMjKR9+NYAL219nFrmo1duXA==} + /drizzle-orm@0.28.6(@types/better-sqlite3@7.6.9)(better-sqlite3@8.7.0)(postgres@3.3.5): + resolution: {integrity: sha512-yBe+F9htrlYER7uXgDJUQsTHFoIrI5yMm5A0bg0GiZ/kY5jNXTWoEy4KQtg35cE27sw1VbgzoMWHAgCckUUUww==} peerDependencies: '@aws-sdk/client-rds-data': '>=3' '@cloudflare/workers-types': '>=3' @@ -5589,13 +5576,13 @@ packages: sqlite3: optional: true dependencies: - '@types/better-sqlite3': 7.6.4 - better-sqlite3: 8.6.0 + '@types/better-sqlite3': 7.6.9 + better-sqlite3: 8.7.0 postgres: 3.3.5 dev: false - /drizzle-orm@0.28.5(@types/sql.js@1.4.4)(kysely@0.26.3)(postgres@3.3.5)(sql.js@1.8.0): - resolution: {integrity: sha512-6r6Iw4c38NAmW6TiKH3TUpGUQ1YdlEoLJOQptn8XPx3Z63+vFNKfAiANqrIiYZiMjKR9+NYAL219nFrmo1duXA==} + /drizzle-orm@0.28.6(@types/sql.js@1.4.9)(kysely@0.26.3)(postgres@3.3.5)(sql.js@1.10.2): + resolution: {integrity: sha512-yBe+F9htrlYER7uXgDJUQsTHFoIrI5yMm5A0bg0GiZ/kY5jNXTWoEy4KQtg35cE27sw1VbgzoMWHAgCckUUUww==} peerDependencies: '@aws-sdk/client-rds-data': '>=3' '@cloudflare/workers-types': '>=3' @@ -5656,10 +5643,10 @@ packages: sqlite3: optional: true dependencies: - '@types/sql.js': 1.4.4 + '@types/sql.js': 1.4.9 kysely: 0.26.3 postgres: 3.3.5 - sql.js: 1.8.0 + sql.js: 1.10.2 dev: false /duplexify@3.7.1: @@ -5668,7 +5655,7 @@ packages: end-of-stream: 1.4.4 inherits: 2.0.4 readable-stream: 2.3.8 - stream-shift: 1.0.1 + stream-shift: 1.0.3 dev: false /duplexify@4.1.2: @@ -5676,28 +5663,27 @@ packages: dependencies: end-of-stream: 1.4.4 inherits: 2.0.4 - readable-stream: 3.6.0 - stream-shift: 1.0.1 + readable-stream: 3.6.2 + stream-shift: 1.0.3 dev: false + /eastasianwidth@0.2.0: + resolution: {integrity: sha512-I88TYZWc9XiYHRQ4/3c5rjjfgkjhLyW2luGIheGERbNQ6OY7yTybanSpDXZa8y7VUP9YmDcYa+eyq4ca7iLqWA==} + dev: true + /ee-first@1.1.1: resolution: {integrity: sha512-WMwm9LhRUo+WUaRN+vRuETqG89IgZphVSNkdFgeb6sS/E4OrDIN7t48CAewSHXc6C8lefD8KKfr5vY61brQlow==} dev: false - /ejs@3.1.8: - resolution: {integrity: sha512-/sXZeMlhS0ArkfX2Aw780gJzXSMPnKjtspYZv+f3NiKLlubezAHDU5+9xz6gd3/NhG3txQCo6xlglmTS+oTGEQ==} + /ejs@3.1.9: + resolution: {integrity: sha512-rC+QVNMJWv+MtPgkt0y+0rVEIdbtxVADApW9JXrUVlzHetgcyczP/E7DJmWJ4fJCZF2cPcBk0laWO9ZHMG3DmQ==} engines: {node: '>=0.10.0'} hasBin: true dependencies: - jake: 10.8.5 + jake: 10.8.7 - /electron-to-chromium@1.4.340: - resolution: {integrity: sha512-zx8hqumOqltKsv/MF50yvdAlPF9S/4PXbyfzJS6ZGhbddGkRegdwImmfSVqCkEziYzrIGZ/TlrzBND4FysfkDg==} - dev: true - - /elegant-spinner@1.0.1: - resolution: {integrity: sha512-B+ZM+RXvRqQaAmkMlO/oSe5nMUOaUnyfGYCEHoR8wrXsZR2mA0XVibsxV1bvTwxdRWah1PkQqso2EzhILGHtEQ==} - engines: {node: '>=0.10.0'} + /electron-to-chromium@1.4.688: + resolution: {integrity: sha512-3/tHg2ChPF00eukURIB8cSVt3/9oeS1oTUIEt3ivngBInUaEcBhG2VdyEDejhwQdR6SLqaiEAEc0dHS0V52pOw==} dev: true /elliptic@6.5.4: @@ -5716,45 +5702,38 @@ packages: engines: {node: '>=12'} dev: true + /emoji-regex@10.3.0: + resolution: {integrity: sha512-QpLs9D9v9kArv4lfDEgg1X/gN5XLnf/A6l9cs8SPZLRZR3ZkY9+kwIQTxm+fsSej5UMYGE8fdoaZVIBlqG0XTw==} + dev: true + /emoji-regex@7.0.3: resolution: {integrity: sha512-CwBLREIQ7LvYFB0WyRvwhq5N5qPhc6PMjD6bYggFlI5YyDgl+0vxq5VHbMOFqLg7hfWzmu8T5Z1QofhmTIhItA==} + dev: false /emoji-regex@8.0.0: resolution: {integrity: sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==} + /emoji-regex@9.2.2: + resolution: {integrity: sha512-L18DaJsXSUk2+42pv8mLs5jJT2hqFkFE4j21wOmgbUqsZ2hL72NsUU785g9RXgo3s0ZNgVl42TiHp3ZtOv/Vyg==} + dev: true + /encodeurl@1.0.2: resolution: {integrity: sha512-TPJXq8JqFaVYm2CWmPvnP2Iyo4ZSM7/QKcSmuMLDObfpH5fi7RUGmd/rTDf+rut/saiDiQEeVTNgAmJEdAOx0w==} engines: {node: '>= 0.8'} dev: false - /encoding-down@6.3.0: - resolution: {integrity: sha512-QKrV0iKR6MZVJV08QY0wp1e7vF6QbhnbQhb07bwpEyuz4uZiZgPlEGdkCROuFkUwdxlFaiPIhjyarH1ee/3vhw==} - engines: {node: '>=6'} - dependencies: - abstract-leveldown: 6.3.0 - inherits: 2.0.4 - level-codec: 9.0.2 - level-errors: 2.0.1 - dev: true - - /encoding@0.1.13: - resolution: {integrity: sha512-ETBauow1T35Y/WZMkio9jiM0Z5xjHHmJ4XmjZOq1l/dXz3lr2sRn87nJy20RupqSh1F2m3HHPSp8ShIPQJrJ3A==} - requiresBuild: true - dependencies: - iconv-lite: 0.6.3 - dev: false - optional: true - /end-of-stream@1.4.4: resolution: {integrity: sha512-+uw1inIHVPQoaVuHzRyXd21icM+cnt4CzD5rW+NC1wjOUSTOs+Te7FOv7AhN7vS9x/oIyhLP5PR1H+phQAHu5Q==} dependencies: once: 1.4.0 + dev: false - /enquirer@2.3.6: - resolution: {integrity: sha512-yjNnPr315/FjS4zIsUxYguYUPP2e1NK4d7E7ZOLiyYCcbFBiTMyID+2wvm2w6+pZ/odMA7cRkjhsPbltwBOrLg==} + /enquirer@2.4.1: + resolution: {integrity: sha512-rRqJg/6gd538VHvR3PSrdRBb/1Vy2YfzHqzvbhGIQpDRKIa4FgV/54b5Q1xYSxOOwKvjXweS26E0Q+nAMwp2pQ==} engines: {node: '>=8.6'} dependencies: ansi-colors: 4.1.3 + strip-ansi: 6.0.1 dev: true /entities@4.5.0: @@ -5765,9 +5744,10 @@ packages: /env-paths@2.2.1: resolution: {integrity: sha512-+h1lkLKhZMTYjog1VEpJNG7NZJWcuc2DDk/qsqSTRRCOXiLjeQ1d1/udrUGhqMxUgAlwKNZ0cf2uqan5GLuS2A==} engines: {node: '>=6'} + dev: true - /envinfo@7.8.1: - resolution: {integrity: sha512-/o+BXHmB7ocbHEAs6F2EnG0ogybVVUdkRunTT2glZU9XAaGmhqskrvKwqXuDfNjEO0LZKWdejEEpnq8aM0tOaw==} + /envinfo@7.11.1: + resolution: {integrity: sha512-8PiZgZNIB4q/Lw4AhOvAfB/ityHAd2bli3lESSWmWSzSsl5dKpy5N1d1Rfkd2teq/g9xN90lc6o98DOjMeYHpg==} engines: {node: '>=4'} hasBin: true dev: false @@ -5776,65 +5756,91 @@ packages: resolution: {integrity: sha512-zf7vvWZ2tI2+P1674dmcyPWopD/0FC2BrAi0DvDY0uKGmrB66rwpRVlOYKFlGwRO4Q6bpkoCTPhjqvi5hMOavQ==} dependencies: chalk: 4.1.2 - envinfo: 7.8.1 - node-fetch: 2.6.9 + envinfo: 7.11.1 + node-fetch: 2.7.0 pkg-up: 3.1.0 transitivePeerDependencies: - encoding dev: false - /err-code@2.0.3: - resolution: {integrity: sha512-2bmlRpNKBxT/CRmPOlyISQpNj+qSeYvcym/uT0Jx2bMOlKLtSy1ZmLuVxSEKKyor/N5yhvp/ZiG1oE3DEYMSFA==} - dev: false - - /errno@0.1.8: - resolution: {integrity: sha512-dJ6oBr5SQ1VSd9qkk7ByRgb/1SH4JZjCHSW/mr63/QcXO9zLVxvJ6Oy13nio03rxpSnVDDjFor75SjVeZWPW/A==} - hasBin: true - dependencies: - prr: 1.0.1 - dev: true - /error-ex@1.3.2: resolution: {integrity: sha512-7dFHNmqeFSEt2ZBsCriorKnn3Z2pj+fd9kmI6QoWw4//DL+icEBfc0U7qJCisqrTsKTjw4fNFy2pW9OqStD84g==} dependencies: is-arrayish: 0.2.1 dev: true - /es-abstract@1.20.5: - resolution: {integrity: sha512-7h8MM2EQhsCA7pU/Nv78qOXFpD8Rhqd12gYiSJVkrH9+e8VuA8JlPJK/hQjjlLv6pJvx/z1iRFKzYb0XT/RuAQ==} + /es-abstract@1.22.5: + resolution: {integrity: sha512-oW69R+4q2wG+Hc3KZePPZxOiisRIqfKBVo/HLx94QcJeWGU/8sZhCvc829rd1kS366vlJbzBfXf9yWwf0+Ko7w==} engines: {node: '>= 0.4'} dependencies: - call-bind: 1.0.2 + array-buffer-byte-length: 1.0.1 + arraybuffer.prototype.slice: 1.0.3 + available-typed-arrays: 1.0.7 + call-bind: 1.0.7 + es-define-property: 1.0.0 + es-errors: 1.3.0 + es-set-tostringtag: 2.0.3 es-to-primitive: 1.2.1 - function-bind: 1.1.1 - function.prototype.name: 1.1.5 - get-intrinsic: 1.1.3 - get-symbol-description: 1.0.0 + function.prototype.name: 1.1.6 + get-intrinsic: 1.2.4 + get-symbol-description: 1.0.2 + globalthis: 1.0.3 gopd: 1.0.1 - has: 1.0.3 - has-property-descriptors: 1.0.0 + has-property-descriptors: 1.0.2 + has-proto: 1.0.3 has-symbols: 1.0.3 - internal-slot: 1.0.3 + hasown: 2.0.1 + internal-slot: 1.0.7 + is-array-buffer: 3.0.4 is-callable: 1.2.7 - is-negative-zero: 2.0.2 + is-negative-zero: 2.0.3 is-regex: 1.1.4 - is-shared-array-buffer: 1.0.2 + is-shared-array-buffer: 1.0.3 is-string: 1.0.7 + is-typed-array: 1.1.13 is-weakref: 1.0.2 - object-inspect: 1.12.2 + object-inspect: 1.13.1 object-keys: 1.1.1 - object.assign: 4.1.4 - regexp.prototype.flags: 1.4.3 - safe-regex-test: 1.0.0 - string.prototype.trimend: 1.0.6 - string.prototype.trimstart: 1.0.6 + object.assign: 4.1.5 + regexp.prototype.flags: 1.5.2 + safe-array-concat: 1.1.0 + safe-regex-test: 1.0.3 + string.prototype.trim: 1.2.8 + string.prototype.trimend: 1.0.7 + string.prototype.trimstart: 1.0.7 + typed-array-buffer: 1.0.2 + typed-array-byte-length: 1.0.1 + typed-array-byte-offset: 1.0.2 + typed-array-length: 1.0.5 unbox-primitive: 1.0.2 + which-typed-array: 1.1.14 dev: true - /es-shim-unscopables@1.0.0: - resolution: {integrity: sha512-Jm6GPcCdC30eMLbZ2x8z2WuRwAws3zTBBKuusffYVUrNj/GVSUAZ+xKMaUpfNDR5IbyNA5LJbaecoUVbmUcB1w==} + /es-define-property@1.0.0: + resolution: {integrity: sha512-jxayLKShrEqqzJ0eumQbVhTYQM27CfT1T35+gCgDFoL82JLsXqTJ76zv6A0YLOgEnLUMvLzsDsGIrl8NFpT2gQ==} + engines: {node: '>= 0.4'} + dependencies: + get-intrinsic: 1.2.4 + dev: true + + /es-errors@1.3.0: + resolution: {integrity: sha512-Zf5H2Kxt2xjTvbJvP2ZWLEICxA6j+hAmMzIlypy4xcBg1vKVnx89Wy0GbS+kf5cwCVFFzdCFh2XSCFNULS6csw==} + engines: {node: '>= 0.4'} + dev: true + + /es-set-tostringtag@2.0.3: + resolution: {integrity: sha512-3T8uNMC3OQTHkFUsFq8r/BwAXLHvU/9O9mE0fBc/MY5iq/8H7ncvO947LmYA6ldWw9Uh8Yhf25zu6n7nML5QWQ==} + engines: {node: '>= 0.4'} dependencies: - has: 1.0.3 + get-intrinsic: 1.2.4 + has-tostringtag: 1.0.2 + hasown: 2.0.1 + dev: true + + /es-shim-unscopables@1.0.2: + resolution: {integrity: sha512-J3yBRXCzDu4ULnQwxyToo/OjdMx6akgVC7K6few0a7F/0wLtmKKN7I73AH5T2836UuXRqN7Qg+IIUw/+YJksRw==} + dependencies: + hasown: 2.0.1 dev: true /es-to-primitive@1.2.1: @@ -5846,13 +5852,14 @@ packages: is-symbol: 1.0.4 dev: true - /es5-ext@0.10.62: - resolution: {integrity: sha512-BHLqn0klhEpnOKSrzn/Xsz2UIW8j+cGmo9JLzr8BiUapV8hPL9+FliFqjwr9ngW7jWdnxv6eO+/LqyhJVqgrjA==} + /es5-ext@0.10.64: + resolution: {integrity: sha512-p2snDhiLaXe6dahss1LddxqEm+SkuDvV8dnIQG0MWjyHpcMNfXKPE+/Cc0y+PhxJX3A4xGNeFCj5oc0BUh6deg==} engines: {node: '>=0.10'} requiresBuild: true dependencies: es6-iterator: 2.0.3 es6-symbol: 3.1.3 + esniff: 2.0.1 next-tick: 1.1.0 dev: false @@ -5860,7 +5867,7 @@ packages: resolution: {integrity: sha512-zw4SRzoUkd+cl+ZoE15A9o1oQd920Bb0iOJMQkQhl3jNc03YqVjAhG7scf9C5KWRU/R13Orf588uCC6525o02g==} dependencies: d: 1.0.1 - es5-ext: 0.10.62 + es5-ext: 0.10.64 es6-symbol: 3.1.3 dev: false @@ -5875,73 +5882,72 @@ packages: resolution: {integrity: sha512-p5um32HOTO1kP+w7PRnB+5lQ43Z6muuMuIMffvDN8ZB4GcnjLBV6zGStpbASIMk4DCAvEaamhe2zhyCb/QXXsA==} dependencies: d: 1.0.1 - es5-ext: 0.10.62 + es5-ext: 0.10.64 es6-iterator: 2.0.3 es6-symbol: 3.1.3 dev: false - /esbuild@0.17.15: - resolution: {integrity: sha512-LBUV2VsUIc/iD9ME75qhT4aJj0r75abCVS0jakhFzOtR7TQsqQA5w0tZ+KTKnwl3kXE0MhskNdHDh/I5aCR1Zw==} + /esbuild@0.17.19: + resolution: {integrity: sha512-XQ0jAPFkK/u3LcVRcvVHQcTIqD6E2H1fvZMA5dQPSOWb3suUbWbfbRf94pjc0bNzRYLfIrDRQXr7X+LHIm5oHw==} engines: {node: '>=12'} hasBin: true requiresBuild: true optionalDependencies: - '@esbuild/android-arm': 0.17.15 - '@esbuild/android-arm64': 0.17.15 - '@esbuild/android-x64': 0.17.15 - '@esbuild/darwin-arm64': 0.17.15 - '@esbuild/darwin-x64': 0.17.15 - '@esbuild/freebsd-arm64': 0.17.15 - '@esbuild/freebsd-x64': 0.17.15 - '@esbuild/linux-arm': 0.17.15 - '@esbuild/linux-arm64': 0.17.15 - '@esbuild/linux-ia32': 0.17.15 - '@esbuild/linux-loong64': 0.17.15 - '@esbuild/linux-mips64el': 0.17.15 - '@esbuild/linux-ppc64': 0.17.15 - '@esbuild/linux-riscv64': 0.17.15 - '@esbuild/linux-s390x': 0.17.15 - '@esbuild/linux-x64': 0.17.15 - '@esbuild/netbsd-x64': 0.17.15 - '@esbuild/openbsd-x64': 0.17.15 - '@esbuild/sunos-x64': 0.17.15 - '@esbuild/win32-arm64': 0.17.15 - '@esbuild/win32-ia32': 0.17.15 - '@esbuild/win32-x64': 0.17.15 - dev: false - - /esbuild@0.17.17: - resolution: {integrity: sha512-/jUywtAymR8jR4qsa2RujlAF7Krpt5VWi72Q2yuLD4e/hvtNcFQ0I1j8m/bxq238pf3/0KO5yuXNpuLx8BE1KA==} + '@esbuild/android-arm': 0.17.19 + '@esbuild/android-arm64': 0.17.19 + '@esbuild/android-x64': 0.17.19 + '@esbuild/darwin-arm64': 0.17.19 + '@esbuild/darwin-x64': 0.17.19 + '@esbuild/freebsd-arm64': 0.17.19 + '@esbuild/freebsd-x64': 0.17.19 + '@esbuild/linux-arm': 0.17.19 + '@esbuild/linux-arm64': 0.17.19 + '@esbuild/linux-ia32': 0.17.19 + '@esbuild/linux-loong64': 0.17.19 + '@esbuild/linux-mips64el': 0.17.19 + '@esbuild/linux-ppc64': 0.17.19 + '@esbuild/linux-riscv64': 0.17.19 + '@esbuild/linux-s390x': 0.17.19 + '@esbuild/linux-x64': 0.17.19 + '@esbuild/netbsd-x64': 0.17.19 + '@esbuild/openbsd-x64': 0.17.19 + '@esbuild/sunos-x64': 0.17.19 + '@esbuild/win32-arm64': 0.17.19 + '@esbuild/win32-ia32': 0.17.19 + '@esbuild/win32-x64': 0.17.19 + + /esbuild@0.18.20: + resolution: {integrity: sha512-ceqxoedUrcayh7Y7ZX6NdbbDzGROiyVBgC4PriJThBKSVPWnnFHZAkfI1lJT8QFkOwH4qOS2SJkS4wvpGl8BpA==} engines: {node: '>=12'} hasBin: true requiresBuild: true optionalDependencies: - '@esbuild/android-arm': 0.17.17 - '@esbuild/android-arm64': 0.17.17 - '@esbuild/android-x64': 0.17.17 - '@esbuild/darwin-arm64': 0.17.17 - '@esbuild/darwin-x64': 0.17.17 - '@esbuild/freebsd-arm64': 0.17.17 - '@esbuild/freebsd-x64': 0.17.17 - '@esbuild/linux-arm': 0.17.17 - '@esbuild/linux-arm64': 0.17.17 - '@esbuild/linux-ia32': 0.17.17 - '@esbuild/linux-loong64': 0.17.17 - '@esbuild/linux-mips64el': 0.17.17 - '@esbuild/linux-ppc64': 0.17.17 - '@esbuild/linux-riscv64': 0.17.17 - '@esbuild/linux-s390x': 0.17.17 - '@esbuild/linux-x64': 0.17.17 - '@esbuild/netbsd-x64': 0.17.17 - '@esbuild/openbsd-x64': 0.17.17 - '@esbuild/sunos-x64': 0.17.17 - '@esbuild/win32-arm64': 0.17.17 - '@esbuild/win32-ia32': 0.17.17 - '@esbuild/win32-x64': 0.17.17 - dev: true - - /escalade@3.1.1: - resolution: {integrity: sha512-k0er2gUkLf8O0zKJiAhmkTnJlTvINGv7ygDNPbeIsX/TJjGJZHuh9B2UxbsaEkmlEo9MfhrSzmhIlhRlI2GXnw==} + '@esbuild/android-arm': 0.18.20 + '@esbuild/android-arm64': 0.18.20 + '@esbuild/android-x64': 0.18.20 + '@esbuild/darwin-arm64': 0.18.20 + '@esbuild/darwin-x64': 0.18.20 + '@esbuild/freebsd-arm64': 0.18.20 + '@esbuild/freebsd-x64': 0.18.20 + '@esbuild/linux-arm': 0.18.20 + '@esbuild/linux-arm64': 0.18.20 + '@esbuild/linux-ia32': 0.18.20 + '@esbuild/linux-loong64': 0.18.20 + '@esbuild/linux-mips64el': 0.18.20 + '@esbuild/linux-ppc64': 0.18.20 + '@esbuild/linux-riscv64': 0.18.20 + '@esbuild/linux-s390x': 0.18.20 + '@esbuild/linux-x64': 0.18.20 + '@esbuild/netbsd-x64': 0.18.20 + '@esbuild/openbsd-x64': 0.18.20 + '@esbuild/sunos-x64': 0.18.20 + '@esbuild/win32-arm64': 0.18.20 + '@esbuild/win32-ia32': 0.18.20 + '@esbuild/win32-x64': 0.18.20 + dev: true + + /escalade@3.1.2: + resolution: {integrity: sha512-ErCHMCae19vR8vQGe50xIsVomy19rg6gFu3+r3jkEO46suLMWBksvVyoGgQV+jOfl84ZSOSlmv6Gxa89PmTGmA==} engines: {node: '>=6'} /escape-html@1.0.3: @@ -5977,30 +5983,22 @@ packages: peerDependencies: eslint: ^3 || ^4 || ^5 || ^6 || ^7 || ^8 dependencies: - array-includes: 3.1.6 - array.prototype.flatmap: 1.3.1 - array.prototype.tosorted: 1.1.1 + array-includes: 3.1.7 + array.prototype.flatmap: 1.3.2 + array.prototype.tosorted: 1.1.3 doctrine: 2.1.0 eslint: 8.29.0 estraverse: 5.3.0 - jsx-ast-utils: 3.3.3 + jsx-ast-utils: 3.3.5 minimatch: 3.1.2 - object.entries: 1.1.6 - object.fromentries: 2.0.6 - object.hasown: 1.1.2 - object.values: 1.1.6 + object.entries: 1.1.7 + object.fromentries: 2.0.7 + object.hasown: 1.1.3 + object.values: 1.1.7 prop-types: 15.8.1 - resolve: 2.0.0-next.4 - semver: 6.3.0 - string.prototype.matchall: 4.0.8 - dev: true - - /eslint-scope@4.0.3: - resolution: {integrity: sha512-p7VutNr1O/QrxysMo3E45FjYDTeXBy0iTltPFNSqKAIfjDSXC+4dj+qfyuD8bfAXrW/y6lW3O76VaYNPKfpKrg==} - engines: {node: '>=4.0.0'} - dependencies: - esrecurse: 4.3.0 - estraverse: 4.3.0 + resolve: 2.0.0-next.5 + semver: 6.3.1 + string.prototype.matchall: 4.0.10 dev: true /eslint-scope@5.1.1: @@ -6011,21 +6009,14 @@ packages: estraverse: 4.3.0 dev: true - /eslint-scope@7.2.0: - resolution: {integrity: sha512-DYj5deGlHBfMt15J7rdtyKNq/Nqlv5KfU4iodrQ019XESsRnwXH9KAE0y3cwtUHDo2ob7CypAnCqefh6vioWRw==} + /eslint-scope@7.2.2: + resolution: {integrity: sha512-dOt21O7lTMhDM+X9mB4GX+DZrZtCUJPL/wlcTqxyrx5IvO0IYtILdtrQGQp+8n5S0gwSVmOf9NQrjMOgfQZlIg==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} dependencies: esrecurse: 4.3.0 estraverse: 5.3.0 dev: true - /eslint-utils@1.4.3: - resolution: {integrity: sha512-fbBN5W2xdY45KulGXmLHZ3c3FHfVYmKg0IrAKGOkT/464PQsx2UeIzfz1RmEci+KLm1bBaAzZAh8+/E+XAeZ8Q==} - engines: {node: '>=6'} - dependencies: - eslint-visitor-keys: 1.3.0 - dev: true - /eslint-utils@3.0.0(eslint@8.29.0): resolution: {integrity: sha512-uuQC43IGctw68pJA1RgbQS8/NP7rch6Cwd4j3ZBtgo4/8Flj4eGE7ZYSZRN3iq5pVUv6GPdW5Z1RFleo84uLDA==} engines: {node: ^10.0.0 || ^12.0.0 || >= 14.0.0} @@ -6036,73 +6027,23 @@ packages: eslint-visitor-keys: 2.1.0 dev: true - /eslint-visitor-keys@1.3.0: - resolution: {integrity: sha512-6J72N8UNa462wa/KFODt/PJ3IU60SDpC3QXC1Hjc1BXXpfL2C9R5+AU7jhe0F6GREqVMh4Juu+NY7xn+6dipUQ==} - engines: {node: '>=4'} - dev: true - /eslint-visitor-keys@2.1.0: resolution: {integrity: sha512-0rSmRBzXgDzIsD6mGdJgevzgezI534Cer5L/vyMX0kHzT/jiB43jRhd9YUlMGYLQy2zprNmoT8qasCGtY+QaKw==} engines: {node: '>=10'} dev: true - /eslint-visitor-keys@3.4.0: - resolution: {integrity: sha512-HPpKPUBQcAsZOsHAFwTtIKcYlCje62XB7SEAcxjtmW6TD1WVpkS6i6/hOVtTZIl4zGj/mBqpFVGvaDneik+VoQ==} + /eslint-visitor-keys@3.4.3: + resolution: {integrity: sha512-wpc+LXeiyiisxPlEkUzU6svyS1frIO3Mgxj1fdy7Pm8Ygzguax2N3Fa/D/ag1WqbOprdI+uY6wMUl8/a2G+iag==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} dev: true - /eslint@5.16.0: - resolution: {integrity: sha512-S3Rz11i7c8AA5JPv7xAH+dOyq/Cu/VXHiHXBPOU1k/JAM5dXqQPt3qcrhpHSorXmrpu2g0gkIBVXAqCpzfoZIg==} - engines: {node: ^6.14.0 || ^8.10.0 || >=9.10.0} - hasBin: true - dependencies: - '@babel/code-frame': 7.21.4 - ajv: 6.12.6 - chalk: 2.4.2 - cross-spawn: 6.0.5 - debug: 4.3.4(supports-color@8.1.1) - doctrine: 3.0.0 - eslint-scope: 4.0.3 - eslint-utils: 1.4.3 - eslint-visitor-keys: 1.3.0 - espree: 5.0.1 - esquery: 1.5.0 - esutils: 2.0.3 - file-entry-cache: 5.0.1 - functional-red-black-tree: 1.0.1 - glob: 7.2.3 - globals: 11.12.0 - ignore: 4.0.6 - import-fresh: 3.3.0 - imurmurhash: 0.1.4 - inquirer: 6.5.2 - js-yaml: 3.14.1 - json-stable-stringify-without-jsonify: 1.0.1 - levn: 0.3.0 - lodash: 4.17.21 - minimatch: 3.1.2 - mkdirp: 0.5.6 - natural-compare: 1.4.0 - optionator: 0.8.3 - path-is-inside: 1.0.2 - progress: 2.0.3 - regexpp: 2.0.1 - semver: 5.7.1 - strip-ansi: 4.0.0 - strip-json-comments: 2.0.1 - table: 5.4.6 - text-table: 0.2.0 - transitivePeerDependencies: - - supports-color - dev: true - /eslint@8.29.0: resolution: {integrity: sha512-isQ4EEiyUjZFbEKvEGJKKGBwXtvXX+zJbkVKCgTuB9t/+jUBcy8avhkEwWJecI15BkRkOYmvIM5ynbhRjEkoeg==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} hasBin: true dependencies: '@eslint/eslintrc': 1.4.1 - '@humanwhocodes/config-array': 0.11.8 + '@humanwhocodes/config-array': 0.11.14 '@humanwhocodes/module-importer': 1.0.1 '@nodelib/fs.walk': 1.2.8 ajv: 6.12.6 @@ -6111,31 +6052,31 @@ packages: debug: 4.3.4(supports-color@8.1.1) doctrine: 3.0.0 escape-string-regexp: 4.0.0 - eslint-scope: 7.2.0 + eslint-scope: 7.2.2 eslint-utils: 3.0.0(eslint@8.29.0) - eslint-visitor-keys: 3.4.0 - espree: 9.5.1 + eslint-visitor-keys: 3.4.3 + espree: 9.6.1 esquery: 1.5.0 esutils: 2.0.3 fast-deep-equal: 3.1.3 file-entry-cache: 6.0.1 find-up: 5.0.0 glob-parent: 6.0.2 - globals: 13.20.0 + globals: 13.24.0 grapheme-splitter: 1.0.4 - ignore: 5.2.4 + ignore: 5.3.1 import-fresh: 3.3.0 imurmurhash: 0.1.4 is-glob: 4.0.3 is-path-inside: 3.0.3 - js-sdsl: 4.4.0 + js-sdsl: 4.4.2 js-yaml: 4.1.0 json-stable-stringify-without-jsonify: 1.0.1 levn: 0.4.1 lodash.merge: 4.6.2 minimatch: 3.1.2 natural-compare: 1.4.0 - optionator: 0.9.1 + optionator: 0.9.3 regexpp: 3.2.0 strip-ansi: 6.0.1 strip-json-comments: 3.1.1 @@ -6144,22 +6085,23 @@ packages: - supports-color dev: true - /espree@5.0.1: - resolution: {integrity: sha512-qWAZcWh4XE/RwzLJejfcofscgMc9CamR6Tn1+XRXNzrvUSSbiAjGOI/fggztjIi7y9VLPqnICMIPiGyr8JaZ0A==} - engines: {node: '>=6.0.0'} + /esniff@2.0.1: + resolution: {integrity: sha512-kTUIGKQ/mDPFoJ0oVfcmyJn4iBDRptjNVIzwIFR7tqWXdVI9xfA2RMwY/gbSpJG3lkdWNEjLap/NqVHZiJsdfg==} + engines: {node: '>=0.10'} dependencies: - acorn: 6.4.2 - acorn-jsx: 5.3.2(acorn@6.4.2) - eslint-visitor-keys: 1.3.0 - dev: true + d: 1.0.1 + es5-ext: 0.10.64 + event-emitter: 0.3.5 + type: 2.7.2 + dev: false - /espree@9.5.1: - resolution: {integrity: sha512-5yxtHSZXRSW5pvv3hAlXM5+/Oswi1AUFqBmbibKb5s6bp3rGIDkyXU6xCoyuuLhijr4SFwPrXRoZjz0AZDN9tg==} + /espree@9.6.1: + resolution: {integrity: sha512-oruZaFkjorTpF32kDSI5/75ViwGeZginGGy2NoOSg3Q9bnwlnmDm4HLnkl0RE3n+njDXR037aY1+x58Z/zFdwQ==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} dependencies: - acorn: 8.8.2 - acorn-jsx: 5.3.2(acorn@8.8.2) - eslint-visitor-keys: 3.4.0 + acorn: 8.11.3 + acorn-jsx: 5.3.2(acorn@8.11.3) + eslint-visitor-keys: 3.4.3 dev: true /esprima@4.0.1: @@ -6206,15 +6148,15 @@ packages: /ethereum-cryptography@0.1.3: resolution: {integrity: sha512-w8/4x1SGGzc+tO97TASLja6SLd3fRIK2tLVcV2Gx4IB21hE19atll5Cq9o3d0ZmAYC/8aw0ipieTSiekAea4SQ==} dependencies: - '@types/pbkdf2': 3.1.0 - '@types/secp256k1': 4.0.3 + '@types/pbkdf2': 3.1.2 + '@types/secp256k1': 4.0.6 blakejs: 1.2.1 browserify-aes: 1.2.0 bs58check: 2.1.2 create-hash: 1.2.0 create-hmac: 1.1.7 hash.js: 1.1.7 - keccak: 3.0.3 + keccak: 3.0.4 pbkdf2: 3.1.2 randombytes: 2.1.0 safe-buffer: 5.2.1 @@ -6232,6 +6174,15 @@ packages: '@scure/bip39': 1.1.1 dev: true + /ethereum-cryptography@2.1.3: + resolution: {integrity: sha512-BlwbIL7/P45W8FGW2r7LGuvoEZ+7PWsniMvQ4p5s2xCyw9tmaDlpfsN9HjAucbF+t/qpVHwZUisgfK24TCW8aA==} + dependencies: + '@noble/curves': 1.3.0 + '@noble/hashes': 1.3.3 + '@scure/bip32': 1.3.3 + '@scure/bip39': 1.2.2 + dev: true + /ethereumjs-abi@0.6.8: resolution: {integrity: sha512-Tx0r/iXI6r+lRsdvkFDlut0N08jWMnKRZ6Gkq+Nmw75lZe4e6o3EkSnkaBP5NF6+m5PTGAr9JP43N3LyeoglsA==} dependencies: @@ -6251,17 +6202,6 @@ packages: rlp: 2.2.7 dev: true - /ethereumjs-util@7.1.5: - resolution: {integrity: sha512-SDl5kKrQAudFBUe5OJM9Ac6WmMyYmXX/6sTmLZ3ffG2eY6ZIGBes3pEDxNN6V72WyOw4CPD5RomKdsa8DAAwLg==} - engines: {node: '>=10.0.0'} - dependencies: - '@types/bn.js': 5.1.1 - bn.js: 5.2.1 - create-hash: 1.2.0 - ethereum-cryptography: 0.1.3 - rlp: 2.2.7 - dev: true - /ethers@5.7.2: resolution: {integrity: sha512-wswUsmWo1aOK8rR7DIKiWSw9DbLWe6x98Jrn8wcTflTVvaXhAMaB5zGAXy0GYQEQp9iO1iSHWVyARQm11zUtyg==} dependencies: @@ -6314,17 +6254,19 @@ packages: is-hex-prefixed: 1.0.0 strip-hex-prefix: 1.0.0 dev: true + bundledDependencies: false /event-emitter@0.3.5: resolution: {integrity: sha512-D9rRn9y7kLPnJ+hMq7S/nhvoKwwvVJahBi2BPmx3bvbsEdK3W9ii8cBSGjP+72/LnM4n6fo3+dkCX5FeTQruXA==} dependencies: d: 1.0.1 - es5-ext: 0.10.62 + es5-ext: 0.10.64 dev: false /event-target-shim@5.0.1: resolution: {integrity: sha512-i/2XbnSz/uxRCU6+NdVJgKWDTM427+MqYbkQzD321DuCQJUqOuJKIA0IM2+W2xtYHdKOmZ4dR6fExsd4SXL+WQ==} engines: {node: '>=6'} + dev: false /eventemitter3@4.0.7: resolution: {integrity: sha512-8guHBZCwKnFhYdHr2ysuRWErTwhoN2X8XELRlrRwpmfeY2jjuUN4taQMsULKUVo1K4DvZl+0pgfyoysHxvmvEw==} @@ -6332,7 +6274,7 @@ packages: /eventemitter3@5.0.1: resolution: {integrity: sha512-GWkBvjiSZK87ELrYOSESUYeVIc9mvLLf/nXalMOS5dYrgZq9o5OVkbZAVM06CVxYsCwH9BDZFPlQTlPA1j4ahA==} - dev: false + dev: true /events@3.3.0: resolution: {integrity: sha512-mQw+2fkQbALzQ7V0MY0IqdnXNOeTtP4r0lN9z7AAawCXgqea7bDii20AYrIBrFd/Hx0M2Ocz6S111CaFkUcb0Q==} @@ -6346,22 +6288,6 @@ packages: safe-buffer: 5.2.1 dev: true - /execa@3.4.0: - resolution: {integrity: sha512-r9vdGQk4bmCuK1yKQu1KTwcT2zwfWdbdaXfCtAh+5nU/4fSX+JAb7vZGvI5naJrQlvONrEB20jeruESI69530g==} - engines: {node: ^8.12.0 || >=9.7.0} - dependencies: - cross-spawn: 7.0.3 - get-stream: 5.2.0 - human-signals: 1.1.1 - is-stream: 2.0.1 - merge-stream: 2.0.0 - npm-run-path: 4.0.1 - onetime: 5.1.2 - p-finally: 2.0.1 - signal-exit: 3.0.7 - strip-final-newline: 2.0.0 - dev: true - /execa@5.1.1: resolution: {integrity: sha512-8uSpZZocAZRBAPIEINJj3Lo9HyGitllczc27Eh5YYojjMFMn8yHMDMaUHE2Jqfq05D/wucwI4JGURyXt1vchyg==} engines: {node: '>=10'} @@ -6376,19 +6302,20 @@ packages: signal-exit: 3.0.7 strip-final-newline: 2.0.0 - /execa@7.0.0: - resolution: {integrity: sha512-tQbH0pH/8LHTnwTrsKWideqi6rFB/QNUawEwrn+WHyz7PX1Tuz2u7wfTvbaNBdP5JD5LVWxNo8/A8CHNZ3bV6g==} - engines: {node: ^14.18.0 || ^16.14.0 || >=18.0.0} + /execa@8.0.1: + resolution: {integrity: sha512-VyhnebXciFV2DESc+p6B+y0LjSm0krU4OgJN44qFAhBY0TJ+1V61tYD2+wHusZ6F9n5K+vl8k0sTy7PEfV4qpg==} + engines: {node: '>=16.17'} dependencies: cross-spawn: 7.0.3 - get-stream: 6.0.1 - human-signals: 4.3.1 + get-stream: 8.0.1 + human-signals: 5.0.0 is-stream: 3.0.0 merge-stream: 2.0.0 - npm-run-path: 5.1.0 + npm-run-path: 5.3.0 onetime: 6.0.0 - signal-exit: 3.0.7 + signal-exit: 4.1.0 strip-final-newline: 3.0.0 + dev: true /execcli@5.0.6: resolution: {integrity: sha512-du+uy/Ew2P90PKjSHI89u/XuqVaBDzvaJ6ePn40JaOy7owFQNsYDbd5AoR5A559HEAb1i5HO22rJxtgVonf5Bg==} @@ -6411,21 +6338,17 @@ packages: engines: {node: '>=6'} dev: false - /expect@29.5.0: - resolution: {integrity: sha512-yM7xqUrCO2JdpFo4XpM82t+PJBFybdqoQuJLDGeDX2ij8NZzqRHyu3Hp188/JX7SWqud+7t4MUdvcgGBICMHZg==} + /expect@29.7.0: + resolution: {integrity: sha512-2Zks0hf1VLFYI1kbh0I5jP3KHHyCHpkfyHBzsSXRFgl/Bg9mWYfMW8oD+PdMPlEwy5HNsR9JutYy6pMeOh61nw==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} dependencies: - '@jest/expect-utils': 29.5.0 - jest-get-type: 29.4.3 - jest-matcher-utils: 29.5.0 - jest-message-util: 29.5.0 - jest-util: 29.5.0 + '@jest/expect-utils': 29.7.0 + jest-get-type: 29.6.3 + jest-matcher-utils: 29.7.0 + jest-message-util: 29.7.0 + jest-util: 29.7.0 dev: true - /exponential-backoff@3.1.1: - resolution: {integrity: sha512-dX7e/LHVJ6W3DE1MHWi9S1EYzDESENfLrYohG2G++ovZrYOkm4Knwa0mc1cn84xJOR4KEU0WSchhLbd0UklbHw==} - dev: false - /ext@1.7.0: resolution: {integrity: sha512-6hxeJYaL110a9b5TEJSj0gojyHQAmA2ch5Os+ySCiA1QGdS697XWY1pzsrSjqA9LDEEgdB/KypIlR59RcLuHYw==} dependencies: @@ -6448,8 +6371,8 @@ packages: iconv-lite: 0.4.24 tmp: 0.0.33 - /fast-content-type-parse@1.0.0: - resolution: {integrity: sha512-Xbc4XcysUXcsP5aHUU7Nq3OwvHq97C+WnbkeIefpeYLX+ryzFJlU6OStFJhs6Ol0LkUGpcK+wL0JwfM+FCU5IA==} + /fast-content-type-parse@1.1.0: + resolution: {integrity: sha512-fBHHqSTFLVnR61C+gltJuE5GkVQMV0S2nqUO8TJ+5Z3qAKG8vAx4FKai1s5jq/inV1+sREynIWSuQ6HgoSXpDQ==} dev: false /fast-decode-uri-component@1.0.1: @@ -6459,12 +6382,12 @@ packages: /fast-deep-equal@3.1.3: resolution: {integrity: sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q==} - /fast-diff@1.2.0: - resolution: {integrity: sha512-xJuoT5+L99XlZ8twedaRf6Ax2TgQVxvgZOYoPKqZufmJib0tL2tegPBOZb1pVNgIhlqDlA0eO0c3wBvQcmzx4w==} + /fast-diff@1.3.0: + resolution: {integrity: sha512-VxPP4NqbUjj6MaAOafWeUn2cXWLcCtljklUtZf0Ind4XQ+QPtmA0b18zZy0jIQx+ExRVCR/ZQpBmik5lXshNsw==} dev: true - /fast-glob@3.2.12: - resolution: {integrity: sha512-DVj4CQIYYow0BlaelwK1pHl5n5cRSJfM60UA0zK891sVInoPri2Ekj7+e1CT3/3qxXenpI+nBBmQAcJPJgaj4w==} + /fast-glob@3.3.2: + resolution: {integrity: sha512-oX2ruAFQwf/Orj8m737Y5adxDQO0LAB7/S5MnxCdTNDd4p6BsyIVsv9JQsATbTSq8KHRpLwIHbVlUNatxd+1Ow==} engines: {node: '>=8.6.0'} dependencies: '@nodelib/fs.stat': 2.0.5 @@ -6477,15 +6400,16 @@ packages: resolution: {integrity: sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw==} dev: true - /fast-json-stringify@5.8.0: - resolution: {integrity: sha512-VVwK8CFMSALIvt14U8AvrSzQAwN/0vaVRiFFUVlpnXSnDGrSkOAO5MtzyN8oQNjLd5AqTW5OZRgyjoNuAuR3jQ==} + /fast-json-stringify@5.12.0: + resolution: {integrity: sha512-7Nnm9UPa7SfHRbHVA1kJQrGXCRzB7LMlAAqHXQFkEQqueJm1V8owm0FsE/2Do55/4CcdhwiLQERaKomOnKQkyA==} dependencies: - '@fastify/deepmerge': 1.3.0 + '@fastify/merge-json-schemas': 0.1.1 ajv: 8.12.0 ajv-formats: 2.1.1(ajv@8.12.0) fast-deep-equal: 3.1.3 - fast-uri: 2.2.0 - rfdc: 1.3.0 + fast-uri: 2.3.0 + json-schema-ref-resolver: 1.0.1 + rfdc: 1.3.1 dev: false /fast-levenshtein@2.0.6: @@ -6503,39 +6427,39 @@ packages: engines: {node: '>=6'} dev: false - /fast-uri@2.2.0: - resolution: {integrity: sha512-cIusKBIt/R/oI6z/1nyfe2FvGKVTohVRfvkOhvx0nCEW+xf5NoCXjAHcWp93uOUBchzYcsvPlrapAdX1uW+YGg==} + /fast-uri@2.3.0: + resolution: {integrity: sha512-eel5UKGn369gGEWOqBShmFJWfq/xSJvsgDzgLYC845GneayWvXBf0lJCBn5qTABfewy1ZDPoaR5OZCP+kssfuw==} dev: false /fastify-plugin@4.5.1: resolution: {integrity: sha512-stRHYGeuqpEZTL1Ef0Ovr2ltazUT9g844X5z/zEBFLG8RYlpDiOCIG+ATvYEp+/zmc7sN29mcIMp8gvYplYPIQ==} dev: false - /fastify@4.21.0: - resolution: {integrity: sha512-tsu4bcwE4HetxqW8prA5fbC9bKHMYDp7jGEDWyzK1l90a3uOaLoIcQbdGcWeODNLVJviQnzh1wvIjTZE3MJFEg==} + /fastify@4.26.1: + resolution: {integrity: sha512-tznA/G55dsxzM5XChBfcvVSloG2ejeeotfPPJSFaWmHyCDVGMpvf3nRNbsCb/JTBF9RmQFBfuujWt3Nphjesng==} dependencies: '@fastify/ajv-compiler': 3.5.0 - '@fastify/error': 3.3.0 + '@fastify/error': 3.4.1 '@fastify/fast-json-stringify-compiler': 4.3.0 abstract-logging: 2.0.1 - avvio: 8.2.1 - fast-content-type-parse: 1.0.0 - fast-json-stringify: 5.8.0 - find-my-way: 7.6.2 - light-my-request: 5.10.0 - pino: 8.14.2 - process-warning: 2.2.0 + avvio: 8.3.0 + fast-content-type-parse: 1.1.0 + fast-json-stringify: 5.12.0 + find-my-way: 8.1.0 + light-my-request: 5.11.1 + pino: 8.19.0 + process-warning: 3.0.0 proxy-addr: 2.0.7 - rfdc: 1.3.0 + rfdc: 1.3.1 secure-json-parse: 2.7.0 - semver: 7.5.0 - tiny-lru: 11.0.1 + semver: 7.6.0 + toad-cache: 3.7.0 transitivePeerDependencies: - supports-color dev: false - /fastq@1.15.0: - resolution: {integrity: sha512-wBrocU2LCXXa+lWBt8RoIRD89Fi8OdABODa/kEnyeyjS5aZO5/GNvI5sEINADqP/h8M29UHTHUb53sUu5Ihqdw==} + /fastq@1.17.1: + resolution: {integrity: sha512-sRVD3lWVIXWg6By68ZN7vho9a1pQcN/WBFaAAsDDFzlJjvoGx0P8z7V1t72grFJfJhu3YPZBuu25f7Kaw2jN1w==} dependencies: reusify: 1.0.4 @@ -6545,21 +6469,6 @@ packages: bser: 2.1.1 dev: true - /figures@1.7.0: - resolution: {integrity: sha512-UxKlfCRuCBxSXU4C6t9scbDyWZ4VlaFFdojKtzJuSkuOBQ5CNFum+zZXFwHjo+CxBC1t6zlYPgHIgFjL8ggoEQ==} - engines: {node: '>=0.10.0'} - dependencies: - escape-string-regexp: 1.0.5 - object-assign: 4.1.1 - dev: true - - /figures@2.0.0: - resolution: {integrity: sha512-Oa2M9atig69ZkfwiApY8F2Yy+tzMbazyvqv21R0NsSC8floSOC09BbT1ITWAdoMGQvJ/aZnR1KMwdx9tvHnTNA==} - engines: {node: '>=4'} - dependencies: - escape-string-regexp: 1.0.5 - dev: true - /figures@3.2.0: resolution: {integrity: sha512-yaduQFRKLXYOGgEn6AZau90j3ggSOyiqXU0F9JZfeXYhNa+Jk4X+s45A2zg5jns87GAFa34BBm2kXw4XpNcbdg==} engines: {node: '>=8'} @@ -6567,18 +6476,11 @@ packages: escape-string-regexp: 1.0.5 dev: false - /file-entry-cache@5.0.1: - resolution: {integrity: sha512-bCg29ictuBaKUwwArK4ouCaqDgLZcysCFLmM/Yn/FDoqndh/9vNuQfXRDvTuXKLxfD/JtZQGKFT8MGcJBK644g==} - engines: {node: '>=4'} - dependencies: - flat-cache: 2.0.1 - dev: true - /file-entry-cache@6.0.1: resolution: {integrity: sha512-7Gps/XWymbLk2QLYK4NzpMOrYjMhdIxXuIvy2QBsLE6ljuodKvdkWs/cpyJJ3CVIVpH0Oi1Hvg1ovbMzLdFBBg==} engines: {node: ^10.12.0 || >=12.0.0} dependencies: - flat-cache: 3.0.4 + flat-cache: 3.2.0 dev: true /file-uri-to-path@1.0.0: @@ -6596,8 +6498,8 @@ packages: dependencies: to-regex-range: 5.0.1 - /find-my-way@7.6.2: - resolution: {integrity: sha512-0OjHn1b1nCX3eVbm9ByeEHiscPYiHLfhei1wOUU9qffQkk98wE0Lo8VrVYfSGMgnSnDh86DxedduAnBf4nwUEw==} + /find-my-way@8.1.0: + resolution: {integrity: sha512-41QwjCGcVTODUmLLqTMeoHeiozbMXYMAE1CKFiDyi9zVZ2Vjh0yz3MF0WQZoIb+cmzP/XlbFjlF2NtJmvZHznA==} engines: {node: '>=14'} dependencies: fast-deep-equal: 3.1.3 @@ -6633,15 +6535,6 @@ packages: dependencies: locate-path: 6.0.0 path-exists: 4.0.0 - dev: true - - /find-up@6.3.0: - resolution: {integrity: sha512-v2ZsoEuVHYy8ZIlYqwPe/39Cy+cFDzp4dXPaxNvkEuouymu+2Jbz0PxpKarJHYJTmv2HWT3O382qY8l4jMWthw==} - engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} - dependencies: - locate-path: 7.2.0 - path-exists: 5.0.0 - dev: false /find-yarn-workspace-root2@1.2.16: resolution: {integrity: sha512-hr6hb1w8ePMpPVUK39S4RlwJzi+xPLuVuG8XlwXU3KD5Yn3qgBWVfy3AzNlDhWvE1EORCE65/Qm26rFQt3VLVA==} @@ -6655,20 +6548,12 @@ packages: engines: {node: '>=7.6', npm: '>=4'} dev: false - /flat-cache@2.0.1: - resolution: {integrity: sha512-LoQe6yDuUMDzQAEH8sgmh4Md6oZnc/7PjtwjNFSzveXqSHt6ka9fPBuso7IGf9Rz4uqnSnWiFH2B/zj24a5ReA==} - engines: {node: '>=4'} - dependencies: - flatted: 2.0.2 - rimraf: 2.6.3 - write: 1.0.3 - dev: true - - /flat-cache@3.0.4: - resolution: {integrity: sha512-dm9s5Pw7Jc0GvMYbshN6zchCA9RgQlzzEZX3vylR9IqFfS8XciblUXOKfW6SiuJ0e13eDYZoZV5wdrev7P3Nwg==} + /flat-cache@3.2.0: + resolution: {integrity: sha512-CYcENa+FtcUKLmhhqyctpclsq7QF38pKjZHsGNiSQF5r4FtoKDWabFDl3hzaEQMvT1LHEysw5twgLvpYYb4vbw==} engines: {node: ^10.12.0 || >=12.0.0} dependencies: - flatted: 3.2.7 + flatted: 3.3.1 + keyv: 4.5.4 rimraf: 3.0.2 dev: true @@ -6677,16 +6562,12 @@ packages: hasBin: true dev: true - /flatted@2.0.2: - resolution: {integrity: sha512-r5wGx7YeOwNWNlCA0wQ86zKyDLMQr+/RB8xy74M4hTphfmjlijTSSXGuH8rnvKZnfT9i+75zmd8jcKdMR4O6jA==} + /flatted@3.3.1: + resolution: {integrity: sha512-X8cqMLLie7KsNUDSdzeN8FYK9rEt4Dt67OsG/DNGnYTSDBG4uFAJFBnUeiV+zCVAvwFy56IjM9sH51jVaEhNxw==} dev: true - /flatted@3.2.7: - resolution: {integrity: sha512-5nqDSxl8nn5BSNxyR3n4I6eDmbolI6WT+QqR547RwxQapgjQBmtktdP+HTBb/a/zLsbzERTONyUB5pefh5TtjQ==} - dev: true - - /follow-redirects@1.15.2(debug@4.3.4): - resolution: {integrity: sha512-VQLG33o04KaQ8uYi2tVNbdrWp1QWxNNea+nmIB4EVM28v0hmP17z7aG1+wAkNzVq4KeXTq3221ye5qTJP91JwA==} + /follow-redirects@1.15.5(debug@4.3.4): + resolution: {integrity: sha512-vSFWUON1B+yAw1VN4xMfxgn5fTUiaOzAJCKBwIIgT/+7CuGy9+r+5gITvP62j3RmaD5Ph65UaERdOSRGUzZtgw==} engines: {node: '>=4.0'} peerDependencies: debug: '*' @@ -6697,13 +6578,18 @@ packages: debug: 4.3.4(supports-color@8.1.1) dev: true - /form-data@3.0.1: - resolution: {integrity: sha512-RHkBKtLWUVwd7SqRIvCZMEvAMoGUp0XU+seQiZejj0COz3RI3hWP4sCv3gZWWLjJTd7rGwcsF5eKZGii0r/hbg==} - engines: {node: '>= 6'} + /for-each@0.3.3: + resolution: {integrity: sha512-jqYfLp7mo9vIyQf8ykW2v7A+2N4QjeCeI5+Dz9XraiO1ign81wjiH7Fb9vSOWvQfNtmSa4H2RoQTrrXivdUZmw==} dependencies: - asynckit: 0.4.0 - combined-stream: 1.0.8 - mime-types: 2.1.35 + is-callable: 1.2.7 + dev: true + + /foreground-child@3.1.1: + resolution: {integrity: sha512-TMKDUnIte6bfb5nWv7V/caI169OHgvwjb7V4WkeUvbQQdjr5rWKqHFiKWb/fcOwB+CzBT+qbWjvj+DVwRskpIg==} + engines: {node: '>=14'} + dependencies: + cross-spawn: 7.0.3 + signal-exit: 4.1.0 dev: true /form-data@4.0.0: @@ -6724,8 +6610,8 @@ packages: resolution: {integrity: sha512-H5KQDspykdHuztLTg+ajGN0Z2qUjcEf3Ybxc6hLt0k7/zPkn29XnKnxlBPyW2XIddWrGaJBzBl4VLYOtk39yZg==} dev: true - /fraction.js@4.2.0: - resolution: {integrity: sha512-MhLuK+2gUcnZe8ZHlaaINnQLl0xRIGRfcGk2yl8xoQAfHrSsL3rYu6FCmBdkdbhc9EPlwyGHewaRsvwRMJtAlA==} + /fraction.js@4.3.7: + resolution: {integrity: sha512-ZsDfxO51wGAXREY55a7la9LScWpwv9RxIrYABrlvOFBlH/ShPnrtsXeuUIfXKKOVicNxQ+o8JTbJvjS4M89yew==} dev: true /fresh@0.5.2: @@ -6772,13 +6658,6 @@ packages: universalify: 0.1.2 dev: true - /fs-minipass@2.1.0: - resolution: {integrity: sha512-V/JgOLFCS+R6Vcq0slCuaeWEdNC3ouDlJMNIsacH2VtALiu9mV4LPrHc5cDl8k5aw6J8jwgWWpiTo5RYhmIzvg==} - engines: {node: '>= 8'} - dependencies: - minipass: 3.3.6 - dev: false - /fs.realpath@1.0.0: resolution: {integrity: sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw==} @@ -6789,42 +6668,24 @@ packages: requiresBuild: true optional: true - /function-bind@1.1.1: - resolution: {integrity: sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==} + /function-bind@1.1.2: + resolution: {integrity: sha512-7XHNxH7qX9xG5mIwxkhumTox/MIRNcOgDrxWsMt2pAr23WHp6MrRlN7FBSFpCpr+oVO0F744iUgR82nJMfG2SA==} dev: true - /function.prototype.name@1.1.5: - resolution: {integrity: sha512-uN7m/BzVKQnCUF/iW8jYea67v++2u7m5UgENbHRtdDVclOUP+FMPlCNdmk0h/ysGyo2tavMJEDqJAkJdRa1vMA==} + /function.prototype.name@1.1.6: + resolution: {integrity: sha512-Z5kx79swU5P27WEayXM1tBi5Ze/lbIyiNgU3qyXUOf9b2rgXYyF9Dy9Cx+IQv/Lc8WCG6L82zwUPpSS9hGehIg==} engines: {node: '>= 0.4'} dependencies: - call-bind: 1.0.2 - define-properties: 1.1.4 - es-abstract: 1.20.5 + call-bind: 1.0.7 + define-properties: 1.2.1 + es-abstract: 1.22.5 functions-have-names: 1.2.3 dev: true - /functional-red-black-tree@1.0.1: - resolution: {integrity: sha512-dsKNQNdj6xA3T+QlADDA7mOSlX0qiMINjn0cgr+eGHGsbSHzTabcIogz2+p/iqP1Xs6EP/sS2SbqH+brGTbq0g==} - dev: true - /functions-have-names@1.2.3: resolution: {integrity: sha512-xckBUXyTIqT97tq2x2AMb+g163b5JFysYk0x4qxNFwbfQkmNZoiRHb6sPzI9/QV33WeuvVYBUIiD4NzNIyqaRQ==} dev: true - /gauge@4.0.4: - resolution: {integrity: sha512-f9m+BEN5jkg6a0fZjleidjN51VE1X+mPFQ2DJ0uv1V39oCLCbsGe6yjbBnp7eK7z/+GAon99a3nHuqbuuthyPg==} - engines: {node: ^12.13.0 || ^14.15.0 || >=16.0.0} - dependencies: - aproba: 2.0.0 - color-support: 1.1.3 - console-control-strings: 1.1.0 - has-unicode: 2.0.1 - signal-exit: 3.0.7 - string-width: 4.2.3 - strip-ansi: 6.0.1 - wide-align: 1.1.5 - dev: false - /gensync@1.0.0-beta.2: resolution: {integrity: sha512-3hN7NaskYvMDLQY55gnW3NQ+mesEAepTqlg+VEbj7zzqEMBVNhzcGYYeqFo/TlYz6eQiFcp1HcsCZO+nGgS8zg==} engines: {node: '>=6.9.0'} @@ -6834,24 +6695,24 @@ packages: resolution: {integrity: sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==} engines: {node: 6.* || 8.* || >= 10.*} - /get-func-name@2.0.0: - resolution: {integrity: sha512-Hm0ixYtaSZ/V7C8FJrtZIuBBI+iSgL+1Aq82zSu8VQNB4S3Gk8e7Qs3VwBDJAhmRZcFqkl3tQu36g/Foh5I5ig==} + /get-east-asian-width@1.2.0: + resolution: {integrity: sha512-2nk+7SIVb14QrgXFHcm84tD4bKQz0RxPuMT8Ag5KPOq7J5fEmAg0UbXdTOSHqNuHSU28k55qnceesxXRZGzKWA==} + engines: {node: '>=18'} dev: true /get-func-name@2.0.2: resolution: {integrity: sha512-8vXOvuE167CtIc3OyItco7N/dpRtBbYOsPsXCz7X/PMnlGjYjSGuZJgM1Y7mmew7BKf9BqvLX2tnOVy1BBUsxQ==} dev: true - /get-intrinsic@1.1.3: - resolution: {integrity: sha512-QJVz1Tj7MS099PevUG5jvnt9tSkXN8K14dxQlikJuPt4uD9hHAHjLyLBiLR5zELelBdD9QNRAXZzsJx0WaDL9A==} + /get-intrinsic@1.2.4: + resolution: {integrity: sha512-5uYhsJH8VJBTv7oslg4BznJYhDoRI6waYCxMmCdnTrcCrHA/fCFKoTFz2JKKE0HdDFUF7/oQuhzumXJK7paBRQ==} + engines: {node: '>= 0.4'} dependencies: - function-bind: 1.1.1 - has: 1.0.3 + es-errors: 1.3.0 + function-bind: 1.1.2 + has-proto: 1.0.3 has-symbols: 1.0.3 - dev: true - - /get-own-enumerable-property-symbols@3.0.2: - resolution: {integrity: sha512-I0UBV/XOz1XkIJHEUDMZAbzCThU/H8DxmSfmdGcKPnVhu2VfFqr34jr9777IyaTYvxjedWhqVIilEDsCdP5G6g==} + hasown: 2.0.1 dev: true /get-package-type@0.1.0: @@ -6859,27 +6720,28 @@ packages: engines: {node: '>=8.0.0'} dev: true - /get-stream@5.2.0: - resolution: {integrity: sha512-nBF+F1rAZVCu/p7rjzgA+Yb4lfYXrpl7a6VmJrU8wF9I1CKvP/QwPNZHnOlwbTkY6dvtFIzFMSyQXbLoTQPRpA==} - engines: {node: '>=8'} - dependencies: - pump: 3.0.0 - dev: true - /get-stream@6.0.1: resolution: {integrity: sha512-ts6Wi+2j3jQjqi70w5AlN8DFnkSwC+MqmxEzdEALB2qXZYV3X/b1CTfgPLGJNMeAWxdPfU8FO1ms3NUfaHCPYg==} engines: {node: '>=10'} - /get-symbol-description@1.0.0: - resolution: {integrity: sha512-2EmdH1YvIQiZpltCNgkuiUnyukzxM/R6NDJX31Ke3BG1Nq5b0S2PhX59UKi9vZpPDQVdqn+1IcaAwnzTT5vCjw==} + /get-stream@8.0.1: + resolution: {integrity: sha512-VaUJspBffn/LMCJVoMvSAdmscJyS1auj5Zulnn5UoYcY531UWmdwhRWkcGKnGU93m5HSXP9LP2usOryrBtQowA==} + engines: {node: '>=16'} + dev: true + + /get-symbol-description@1.0.2: + resolution: {integrity: sha512-g0QYk1dZBxGwk+Ngc+ltRH2IBp2f7zBkBMBJZCDerh6EhlhSR6+9irMCuT/09zD6qkarHUSn529sK/yL4S27mg==} engines: {node: '>= 0.4'} dependencies: - call-bind: 1.0.2 - get-intrinsic: 1.1.3 + call-bind: 1.0.7 + es-errors: 1.3.0 + get-intrinsic: 1.2.4 dev: true - /get-tsconfig@4.5.0: - resolution: {integrity: sha512-MjhiaIWCJ1sAU4pIQ5i5OfOuHHxVo1oYeNsWTON7jxYkod8pHocXeh+SSbmu5OZZZK73B6cbJ2XADzXehLyovQ==} + /get-tsconfig@4.7.2: + resolution: {integrity: sha512-wuMsz4leaj5hbGgg4IvDU0bqJagpftG5l5cXIAvo8uZrqn0NJqwtfupTN00VnkQJPcIRrxYrm1Ue24btpCha2A==} + dependencies: + resolve-pkg-maps: 1.0.0 dev: true /gitconfig@2.0.8: @@ -6912,15 +6774,16 @@ packages: is-glob: 4.0.3 dev: true - /glob@7.1.6: - resolution: {integrity: sha512-LwaxwyZ72Lk7vZINtNNrywX0ZuLyStrdDtabefZKAY5ZGJhVtgdznluResxNmPitE0SAO+O26sWTHeKSI2wMBA==} + /glob@10.3.10: + resolution: {integrity: sha512-fa46+tv1Ak0UPK1TOy/pZrIybNNt4HCv7SDzwyfiOZkvZLEbjsZkJBPtDHVshZjbecAoAGSC20MjLDG/qr679g==} + engines: {node: '>=16 || 14 >=14.17'} + hasBin: true dependencies: - fs.realpath: 1.0.0 - inflight: 1.0.6 - inherits: 2.0.4 - minimatch: 3.1.2 - once: 1.4.0 - path-is-absolute: 1.0.1 + foreground-child: 3.1.1 + jackspeak: 2.3.6 + minimatch: 9.0.3 + minipass: 7.0.4 + path-scurry: 1.10.1 dev: true /glob@7.2.0: @@ -6943,9 +6806,10 @@ packages: minimatch: 3.1.2 once: 1.4.0 path-is-absolute: 1.0.1 + dev: true - /glob@8.0.3: - resolution: {integrity: sha512-ull455NHSHI/Y1FqGaaYFaLGkNMMJbavMrEGFXG/PGrg6y7sutWHUHrz6gy6WEBH6akM1M414dWKCNs+IhKdiQ==} + /glob@8.1.0: + resolution: {integrity: sha512-r8hpEjiQEYlF2QU0df3dS+nxxSIreXQS1qRhMJM0Q5NDdR386C7jb7Hwwod8Fgiuex+k0GFjgft18yvxm5XoCQ==} engines: {node: '>=12'} dependencies: fs.realpath: 1.0.0 @@ -6959,21 +6823,28 @@ packages: engines: {node: '>=4'} dev: true - /globals@13.20.0: - resolution: {integrity: sha512-Qg5QtVkCy/kv3FUSlu4ukeZDVf9ee0iXLAUYX13gbR17bnejFTzr4iS9bY7kwCf1NztRNm1t91fjOiyx4CSwPQ==} + /globals@13.24.0: + resolution: {integrity: sha512-AhO5QUcj8llrbG09iWhPU2B204J1xnPeL8kQmVorSsy+Sjj1sk8gIyh6cUocGmH4L0UuhAJy+hJMRA4mgA4mFQ==} engines: {node: '>=8'} dependencies: type-fest: 0.20.2 dev: true + /globalthis@1.0.3: + resolution: {integrity: sha512-sFdI5LyBiNTHjRd7cGPWapiHWMOXKyuBNX/cWJ3NfzrZQVa8GI/8cofCl74AOVqq9W5kNmguTIzJ/1s2gyI9wA==} + engines: {node: '>= 0.4'} + dependencies: + define-properties: 1.2.1 + dev: true + /globby@11.1.0: resolution: {integrity: sha512-jhIXaOzy1sb8IyocaruWSn1TjmnBVs8Ayhcy83rmxNJ8q2uWKCAj3CnJY+KpGSXCueAPc0i05kVvVKtP1t9S3g==} engines: {node: '>=10'} dependencies: array-union: 2.1.0 dir-glob: 3.0.1 - fast-glob: 3.2.12 - ignore: 5.2.4 + fast-glob: 3.3.2 + ignore: 5.3.1 merge2: 1.4.1 slash: 3.0.0 @@ -6984,19 +6855,19 @@ packages: /gopd@1.0.1: resolution: {integrity: sha512-d65bNlIadxvpb/A2abVdlqKqV563juRnZ1Wtk6s1sIR8uNsXR70xqIzVqxVf1eTqDunwT2MkczEeaezCKTZhwA==} dependencies: - get-intrinsic: 1.1.3 + get-intrinsic: 1.2.4 dev: true /graceful-fs@4.2.11: resolution: {integrity: sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==} - requiresBuild: true + dev: true /grapheme-splitter@1.0.4: resolution: {integrity: sha512-bzh50DW9kTPM00T8y4o8vQg89Di9oLJVLW/KaOGIXJWP/iqCN6WKYkbNOF04vFLJhwcpYUh9ydh/+5vpOqV4YQ==} dev: true - /handlebars@4.7.7: - resolution: {integrity: sha512-aAcXm5OAfE/8IXkcZvCepKU3VzW1/39Fb5ZuqMtgI/hT8X2YgoMvBY5dLhq/cpOvw7Lk1nK/UF71aLG/ZnVYRA==} + /handlebars@4.7.8: + resolution: {integrity: sha512-vafaFqs8MZkRrSX7sFVUdo3ap/eNiLnb4IakshzvP56X5Nr1iGKAIqdX6tMlm6HcNRIkr6AxO5jFEoJzzpT8aQ==} engines: {node: '>=0.4.7'} hasBin: true dependencies: @@ -7013,9 +6884,8 @@ packages: engines: {node: '>=6'} dev: true - /hardhat@2.10.2(typescript@5.1.6): - resolution: {integrity: sha512-L/KvDDT/MA6332uAtYTqdcHoSABljw4pPjHQe5SHdIJ+xKfaSc6vDKw03CmrQ5Xup0gHs8XnVSBpZo1AbbIW7g==} - engines: {node: ^14.0.0 || ^16.0.0 || ^18.0.0} + /hardhat@2.20.1(typescript@5.1.6): + resolution: {integrity: sha512-q75xDQiQtCZcTMBwjTovrXEU5ECr49baxr4/OBkIu/ULTPzlB20yk1dRWNmD2IFbAeAeXggaWvQAdpiScaHtPw==} hasBin: true peerDependencies: ts-node: '*' @@ -7026,68 +6896,64 @@ packages: typescript: optional: true dependencies: - '@ethereumjs/block': 3.6.3 - '@ethereumjs/blockchain': 5.5.3 - '@ethereumjs/common': 2.6.5 - '@ethereumjs/tx': 3.5.2 - '@ethereumjs/vm': 5.9.3 '@ethersproject/abi': 5.7.0 '@metamask/eth-sig-util': 4.0.1 + '@nomicfoundation/ethereumjs-block': 5.0.4 + '@nomicfoundation/ethereumjs-blockchain': 7.0.4 + '@nomicfoundation/ethereumjs-common': 4.0.4 + '@nomicfoundation/ethereumjs-evm': 2.0.4(@nomicfoundation/ethereumjs-verkle@0.0.2) + '@nomicfoundation/ethereumjs-rlp': 5.0.4 + '@nomicfoundation/ethereumjs-statemanager': 2.0.4(@nomicfoundation/ethereumjs-verkle@0.0.2) + '@nomicfoundation/ethereumjs-trie': 6.0.4 + '@nomicfoundation/ethereumjs-tx': 5.0.4 + '@nomicfoundation/ethereumjs-util': 9.0.4 + '@nomicfoundation/ethereumjs-verkle': 0.0.2 + '@nomicfoundation/ethereumjs-vm': 7.0.4(@nomicfoundation/ethereumjs-verkle@0.0.2) + '@nomicfoundation/solidity-analyzer': 0.1.1 '@sentry/node': 5.30.0 - '@solidity-parser/parser': 0.14.5 - '@types/bn.js': 5.1.1 + '@types/bn.js': 5.1.5 '@types/lru-cache': 5.1.1 - abort-controller: 3.0.0 adm-zip: 0.4.16 aggregate-error: 3.1.0 ansi-escapes: 4.3.2 + boxen: 5.1.2 chalk: 2.4.2 - chokidar: 3.5.3 + chokidar: 3.6.0 ci-info: 2.0.0 debug: 4.3.4(supports-color@8.1.1) - enquirer: 2.3.6 + enquirer: 2.4.1 env-paths: 2.2.1 ethereum-cryptography: 1.2.0 ethereumjs-abi: 0.6.8 - ethereumjs-util: 7.1.5 find-up: 2.1.0 fp-ts: 1.19.3 fs-extra: 7.0.1 glob: 7.2.0 - immutable: 4.3.0 + immutable: 4.3.5 io-ts: 1.10.4 + keccak: 3.0.4 lodash: 4.17.21 - merkle-patricia-tree: 4.2.4 mnemonist: 0.38.5 - mocha: 10.0.0 + mocha: 10.3.0 p-map: 4.0.0 - qs: 6.11.0 raw-body: 2.5.2 resolve: 1.17.0 - semver: 6.3.0 - slash: 3.0.0 + semver: 6.3.1 solc: 0.7.3(debug@4.3.4) source-map-support: 0.5.21 stacktrace-parser: 0.1.10 - true-case-path: 2.2.1 tsort: 0.0.1 typescript: 5.1.6 - undici: 5.21.0 + undici: 5.28.3 uuid: 8.3.2 ws: 7.5.9 transitivePeerDependencies: - bufferutil + - c-kzg - supports-color - utf-8-validate dev: true - /has-ansi@2.0.0: - resolution: {integrity: sha512-C8vBJ8DwUCx19vhm7urhTuUsr4/IyP6l4VzNQDv+ryHQObW3TTTp9yB68WpYgRe2bbaGuZ/se74IqFeVnMnLZg==} - engines: {node: '>=0.10.0'} - dependencies: - ansi-regex: 2.1.1 - dev: true - /has-bigints@1.0.2: resolution: {integrity: sha512-tSvCKtBr9lkF0Ex0aQiP9N+OpV4zi2r/Nee5VkRDbaqv35RLYMzbwQfFSZZH0kR+Rd6302UJZ2p/bJCEoR3VoQ==} dev: true @@ -7101,33 +6967,27 @@ packages: resolution: {integrity: sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==} engines: {node: '>=8'} - /has-property-descriptors@1.0.0: - resolution: {integrity: sha512-62DVLZGoiEBDHQyqG4w9xCuZ7eJEwNmJRWw2VY84Oedb7WFcA27fiEVe8oUQx9hAUJ4ekurquucTGwsyO1XGdQ==} + /has-property-descriptors@1.0.2: + resolution: {integrity: sha512-55JNKuIW+vq4Ke1BjOTjM2YctQIvCT7GFzHwmfZPGo5wnrgkid0YQtnAleFSqumZm4az3n2BS+erby5ipJdgrg==} dependencies: - get-intrinsic: 1.1.3 + es-define-property: 1.0.0 + dev: true + + /has-proto@1.0.3: + resolution: {integrity: sha512-SJ1amZAJUiZS+PhsVLf5tGydlaVB8EdFpaSO4gmiUKUOxk8qzn5AIy4ZeJUmh22znIdk/uMAUT2pl3FxzVUH+Q==} + engines: {node: '>= 0.4'} dev: true /has-symbols@1.0.3: resolution: {integrity: sha512-l3LCuF6MgDNwTDKkdYGEihYjt5pRPbEg46rtlmnSPlUbgmB8LOIrKJbYYFBSbnPaJexMKtiPO8hmeRjRz2Td+A==} engines: {node: '>= 0.4'} - /has-tostringtag@1.0.0: - resolution: {integrity: sha512-kFjcSNhnlGV1kyoGk7OXKSawH5JOb/LzUc5w9B02hOTO0dfFRjbHQKvg1d6cf3HbeUmtU9VbbV3qzZ2Teh97WQ==} + /has-tostringtag@1.0.2: + resolution: {integrity: sha512-NqADB8VjPFLM2V0VvHUewwwsw0ZWBaIdgo+ieHtK3hasLz4qeCRjYcqfB6AQrBggRKppKF8L52/VqdVsO47Dlw==} engines: {node: '>= 0.4'} dependencies: has-symbols: 1.0.3 - /has-unicode@2.0.1: - resolution: {integrity: sha512-8Rf9Y83NBReMnx0gFzA8JImQACstCYWUplepDa9xprwwtmgEZUF0h/i5xSA625zB/I37EtrswSST6OXxwaaIJQ==} - dev: false - - /has@1.0.3: - resolution: {integrity: sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==} - engines: {node: '>= 0.4.0'} - dependencies: - function-bind: 1.1.1 - dev: true - /hasbin@1.2.3: resolution: {integrity: sha512-CCd8e/w2w28G8DyZvKgiHnQJ/5XXDz6qiUHnthvtag/6T5acUeN5lqq+HMoBqcmgWueWDhiCplrw0Kb1zDACRg==} engines: {node: '>=0.10'} @@ -7140,7 +7000,7 @@ packages: engines: {node: '>=4'} dependencies: inherits: 2.0.4 - readable-stream: 3.6.0 + readable-stream: 3.6.2 safe-buffer: 5.2.1 dev: true @@ -7150,6 +7010,13 @@ packages: inherits: 2.0.4 minimalistic-assert: 1.0.1 + /hasown@2.0.1: + resolution: {integrity: sha512-1/th4MHjnwncwXsIW6QMzlvYL9kG5e/CpVvLRZe4XPa8TOUNbCELqmvhDmnkNsAjwaG4+I8gJJL0JBvTTLO9qA==} + engines: {node: '>= 0.4'} + dependencies: + function-bind: 1.1.2 + dev: true + /he@1.2.0: resolution: {integrity: sha512-F/1DnUGPopORZi0ni+CvrCgHQ5FyEAHRLSApuYWMmrbSwoN2Mn/7k+Gl38gJnR7yyDZk6WLXwiGod1JOWNDKGw==} hasBin: true @@ -7185,10 +7052,6 @@ packages: http-errors: 1.8.1 dev: false - /http-cache-semantics@4.1.1: - resolution: {integrity: sha512-er295DKPVsV82j5kw1Gjt+ADA/XYHsajl82cGNQG2eyoPkvgUhX+nDIyelzhIWbbsXP39EHcI6l5tYs2FYqYXQ==} - dev: false - /http-errors@1.8.1: resolution: {integrity: sha512-Kpk9Sm7NmI+RHhnj6OIWDI1d6fIoFAtFt9RLaTMRlg/8w49juAStsrBgp0Dp4OdxdVbRIeKhtCUvoi/RuAhO4g==} engines: {node: '>= 0.6'} @@ -7219,6 +7082,7 @@ packages: debug: 4.3.4(supports-color@8.1.1) transitivePeerDependencies: - supports-color + dev: true /https-proxy-agent@5.0.1: resolution: {integrity: sha512-dFcAjpTQFgoLMzC2VwU+C/CbS7uRL0lWmxDITmqm7C+7F0Odmj6s9l6alZc6AELXhrnggM2CeWSXHGOdX2YtwA==} @@ -7228,32 +7092,24 @@ packages: debug: 4.3.4(supports-color@8.1.1) transitivePeerDependencies: - supports-color + dev: true /human-id@1.0.2: resolution: {integrity: sha512-UNopramDEhHJD+VR+ehk8rOslwSfByxPIZyJRfV739NDhN5LF1fa1MqnzKm2lGTQRjNrjK19Q5fhkgIfjlVUKw==} dev: true - /human-signals@1.1.1: - resolution: {integrity: sha512-SEQu7vl8KjNL2eoGBLF3+wAjpsNfA9XMlXAYj/3EdaNfAlxKthD1xjEQfGOUhllCGGJVNY34bRr6lPINhNjyZw==} - engines: {node: '>=8.12.0'} - dev: true - /human-signals@2.1.0: resolution: {integrity: sha512-B4FFZ6q/T2jhhksgkbEW3HBvWIfDW85snkQgawt07S7J5QXTk6BkNV+0yAeZrM5QpMAdYlocGoljn0sJ/WQkFw==} engines: {node: '>=10.17.0'} - /human-signals@4.3.1: - resolution: {integrity: sha512-nZXjEF2nbo7lIw3mgYjItAfgQXog3OjJogSbKa2CQIIvSGWcKgeJnQlNXip6NglNzYH45nSRiEVimMvYL8DDqQ==} - engines: {node: '>=14.18.0'} - - /humanize-ms@1.2.1: - resolution: {integrity: sha512-Fl70vYtsAFb/C06PTS9dZBo7ihau+Tu/DNCk/OyHhea07S+aeMWpFFkUaXRa8fI+ScZbEI8dfSxwY7gxZ9SAVQ==} - dependencies: - ms: 2.1.3 - dev: false + /human-signals@5.0.0: + resolution: {integrity: sha512-AXcZb6vzzrFAUE61HnN4mpLqd/cSIwNQjtNWR0euPm6y0iqx3G4gOXaIDdtdDwZmhwe82LA6+zinmW4UBWVePQ==} + engines: {node: '>=16.17.0'} + dev: true - /husky@6.0.0: - resolution: {integrity: sha512-SQS2gDTB7tBN486QSoKPKQItZw97BMOd+Kdb6ghfpBc0yXyzrddI0oDV5MkDAbuB4X2mO3/nj60TRMcYxwzZeQ==} + /husky@9.0.11: + resolution: {integrity: sha512-AB6lFlbwwyIqMdHYhwPe+kjOC3Oc5P3nThEoW/AaO2BX3vJDjWPFxYLxokUZOo6RNX20He3AaT8sESs9NJcmEw==} + engines: {node: '>=18'} hasBin: true dev: true @@ -7268,9 +7124,11 @@ packages: engines: {node: '>=0.10.0'} dependencies: safer-buffer: 2.1.2 + dev: true /ieee754@1.2.1: resolution: {integrity: sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA==} + dev: false /iftype@3.0.2: resolution: {integrity: sha512-vA/NSyCG3E7XXWC1hmbEDj8WvsduSzLblmj4m2Idywx8YC6CKqGTYzrnoxbMrC+qBcHz85P7uwBwYEY2rX1jvQ==} @@ -7284,33 +7142,12 @@ packages: engines: {node: '>=8', npm: '>=5'} dev: false - /ignore@4.0.6: - resolution: {integrity: sha512-cyFDKrqc/YdcWFniJhzI42+AzS+gNwmUzOSFcRCQYwySuBBBy/KjuxWLZ/FHEH6Moq1NizMOBWyTcv8O4OZIMg==} - engines: {node: '>= 4'} - dev: true - - /ignore@5.2.4: - resolution: {integrity: sha512-MAb38BcSbH0eHNBxn7ql2NH/kX33OkB3lZ1BNdh7ENeRChHTYsTvWrMubiIAMNS2llXEEgZ1MUOBtXChP3kaFQ==} + /ignore@5.3.1: + resolution: {integrity: sha512-5Fytz/IraMjqpwfd34ke28PTVMjZjJG2MPn5t7OE4eUCUNf8BAa7b5WUS9/Qvr6mwOQS7Mk6vdsMno5he+T8Xw==} engines: {node: '>= 4'} - /immediate@3.2.3: - resolution: {integrity: sha512-RrGCXRm/fRVqMIhqXrGEX9rRADavPiDFSoMb/k64i9XMk8uH4r/Omi5Ctierj6XzNecwDbO4WuFbDD1zmpl3Tg==} - dev: true - - /immediate@3.3.0: - resolution: {integrity: sha512-HR7EVodfFUdQCTIeySw+WDRFJlPcLOJbXfwwZ7Oom6tjsvZ3bOkCDJHehQC3nxJrv7+f9XecwazynjU8e4Vw3Q==} - dev: true - - /immutable@4.3.0: - resolution: {integrity: sha512-0AOCmOip+xgJwEVTQj1EfiDDOkPmuyllDuTuEX+DDXUgapLAsBIfkg3sxCYyCEA8mQqZrrxPUGjcOQ2JS3WLkg==} - dev: true - - /import-fresh@2.0.0: - resolution: {integrity: sha512-eZ5H8rcgYazHbKC3PG4ClHNykCSxtAhxSSEM+2mb+7evD2CKF5V7c0dNum7AdpDh0ZdICwZY9sRSn8f+KH96sg==} - engines: {node: '>=4'} - dependencies: - caller-path: 2.0.0 - resolve-from: 3.0.0 + /immutable@4.3.5: + resolution: {integrity: sha512-8eabxkth9gZatlwl5TBuJnCsoTADlL6ftEr7A4qgdaTsPyreilDSnUk57SO+jfKcNtxPa22U5KK6DSeAYhpBJw==} dev: true /import-fresh@3.3.0: @@ -7333,19 +7170,12 @@ packages: /imurmurhash@0.1.4: resolution: {integrity: sha512-JmXMZ6wuvDmLiHEml9ykzqO6lwFbof0GG4IkcGaENdCRDDmMVnny7s5HsIgHCbaq0w2MyPhDqkhTUgS2LU2PHA==} engines: {node: '>=0.8.19'} - - /indent-string@3.2.0: - resolution: {integrity: sha512-BYqTHXTGUIvg7t1r4sJNKcbDZkL92nkXA8YtRpbjFHRHGDL/NtUeiBJMeE60kIFN/Mg8ESaWQvftaYMGJzQZCQ==} - engines: {node: '>=4'} dev: true /indent-string@4.0.0: resolution: {integrity: sha512-EdDDZu4A2OyIK7Lr/2zG+w5jmbuk1DVBnEwREQvBzspBJkCEbRa8GxU1lghYcaGJCnRWibjDXlq779X1/y5xwg==} engines: {node: '>=8'} - - /infer-owner@1.0.4: - resolution: {integrity: sha512-IClj+Xz94+d7irH5qRyfJonOdfTzuDaifE6ZPWfx0N0+/ATZCbuTPq2prFl526urkQd90WyUKIh1DfBQ2hMz9A==} - dev: false + dev: true /inflight@1.0.6: resolution: {integrity: sha512-k92I/b08q4wvFscXCLvqfsHCrjrF7yiXsQuIVvVE7N82W3+aqpzuUdBbfhWcy/FZR3/4IgflMgKLOsvPDrGCJA==} @@ -7364,25 +7194,6 @@ packages: resolution: {integrity: sha512-JV/yugV2uzW5iMRSiZAyDtQd+nxtUnjeLt0acNdw98kKLrvuRVyB80tsREOE7yvGVgalhZ6RNXCmEHkUKBKxew==} dev: false - /inquirer@6.5.2: - resolution: {integrity: sha512-cntlB5ghuB0iuO65Ovoi8ogLHiWGs/5yNrtUcKjFhSSiVeAIVpD7koaSU9RM8mpXw5YDi9RdYXGQMaOURB7ycQ==} - engines: {node: '>=6.0.0'} - dependencies: - ansi-escapes: 3.2.0 - chalk: 2.4.2 - cli-cursor: 2.1.0 - cli-width: 2.2.1 - external-editor: 3.1.0 - figures: 2.0.0 - lodash: 4.17.21 - mute-stream: 0.0.7 - run-async: 2.4.1 - rxjs: 6.6.7 - string-width: 2.1.1 - strip-ansi: 5.2.0 - through: 2.3.8 - dev: true - /inquirer@7.3.3: resolution: {integrity: sha512-JG3eIAj5V9CwcGvuOmoo6LB9kbAYT8HXffUl6memuszlwDC/qvFAJw49XJ5NROSFNPxp3iQg1GqkFhaY/CR0IA==} engines: {node: '>=8.0.0'} @@ -7402,13 +7213,13 @@ packages: through: 2.3.8 dev: false - /internal-slot@1.0.3: - resolution: {integrity: sha512-O0DB1JC/sPyZl7cIo78n5dR7eUSwwpYPiXRhTzNxZVAMUuB8vlnRFyLxdrVToks6XPLVnFfbzaVd5WLjhgg+vA==} + /internal-slot@1.0.7: + resolution: {integrity: sha512-NGnrKwXzSms2qUUih/ILZ5JBqNTSa1+ZmP6flaIp6KmSElgE9qdndzS3cqjrDovwFdmwsGsLdeFgB6suw+1e9g==} engines: {node: '>= 0.4'} dependencies: - get-intrinsic: 1.1.3 - has: 1.0.3 - side-channel: 1.0.4 + es-errors: 1.3.0 + hasown: 2.0.1 + side-channel: 1.0.6 dev: true /into-stream@6.0.0: @@ -7425,15 +7236,19 @@ packages: fp-ts: 1.19.3 dev: true - /ip@2.0.0: - resolution: {integrity: sha512-WKa+XuLG1A1R0UWhl2+1XQSi+fZWMsYKffMZTTYsiZaUD8k2yDAj5atimTUD2TZkyCkNEeYE5NhFZmupOGtjYQ==} - dev: false - /ipaddr.js@1.9.1: resolution: {integrity: sha512-0KI/607xoxSToH7GjN1FfSbLoU0+btTicjsQSWQlh/hZykN8KpmMf7uYwPW3R+akZ6R/w18ZlXSHBYXiYUPO3g==} engines: {node: '>= 0.10'} dev: false + /is-array-buffer@3.0.4: + resolution: {integrity: sha512-wcjaerHw0ydZwfhiKbXJWLDY8A7yV7KhjQOpb83hGgGfId/aQa4TOvwyzn2PuswW2gPCYEL/nEAiSVpdOj1lXw==} + engines: {node: '>= 0.4'} + dependencies: + call-bind: 1.0.7 + get-intrinsic: 1.2.4 + dev: true + /is-arrayish@0.2.1: resolution: {integrity: sha512-zz06S8t0ozoDXMG+ube26zeCTNXcKIPJZJi8hBrF4idCLms4CG9QtK7qBl1boi5ODzFpjswb5JPmHCbMpjaYzg==} dev: true @@ -7454,8 +7269,8 @@ packages: resolution: {integrity: sha512-gDYaKHJmnj4aWxyj6YHyXVpdQawtVLHU5cb+eztPGczf6cjuTdwve5ZIEfgXqH4e57An1D1AKf8CZ3kYrQRqYA==} engines: {node: '>= 0.4'} dependencies: - call-bind: 1.0.2 - has-tostringtag: 1.0.0 + call-bind: 1.0.7 + has-tostringtag: 1.0.2 dev: true /is-callable@1.2.7: @@ -7463,50 +7278,44 @@ packages: engines: {node: '>= 0.4'} dev: true - /is-ci@3.0.1: - resolution: {integrity: sha512-ZYvCgrefwqoQ6yTyYUbQu64HsITZ3NfKX1lzaEYdkTDcfKzzCI/wthRRYKkdjHKFVgNiXKAKm65Zo1pk2as/QQ==} - hasBin: true - dependencies: - ci-info: 3.8.0 - dev: true - - /is-core-module@2.12.0: - resolution: {integrity: sha512-RECHCBCd/viahWmwj6enj19sKbHfJrddi/6cBDsNTKbNq0f7VeaUkBo60BqzvPqo/W54ChS62Z5qyun7cfOMqQ==} + /is-core-module@2.13.1: + resolution: {integrity: sha512-hHrIjvZsftOsvKSn2TRYl63zvxsgE0K+0mYMoH6gD4omR5IWB2KynivBQczo3+wF1cCkjzvptnI9Q0sPU66ilw==} dependencies: - has: 1.0.3 + hasown: 2.0.1 dev: true /is-date-object@1.0.5: resolution: {integrity: sha512-9YQaSxsAiSwcvS33MBk3wTCVnWK+HhF8VZR2jRxehM16QcVOdHqPn4VPHmRK4lSr38n9JriurInLcP90xsYNfQ==} engines: {node: '>= 0.4'} dependencies: - has-tostringtag: 1.0.0 - dev: true - - /is-directory@0.3.1: - resolution: {integrity: sha512-yVChGzahRFvbkscn2MlwGismPO12i9+znNruC5gVEntG3qu0xQMzsGg/JFbrsqDOHtHFPci+V5aP5T9I+yeKqw==} - engines: {node: '>=0.10.0'} + has-tostringtag: 1.0.2 dev: true /is-extglob@2.1.1: resolution: {integrity: sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ==} engines: {node: '>=0.10.0'} - /is-fullwidth-code-point@1.0.0: - resolution: {integrity: sha512-1pqUqRjkhPJ9miNq9SwMfdvi6lBJcd6eFxvfaivQhaH3SgisfiuudvFntdKOmxuee/77l+FPjKrQjWvmPjWrRw==} - engines: {node: '>=0.10.0'} - dependencies: - number-is-nan: 1.0.1 - dev: true - /is-fullwidth-code-point@2.0.0: resolution: {integrity: sha512-VHskAKYM8RfSFXwee5t5cbN5PZeq1Wrh6qd5bkyiXIf6UQcN6w/A0eXM9r6t8d+GYOh+o6ZhiEnb88LN/Y8m2w==} engines: {node: '>=4'} + dev: false /is-fullwidth-code-point@3.0.0: resolution: {integrity: sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==} engines: {node: '>=8'} + /is-fullwidth-code-point@4.0.0: + resolution: {integrity: sha512-O4L094N2/dZ7xqVdrXhh9r1KODPJpFms8B5sGdJLPy664AgvXsreZUyCQQNItZRDlYug4xStLjNp/sz3HvBowQ==} + engines: {node: '>=12'} + dev: true + + /is-fullwidth-code-point@5.0.0: + resolution: {integrity: sha512-OVa3u9kkBbw7b8Xw5F9P+D/T9X+Z4+JruYVNapTjPYZYUznQ5YfWeFkOj606XYYW8yugTfC8Pj0hYqvi4ryAhA==} + engines: {node: '>=18'} + dependencies: + get-east-asian-width: 1.2.0 + dev: true + /is-generator-fn@2.1.0: resolution: {integrity: sha512-cTIB4yPYL/Grw0EaSzASzg6bBy9gqCofvWN8okThAYIxKJZC+udlRAmGbM0XLeniEJSs8uEgHPGuHSe1XsOLSQ==} engines: {node: '>=6'} @@ -7516,7 +7325,7 @@ packages: resolution: {integrity: sha512-jsEjy9l3yiXEQ+PsXdmBwEPcOxaXWLspKdplFUVI9vq1iZgIekeC0L167qeu86czQaxed3q/Uzuw0swL0irL8A==} engines: {node: '>= 0.4'} dependencies: - has-tostringtag: 1.0.0 + has-tostringtag: 1.0.2 dev: false /is-glob@4.0.3: @@ -7530,12 +7339,8 @@ packages: engines: {node: '>=6.5.0', npm: '>=3'} dev: true - /is-lambda@1.0.1: - resolution: {integrity: sha512-z7CMFGNrENq5iFB9Bqo64Xk6Y9sg+epq1myIcdHaGnbMTYOxvzsEtdYqQUylB7LxfkvgrrjP32T6Ywciio9UIQ==} - dev: false - - /is-negative-zero@2.0.2: - resolution: {integrity: sha512-dqJvarLawXsFbNDeJW7zAz8ItJ9cd28YufuuFzh0G8pNHjJMnY08Dv7sYX2uF5UpQOwieAeOExEYAWWfu7ZZUA==} + /is-negative-zero@2.0.3: + resolution: {integrity: sha512-5KoIu2Ngpyek75jXodFvnafB6DJgr3u8uuK0LEZJjrU19DrMD3EVERaR8sjz8CCGgpZvxPl9SuE1GMVPFHx1mw==} engines: {node: '>= 0.4'} dev: true @@ -7543,25 +7348,13 @@ packages: resolution: {integrity: sha512-k1U0IRzLMo7ZlYIfzRu23Oh6MiIFasgpb9X76eqfFZAqwH44UI4KTBvBYIZ1dSL9ZzChTB9ShHfLkR4pdW5krQ==} engines: {node: '>= 0.4'} dependencies: - has-tostringtag: 1.0.0 + has-tostringtag: 1.0.2 dev: true /is-number@7.0.0: resolution: {integrity: sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==} engines: {node: '>=0.12.0'} - /is-obj@1.0.1: - resolution: {integrity: sha512-l4RyHgRqGN4Y3+9JHVrNqO+tN0rV5My76uW5/nuO4K1b6vw5G8d/cmFjP9tRfEsdhZNt0IFdZuK/c2Vr4Nb+Qg==} - engines: {node: '>=0.10.0'} - dev: true - - /is-observable@1.1.0: - resolution: {integrity: sha512-NqCa4Sa2d+u7BWc6CukaObG3Fh+CU9bvixbpcXYhy2VvYS7vVGIdAgnIS5Ks3A/cqk4rebLJ9s8zBstT2aKnIA==} - engines: {node: '>=4'} - dependencies: - symbol-observable: 1.2.0 - dev: true - /is-path-inside@3.0.3: resolution: {integrity: sha512-Fd4gABb+ycGAmKou8eMftCupSir5lRxqf4aD/vd0cD2qc4HL07OjCeuHMr8Ro4CoMaeCKDB0/ECBOVWjTwUvPQ==} engines: {node: '>=8'} @@ -7583,29 +7376,21 @@ packages: /is-promise@2.2.2: resolution: {integrity: sha512-+lP4/6lKUBfQjZ2pdxThZvLUAafmZb8OAxFb8XXtiQmS35INgr85hdOGoEs124ez1FCnZJt6jau/T+alh58QFQ==} + dev: false /is-regex@1.1.4: resolution: {integrity: sha512-kvRdxDsxZjhzUX07ZnLydzS1TU/TJlTUHHY4YLL87e37oUA49DfkLqgy+VjFocowy29cKvcSiu+kIv728jTTVg==} engines: {node: '>= 0.4'} dependencies: - call-bind: 1.0.2 - has-tostringtag: 1.0.0 + call-bind: 1.0.7 + has-tostringtag: 1.0.2 dev: true - /is-regexp@1.0.0: - resolution: {integrity: sha512-7zjFAPO4/gwyQAAgRRmqeEeyIICSdmCqa3tsVHMdBzaXXRiqopZL4Cyghg/XulGWrtABTpbnYYzzIRffLkP4oA==} - engines: {node: '>=0.10.0'} - dev: true - - /is-shared-array-buffer@1.0.2: - resolution: {integrity: sha512-sqN2UDu1/0y6uvXyStCOzyhAjCSlHceFoMKJW8W9EU9cvic/QdsZ0kEU93HEy3IUEFZIiH/3w+AH/UQbPHNdhA==} + /is-shared-array-buffer@1.0.3: + resolution: {integrity: sha512-nA2hv5XIhLR3uVzDDfCIknerhx8XUKnstuOERPNNIinXG7v9u+ohXF67vxm4TPTEPU6lm61ZkwP3c9PCB97rhg==} + engines: {node: '>= 0.4'} dependencies: - call-bind: 1.0.2 - dev: true - - /is-stream@1.1.0: - resolution: {integrity: sha512-uQPm8kcs47jx38atAcWTVxyltQYoPT68y9aWYdV6yWXSyW8mzSat0TL6CiWdZeCdF3KrAvpVtnHbTv4RN+rqdQ==} - engines: {node: '>=0.10.0'} + call-bind: 1.0.7 dev: true /is-stream@2.0.1: @@ -7615,12 +7400,13 @@ packages: /is-stream@3.0.0: resolution: {integrity: sha512-LnQR4bZ9IADDRSkvpqMGvt/tEJWclzklNgSw48V5EAaAeDd6qGvN8ei6k5p0tvxSR171VmGyHuTiAOfxAbr8kA==} engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} + dev: true /is-string@1.0.7: resolution: {integrity: sha512-tE2UXzivje6ofPW7l23cjDOMa09gb7xlAqG6jG5ej6uPV32TlWP3NKPigtaGeHNu9fohccRYvIiZMfOOnOYUtg==} engines: {node: '>= 0.4'} dependencies: - has-tostringtag: 1.0.0 + has-tostringtag: 1.0.2 dev: true /is-subdir@1.2.0: @@ -7637,6 +7423,13 @@ packages: has-symbols: 1.0.3 dev: true + /is-typed-array@1.1.13: + resolution: {integrity: sha512-uZ25/bUAlUY5fR4OKT4rZQEBrzQWYV9ZJYGGsUmEJ6thodVJ1HX64ePQ6Z0qPWP+m+Uq6e9UugrE38jeYsDSMw==} + engines: {node: '>= 0.4'} + dependencies: + which-typed-array: 1.1.14 + dev: true + /is-unicode-supported@0.1.0: resolution: {integrity: sha512-knxG2q4UC3u8stRGyAVJCOdxFmv5DZiRcdlIaAQXAbSfJya+OhopNotLQrstBhququ4ZpuKbDc/8S6mgXgPFPw==} engines: {node: '>=10'} @@ -7649,11 +7442,11 @@ packages: /is-weakref@1.0.2: resolution: {integrity: sha512-qctsuLZmIQ0+vSSMfoVvyFe2+GSEvnmZ2ezTup1SBse9+twCCeial6EEi3Nc2KFcf6+qz2FBPnjXsk8xhKSaPQ==} dependencies: - call-bind: 1.0.2 + call-bind: 1.0.7 dev: true - /is-what@4.1.15: - resolution: {integrity: sha512-uKua1wfy3Yt+YqsD6mTUEa2zSi3G1oPlqTflgaPJ7z63vUGN5pxFpnQfeSLMFnJDEsdvOtkp1rUWkYjB4YfhgA==} + /is-what@4.1.16: + resolution: {integrity: sha512-ZhMwEosbFJkA0YhFnNDgTM4ZxDRsS6HqTo7qsZM08fehyRYIYa0yHu5R6mgo1n/8MgaPBXiPimPD77baVFYg+A==} engines: {node: '>=12.13'} dev: false @@ -7666,6 +7459,10 @@ packages: resolution: {integrity: sha512-VLghIWNM6ELQzo7zwmcg0NmTVyWKYjvIeM83yjp0wRDTmUnrM678fQbcKBo6n2CJEF0szoG//ytg+TKla89ALQ==} dev: false + /isarray@2.0.5: + resolution: {integrity: sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw==} + dev: true + /isexe@2.0.0: resolution: {integrity: sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==} @@ -7677,8 +7474,8 @@ packages: ws: 8.13.0 dev: false - /istanbul-lib-coverage@3.2.0: - resolution: {integrity: sha512-eOeJ5BHCmHYvQK7xt9GkdHuzuCGS1Y6g9Gvnx3Ym33fz/HpLRYxiS0wHNr+m/MBC8B647Xt608vCDEvhl9c6Mw==} + /istanbul-lib-coverage@3.2.2: + resolution: {integrity: sha512-O8dpsF+r0WV/8MNRKfnmrtCWhuKjxrq2w+jpzBL5UZKTi2LeVWnWOmWRxFlesJONmc+wLAGvKQZEOanko0LFTg==} engines: {node: '>=8'} dev: true @@ -7686,21 +7483,34 @@ packages: resolution: {integrity: sha512-pzqtp31nLv/XFOzXGuvhCb8qhjmTVo5vjVk19XE4CRlSWz0KoeJ3bw9XsA7nOp9YBf4qHjwBxkDzKcME/J29Yg==} engines: {node: '>=8'} dependencies: - '@babel/core': 7.21.4 - '@babel/parser': 7.21.4 + '@babel/core': 7.24.0 + '@babel/parser': 7.24.0 '@istanbuljs/schema': 0.1.3 - istanbul-lib-coverage: 3.2.0 - semver: 6.3.0 + istanbul-lib-coverage: 3.2.2 + semver: 6.3.1 transitivePeerDependencies: - supports-color dev: true - /istanbul-lib-report@3.0.0: - resolution: {integrity: sha512-wcdi+uAKzfiGT2abPpKZ0hSU1rGQjUQnLvtY5MpQ7QCTahD3VODhcu4wcfY1YtkGaDD5yuydOLINXsfbus9ROw==} - engines: {node: '>=8'} + /istanbul-lib-instrument@6.0.2: + resolution: {integrity: sha512-1WUsZ9R1lA0HtBSohTkm39WTPlNKSJ5iFk7UwqXkBLoHQT+hfqPsfsTDVuZdKGaBwn7din9bS7SsnoAr943hvw==} + engines: {node: '>=10'} dependencies: - istanbul-lib-coverage: 3.2.0 - make-dir: 3.1.0 + '@babel/core': 7.24.0 + '@babel/parser': 7.24.0 + '@istanbuljs/schema': 0.1.3 + istanbul-lib-coverage: 3.2.2 + semver: 7.6.0 + transitivePeerDependencies: + - supports-color + dev: true + + /istanbul-lib-report@3.0.1: + resolution: {integrity: sha512-GCfE1mtsHGOELCU8e/Z7YWzpmybrx/+dSTfLrvY8qRmaY6zXTKWn6WQIjaAFw069icm6GVMNkgu0NzI4iPZUNw==} + engines: {node: '>=10'} + dependencies: + istanbul-lib-coverage: 3.2.2 + make-dir: 4.0.0 supports-color: 7.2.0 dev: true @@ -7709,68 +7519,79 @@ packages: engines: {node: '>=10'} dependencies: debug: 4.3.4(supports-color@8.1.1) - istanbul-lib-coverage: 3.2.0 + istanbul-lib-coverage: 3.2.2 source-map: 0.6.1 transitivePeerDependencies: - supports-color dev: true - /istanbul-reports@3.1.5: - resolution: {integrity: sha512-nUsEMa9pBt/NOHqbcbeJEgqIlY/K7rVWUX6Lql2orY5e9roQOthbR3vtY4zzf2orPELg80fnxxk9zUyPlgwD1w==} + /istanbul-reports@3.1.7: + resolution: {integrity: sha512-BewmUXImeuRk2YY0PVbxgKAysvhRPUQE0h5QRM++nVWyubKGV0l8qQ5op8+B2DOmwSe63Jivj0BjkPQVf8fP5g==} engines: {node: '>=8'} dependencies: html-escaper: 2.0.2 - istanbul-lib-report: 3.0.0 + istanbul-lib-report: 3.0.1 dev: true - /jake@10.8.5: - resolution: {integrity: sha512-sVpxYeuAhWt0OTWITwT98oyV0GsXyMlXCF+3L1SuafBVUIr/uILGRB+NqwkzhgXKvoJpDIpQvqkUALgdmQsQxw==} + /jackspeak@2.3.6: + resolution: {integrity: sha512-N3yCS/NegsOBokc8GAdM8UcmfsKiSS8cipheD/nivzr700H+nsMOxJjQnvwOcRYVuFkdH0wGUvW2WbXGmrZGbQ==} + engines: {node: '>=14'} + dependencies: + '@isaacs/cliui': 8.0.2 + optionalDependencies: + '@pkgjs/parseargs': 0.11.0 + dev: true + + /jake@10.8.7: + resolution: {integrity: sha512-ZDi3aP+fG/LchyBzUM804VjddnwfSfsdeYkwt8NcbKRvo4rFkjhs456iLFn3k2ZUWvNe4i48WACDbza8fhq2+w==} engines: {node: '>=10'} hasBin: true dependencies: - async: 3.2.4 + async: 3.2.5 chalk: 4.1.2 filelist: 1.0.4 minimatch: 3.1.2 - /jest-changed-files@29.5.0: - resolution: {integrity: sha512-IFG34IUMUaNBIxjQXF/iu7g6EcdMrGRRxaUSw92I/2g2YC6vCdTltl4nHvt7Ci5nSJwXIkCu8Ka1DKF+X7Z1Ag==} + /jest-changed-files@29.7.0: + resolution: {integrity: sha512-fEArFiwf1BpQ+4bXSprcDc3/x4HSzL4al2tozwVpDFpsxALjLYdyiIK4e5Vz66GQJIbXJ82+35PtysofptNX2w==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} dependencies: execa: 5.1.1 + jest-util: 29.7.0 p-limit: 3.1.0 dev: true - /jest-circus@29.5.0: - resolution: {integrity: sha512-gq/ongqeQKAplVxqJmbeUOJJKkW3dDNPY8PjhJ5G0lBRvu0e3EWGxGy5cI4LAGA7gV2UHCtWBI4EMXK8c9nQKA==} + /jest-circus@29.7.0: + resolution: {integrity: sha512-3E1nCMgipcTkCocFwM90XXQab9bS+GMsjdpmPrlelaxwD93Ad8iVEjX/vvHPdLPnFf+L40u+5+iutRdA1N9myw==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} dependencies: - '@jest/environment': 29.5.0 - '@jest/expect': 29.5.0 - '@jest/test-result': 29.5.0 - '@jest/types': 29.5.0 - '@types/node': 18.15.11 + '@jest/environment': 29.7.0 + '@jest/expect': 29.7.0 + '@jest/test-result': 29.7.0 + '@jest/types': 29.6.3 + '@types/node': 18.19.21 chalk: 4.1.2 co: 4.6.0 - dedent: 0.7.0 + dedent: 1.5.1 is-generator-fn: 2.1.0 - jest-each: 29.5.0 - jest-matcher-utils: 29.5.0 - jest-message-util: 29.5.0 - jest-runtime: 29.5.0 - jest-snapshot: 29.5.0 - jest-util: 29.5.0 + jest-each: 29.7.0 + jest-matcher-utils: 29.7.0 + jest-message-util: 29.7.0 + jest-runtime: 29.7.0 + jest-snapshot: 29.7.0 + jest-util: 29.7.0 p-limit: 3.1.0 - pretty-format: 29.5.0 - pure-rand: 6.0.1 + pretty-format: 29.7.0 + pure-rand: 6.0.4 slash: 3.0.0 stack-utils: 2.0.6 transitivePeerDependencies: + - babel-plugin-macros - supports-color dev: true - /jest-cli@29.5.0(@types/node@18.15.11): - resolution: {integrity: sha512-L1KcP1l4HtfwdxXNFCL5bmUbLQiKrakMUriBEcc1Vfz6gx31ORKdreuWvmQVBit+1ss9NNR3yxjwfwzZNdQXJw==} + /jest-cli@29.7.0(@types/node@18.19.21): + resolution: {integrity: sha512-OVVobw2IubN/GSYsxETi+gOe7Ka59EFMR/twOU3Jb2GnKKeMGJB5SGUUrEz3SFVmJASUdZUzy83sLNNQ2gZslg==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} hasBin: true peerDependencies: @@ -7779,26 +7600,26 @@ packages: node-notifier: optional: true dependencies: - '@jest/core': 29.5.0 - '@jest/test-result': 29.5.0 - '@jest/types': 29.5.0 + '@jest/core': 29.7.0 + '@jest/test-result': 29.7.0 + '@jest/types': 29.6.3 chalk: 4.1.2 + create-jest: 29.7.0(@types/node@18.19.21) exit: 0.1.2 - graceful-fs: 4.2.11 import-local: 3.1.0 - jest-config: 29.5.0(@types/node@18.15.11) - jest-util: 29.5.0 - jest-validate: 29.5.0 - prompts: 2.4.2 + jest-config: 29.7.0(@types/node@18.19.21) + jest-util: 29.7.0 + jest-validate: 29.7.0 yargs: 17.7.2 transitivePeerDependencies: - '@types/node' + - babel-plugin-macros - supports-color - ts-node dev: true - /jest-config@29.5.0(@types/node@18.15.11): - resolution: {integrity: sha512-kvDUKBnNJPNBmFFOhDbm59iu1Fii1Q6SxyhXfvylq3UTHbg6o7j/g8k2dZyXWLvfdKB1vAPxNZnMgtKJcmu3kA==} + /jest-config@29.7.0(@types/node@18.19.21): + resolution: {integrity: sha512-uXbpfeQ7R6TZBqI3/TxCU4q4ttk3u0PJeC+E0zbfSoSjq6bJ7buBPxzQPL0ifrkY4DNu4JUdk0ImlBUYi840eQ==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} peerDependencies: '@types/node': '*' @@ -7809,30 +7630,31 @@ packages: ts-node: optional: true dependencies: - '@babel/core': 7.21.4 - '@jest/test-sequencer': 29.5.0 - '@jest/types': 29.5.0 - '@types/node': 18.15.11 - babel-jest: 29.5.0(@babel/core@7.21.4) + '@babel/core': 7.24.0 + '@jest/test-sequencer': 29.7.0 + '@jest/types': 29.6.3 + '@types/node': 18.19.21 + babel-jest: 29.7.0(@babel/core@7.24.0) chalk: 4.1.2 - ci-info: 3.8.0 + ci-info: 3.9.0 deepmerge: 4.3.1 glob: 7.2.3 graceful-fs: 4.2.11 - jest-circus: 29.5.0 - jest-environment-node: 29.5.0 - jest-get-type: 29.4.3 - jest-regex-util: 29.4.3 - jest-resolve: 29.5.0 - jest-runner: 29.5.0 - jest-util: 29.5.0 - jest-validate: 29.5.0 + jest-circus: 29.7.0 + jest-environment-node: 29.7.0 + jest-get-type: 29.6.3 + jest-regex-util: 29.6.3 + jest-resolve: 29.7.0 + jest-runner: 29.7.0 + jest-util: 29.7.0 + jest-validate: 29.7.0 micromatch: 4.0.5 parse-json: 5.2.0 - pretty-format: 29.5.0 + pretty-format: 29.7.0 slash: 3.0.0 strip-json-comments: 3.1.1 transitivePeerDependencies: + - babel-plugin-macros - supports-color dev: true @@ -7846,44 +7668,44 @@ packages: pretty-format: 27.5.1 dev: true - /jest-diff@29.5.0: - resolution: {integrity: sha512-LtxijLLZBduXnHSniy0WMdaHjmQnt3g5sa16W4p0HqukYTTsyTW3GD1q41TyGl5YFXj/5B2U6dlh5FM1LIMgxw==} + /jest-diff@29.7.0: + resolution: {integrity: sha512-LMIgiIrhigmPrs03JHpxUh2yISK3vLFPkAodPeo0+BuF7wA2FoQbkEg1u8gBYBThncu7e1oEDUfIXVuTqLRUjw==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} dependencies: chalk: 4.1.2 diff-sequences: 29.6.3 - jest-get-type: 29.4.3 - pretty-format: 29.5.0 + jest-get-type: 29.6.3 + pretty-format: 29.7.0 dev: true - /jest-docblock@29.4.3: - resolution: {integrity: sha512-fzdTftThczeSD9nZ3fzA/4KkHtnmllawWrXO69vtI+L9WjEIuXWs4AmyME7lN5hU7dB0sHhuPfcKofRsUb/2Fg==} + /jest-docblock@29.7.0: + resolution: {integrity: sha512-q617Auw3A612guyaFgsbFeYpNP5t2aoUNLwBUbc/0kD1R4t9ixDbyFTHd1nok4epoVFpr7PmeWHrhvuV3XaJ4g==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} dependencies: detect-newline: 3.1.0 dev: true - /jest-each@29.5.0: - resolution: {integrity: sha512-HM5kIJ1BTnVt+DQZ2ALp3rzXEl+g726csObrW/jpEGl+CDSSQpOJJX2KE/vEg8cxcMXdyEPu6U4QX5eruQv5hA==} + /jest-each@29.7.0: + resolution: {integrity: sha512-gns+Er14+ZrEoC5fhOfYCY1LOHHr0TI+rQUHZS8Ttw2l7gl+80eHc/gFf2Ktkw0+SIACDTeWvpFcv3B04VembQ==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} dependencies: - '@jest/types': 29.5.0 + '@jest/types': 29.6.3 chalk: 4.1.2 - jest-get-type: 29.4.3 - jest-util: 29.5.0 - pretty-format: 29.5.0 + jest-get-type: 29.6.3 + jest-util: 29.7.0 + pretty-format: 29.7.0 dev: true - /jest-environment-node@29.5.0: - resolution: {integrity: sha512-ExxuIK/+yQ+6PRGaHkKewYtg6hto2uGCgvKdb2nfJfKXgZ17DfXjvbZ+jA1Qt9A8EQSfPnt5FKIfnOO3u1h9qw==} + /jest-environment-node@29.7.0: + resolution: {integrity: sha512-DOSwCRqXirTOyheM+4d5YZOrWcdu0LNZ87ewUoywbcb2XR4wKgqiG8vNeYwhjFMbEkfju7wx2GYH0P2gevGvFw==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} dependencies: - '@jest/environment': 29.5.0 - '@jest/fake-timers': 29.5.0 - '@jest/types': 29.5.0 - '@types/node': 18.15.11 - jest-mock: 29.5.0 - jest-util: 29.5.0 + '@jest/environment': 29.7.0 + '@jest/fake-timers': 29.7.0 + '@jest/types': 29.6.3 + '@types/node': 18.19.21 + jest-mock: 29.7.0 + jest-util: 29.7.0 dev: true /jest-get-type@27.5.1: @@ -7891,36 +7713,36 @@ packages: engines: {node: ^10.13.0 || ^12.13.0 || ^14.15.0 || >=15.0.0} dev: true - /jest-get-type@29.4.3: - resolution: {integrity: sha512-J5Xez4nRRMjk8emnTpWrlkyb9pfRQQanDrvWHhsR1+VUfbwxi30eVcZFlcdGInRibU4G5LwHXpI7IRHU0CY+gg==} + /jest-get-type@29.6.3: + resolution: {integrity: sha512-zrteXnqYxfQh7l5FHyL38jL39di8H8rHoecLH3JNxH3BwOrBsNeabdap5e0I23lD4HHI8W5VFBZqG4Eaq5LNcw==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} dev: true - /jest-haste-map@29.5.0: - resolution: {integrity: sha512-IspOPnnBro8YfVYSw6yDRKh/TiCdRngjxeacCps1cQ9cgVN6+10JUcuJ1EabrgYLOATsIAigxA0rLR9x/YlrSA==} + /jest-haste-map@29.7.0: + resolution: {integrity: sha512-fP8u2pyfqx0K1rGn1R9pyE0/KTn+G7PxktWidOBTqFPLYX0b9ksaMFkhK5vrS3DVun09pckLdlx90QthlW7AmA==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} dependencies: - '@jest/types': 29.5.0 - '@types/graceful-fs': 4.1.6 - '@types/node': 18.15.11 + '@jest/types': 29.6.3 + '@types/graceful-fs': 4.1.9 + '@types/node': 18.19.21 anymatch: 3.1.3 fb-watchman: 2.0.2 graceful-fs: 4.2.11 - jest-regex-util: 29.4.3 - jest-util: 29.5.0 - jest-worker: 29.5.0 + jest-regex-util: 29.6.3 + jest-util: 29.7.0 + jest-worker: 29.7.0 micromatch: 4.0.5 walker: 1.0.8 optionalDependencies: fsevents: 2.3.3 dev: true - /jest-leak-detector@29.5.0: - resolution: {integrity: sha512-u9YdeeVnghBUtpN5mVxjID7KbkKE1QU4f6uUwuxiY0vYRi9BUCLKlPEZfDGR67ofdFmDz9oPAy2G92Ujrntmow==} + /jest-leak-detector@29.7.0: + resolution: {integrity: sha512-kYA8IJcSYtST2BY9I+SMC32nDpBT3J2NvWJx8+JCuCdl/CR1I4EKUJROiP8XtCcxqgTTBGJNdbB1A8XRKbTetw==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} dependencies: - jest-get-type: 29.4.3 - pretty-format: 29.5.0 + jest-get-type: 29.6.3 + pretty-format: 29.7.0 dev: true /jest-matcher-utils@27.5.1: @@ -7933,41 +7755,41 @@ packages: pretty-format: 27.5.1 dev: true - /jest-matcher-utils@29.5.0: - resolution: {integrity: sha512-lecRtgm/rjIK0CQ7LPQwzCs2VwW6WAahA55YBuI+xqmhm7LAaxokSB8C97yJeYyT+HvQkH741StzpU41wohhWw==} + /jest-matcher-utils@29.7.0: + resolution: {integrity: sha512-sBkD+Xi9DtcChsI3L3u0+N0opgPYnCRPtGcQYrgXmR+hmt/fYfWAL0xRXYU8eWOdfuLgBe0YCW3AFtnRLagq/g==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} dependencies: chalk: 4.1.2 - jest-diff: 29.5.0 - jest-get-type: 29.4.3 - pretty-format: 29.5.0 + jest-diff: 29.7.0 + jest-get-type: 29.6.3 + pretty-format: 29.7.0 dev: true - /jest-message-util@29.5.0: - resolution: {integrity: sha512-Kijeg9Dag6CKtIDA7O21zNTACqD5MD/8HfIV8pdD94vFyFuer52SigdC3IQMhab3vACxXMiFk+yMHNdbqtyTGA==} + /jest-message-util@29.7.0: + resolution: {integrity: sha512-GBEV4GRADeP+qtB2+6u61stea8mGcOT4mCtrYISZwfu9/ISHFJ/5zOMXYbpBE9RsS5+Gb63DW4FgmnKJ79Kf6w==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} dependencies: - '@babel/code-frame': 7.21.4 - '@jest/types': 29.5.0 - '@types/stack-utils': 2.0.1 + '@babel/code-frame': 7.23.5 + '@jest/types': 29.6.3 + '@types/stack-utils': 2.0.3 chalk: 4.1.2 graceful-fs: 4.2.11 micromatch: 4.0.5 - pretty-format: 29.5.0 + pretty-format: 29.7.0 slash: 3.0.0 stack-utils: 2.0.6 dev: true - /jest-mock@29.5.0: - resolution: {integrity: sha512-GqOzvdWDE4fAV2bWQLQCkujxYWL7RxjCnj71b5VhDAGOevB3qj3Ovg26A5NI84ZpODxyzaozXLOh2NCgkbvyaw==} + /jest-mock@29.7.0: + resolution: {integrity: sha512-ITOMZn+UkYS4ZFh83xYAOzWStloNzJFO2s8DWrE4lhtGD+AorgnbkiKERe4wQVBydIGPx059g6riW5Btp6Llnw==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} dependencies: - '@jest/types': 29.5.0 - '@types/node': 18.15.11 - jest-util: 29.5.0 + '@jest/types': 29.6.3 + '@types/node': 18.19.21 + jest-util: 29.7.0 dev: true - /jest-pnp-resolver@1.2.3(jest-resolve@29.5.0): + /jest-pnp-resolver@1.2.3(jest-resolve@29.7.0): resolution: {integrity: sha512-+3NpwQEnRoIBtx4fyhblQDPgJI0H1IEIkX7ShLUjPGA7TtUTvI1oiKi3SR4oBR0hQhQR80l4WAe5RrXBwWMA8w==} engines: {node: '>=6'} peerDependencies: @@ -7976,179 +7798,176 @@ packages: jest-resolve: optional: true dependencies: - jest-resolve: 29.5.0 + jest-resolve: 29.7.0 dev: true - /jest-regex-util@29.4.3: - resolution: {integrity: sha512-O4FglZaMmWXbGHSQInfXewIsd1LMn9p3ZXB/6r4FOkyhX2/iP/soMG98jGvk/A3HAN78+5VWcBGO0BJAPRh4kg==} + /jest-regex-util@29.6.3: + resolution: {integrity: sha512-KJJBsRCyyLNWCNBOvZyRDnAIfUiRJ8v+hOBQYGn8gDyF3UegwiP4gwRR3/SDa42g1YbVycTidUF3rKjyLFDWbg==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} dev: true - /jest-resolve-dependencies@29.5.0: - resolution: {integrity: sha512-sjV3GFr0hDJMBpYeUuGduP+YeCRbd7S/ck6IvL3kQ9cpySYKqcqhdLLC2rFwrcL7tz5vYibomBrsFYWkIGGjOg==} + /jest-resolve-dependencies@29.7.0: + resolution: {integrity: sha512-un0zD/6qxJ+S0et7WxeI3H5XSe9lTBBR7bOHCHXkKR6luG5mwDDlIzVQ0V5cZCuoTgEdcdwzTghYkTWfubi+nA==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} dependencies: - jest-regex-util: 29.4.3 - jest-snapshot: 29.5.0 + jest-regex-util: 29.6.3 + jest-snapshot: 29.7.0 transitivePeerDependencies: - supports-color dev: true - /jest-resolve@29.5.0: - resolution: {integrity: sha512-1TzxJ37FQq7J10jPtQjcc+MkCkE3GBpBecsSUWJ0qZNJpmg6m0D9/7II03yJulm3H/fvVjgqLh/k2eYg+ui52w==} + /jest-resolve@29.7.0: + resolution: {integrity: sha512-IOVhZSrg+UvVAshDSDtHyFCCBUl/Q3AAJv8iZ6ZjnZ74xzvwuzLXid9IIIPgTnY62SJjfuupMKZsZQRsCvxEgA==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} dependencies: chalk: 4.1.2 graceful-fs: 4.2.11 - jest-haste-map: 29.5.0 - jest-pnp-resolver: 1.2.3(jest-resolve@29.5.0) - jest-util: 29.5.0 - jest-validate: 29.5.0 - resolve: 1.22.2 + jest-haste-map: 29.7.0 + jest-pnp-resolver: 1.2.3(jest-resolve@29.7.0) + jest-util: 29.7.0 + jest-validate: 29.7.0 + resolve: 1.22.8 resolve.exports: 2.0.2 slash: 3.0.0 dev: true - /jest-runner@29.5.0: - resolution: {integrity: sha512-m7b6ypERhFghJsslMLhydaXBiLf7+jXy8FwGRHO3BGV1mcQpPbwiqiKUR2zU2NJuNeMenJmlFZCsIqzJCTeGLQ==} + /jest-runner@29.7.0: + resolution: {integrity: sha512-fsc4N6cPCAahybGBfTRcq5wFR6fpLznMg47sY5aDpsoejOcVYFb07AHuSnR0liMcPTgBsA3ZJL6kFOjPdoNipQ==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} dependencies: - '@jest/console': 29.5.0 - '@jest/environment': 29.5.0 - '@jest/test-result': 29.5.0 - '@jest/transform': 29.5.0 - '@jest/types': 29.5.0 - '@types/node': 18.15.11 + '@jest/console': 29.7.0 + '@jest/environment': 29.7.0 + '@jest/test-result': 29.7.0 + '@jest/transform': 29.7.0 + '@jest/types': 29.6.3 + '@types/node': 18.19.21 chalk: 4.1.2 emittery: 0.13.1 graceful-fs: 4.2.11 - jest-docblock: 29.4.3 - jest-environment-node: 29.5.0 - jest-haste-map: 29.5.0 - jest-leak-detector: 29.5.0 - jest-message-util: 29.5.0 - jest-resolve: 29.5.0 - jest-runtime: 29.5.0 - jest-util: 29.5.0 - jest-watcher: 29.5.0 - jest-worker: 29.5.0 + jest-docblock: 29.7.0 + jest-environment-node: 29.7.0 + jest-haste-map: 29.7.0 + jest-leak-detector: 29.7.0 + jest-message-util: 29.7.0 + jest-resolve: 29.7.0 + jest-runtime: 29.7.0 + jest-util: 29.7.0 + jest-watcher: 29.7.0 + jest-worker: 29.7.0 p-limit: 3.1.0 source-map-support: 0.5.13 transitivePeerDependencies: - supports-color dev: true - /jest-runtime@29.5.0: - resolution: {integrity: sha512-1Hr6Hh7bAgXQP+pln3homOiEZtCDZFqwmle7Ew2j8OlbkIu6uE3Y/etJQG8MLQs3Zy90xrp2C0BRrtPHG4zryw==} + /jest-runtime@29.7.0: + resolution: {integrity: sha512-gUnLjgwdGqW7B4LvOIkbKs9WGbn+QLqRQQ9juC6HndeDiezIwhDP+mhMwHWCEcfQ5RUXa6OPnFF8BJh5xegwwQ==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} dependencies: - '@jest/environment': 29.5.0 - '@jest/fake-timers': 29.5.0 - '@jest/globals': 29.5.0 - '@jest/source-map': 29.4.3 - '@jest/test-result': 29.5.0 - '@jest/transform': 29.5.0 - '@jest/types': 29.5.0 - '@types/node': 18.15.11 + '@jest/environment': 29.7.0 + '@jest/fake-timers': 29.7.0 + '@jest/globals': 29.7.0 + '@jest/source-map': 29.6.3 + '@jest/test-result': 29.7.0 + '@jest/transform': 29.7.0 + '@jest/types': 29.6.3 + '@types/node': 18.19.21 chalk: 4.1.2 - cjs-module-lexer: 1.2.2 - collect-v8-coverage: 1.0.1 + cjs-module-lexer: 1.2.3 + collect-v8-coverage: 1.0.2 glob: 7.2.3 graceful-fs: 4.2.11 - jest-haste-map: 29.5.0 - jest-message-util: 29.5.0 - jest-mock: 29.5.0 - jest-regex-util: 29.4.3 - jest-resolve: 29.5.0 - jest-snapshot: 29.5.0 - jest-util: 29.5.0 + jest-haste-map: 29.7.0 + jest-message-util: 29.7.0 + jest-mock: 29.7.0 + jest-regex-util: 29.6.3 + jest-resolve: 29.7.0 + jest-snapshot: 29.7.0 + jest-util: 29.7.0 slash: 3.0.0 strip-bom: 4.0.0 transitivePeerDependencies: - supports-color dev: true - /jest-snapshot@29.5.0: - resolution: {integrity: sha512-x7Wolra5V0tt3wRs3/ts3S6ciSQVypgGQlJpz2rsdQYoUKxMxPNaoHMGJN6qAuPJqS+2iQ1ZUn5kl7HCyls84g==} + /jest-snapshot@29.7.0: + resolution: {integrity: sha512-Rm0BMWtxBcioHr1/OX5YCP8Uov4riHvKPknOGs804Zg9JGZgmIBkbtlxJC/7Z4msKYVbIJtfU+tKb8xlYNfdkw==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} dependencies: - '@babel/core': 7.21.4 - '@babel/generator': 7.21.4 - '@babel/plugin-syntax-jsx': 7.18.6(@babel/core@7.21.4) - '@babel/plugin-syntax-typescript': 7.20.0(@babel/core@7.21.4) - '@babel/traverse': 7.21.4 - '@babel/types': 7.21.4 - '@jest/expect-utils': 29.5.0 - '@jest/transform': 29.5.0 - '@jest/types': 29.5.0 - '@types/babel__traverse': 7.18.3 - '@types/prettier': 2.7.2 - babel-preset-current-node-syntax: 1.0.1(@babel/core@7.21.4) + '@babel/core': 7.24.0 + '@babel/generator': 7.23.6 + '@babel/plugin-syntax-jsx': 7.23.3(@babel/core@7.24.0) + '@babel/plugin-syntax-typescript': 7.23.3(@babel/core@7.24.0) + '@babel/types': 7.24.0 + '@jest/expect-utils': 29.7.0 + '@jest/transform': 29.7.0 + '@jest/types': 29.6.3 + babel-preset-current-node-syntax: 1.0.1(@babel/core@7.24.0) chalk: 4.1.2 - expect: 29.5.0 + expect: 29.7.0 graceful-fs: 4.2.11 - jest-diff: 29.5.0 - jest-get-type: 29.4.3 - jest-matcher-utils: 29.5.0 - jest-message-util: 29.5.0 - jest-util: 29.5.0 + jest-diff: 29.7.0 + jest-get-type: 29.6.3 + jest-matcher-utils: 29.7.0 + jest-message-util: 29.7.0 + jest-util: 29.7.0 natural-compare: 1.4.0 - pretty-format: 29.5.0 - semver: 7.5.0 + pretty-format: 29.7.0 + semver: 7.6.0 transitivePeerDependencies: - supports-color dev: true - /jest-util@29.5.0: - resolution: {integrity: sha512-RYMgG/MTadOr5t8KdhejfvUU82MxsCu5MF6KuDUHl+NuwzUt+Sm6jJWxTJVrDR1j5M/gJVCPKQEpWXY+yIQ6lQ==} + /jest-util@29.7.0: + resolution: {integrity: sha512-z6EbKajIpqGKU56y5KBUgy1dt1ihhQJgWzUlZHArA/+X2ad7Cb5iF+AK1EWVL/Bo7Rz9uurpqw6SiBCefUbCGA==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} dependencies: - '@jest/types': 29.5.0 - '@types/node': 18.15.11 + '@jest/types': 29.6.3 + '@types/node': 18.19.21 chalk: 4.1.2 - ci-info: 3.8.0 + ci-info: 3.9.0 graceful-fs: 4.2.11 picomatch: 2.3.1 dev: true - /jest-validate@29.5.0: - resolution: {integrity: sha512-pC26etNIi+y3HV8A+tUGr/lph9B18GnzSRAkPaaZJIE1eFdiYm6/CewuiJQ8/RlfHd1u/8Ioi8/sJ+CmbA+zAQ==} + /jest-validate@29.7.0: + resolution: {integrity: sha512-ZB7wHqaRGVw/9hST/OuFUReG7M8vKeq0/J2egIGLdvjHCmYqGARhzXmtgi+gVeZ5uXFF219aOc3Ls2yLg27tkw==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} dependencies: - '@jest/types': 29.5.0 + '@jest/types': 29.6.3 camelcase: 6.3.0 chalk: 4.1.2 - jest-get-type: 29.4.3 + jest-get-type: 29.6.3 leven: 3.1.0 - pretty-format: 29.5.0 + pretty-format: 29.7.0 dev: true - /jest-watcher@29.5.0: - resolution: {integrity: sha512-KmTojKcapuqYrKDpRwfqcQ3zjMlwu27SYext9pt4GlF5FUgB+7XE1mcCnSm6a4uUpFyQIkb6ZhzZvHl+jiBCiA==} + /jest-watcher@29.7.0: + resolution: {integrity: sha512-49Fg7WXkU3Vl2h6LbLtMQ/HyB6rXSIX7SqvBLQmssRBGN9I0PNvPmAmCWSOY6SOvrjhI/F7/bGAv9RtnsPA03g==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} dependencies: - '@jest/test-result': 29.5.0 - '@jest/types': 29.5.0 - '@types/node': 18.15.11 + '@jest/test-result': 29.7.0 + '@jest/types': 29.6.3 + '@types/node': 18.19.21 ansi-escapes: 4.3.2 chalk: 4.1.2 emittery: 0.13.1 - jest-util: 29.5.0 + jest-util: 29.7.0 string-length: 4.0.2 dev: true - /jest-worker@29.5.0: - resolution: {integrity: sha512-NcrQnevGoSp4b5kg+akIpthoAFHxPBcb5P6mYPY0fUNT+sSvmtu6jlkEle3anczUKIKEbMxFimk9oTP/tpIPgA==} + /jest-worker@29.7.0: + resolution: {integrity: sha512-eIz2msL/EzL9UFTFFx7jBTkeZfku0yUAyZZZmJ93H2TYEiroIx2PQjEXcwYtYl8zXCxb+PAmA2hLIt/6ZEkPHw==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} dependencies: - '@types/node': 18.15.11 - jest-util: 29.5.0 + '@types/node': 18.19.21 + jest-util: 29.7.0 merge-stream: 2.0.0 supports-color: 8.1.1 dev: true - /jest@29.5.0(@types/node@18.15.11): - resolution: {integrity: sha512-juMg3he2uru1QoXX078zTa7pO85QyB9xajZc6bU+d9yEGwrKX6+vGmJQ3UdVZsvTEUARIdObzH68QItim6OSSQ==} + /jest@29.7.0(@types/node@18.19.21): + resolution: {integrity: sha512-NIy3oAFp9shda19hy4HK0HRTWKtPJmGdnvywu01nOqNC2vZg+Z+fvJDxpMQA88eb2I9EcafcdjYgsDthnYTvGw==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} hasBin: true peerDependencies: @@ -8157,18 +7976,19 @@ packages: node-notifier: optional: true dependencies: - '@jest/core': 29.5.0 - '@jest/types': 29.5.0 + '@jest/core': 29.7.0 + '@jest/types': 29.6.3 import-local: 3.1.0 - jest-cli: 29.5.0(@types/node@18.15.11) + jest-cli: 29.7.0(@types/node@18.19.21) transitivePeerDependencies: - '@types/node' + - babel-plugin-macros - supports-color - ts-node dev: true - /jiti@1.18.2: - resolution: {integrity: sha512-QAdOptna2NYiSSpv0O/BwoHBSmz4YhpzJHyi+fnMRTXFjp7B8i/YG5Z8IfusxB1ufjcD2Sre1F3R+nX3fvy7gg==} + /jiti@1.21.0: + resolution: {integrity: sha512-gFqAIbuKyyso/3G2qhiO2OM6shY6EPP/R0+mkDbyspxKazh8BXDC5FiFsUjlczgdNz/vfra0da2y+aHrusLG/Q==} hasBin: true dev: true @@ -8177,12 +7997,12 @@ packages: engines: {node: '>=10'} dev: true - /js-base64@3.7.5: - resolution: {integrity: sha512-3MEt5DTINKqfScXKfJFrRbxkrnk2AxPWGBL/ycjz4dK8iqiSJ06UxD8jh8xuh6p10TX4t2+7FsBYVxxQbMg+qA==} + /js-base64@3.7.7: + resolution: {integrity: sha512-7rCnleh0z2CkXhH67J8K1Ytz0b2Y+yxTPL+/KOJoa20hfnVQ/3/T6W/KflYI4bRHRagNeXeU2bkNGI3v1oS/lw==} dev: false - /js-sdsl@4.4.0: - resolution: {integrity: sha512-FfVSdx6pJ41Oa+CF7RDaFmTnCaFhua+SNYQX74riGOpl96x+2jQCqEfQ2bnXu/5DPCqlRuiqyvTJM0Qjz26IVg==} + /js-sdsl@4.4.2: + resolution: {integrity: sha512-dwXFwByc/ajSV6m5bcKAPwe4yDDF6D614pxmIi5odytzxRlwqF6nwoiCek80Ixc7Cvma5awClxrzFtxCQvcM8w==} dev: true /js-sha3@0.8.0: @@ -8236,7 +8056,7 @@ packages: whatwg-encoding: 2.0.0 whatwg-mimetype: 3.0.0 whatwg-url: 12.0.1 - ws: 8.13.0 + ws: 8.16.0 xml-name-validator: 4.0.0 transitivePeerDependencies: - bufferutil @@ -8250,21 +8070,26 @@ packages: hasBin: true dev: true - /json-parse-better-errors@1.0.2: - resolution: {integrity: sha512-mrqyZKfX5EhL7hvqcV6WG1yYjnjeuYDzDhhcAAUrq8Po85NBQBJP+ZDUT75qZQ98IkUoBqdkExkukOU7Ts2wrw==} + /json-buffer@3.0.1: + resolution: {integrity: sha512-4bV5BfR2mqfQTJm+V5tPPdf+ZpuhiIvTuAB5g8kcrXOZpTT/QwwVRWBywX1ozr6lEuPdbHxwaJlm9G6mI2sfSQ==} dev: true /json-parse-even-better-errors@2.3.1: resolution: {integrity: sha512-xyFwyhro/JEof6Ghe2iz2NcXoj2sloNsWr/XsERDK/oiPCfaNhl5ONfp+jQdAZRQQ0IJWNzH9zIZF7li91kh2w==} dev: true + /json-schema-ref-resolver@1.0.1: + resolution: {integrity: sha512-EJAj1pgHc1hxF6vo2Z3s69fMjO1INq6eGHXZ8Z6wCQeldCuwxGK9Sxf4/cScGn3FZubCVUehfWtcDM/PLteCQw==} + dependencies: + fast-deep-equal: 3.1.3 + dev: false + /json-schema-traverse@0.4.1: resolution: {integrity: sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==} dev: true /json-schema-traverse@1.0.0: resolution: {integrity: sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug==} - dev: false /json-stable-stringify-without-jsonify@1.0.1: resolution: {integrity: sha512-Bdboy+l7tA3OGW6FjyFHWkP5LuByj1Tk33Ljyq0axyzdk9//JSi2u3fP1QSmd1KNwq6VOKYGlAu87CisVir6Pw==} @@ -8276,8 +8101,8 @@ packages: hasBin: true dev: true - /jsonc-parser@3.2.0: - resolution: {integrity: sha512-gfFQZrcTc8CnKXp6Y4/CBT3fTc0OVuDofpre4aEeEpSBPV5X5v4+Vmx+8snU7RLPrNHPKSgLxGo9YuQzz20o+w==} + /jsonc-parser@3.2.1: + resolution: {integrity: sha512-AilxAyFOAcK5wA1+LeaySVBrHsGQvUFCDWXKpZjzaL0PqW+xfBOttn8GNtWKFWqneyMZj41MWF9Kl6iPWLwgOA==} dev: true /jsonfile@2.4.0: @@ -8292,31 +8117,33 @@ packages: graceful-fs: 4.2.11 dev: true - /jsx-ast-utils@3.3.3: - resolution: {integrity: sha512-fYQHZTZ8jSfmWZ0iyzfwiU4WDX4HpHbMCZ3gPlWYiCl3BoeOTsqKBqnTVfH2rYT7eP5c3sVbeSPHnnJOaTrWiw==} + /jsx-ast-utils@3.3.5: + resolution: {integrity: sha512-ZZow9HBI5O6EPgSJLUb8n2NKgmVWTwCvHGwFuJlMjvLFqlGG6pjirPhtdsseaLZjSibD8eegzmYpUZwoIlj2cQ==} engines: {node: '>=4.0'} dependencies: - array-includes: 3.1.6 - object.assign: 4.1.4 + array-includes: 3.1.7 + array.prototype.flat: 1.3.2 + object.assign: 4.1.5 + object.values: 1.1.7 dev: true - /keccak-wasm@0.10.3(buffer-lite@1.0.0): + /keccak-wasm@0.10.3(buffer-lite@1.1.0): resolution: {integrity: sha512-HMbeV9BX+hGmrPk5C1PdZBPAGIAVyGzKywQt4OnU9cG+7sI1/moZmH7DXRd3XQBhR6z04LdMXkA15roVINmMsA==} requiresBuild: true peerDependencies: buffer-lite: ^1.0.0 dependencies: - buffer-lite: 1.0.0 + buffer-lite: 1.1.0 dev: true - /keccak@3.0.3: - resolution: {integrity: sha512-JZrLIAJWuZxKbCilMpNz5Vj7Vtb4scDG3dMXLOsbzBmQGyjwE61BbW7bJkfKKCShXiQZt3T6sBgALRtmd+nZaQ==} + /keccak@3.0.4: + resolution: {integrity: sha512-3vKuW0jV8J3XNTzvfyicFR5qvxrSAGl7KIhvgOu5cmWwM7tZRj3fMbj/pfIf4be7aznbc+prBWGjywox/g2Y6Q==} engines: {node: '>=10.0.0'} requiresBuild: true dependencies: node-addon-api: 2.0.2 - node-gyp-build: 4.5.0 - readable-stream: 3.6.0 + node-gyp-build: 4.8.0 + readable-stream: 3.6.2 dev: true /keygrip@1.1.0: @@ -8326,6 +8153,12 @@ packages: tsscmp: 1.0.6 dev: false + /keyv@4.5.4: + resolution: {integrity: sha512-oxVHkHR/EJf2CNXnWxRLW6mg7JyCCUcG0DtEGmL2ctUo1PNTin1PUil+r/+4r5MpVgC/fn1kjsx7mjSujKqIpw==} + dependencies: + json-buffer: 3.0.1 + dev: true + /kind-of@6.0.3: resolution: {integrity: sha512-dcS1ul+9tmeD95T+x28/ehLgd9mENa3LsvDTtzm3vyBEO7RPptvAD+t44WVXaUjTBRcrpFeFlC8WCruUR456hw==} engines: {node: '>=0.10.0'} @@ -8359,15 +8192,15 @@ packages: koa-compose: 4.1.0 dev: false - /koa@2.14.2: - resolution: {integrity: sha512-VFI2bpJaodz6P7x2uyLiX6RLYpZmOJqNmoCst/Yyd7hQlszyPwG/I9CQJ63nOtKSxpt5M7NH67V6nJL2BwCl7g==} + /koa@2.15.0: + resolution: {integrity: sha512-KEL/vU1knsoUvfP4MC4/GthpQrY/p6dzwaaGI6Rt4NQuFqkw3qrvsdYF5pz3wOfi7IGTvMPHC9aZIcUKYFNxsw==} engines: {node: ^4.8.4 || ^6.10.1 || ^7.10.1 || >= 8.1.4} dependencies: accepts: 1.3.8 cache-content-type: 1.0.1 content-disposition: 0.5.4 content-type: 1.0.5 - cookies: 0.8.0 + cookies: 0.9.1 debug: 4.3.4(supports-color@8.1.1) delegates: 1.0.0 depd: 2.0.0 @@ -8395,90 +8228,11 @@ packages: engines: {node: '>=14.0.0'} dev: false - /level-codec@9.0.2: - resolution: {integrity: sha512-UyIwNb1lJBChJnGfjmO0OR+ezh2iVu1Kas3nvBS/BzGnx79dv6g7unpKIDNPMhfdTEGoc7mC8uAu51XEtX+FHQ==} - engines: {node: '>=6'} - dependencies: - buffer: 5.7.1 - dev: true - - /level-concat-iterator@2.0.1: - resolution: {integrity: sha512-OTKKOqeav2QWcERMJR7IS9CUo1sHnke2C0gkSmcR7QuEtFNLLzHQAvnMw8ykvEcv0Qtkg0p7FOwP1v9e5Smdcw==} - engines: {node: '>=6'} - dev: true - - /level-errors@2.0.1: - resolution: {integrity: sha512-UVprBJXite4gPS+3VznfgDSU8PTRuVX0NXwoWW50KLxd2yw4Y1t2JUR5In1itQnudZqRMT9DlAM3Q//9NCjCFw==} - engines: {node: '>=6'} - dependencies: - errno: 0.1.8 - dev: true - - /level-iterator-stream@4.0.2: - resolution: {integrity: sha512-ZSthfEqzGSOMWoUGhTXdX9jv26d32XJuHz/5YnuHZzH6wldfWMOVwI9TBtKcya4BKTyTt3XVA0A3cF3q5CY30Q==} - engines: {node: '>=6'} - dependencies: - inherits: 2.0.4 - readable-stream: 3.6.0 - xtend: 4.0.2 - dev: true - - /level-mem@5.0.1: - resolution: {integrity: sha512-qd+qUJHXsGSFoHTziptAKXoLX87QjR7v2KMbqncDXPxQuCdsQlzmyX+gwrEHhlzn08vkf8TyipYyMmiC6Gobzg==} - engines: {node: '>=6'} - dependencies: - level-packager: 5.1.1 - memdown: 5.1.0 - dev: true - - /level-packager@5.1.1: - resolution: {integrity: sha512-HMwMaQPlTC1IlcwT3+swhqf/NUO+ZhXVz6TY1zZIIZlIR0YSn8GtAAWmIvKjNY16ZkEg/JcpAuQskxsXqC0yOQ==} - engines: {node: '>=6'} - dependencies: - encoding-down: 6.3.0 - levelup: 4.4.0 - dev: true - - /level-supports@1.0.1: - resolution: {integrity: sha512-rXM7GYnW8gsl1vedTJIbzOrRv85c/2uCMpiiCzO2fndd06U/kUXEEU9evYn4zFggBOg36IsBW8LzqIpETwwQzg==} - engines: {node: '>=6'} - dependencies: - xtend: 4.0.2 - dev: true - - /level-ws@2.0.0: - resolution: {integrity: sha512-1iv7VXx0G9ec1isqQZ7y5LmoZo/ewAsyDHNA8EFDW5hqH2Kqovm33nSFkSdnLLAK+I5FlT+lo5Cw9itGe+CpQA==} - engines: {node: '>=6'} - dependencies: - inherits: 2.0.4 - readable-stream: 3.6.0 - xtend: 4.0.2 - dev: true - - /levelup@4.4.0: - resolution: {integrity: sha512-94++VFO3qN95cM/d6eBXvd894oJE0w3cInq9USsyQzzoJxmiYzPAocNcuGCPGGjoXqDVJcr3C1jzt1TSjyaiLQ==} - engines: {node: '>=6'} - dependencies: - deferred-leveldown: 5.3.0 - level-errors: 2.0.1 - level-iterator-stream: 4.0.2 - level-supports: 1.0.1 - xtend: 4.0.2 - dev: true - /leven@3.1.0: resolution: {integrity: sha512-qsda+H8jTaUaN/x5vzW2rzc+8Rw4TAQ/4KjB46IwK5VH+IlVeeeje/EoZRpiXvIqjFgK84QffqPztGI3VBLG1A==} engines: {node: '>=6'} dev: true - /levn@0.3.0: - resolution: {integrity: sha512-0OO4y2iOHix2W6ujICbKIaEQXvFQHue65vUG3pb5EUomzPI90z9hsA1VsO/dbIIpC53J8gxM9Q4Oho0jrCM/yA==} - engines: {node: '>= 0.8.0'} - dependencies: - prelude-ls: 1.1.2 - type-check: 0.3.2 - dev: true - /levn@0.4.1: resolution: {integrity: sha512-+bT2uH4E5LGE7h/n3evcS/sQlJXCpIp6ym8OWJ5eV6+67Dsql/LaaT7qJBAt2rzfoa/5QBGBhxDix1dMt2kQKQ==} engines: {node: '>= 0.8.0'} @@ -8494,11 +8248,11 @@ packages: pify: 3.0.0 dev: false - /light-my-request@5.10.0: - resolution: {integrity: sha512-ZU2D9GmAcOUculTTdH9/zryej6n8TzT+fNGdNtm6SDp5MMMpHrJJkvAdE3c6d8d2chE9i+a//dS9CWZtisknqA==} + /light-my-request@5.11.1: + resolution: {integrity: sha512-KXAh2m6VRlkWCk2KfmHE7tLBXKh30JE0tXUJY4dNxje4oLmPKUqlUfImiEQZLphx+Z9KTQcVv4DjGnJxkVOIbA==} dependencies: - cookie: 0.5.0 - process-warning: 2.2.0 + cookie: 0.6.0 + process-warning: 2.3.2 set-cookie-parser: 2.6.0 dev: false @@ -8507,80 +8261,49 @@ packages: engines: {node: '>=10'} dev: true + /lilconfig@3.0.0: + resolution: {integrity: sha512-K2U4W2Ff5ibV7j7ydLr+zLAkIg5JJ4lPn1Ltsdt+Tz/IjQ8buJ55pZAxoP34lqIiwtF9iAvtLv3JGv7CAyAg+g==} + engines: {node: '>=14'} + dev: true + + /lilconfig@3.1.1: + resolution: {integrity: sha512-O18pf7nyvHTckunPWCV1XUNXU1piu01y2b7ATJ0ppkUkk8ocqVWBrYjJBCwHDjD/ZWcfyrA0P4gKhzWGi5EINQ==} + engines: {node: '>=14'} + dev: true + /lines-and-columns@1.2.4: resolution: {integrity: sha512-7ylylesZQ/PV29jhEDl3Ufjo6ZX7gCqJr5F7PKrqc93v7fzSymt1BpwEU8nAUXs8qzzvqhbjhK5QZg6Mt/HkBg==} dev: true - /lint-staged@10.0.0: - resolution: {integrity: sha512-/MrZOLMnljjMHakxlRd1Z5Kr8wWWlrWFasye7HaTv5tx56icwzT/STRty8flMKsyzBGTfTa9QszNVPsDS/yOug==} + /lint-staged@15.2.2: + resolution: {integrity: sha512-TiTt93OPh1OZOsb5B7k96A/ATl2AjIZo+vnzFZ6oHK5FuTk63ByDtxGQpHm+kFETjEWqgkF95M8FRXKR/LEBcw==} + engines: {node: '>=18.12.0'} hasBin: true dependencies: - chalk: 3.0.0 - commander: 4.1.1 - cosmiconfig: 6.0.0 + chalk: 5.3.0 + commander: 11.1.0 debug: 4.3.4(supports-color@8.1.1) - dedent: 0.7.0 - execa: 3.4.0 - listr: 0.14.3 - log-symbols: 3.0.0 + execa: 8.0.1 + lilconfig: 3.0.0 + listr2: 8.0.1 micromatch: 4.0.5 - normalize-path: 3.0.0 - please-upgrade-node: 3.2.0 - stringify-object: 3.3.0 + pidtree: 0.6.0 + string-argv: 0.3.2 + yaml: 2.3.4 transitivePeerDependencies: - supports-color - - zen-observable - - zenObservable - dev: true - - /listr-silent-renderer@1.1.1: - resolution: {integrity: sha512-L26cIFm7/oZeSNVhWB6faeorXhMg4HNlb/dS/7jHhr708jxlXrtrBWo4YUxZQkc6dGoxEAe6J/D3juTRBUzjtA==} - engines: {node: '>=4'} - dev: true - - /listr-update-renderer@0.5.0(listr@0.14.3): - resolution: {integrity: sha512-tKRsZpKz8GSGqoI/+caPmfrypiaq+OQCbd+CovEC24uk1h952lVj5sC7SqyFUm+OaJ5HN/a1YLt5cit2FMNsFA==} - engines: {node: '>=6'} - peerDependencies: - listr: ^0.14.2 - dependencies: - chalk: 1.1.3 - cli-truncate: 0.2.1 - elegant-spinner: 1.0.1 - figures: 1.7.0 - indent-string: 3.2.0 - listr: 0.14.3 - log-symbols: 1.0.2 - log-update: 2.3.0 - strip-ansi: 3.0.1 - dev: true - - /listr-verbose-renderer@0.5.0: - resolution: {integrity: sha512-04PDPqSlsqIOaaaGZ+41vq5FejI9auqTInicFRndCBgE3bXG8D6W1I+mWhk+1nqbHmyhla/6BUrd5OSiHwKRXw==} - engines: {node: '>=4'} - dependencies: - chalk: 2.4.2 - cli-cursor: 2.1.0 - date-fns: 1.30.1 - figures: 2.0.0 dev: true - /listr@0.14.3: - resolution: {integrity: sha512-RmAl7su35BFd/xoMamRjpIE4j3v+L28o8CT5YhAXQJm1fD+1l9ngXY8JAQRJ+tFK2i5njvi0iRUKV09vPwA0iA==} - engines: {node: '>=6'} + /listr2@8.0.1: + resolution: {integrity: sha512-ovJXBXkKGfq+CwmKTjluEqFi3p4h8xvkxGQQAQan22YCgef4KZ1mKGjzfGh6PL6AW5Csw0QiQPNuQyH+6Xk3hA==} + engines: {node: '>=18.0.0'} dependencies: - '@samverschueren/stream-to-observable': 0.3.1(rxjs@6.6.7) - is-observable: 1.1.0 - is-promise: 2.2.2 - is-stream: 1.1.0 - listr-silent-renderer: 1.1.1 - listr-update-renderer: 0.5.0(listr@0.14.3) - listr-verbose-renderer: 0.5.0 - p-map: 2.1.0 - rxjs: 6.6.7 - transitivePeerDependencies: - - zen-observable - - zenObservable + cli-truncate: 4.0.0 + colorette: 2.0.20 + eventemitter3: 5.0.1 + log-update: 6.0.0 + rfdc: 1.3.1 + wrap-ansi: 9.0.0 dev: true /load-tsconfig@0.2.5: @@ -8631,14 +8354,6 @@ packages: engines: {node: '>=10'} dependencies: p-locate: 5.0.0 - dev: true - - /locate-path@7.2.0: - resolution: {integrity: sha512-gvVijfZvn7R+2qyPX8mAuKcFGDf6Nc61GdvGafQsHL0sBIxfKzA+usWn4GFC/bk+QdwPUD4kWFJLhElipq+0VA==} - engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} - dependencies: - p-locate: 6.0.0 - dev: false /lodash.get@4.4.2: resolution: {integrity: sha512-z+Uw/vLuy6gQe8cfaFWD7p0wVv8fJl3mbzXh33RS+0oW2wvUqiRXiQ69gLWSLpgB5/6sU+r6BlQR0MBILadqTQ==} @@ -8662,25 +8377,10 @@ packages: /lodash.truncate@4.4.2: resolution: {integrity: sha512-jttmRe7bRse52OsWIMDLaXxWqRAmtIUccAQ3garviCqJjafXOfNMO0yMfNpdD6zbGaTU0P5Nz7e7gAT6cKmJRw==} - dev: false /lodash@4.17.21: resolution: {integrity: sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==} - /log-symbols@1.0.2: - resolution: {integrity: sha512-mmPrW0Fh2fxOzdBbFv4g1m6pR72haFLPJ2G5SJEELf1y+iaQrDG6cWCPjy54RHYbZAt7X+ls690Kw62AdWXBzQ==} - engines: {node: '>=0.10.0'} - dependencies: - chalk: 1.1.3 - dev: true - - /log-symbols@3.0.0: - resolution: {integrity: sha512-dSkNGuI7iG3mfvDzUuYZyvk5dD9ocYCYzNU6CYDE6+Xqd+gwme6Z00NS3dUh8mq/73HaEtT7m6W+yUPtU6BZnQ==} - engines: {node: '>=8'} - dependencies: - chalk: 2.4.2 - dev: true - /log-symbols@4.1.0: resolution: {integrity: sha512-8XPvpAA8uyhfteu8pIvQxpJZ7SYYdpUivZpGy6sFsBuKRY/7rQGavedeB8aK+Zkyq6upMFVL/9AW6vOYzfRyLg==} engines: {node: '>=10'} @@ -8689,21 +8389,19 @@ packages: is-unicode-supported: 0.1.0 dev: true - /log-update@2.3.0: - resolution: {integrity: sha512-vlP11XfFGyeNQlmEn9tJ66rEW1coA/79m5z6BCkudjbAGE83uhAcGYrBFwfs3AdLiLzGRusRPAbSPK9xZteCmg==} - engines: {node: '>=4'} + /log-update@6.0.0: + resolution: {integrity: sha512-niTvB4gqvtof056rRIrTZvjNYE4rCUzO6X/X+kYjd7WFxXeJ0NwEFnRxX6ehkvv3jTwrXnNdtAak5XYZuIyPFw==} + engines: {node: '>=18'} dependencies: - ansi-escapes: 3.2.0 - cli-cursor: 2.1.0 - wrap-ansi: 3.0.1 - dev: true - - /long@4.0.0: - resolution: {integrity: sha512-XsP+KhQif4bjX1kbuSiySJFNAehNxgLb6hPRGJ9QsUr8ajHkuXGdrHmFUTUUXhDwVX2R5bY4JNZEwbUiMhV+MA==} + ansi-escapes: 6.2.0 + cli-cursor: 4.0.0 + slice-ansi: 7.1.0 + strip-ansi: 7.1.0 + wrap-ansi: 9.0.0 dev: true - /long@5.2.1: - resolution: {integrity: sha512-GKSNGeNAtw8IryjjkhZxuKB3JzlcLTwjtiQCHKvqQet81I93kXslhDQruGI/QsddO83mcDToBVy7GqGS/zYf/A==} + /long@5.2.3: + resolution: {integrity: sha512-lcHwpNoggQTObv5apGNCTdJrO69eHOZMi4BNC+rTLER8iHAqGrUVeLh/irVIM7zTw2bOXA8T6uNPeujwOLg/2Q==} /loose-envify@1.4.0: resolution: {integrity: sha512-lyuxPGr/Wfhrlem2CL/UcnUc1zcqKAImBDzukY7Y5F/yQiNdko6+fRLevlw1HgMySw7f611UIY408EtxRSoK3Q==} @@ -8711,11 +8409,15 @@ packages: dependencies: js-tokens: 4.0.0 - /loupe@2.3.6: - resolution: {integrity: sha512-RaPMZKiMy8/JruncMU5Bt6na1eftNoo++R4Y+N2FrxkDVTrGvcyzFTsaGif4QTeKESheMGegbhw6iUAq+5A8zA==} - deprecated: Please upgrade to 2.3.7 which fixes GHSA-4q6p-r6v2-jvc5 + /loupe@2.3.7: + resolution: {integrity: sha512-zSMINGVYkdpYSOBmLi0D1Uo7JU9nVdQKrHxC8eYlV+9YKK9WePqAlL7lSlorG/U2Fw1w0hTBmaa/jrQ3UbPHtA==} dependencies: - get-func-name: 2.0.0 + get-func-name: 2.0.2 + dev: true + + /lru-cache@10.2.0: + resolution: {integrity: sha512-2bIM8x+VAf6JT4bKAljS1qUWgMsqZRPGJS6FSahIMPVvctcNhyVp7AJu7quxOW9jwkryBReKZY5tY5JYv2n/7Q==} + engines: {node: 14 || >=16.14} dev: true /lru-cache@4.1.5: @@ -8737,68 +8439,34 @@ packages: dependencies: yallist: 4.0.0 - /lru-cache@7.18.3: - resolution: {integrity: sha512-jumlc0BIUrS3qJGgIkWZsyfAM7NCWiBcCDhnd+3NNM5KbBmLTgHVfWBcg6W+rLUsIpzpERPsvwUP7CckAQSOoA==} - engines: {node: '>=12'} - dev: false - /lru-queue@0.1.0: resolution: {integrity: sha512-BpdYkt9EvGl8OfWHDQPISVpcl5xZthb+XPsbELj5AQXxIC8IriDZIQYjBJPEm5rS420sjZ0TLEzRcq5KdBhYrQ==} dependencies: - es5-ext: 0.10.62 + es5-ext: 0.10.64 dev: false /lru_map@0.3.3: resolution: {integrity: sha512-Pn9cox5CsMYngeDbmChANltQl+5pi6XmTrraMSzhPmMBbmgcxmqWry0U3PGapCU1yB4/LqCcom7qhHZiF/jGfQ==} dev: true - /ltgt@2.2.1: - resolution: {integrity: sha512-AI2r85+4MquTw9ZYqabu4nMwy9Oftlfa/e/52t9IjtfG+mGBbTNdAoZ3RQKLHR6r0wQnwZnPIEh/Ya6XTWAKNA==} - dev: true - - /magic-string@0.30.5: - resolution: {integrity: sha512-7xlpfBaQaP/T6Vh8MO/EqXSW5En6INHEvEXQiuff7Gku0PWjU3uf6w/j9o7O+SpB5fOAkrI5HeoNgwjEO0pFsA==} + /magic-string@0.30.7: + resolution: {integrity: sha512-8vBuFF/I/+OSLRmdf2wwFCJCz+nSn0m6DPvGH1fS/KiQoSaR+sETbov0eIk9KhEKy8CYqIkIAnbohxT/4H0kuA==} engines: {node: '>=12'} dependencies: '@jridgewell/sourcemap-codec': 1.4.15 dev: true - /make-dir@3.1.0: - resolution: {integrity: sha512-g3FeP20LNwhALb/6Cz6Dd4F2ngze0jz7tbzrD2wAV+o9FeNHe4rL+yK2md0J/fiSf1sa1ADhXqi5+oVwOM/eGw==} - engines: {node: '>=8'} + /make-dir@4.0.0: + resolution: {integrity: sha512-hXdUTZYIVOt1Ex//jAQi+wTZZpUpwBj/0QsOzqegb3rGMMeJiSEu5xLHnYfBrRV4RH2+OCSOO95Is/7x1WJ4bw==} + engines: {node: '>=10'} dependencies: - semver: 6.3.0 + semver: 7.6.0 dev: true /make-error@1.3.6: resolution: {integrity: sha512-s8UhlNe7vPKomQhC1qFelMokr/Sc3AgNbso3n74mVPA5LTZwkB9NlXf4XPamLxJE8h0gh73rM94xvwRT2CVInw==} dev: true - /make-fetch-happen@10.2.1: - resolution: {integrity: sha512-NgOPbRiaQM10DYXvN3/hhGVI2M5MtITFryzBGxHM5p4wnFxsVCbxkrBrDsk+EZ5OB4jEOT7AjDxtdF+KVEFT7w==} - engines: {node: ^12.13.0 || ^14.15.0 || >=16.0.0} - dependencies: - agentkeepalive: 4.5.0 - cacache: 16.1.3 - http-cache-semantics: 4.1.1 - http-proxy-agent: 5.0.0 - https-proxy-agent: 5.0.1 - is-lambda: 1.0.1 - lru-cache: 7.18.3 - minipass: 3.3.6 - minipass-collect: 1.0.2 - minipass-fetch: 2.1.2 - minipass-flush: 1.0.5 - minipass-pipeline: 1.2.4 - negotiator: 0.6.3 - promise-retry: 2.0.1 - socks-proxy-agent: 7.0.0 - ssri: 9.0.1 - transitivePeerDependencies: - - bluebird - - supports-color - dev: false - /makeerror@1.0.12: resolution: {integrity: sha512-JmqCvUhmt43madlpFzG4BQzG2Z3m6tvQDNKdClZnO3VbIudJYmxsT0FNJMeiB2+JTSlTQTSbU8QdesVmwJcmLg==} dependencies: @@ -8815,11 +8483,6 @@ packages: engines: {node: '>=8'} dev: true - /mcl-wasm@0.7.9: - resolution: {integrity: sha512-iJIUcQWA88IJB/5L15GnJVnSQJmf/YaxxV6zRavv83HILHaJQb6y0iFyDMdDO0gN8X37tdxmAOrH/P8B6RB8sQ==} - engines: {node: '>=8.9.0'} - dev: true - /md5.js@1.3.5: resolution: {integrity: sha512-xitP+WxNPcTTOgnTJcrhM0xvdPepipPSf3I8EIpGKeFLjt3PlJLIDG3u8EX53ZIubkb+5U2+3rELYpEhHhzdkg==} dependencies: @@ -8833,23 +8496,11 @@ packages: engines: {node: '>= 0.6'} dev: false - /memdown@5.1.0: - resolution: {integrity: sha512-B3J+UizMRAlEArDjWHTMmadet+UKwHd3UjMgGBkZcKAxAYVPS9o0Yeiha4qvz7iGiL2Sb3igUft6p7nbFWctpw==} - engines: {node: '>=6'} - dependencies: - abstract-leveldown: 6.2.3 - functional-red-black-tree: 1.0.1 - immediate: 3.2.3 - inherits: 2.0.4 - ltgt: 2.2.1 - safe-buffer: 5.2.1 - dev: true - /memoizee@0.4.15: resolution: {integrity: sha512-UBWmJpLZd5STPm7PMUlOw/TSy972M+z8gcyQ5veOnSDRREz/0bmpyTfKt3/51DhEBqCZQn1udM/5flcSPYhkdQ==} dependencies: d: 1.0.1 - es5-ext: 0.10.62 + es5-ext: 0.10.64 es6-weak-map: 2.0.3 event-emitter: 0.3.5 is-promise: 2.2.2 @@ -8867,7 +8518,7 @@ packages: resolution: {integrity: sha512-3YffViIt2QWgTy6Pale5QpopX/IvU3LPL03jOTqp6pGj3VjesdO/U8CuHMKpnQr4shCNCM5fd5XFFvIIl6JBHg==} engines: {node: '>=8'} dependencies: - '@types/minimist': 1.2.2 + '@types/minimist': 1.2.5 camelcase-keys: 6.2.2 decamelize-keys: 1.1.1 hard-rejection: 2.1.0 @@ -8887,22 +8538,15 @@ packages: resolution: {integrity: sha512-8q7VEgMJW4J8tcfVPy8g09NcQwZdbwFEqhe/WZkoIzjn/3TGDwtOCYtXGxA3O8tPzpczCCDgv+P2P5y00ZJOOg==} engines: {node: '>= 8'} - /merkle-patricia-tree@4.2.4: - resolution: {integrity: sha512-eHbf/BG6eGNsqqfbLED9rIqbsF4+sykEaBn6OLNs71tjclbMcMOk1tEPmJKcNcNCLkvbpY/lwyOlizWsqPNo8w==} - dependencies: - '@types/levelup': 4.3.3 - ethereumjs-util: 7.1.5 - level-mem: 5.0.1 - level-ws: 2.0.0 - readable-stream: 3.6.0 - semaphore-async-await: 1.5.1 - dev: true - /methods@1.1.2: resolution: {integrity: sha512-iclAHeNqNm68zFtnZ0e+1L2yUIdvzNoauKU4WBA3VvH/vPFieF7qfRlwUZU+DA9P9bPXIS90ulxoUoCH23sV2w==} engines: {node: '>= 0.6'} dev: false + /micro-ftch@0.3.1: + resolution: {integrity: sha512-/0LLxhzP0tfiR5hcQebtudP56gUurs2CLkGarnCiB/OqEyUFQ6U3paQi/tgLv0hBJYt2rnr9MNpxz4fiiugstg==} + dev: true + /micromatch@4.0.5: resolution: {integrity: sha512-DMy+ERcEW2q8Z2Po+WNXuw3c5YaUSFjAO5GsJqfEl7UjvtIuFKO6ZrKvcItdy98dwFI2N1tg3zNIdKaQT+aNdA==} engines: {node: '>=8.6'} @@ -8910,14 +8554,6 @@ packages: braces: 3.0.2 picomatch: 2.3.1 - /miller-rabin@4.0.1: - resolution: {integrity: sha512-115fLhvZVqWwHPbClyntxEVfVDfl9DLLTuJvq3g2O/Oxi8AiNouAHvDSzHS0viUJc+V5vm3eq91Xwqn9dp4jRA==} - hasBin: true - dependencies: - bn.js: 4.12.0 - brorand: 1.1.0 - dev: true - /mime-db@1.52.0: resolution: {integrity: sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg==} engines: {node: '>= 0.6'} @@ -8928,11 +8564,6 @@ packages: dependencies: mime-db: 1.52.0 - /mimic-fn@1.2.0: - resolution: {integrity: sha512-jf84uxzwiuiIVKiOLpfYk7N46TSy8ubTonmneY9vrpHNAnp0QBt2BxWV9dO3/j+BoVAb+a5G6YDPW3M5HOdMWQ==} - engines: {node: '>=4'} - dev: true - /mimic-fn@2.1.0: resolution: {integrity: sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg==} engines: {node: '>=6'} @@ -8940,6 +8571,7 @@ packages: /mimic-fn@4.0.0: resolution: {integrity: sha512-vqiC06CuhBTUdZH+RYl8sFrL096vA45Ok5ISO6sE/Mr1jRbGH4Csnhi8f3wKVl7x8mO4Au7Ir9D3Oyv1VYMFJw==} engines: {node: '>=12'} + dev: true /mimic-response@3.1.0: resolution: {integrity: sha512-z0yWI+4FDrrweS8Zmt4Ej5HdJmky15+L2e6Wgn3+iK5fWzb6T3fhNFq2+MeTRb064c6Wr4N/wv0DzQTjNzHNGQ==} @@ -8975,6 +8607,13 @@ packages: dependencies: brace-expansion: 2.0.1 + /minimatch@9.0.3: + resolution: {integrity: sha512-RHiac9mvaRw0x3AYRgDC1CxAP7HTcNrrECeA8YYJeWnpo+2Q5CegtZjaotWTWxDG3UeGA1coE05iH1mPjT/2mg==} + engines: {node: '>=16 || 14 >=14.17'} + dependencies: + brace-expansion: 2.0.1 + dev: true + /minimist-options@4.1.0: resolution: {integrity: sha512-Q4r8ghd80yhO/0j1O3B2BjweX3fiHg9cdOwjJd2J76Q135c+NDxGCqdYKQ1SKBuFfgWbAUzBfvYjPUEeNgqN1A==} engines: {node: '>= 6'} @@ -8986,73 +8625,14 @@ packages: /minimist@1.2.8: resolution: {integrity: sha512-2yyAR8qBkN3YuheJanUpWC5U3bb5osDywNB8RzDVlDwDHbocAJveqqj1u8+SVD7jkWT4yvsHCpWqqWqAxb0zCA==} - - /minipass-collect@1.0.2: - resolution: {integrity: sha512-6T6lH0H8OG9kITm/Jm6tdooIbogG9e0tLgpY6mphXSm/A9u8Nq1ryBG+Qspiub9LjWlBPsPS3tWQ/Botq4FdxA==} - engines: {node: '>= 8'} - dependencies: - minipass: 3.3.6 - dev: false - - /minipass-fetch@2.1.2: - resolution: {integrity: sha512-LT49Zi2/WMROHYoqGgdlQIZh8mLPZmOrN2NdJjMXxYe4nkN6FUyuPuOAOedNJDrx0IRGg9+4guZewtp8hE6TxA==} - engines: {node: ^12.13.0 || ^14.15.0 || >=16.0.0} - dependencies: - minipass: 3.3.6 - minipass-sized: 1.0.3 - minizlib: 2.1.2 - optionalDependencies: - encoding: 0.1.13 - dev: false - - /minipass-flush@1.0.5: - resolution: {integrity: sha512-JmQSYYpPUqX5Jyn1mXaRwOda1uQ8HP5KAT/oDSLCzt1BYRhQU0/hDtsB1ufZfEEzMZ9aAVmsBw8+FWsIXlClWw==} - engines: {node: '>= 8'} - dependencies: - minipass: 3.3.6 - dev: false - - /minipass-pipeline@1.2.4: - resolution: {integrity: sha512-xuIq7cIOt09RPRJ19gdi4b+RiNvDFYe5JH+ggNvBqGqpQXcru3PcRmOZuHBKWK1Txf9+cQ+HMVN4d6z46LZP7A==} - engines: {node: '>=8'} - dependencies: - minipass: 3.3.6 - dev: false - - /minipass-sized@1.0.3: - resolution: {integrity: sha512-MbkQQ2CTiBMlA2Dm/5cY+9SWFEN8pzzOXi6rlM5Xxq0Yqbda5ZQy9sU75a673FE9ZK0Zsbr6Y5iP6u9nktfg2g==} - engines: {node: '>=8'} - dependencies: - minipass: 3.3.6 - dev: false - - /minipass@3.3.6: - resolution: {integrity: sha512-DxiNidxSEK+tHG6zOIklvNOwm3hvCrbUrdtzY74U6HKTJxvIDfOUL5W5P2Ghd3DTkhhKPYGqeNUIh5qcM4YBfw==} - engines: {node: '>=8'} - dependencies: - yallist: 4.0.0 - dev: false - - /minipass@5.0.0: - resolution: {integrity: sha512-3FnjYuehv9k6ovOEbyOswadCDPX1piCfhV8ncmYtHOjuPwylVWsghTLo7rabjC3Rx5xD4HDx8Wm1xnMF7S5qFQ==} - engines: {node: '>=8'} dev: false /minipass@7.0.4: resolution: {integrity: sha512-jYofLM5Dam9279rdkWzqHozUo4ybjdZmCsDHePy5V/PbBcVMiSZR97gmAy45aqi8CK1lG2ECd356FU86avfwUQ==} engines: {node: '>=16 || 14 >=14.17'} - dev: false - - /minizlib@2.1.2: - resolution: {integrity: sha512-bAxsR8BVfj60DWXHE3u30oHzfl4G7khkSuPW+qvpd7jFRHm7dLxOjUk1EHACJ/hxLY8phGJ0YhYHZo7jil7Qdg==} - engines: {node: '>= 8'} - dependencies: - minipass: 3.3.6 - yallist: 4.0.0 - dev: false - /mixme@0.5.9: - resolution: {integrity: sha512-VC5fg6ySUscaWUpI4gxCBTQMH2RdUpNrk+MsbpCYtIvf9SBJdiUey4qE7BXviJsJR4nDQxCZ+3yaYNW3guz/Pw==} + /mixme@0.5.10: + resolution: {integrity: sha512-5H76ANWinB1H3twpJ6JY8uvAtpmFvHNArpilJAjXRKXSDDLPIMoZArw5SH0q9z+lLs8IrMw7Q2VWpWimFKFT1Q==} engines: {node: '>= 8.0.0'} dev: true @@ -9060,26 +8640,13 @@ packages: resolution: {integrity: sha512-gKLcREMhtuZRwRAfqP3RFW+TK4JqApVBtOIftVgjuABpAtpxhPGaDcfvbhNvD0B8iD1oUr/txX35NjcaY6Ns/A==} dev: false - /mkdirp@0.5.6: - resolution: {integrity: sha512-FP+p8RB8OWpF3YZBCrP5gtADmtXApB5AMLn+vdyA+PyxCjrCs00mjyUozssO33cwDeT3wNGdLxJ5M//YqtHAJw==} - hasBin: true - dependencies: - minimist: 1.2.8 - dev: true - - /mkdirp@1.0.4: - resolution: {integrity: sha512-vVqVZQyf3WLx2Shd0qJ9xuvqgAyKPLAiqITEtqW0oIUjzo3PePDd6fW9iFz30ef7Ysp/oiWqbhszeGWW2T6Gzw==} - engines: {node: '>=10'} - hasBin: true - dev: false - - /mlly@1.5.0: - resolution: {integrity: sha512-NPVQvAY1xr1QoVeG0cy8yUYC7FQcOx6evl/RjT1wL5FvzPnzOysoqB/jmx/DhssT2dYa8nxECLAaFI/+gVLhDQ==} + /mlly@1.6.1: + resolution: {integrity: sha512-vLgaHvaeunuOXHSmEbZ9izxPx3USsk8KCQ8iC+aTlp5sKRSoZvwhHh5L9VbKSaVC6sJDqbyohIS76E2VmHIPAA==} dependencies: acorn: 8.11.3 pathe: 1.1.2 pkg-types: 1.0.3 - ufo: 1.3.2 + ufo: 1.4.0 dev: true /mnemonist@0.38.5: @@ -9088,22 +8655,21 @@ packages: obliterator: 2.0.4 dev: true - /mnemonist@0.39.5: - resolution: {integrity: sha512-FPUtkhtJ0efmEFGpU14x7jGbTB+s18LrzRL2KgoWz9YvcY3cPomz8tih01GbHwnGk/OmkOKfqd/RAQoc8Lm7DQ==} + /mnemonist@0.39.6: + resolution: {integrity: sha512-A/0v5Z59y63US00cRSLiloEIw3t5G+MiKz4BhX21FI+YBJXBOGW0ohFxTxO08dsOYlzxo87T7vGfZKYp2bcAWA==} dependencies: obliterator: 2.0.4 dev: false - /mobx@6.9.0: - resolution: {integrity: sha512-HdKewQEREEJgsWnErClfbFoVebze6rGazxFLU/XUyrII8dORfVszN1V0BMRnQSzcgsNNtkX8DHj3nC6cdWE9YQ==} + /mobx@6.12.0: + resolution: {integrity: sha512-Mn6CN6meXEnMa0a5u6a5+RKrqRedHBhZGd15AWLk9O6uFY4KYHzImdt8JI8WODo1bjTSRnwXhJox+FCUZhCKCQ==} dev: false - /mocha@10.0.0: - resolution: {integrity: sha512-0Wl+elVUD43Y0BqPZBzZt8Tnkw9CMUdNYnUsTfOM1vuhJVZL+kiesFYsqwBkEEuEixaiPe5ZQdqDgX2jddhmoA==} + /mocha@10.3.0: + resolution: {integrity: sha512-uF2XJs+7xSLsrmIvn37i/wnc91nw7XjOQB8ccyx5aEgdnohr7n+rEiZP23WkCYHjilR6+EboEnbq/ZQDz4LSbg==} engines: {node: '>= 14.0.0'} hasBin: true dependencies: - '@ungap/promise-all-settled': 1.1.2 ansi-colors: 4.1.1 browser-stdout: 1.3.1 chokidar: 3.5.3 @@ -9111,13 +8677,12 @@ packages: diff: 5.0.0 escape-string-regexp: 4.0.0 find-up: 5.0.0 - glob: 7.2.0 + glob: 8.1.0 he: 1.2.0 js-yaml: 4.1.0 log-symbols: 4.1.0 minimatch: 5.0.1 ms: 2.1.3 - nanoid: 3.3.3 serialize-javascript: 6.0.0 strip-json-comments: 3.1.1 supports-color: 8.1.1 @@ -9132,9 +8697,6 @@ packages: /ms@2.1.3: resolution: {integrity: sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==} - - /mute-stream@0.0.7: - resolution: {integrity: sha512-r65nCZhrbXXb6dXOACihYApHw2Q6pV0M3V0PSxd74N0+D8nzAdEAITq2oAjA1jVnKI+tGvEBUpqiMh0+rW6zDQ==} dev: true /mute-stream@0.0.8: @@ -9149,14 +8711,8 @@ packages: thenify-all: 1.6.0 dev: true - /nanoid@3.3.3: - resolution: {integrity: sha512-p1sjXuopFs0xg+fPASzQ28agW1oHD7xDsd9Xkf3T15H3c/cifrFHVwrh74PdoklAPi+i7MdRsE47vm2r6JoB+w==} - engines: {node: ^10 || ^12 || ^13.7 || ^14 || >=15.0.1} - hasBin: true - dev: true - - /nanoid@3.3.6: - resolution: {integrity: sha512-BGcqMMJuToF7i1rt+2PWSNVnWIkGCU78jBG3RxO/bZlnZPK2Cmi2QaffxGO/2RvWi9sL+FAiRiXMgsyxQ1DIDA==} + /nanoid@3.3.7: + resolution: {integrity: sha512-eSRppjcPIatRIMC1U6UngP8XFcz8MQWGQdt1MTBQ7NaAmvXDfvNxbvWV3x2y6CdEUciCSsDHDQZbhYaB8QEo2g==} engines: {node: ^10 || ^12 || ^13.7 || ^14 || >=15.0.1} hasBin: true dev: true @@ -9192,41 +8748,30 @@ packages: ts-error: 1.0.6 dev: false - /nice-grpc-web@2.0.1(google-protobuf@3.21.2): - resolution: {integrity: sha512-r8jy0TJY6ZO9qWtujiqmtRkqgItAChoJxJyYv+CHacP9G5kRIH03M+sQqtieXNNDUAKfFT/z5yroSy1cPFX0sA==} + /nice-grpc-web@2.0.2(google-protobuf@3.21.2): + resolution: {integrity: sha512-hIgvd0ufjOR1FqrakqQ1HdO6A8M1rps9cTCnO+8aPml2NXyLOsuZCdzCp/f31Y1ngBGvDkoalW5H+CBd11x+GQ==} dependencies: '@improbable-eng/grpc-web': 0.15.0(google-protobuf@3.21.2) - abort-controller-x: 0.4.1 - js-base64: 3.7.5 + abort-controller-x: 0.4.3 + js-base64: 3.7.7 nice-grpc-common: 2.0.2 transitivePeerDependencies: - google-protobuf dev: false - /nice-try@1.0.5: - resolution: {integrity: sha512-1nh45deeb5olNY7eX82BkPO7SSxR5SSYJiPTrTdFUVYwAl8CKMA5N9PjTYkHiRjisVcxcQ1HXdLhx2qxxJzLNQ==} - dev: true - - /node-abi@3.45.0: - resolution: {integrity: sha512-iwXuFrMAcFVi/ZoZiqq8BzAdsLw9kxDfTC0HMyjXfSL/6CSDAGD5UmR7azrAgWV1zKYq7dUUMj4owusBWKLsiQ==} - engines: {node: '>=10'} - dependencies: - semver: 7.5.0 - dev: false - - /node-abi@3.52.0: - resolution: {integrity: sha512-JJ98b02z16ILv7859irtXn4oUaFWADtvkzy2c0IAatNVX2Mc9Yoh8z6hZInn3QwvMEYhHuQloYi+TTQy67SIdQ==} + /node-abi@3.56.0: + resolution: {integrity: sha512-fZjdhDOeRcaS+rcpve7XuwHBmktS1nS1gzgghwKUQQ8nTy2FdSDr6ZT8k6YhvlJeHmmQMYiT/IH9hfco5zeW2Q==} engines: {node: '>=10'} dependencies: - semver: 7.5.0 + semver: 7.6.0 dev: false /node-addon-api@2.0.2: resolution: {integrity: sha512-Ntyt4AIXyaLIuMHF6IOoTakB3K+RWxwtsHNRxllEoA6vPwP9o4866g6YWDLUdnucilZhmkxiHwHr11gAENw+QA==} dev: true - /node-fetch@2.6.9: - resolution: {integrity: sha512-DJm/CJkZkRjKKj4Zi4BsKVZh3ValV5IR5s7LVZnW+6YMh0W1BfNA8XSs6DLMGYlId5F3KnA70uu2qepcR08Qqg==} + /node-fetch@2.7.0: + resolution: {integrity: sha512-c4FRfUm/dbcWZ7U+1Wq0AwCyFL+3nt2bEw05wfxSz+DWpWsitgmSgYmy2dQdWyKC1694ELPqMs/YzUSNozLt8A==} engines: {node: 4.x || >=6.0.0} peerDependencies: encoding: ^0.1.0 @@ -9237,54 +8782,25 @@ packages: whatwg-url: 5.0.0 dev: false - /node-gyp-build@4.5.0: - resolution: {integrity: sha512-2iGbaQBV+ITgCz76ZEjmhUKAKVf7xfY1sRl4UiKQspfZMH2h06SyhNsnSVy50cwkFQDGLyif6m/6uFXHkOZ6rg==} + /node-gyp-build@4.8.0: + resolution: {integrity: sha512-u6fs2AEUljNho3EYTJNBfImO5QTo/J/1Etd+NVdCj7qWKUSN/bSLkZwhDv7I+w/MSC6qJ4cknepkAYykDdK8og==} hasBin: true dev: true - /node-gyp@9.4.1: - resolution: {integrity: sha512-OQkWKbjQKbGkMf/xqI1jjy3oCTgMKJac58G2+bjZb3fza6gW2YrCSdMQYaoTb70crvE//Gngr4f0AgVHmqHvBQ==} - engines: {node: ^12.13 || ^14.13 || >=16} - hasBin: true - dependencies: - env-paths: 2.2.1 - exponential-backoff: 3.1.1 - glob: 7.2.3 - graceful-fs: 4.2.11 - make-fetch-happen: 10.2.1 - nopt: 6.0.0 - npmlog: 6.0.2 - rimraf: 3.0.2 - semver: 7.5.0 - tar: 6.2.0 - which: 2.0.2 - transitivePeerDependencies: - - bluebird - - supports-color - dev: false - /node-int64@0.4.0: resolution: {integrity: sha512-O5lz91xSOeoXP6DulyHfllpq+Eg00MWitZIbtPfoSEvqIHdl5gfcY6hYzDWnj0qD5tz52PI08u9qUvSVeUBeHw==} dev: true - /node-releases@2.0.10: - resolution: {integrity: sha512-5GFldHPXVG/YZmFzJvKK2zDSzPKhEp0+ZR5SVaoSag9fsL5YgHbUHDfnG5494ISANDcK4KwPXAx2xqVEydmd7w==} + /node-releases@2.0.14: + resolution: {integrity: sha512-y10wOWt8yZpqXmOgRo77WaHEmhYQYGNA6y421PKsKYWEK8aW+cqAphborZDhqfyKrbZEN92CN1X2KbafY2s7Yw==} dev: true - /nopt@6.0.0: - resolution: {integrity: sha512-ZwLpbTgdhuZUnZzjd7nb1ZV+4DoiC6/sfiVKok72ym/4Tlf+DFdlHYmT2JPmcNNWV6Pi3SDf1kT+A4r9RTuT9g==} - engines: {node: ^12.13.0 || ^14.15.0 || >=16.0.0} - hasBin: true - dependencies: - abbrev: 1.1.1 - dev: false - /normalize-package-data@2.5.0: resolution: {integrity: sha512-/5CMN3T0R4XTj4DcGaexo+roZSdSFW/0AOOTROrjxzCG1wrWXEsGbRKevjlIL+ZDE4sZlJr5ED4YW0yqmkK+eA==} dependencies: hosted-git-info: 2.8.9 - resolve: 1.22.2 - semver: 5.7.1 + resolve: 1.22.8 + semver: 5.7.2 validate-npm-package-license: 3.0.4 dev: true @@ -9303,25 +8819,11 @@ packages: dependencies: path-key: 3.1.1 - /npm-run-path@5.1.0: - resolution: {integrity: sha512-sJOdmRGrY2sjNTRMbSvluQqg+8X7ZK61yvzBEIDhz4f8z1TZFYABsqjjCBd/0PUNE9M6QDgHJXQkGUEm7Q+l9Q==} + /npm-run-path@5.3.0: + resolution: {integrity: sha512-ppwTtiJZq0O/ai0z7yfudtBpWIoxM8yE6nHi1X47eFR2EWORqfbu6CnPlNsjeN683eT0qG6H/Pyf9fCcvjnnnQ==} engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} dependencies: path-key: 4.0.0 - - /npmlog@6.0.2: - resolution: {integrity: sha512-/vBvz5Jfr9dT/aFWd0FIRf+T/Q2WBsLENygUaFUqstqsycmZAP/t5BvFJTK0viFmSUxiUKTUplWy5vt+rvKIxg==} - engines: {node: ^12.13.0 || ^14.15.0 || >=16.0.0} - dependencies: - are-we-there-yet: 3.0.1 - console-control-strings: 1.1.0 - gauge: 4.0.4 - set-blocking: 2.0.0 - dev: false - - /number-is-nan@1.0.1: - resolution: {integrity: sha512-4jbtZXNAsfZbAHiiqjLPBiCl16dES1zI4Hpzzxw61Tk+loF+sBDBKx1ICKKKwIqQ7M0mFn1TmkN7euSncWgHiQ==} - engines: {node: '>=0.10.0'} dev: true /number-to-bn@1.7.0: @@ -9341,18 +8843,13 @@ packages: engines: {node: '>=0.10.0'} dev: true - /object-hash@1.3.1: - resolution: {integrity: sha512-OSuu/pU4ENM9kmREg0BdNrUDIl1heYa4mBZacJc+vVWz4GtAwu7jO8s4AIt2aGRUTqxykpWzI3Oqnsm13tTMDA==} - engines: {node: '>= 0.10.0'} - dev: true - /object-hash@3.0.0: resolution: {integrity: sha512-RSn9F68PjH9HqtltsSnqYC1XXoWe9Bju5+213R98cNGttag9q9yAOTzdbsqvIa7aNm5WffBZFpWYr2aWrklWAw==} engines: {node: '>= 6'} dev: true - /object-inspect@1.12.2: - resolution: {integrity: sha512-z+cPxW0QGUp0mcqcsgQyLVRDoXFQbXOwBaqyF7VIgI4TWNQsDHrBpUQslRmIfAoYWdYzs6UlKJtB2XJpTaNSpQ==} + /object-inspect@1.13.1: + resolution: {integrity: sha512-5qoj1RUiKOMsCCNLV1CBiPYE10sziTsnmNxkAI/rZhiD63CF7IqdFGC/XzjWjpSgLf0LxXX3bDFIh0E18f6UhQ==} dev: true /object-keys@1.1.1: @@ -9360,55 +8857,55 @@ packages: engines: {node: '>= 0.4'} dev: true - /object.assign@4.1.4: - resolution: {integrity: sha512-1mxKf0e58bvyjSCtKYY4sRe9itRk3PJpquJOjeIkz885CczcI4IvJJDLPS72oowuSh+pBxUFROpX+TU++hxhZQ==} + /object.assign@4.1.5: + resolution: {integrity: sha512-byy+U7gp+FVwmyzKPYhW2h5l3crpmGsxl7X2s8y43IgxvG4g3QZ6CffDtsNQy1WsmZpQbO+ybo0AlW7TY6DcBQ==} engines: {node: '>= 0.4'} dependencies: - call-bind: 1.0.2 - define-properties: 1.1.4 + call-bind: 1.0.7 + define-properties: 1.2.1 has-symbols: 1.0.3 object-keys: 1.1.1 dev: true - /object.entries@1.1.6: - resolution: {integrity: sha512-leTPzo4Zvg3pmbQ3rDK69Rl8GQvIqMWubrkxONG9/ojtFE2rD9fjMKfSI5BxW3osRH1m6VdzmqK8oAY9aT4x5w==} + /object.entries@1.1.7: + resolution: {integrity: sha512-jCBs/0plmPsOnrKAfFQXRG2NFjlhZgjjcBLSmTnEhU8U6vVTsVe8ANeQJCHTl3gSsI4J+0emOoCgoKlmQPMgmA==} engines: {node: '>= 0.4'} dependencies: - call-bind: 1.0.2 - define-properties: 1.1.4 - es-abstract: 1.20.5 + call-bind: 1.0.7 + define-properties: 1.2.1 + es-abstract: 1.22.5 dev: true - /object.fromentries@2.0.6: - resolution: {integrity: sha512-VciD13dswC4j1Xt5394WR4MzmAQmlgN72phd/riNp9vtD7tp4QQWJ0R4wvclXcafgcYK8veHRed2W6XeGBvcfg==} + /object.fromentries@2.0.7: + resolution: {integrity: sha512-UPbPHML6sL8PI/mOqPwsH4G6iyXcCGzLin8KvEPenOZN5lpCNBZZQ+V62vdjB1mQHrmqGQt5/OJzemUA+KJmEA==} engines: {node: '>= 0.4'} dependencies: - call-bind: 1.0.2 - define-properties: 1.1.4 - es-abstract: 1.20.5 + call-bind: 1.0.7 + define-properties: 1.2.1 + es-abstract: 1.22.5 dev: true - /object.hasown@1.1.2: - resolution: {integrity: sha512-B5UIT3J1W+WuWIU55h0mjlwaqxiE5vYENJXIXZ4VFe05pNYrkKuK0U/6aFcb0pKywYJh7IhfoqUfKVmrJJHZHw==} + /object.hasown@1.1.3: + resolution: {integrity: sha512-fFI4VcYpRHvSLXxP7yiZOMAd331cPfd2p7PFDVbgUsYOfCT3tICVqXWngbjr4m49OvsBwUBQ6O2uQoJvy3RexA==} dependencies: - define-properties: 1.1.4 - es-abstract: 1.20.5 + define-properties: 1.2.1 + es-abstract: 1.22.5 dev: true - /object.values@1.1.6: - resolution: {integrity: sha512-FVVTkD1vENCsAcwNs9k6jea2uHC/X0+JcjG8YA60FN5CMaJmG95wT9jek/xX9nornqGRrBkKtzuAu2wuHpKqvw==} + /object.values@1.1.7: + resolution: {integrity: sha512-aU6xnDFYT3x17e/f0IiiwlGPTy2jzMySGfUB4fq6z7CV8l85CWHDk5ErhyhpfDHhrOMwGFhSQkhMGHaIotA6Ng==} engines: {node: '>= 0.4'} dependencies: - call-bind: 1.0.2 - define-properties: 1.1.4 - es-abstract: 1.20.5 + call-bind: 1.0.7 + define-properties: 1.2.1 + es-abstract: 1.22.5 dev: true /objnest@5.1.1: resolution: {integrity: sha512-C4fjNlHhUQbHiiFpgzvZse3/WUHq356Da3P8NZazg9JpPHFiQP2Y9lmYvpLU06midap0YpNz/MuA8GGSL8G0YQ==} engines: {node: '>=8', npm: '>=5'} dependencies: - '@babel/runtime': 7.21.0 + '@babel/runtime': 7.24.0 abind: 1.0.5 extend: 3.0.2 dev: false @@ -9416,8 +8913,9 @@ packages: /obliterator@2.0.4: resolution: {integrity: sha512-lgHwxlxV1qIg1Eap7LgIeoBWIMFibOjbrYPIPJZcI1mmGAI2m3lNYpK12Y+GBdPQ0U1hRwSord7GIaawz962qQ==} - /on-exit-leak-free@2.1.0: - resolution: {integrity: sha512-VuCaZZAjReZ3vUwgOB8LxAosIurDiAW0s13rI1YwmaP++jvcxP77AWoQvenZebpCA2m8WC1/EosPYPMjnRAp/w==} + /on-exit-leak-free@2.1.2: + resolution: {integrity: sha512-0eJJY6hXLGf1udHwfNftBqH+g73EU4B504nZeKpz1sYRKafAghwxEJunB2O7rDZkL4PGfsMVnTXZ2EjibbqcsA==} + engines: {node: '>=14.0.0'} dev: false /on-finished@2.4.1: @@ -9432,13 +8930,6 @@ packages: dependencies: wrappy: 1.0.2 - /onetime@2.0.1: - resolution: {integrity: sha512-oyyPpiMaKARvvcgip+JV+7zci5L8D1W9RZIz2l1o08AM3pfspitVWnPt3mzHcBPp12oYMTy0pqrFs/C+m3EwsQ==} - engines: {node: '>=4'} - dependencies: - mimic-fn: 1.2.0 - dev: true - /onetime@5.1.2: resolution: {integrity: sha512-kbpaSSGJTWdAY5KPVeMOKXSrPtr8C8C7wodJbcsd51jRnmD+GZu8Y0VoU6Dm5Z4vWr0Ig/1NKuWRKf7j5aaYSg==} engines: {node: '>=6'} @@ -9450,6 +8941,7 @@ packages: engines: {node: '>=12'} dependencies: mimic-fn: 4.0.0 + dev: true /only@0.0.2: resolution: {integrity: sha512-Fvw+Jemq5fjjyWz6CpKx6w9s7xxqo3+JCyM0WXWeCSOboZ8ABkyvP8ID4CZuChA/wxSx+XSJmdOm8rGVyJ1hdQ==} @@ -9459,28 +8951,16 @@ packages: resolution: {integrity: sha512-d/gTkTb1i1GKz5k3XE3XFV/PxQ1k45zDqGP2OA7YhgsaLoqm6qRvARAZOFer1fcXritWlGBRCu/UgeS4HAnXAA==} dev: false - /optionator@0.8.3: - resolution: {integrity: sha512-+IW9pACdk3XWmmTXG8m3upGUJst5XRGzxMRjXzAuJ1XnIFNvfhjjIuYkDvysnPQ7qzqVzLt78BCruntqRhWQbA==} - engines: {node: '>= 0.8.0'} - dependencies: - deep-is: 0.1.4 - fast-levenshtein: 2.0.6 - levn: 0.3.0 - prelude-ls: 1.1.2 - type-check: 0.3.2 - word-wrap: 1.2.3 - dev: true - - /optionator@0.9.1: - resolution: {integrity: sha512-74RlY5FCnhq4jRxVUPKDaRwrVNXMqsGsiW6AJw4XK8hmtm10wC0ypZBLw5IIp85NZMr91+qd1RvvENwg7jjRFw==} + /optionator@0.9.3: + resolution: {integrity: sha512-JjCoypp+jKn1ttEFExxhetCKeJt9zhAgAve5FXHixTvFDW/5aEktX9bufBKLRRMdU7bNtpLfcGu94B3cdEJgjg==} engines: {node: '>= 0.8.0'} dependencies: + '@aashutoshrathi/word-wrap': 1.2.6 deep-is: 0.1.4 fast-levenshtein: 2.0.6 levn: 0.4.1 prelude-ls: 1.2.1 type-check: 0.4.0 - word-wrap: 1.2.3 dev: true /ordinal@1.0.3: @@ -9502,10 +8982,10 @@ packages: p-map: 2.1.0 dev: true - /p-finally@2.0.1: - resolution: {integrity: sha512-vpm09aKwq6H9phqRQzecoDpD8TmVyGw70qmWlyq5onxY7tqyTTFVvxMykxQSQKILBSFlbXpypIw2T1Ml7+DDtw==} - engines: {node: '>=8'} - dev: true + /p-finally@1.0.0: + resolution: {integrity: sha512-LICb2p9CB7FS+0eR1oqWnHhp0FljGLZCWBE9aix0Uye9W8LTQPwMTYVGWQWIw9RdQiDg4+epXQODwIYJtSJaow==} + engines: {node: '>=4'} + dev: false /p-is-promise@3.0.0: resolution: {integrity: sha512-Wo8VsW4IRQSKVXsJCn7TomUaVtyfjVDn3nUP7kE967BQk0CwFpdbZs0X0uk5sW9mkBa9eNM7hCMaG93WUAwxYQ==} @@ -9530,13 +9010,13 @@ packages: engines: {node: '>=10'} dependencies: yocto-queue: 0.1.0 - dev: true /p-limit@4.0.0: resolution: {integrity: sha512-5b0R4txpzjPWVw/cXXUResoD4hb6U/x9BH08L7nw+GN1sezDzPdxeRvpc9c433fZhBan/wusjbCsqwqm4EIBIQ==} engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} dependencies: yocto-queue: 1.0.0 + dev: true /p-locate@2.0.0: resolution: {integrity: sha512-nQja7m7gSKuewoVRen45CtVfODR3crN3goVQ0DDZ9N3yHxgpkuBhZqsaiotSQRrADUrne346peY7kT3TSACykg==} @@ -9564,14 +9044,6 @@ packages: engines: {node: '>=10'} dependencies: p-limit: 3.1.0 - dev: true - - /p-locate@6.0.0: - resolution: {integrity: sha512-wPrq66Llhl7/4AGC6I+cqxT07LhXvWL08LNXz1fENOw0Ap4sRZZ/gZpTTJ5jpurzzzfS2W/Ge9BY3LgLjCShcw==} - engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} - dependencies: - p-limit: 4.0.0 - dev: false /p-map@2.1.0: resolution: {integrity: sha512-y3b8Kpd8OAN444hxfBbFfj1FY/RjtTd8tzYwhUqNYXx0fXx2iX4maP4Qr6qhIKbQXI02wTLAda4fYUbDagTUFw==} @@ -9583,26 +9055,29 @@ packages: engines: {node: '>=10'} dependencies: aggregate-error: 3.1.0 + dev: true - /p-queue@7.4.1: - resolution: {integrity: sha512-vRpMXmIkYF2/1hLBKisKeVYJZ8S2tZ0zEAmIJgdVKP2nq0nh4qCdf8bgw+ZgKrkh71AOCaqzwbJJk1WtdcF3VA==} - engines: {node: '>=12'} + /p-queue@6.6.2: + resolution: {integrity: sha512-RwFpb72c/BhQLEXIZ5K2e+AhgNVmIejGlTgiB9MzZ0e93GRvqZ7uSi0dvRF7/XIXDeNkra2fNHBxTyPDGySpjQ==} + engines: {node: '>=8'} dependencies: - eventemitter3: 5.0.1 - p-timeout: 5.1.0 + eventemitter3: 4.0.7 + p-timeout: 3.2.0 dev: false - /p-retry@5.1.2: - resolution: {integrity: sha512-couX95waDu98NfNZV+i/iLt+fdVxmI7CbrrdC2uDWfPdUAApyxT4wmDlyOtR5KtTDmkDO0zDScDjDou9YHhd9g==} - engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} + /p-retry@4.6.2: + resolution: {integrity: sha512-312Id396EbJdvRONlngUx0NydfrIQ5lsYu0znKVUzVvArzEIt08V1qhtyESbGVd1FGX7UKtiFp5uwKZdM8wIuQ==} + engines: {node: '>=8'} dependencies: - '@types/retry': 0.12.1 + '@types/retry': 0.12.0 retry: 0.13.1 dev: false - /p-timeout@5.1.0: - resolution: {integrity: sha512-auFDyzzzGZZZdHz3BtET9VEz0SE/uMEAx7uWfGPucfzEwwe/xH0iVeZibQmANYE/hp9T2+UUZT5m+BKyrDp3Ew==} - engines: {node: '>=12'} + /p-timeout@3.2.0: + resolution: {integrity: sha512-rhIwUycgwwKcP9yTOOFK/AKsAopjjCakVqLHePO3CC6Mir1Z99xT+R63jZxAT5lFZLa2inS5h+ZS2GvR99/FBg==} + engines: {node: '>=8'} + dependencies: + p-finally: 1.0.0 dev: false /p-try@1.0.0: @@ -9621,19 +9096,11 @@ packages: callsites: 3.1.0 dev: true - /parse-json@4.0.0: - resolution: {integrity: sha512-aOIos8bujGN93/8Ox/jPLh7RwVnPEysynVFE+fQZyg6jKELEHwzgKdLRFHUgXJL6kylijVSBC4BvN9OmsB48Rw==} - engines: {node: '>=4'} - dependencies: - error-ex: 1.3.2 - json-parse-better-errors: 1.0.2 - dev: true - /parse-json@5.2.0: resolution: {integrity: sha512-ayCKvm/phCGxOkYRSCM82iDwct8/EonSEgCSxWxD7ve6jHggsFl4fZVQBPRNgQoKiuV/odhFrGzQXZwbifC8Rg==} engines: {node: '>=8'} dependencies: - '@babel/code-frame': 7.21.4 + '@babel/code-frame': 7.23.5 error-ex: 1.3.2 json-parse-even-better-errors: 2.3.1 lines-and-columns: 1.2.4 @@ -9657,24 +9124,10 @@ packages: /path-exists@4.0.0: resolution: {integrity: sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==} engines: {node: '>=8'} - dev: true - - /path-exists@5.0.0: - resolution: {integrity: sha512-RjhtfwJOxzcFmNOi6ltcbcu4Iu+FL3zEj83dk4kAS+fVpTxXLO1b38RvJgT/0QwvV/L3aY9TAnyv0EOqW4GoMQ==} - engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} - dev: false /path-is-absolute@1.0.1: resolution: {integrity: sha512-AVbw3UJ2e9bq64vSaS9Am0fje1Pa8pbGqTTsmXfaIiMpnr5DlDhfJOuLj9Sf95ZPVDAUerDfEk88MPmPe7UCQg==} engines: {node: '>=0.10.0'} - - /path-is-inside@1.0.2: - resolution: {integrity: sha512-DUWJr3+ULp4zXmol/SZkFf3JGsS9/SIv+Y3Rt93/UjPpDpklB5f1er4O3POIbUuUJ3FXgqte2Q7SrU6zAqwk8w==} - dev: true - - /path-key@2.0.1: - resolution: {integrity: sha512-fEHGKCSmUSDPv4uoj8AlD+joPlq3peND+HRYyxFz4KPw4z926S/b8rIuFs2FYJg3BwsxJf6A9/3eIdLaYC+9Dw==} - engines: {node: '>=4'} dev: true /path-key@3.1.1: @@ -9684,11 +9137,20 @@ packages: /path-key@4.0.0: resolution: {integrity: sha512-haREypq7xkM7ErfgIyA0z+Bj4AGKlMSdlQE2jvJo6huWD1EdkKYV+G/T4nq0YEF2vgTT8kqMFKo1uHn950r4SQ==} engines: {node: '>=12'} + dev: true /path-parse@1.0.7: resolution: {integrity: sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==} dev: true + /path-scurry@1.10.1: + resolution: {integrity: sha512-MkhCqzzBEpPvxxQ71Md0b1Kk51W01lrYvlMzSUaIzNsODdd7mqhiimSZlr+VegAz5Z6Vzt9Xg2ttE//XBhH3EQ==} + engines: {node: '>=16 || 14 >=14.17'} + dependencies: + lru-cache: 10.2.0 + minipass: 7.0.4 + dev: true + /path-to-regexp@6.2.1: resolution: {integrity: sha512-JLyh7xT1kizaEvcaXOQwOc2/Yhw6KZOvPf1S8401UyLk86CU79LN3vl7ztXGm/pZ+YjoyAJ4rxmHwbkBXJX+yw==} dev: false @@ -9745,6 +9207,12 @@ packages: resolution: {integrity: sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==} engines: {node: '>=8.6'} + /pidtree@0.6.0: + resolution: {integrity: sha512-eG2dWTVw5bzqGRztnHExczNxt5VGsE6OwTeCG3fdUf9KBsZzO3R5OIIIzWR+iZA0NtZ+RDVdaoE2dK1cn6jH4g==} + engines: {node: '>=0.10'} + hasBin: true + dev: true + /pify@2.3.0: resolution: {integrity: sha512-udgsAY+fTnvv7kI7aaxbqwWNb0AHiB0qBO89PZKPkoTmGOgdbrHDKD+0B2X4uTfJ/FT1R09r9gTsjUjNJotuog==} engines: {node: '>=0.10.0'} @@ -9760,10 +9228,10 @@ packages: engines: {node: '>=6'} dev: true - /pino-abstract-transport@1.0.0: - resolution: {integrity: sha512-c7vo5OpW4wIS42hUVcT5REsL8ZljsUfBjqV/e2sFxmFEFZiq1XLUp5EYLtuDH6PEHq9W1egWqRbnLUP5FuZmOA==} + /pino-abstract-transport@1.1.0: + resolution: {integrity: sha512-lsleG3/2a/JIWUtf9Q5gUNErBqwIu1tUKTT3dUzaf5DySw9ra1wcqKjJjLX1VTY64Wk1eEOYsVGSaGfCK85ekA==} dependencies: - readable-stream: 4.4.2 + readable-stream: 4.5.2 split2: 4.2.0 dev: false @@ -9771,25 +9239,25 @@ packages: resolution: {integrity: sha512-cHjPPsE+vhj/tnhCy/wiMh3M3z3h/j15zHQX+S9GkTBgqJuTuJzYJ4gUyACLhDaJ7kk9ba9iRDmbH2tJU03OiA==} dev: false - /pino@8.14.2: - resolution: {integrity: sha512-zKu9aWeSWTy1JgvxIpZveJKKsAr4+6uNMZ0Vf0KRwzl/UNZA3XjHiIl/0WwqLMkDwuHuDkT5xAgPA2jpKq4whA==} + /pino@8.19.0: + resolution: {integrity: sha512-oswmokxkav9bADfJ2ifrvfHUwad6MLp73Uat0IkQWY3iAw5xTRoznXbXksZs8oaOUMpmhVWD+PZogNzllWpJaA==} hasBin: true dependencies: atomic-sleep: 1.0.0 fast-redact: 3.3.0 - on-exit-leak-free: 2.1.0 - pino-abstract-transport: 1.0.0 + on-exit-leak-free: 2.1.2 + pino-abstract-transport: 1.1.0 pino-std-serializers: 6.2.2 - process-warning: 2.2.0 + process-warning: 3.0.0 quick-format-unescaped: 4.0.4 real-require: 0.2.0 safe-stable-stringify: 2.4.3 - sonic-boom: 3.3.0 - thread-stream: 2.3.0 + sonic-boom: 3.8.0 + thread-stream: 2.4.1 dev: false - /pirates@4.0.5: - resolution: {integrity: sha512-8V9+HQPupnaXMA23c5hvl69zXvTwTzyAYasnkb0Tts4XvO4CliqONMOnvlq26rkhLC3nWDFBJf73LU1e1VZLaQ==} + /pirates@4.0.6: + resolution: {integrity: sha512-saLsH7WeYYPiD25LDuLRRY/i+6HaPYr6G1OUlN39otzkSTxKnubR9RTxS3/Kk50s1g2JTgFwWQDQyplC5/SHZg==} engines: {node: '>= 6'} dev: true @@ -9803,8 +9271,8 @@ packages: /pkg-types@1.0.3: resolution: {integrity: sha512-nN7pYi0AQqJnoLPC9eHFQ8AcyaixBUOwvqc5TDnIKCMEE6I0y8P7OKA7fPexsXGCGxQDl/cmrLAp26LhcwxZ4A==} dependencies: - jsonc-parser: 3.2.0 - mlly: 1.5.0 + jsonc-parser: 3.2.1 + mlly: 1.6.1 pathe: 1.1.2 dev: true @@ -9815,35 +9283,39 @@ packages: find-up: 3.0.0 dev: false - /please-upgrade-node@3.2.0: - resolution: {integrity: sha512-gQR3WpIgNIKwBMVLkpMUeR3e1/E1y42bqDQZfql+kDeXd8COYfM8PQA4X6y7a8u9Ua9FHmsrrmirW2vHs45hWg==} - dependencies: - semver-compare: 1.0.0 + /pluralize@8.0.0: + resolution: {integrity: sha512-Nc3IT5yHzflTfbjgqWcCPpo7DaKy4FnpB0l/zCAW0Tc7jxAiuqSxHasntB3D7887LSrA93kDJ9IXovxJYxyLCA==} + engines: {node: '>=4'} + dev: true + + /possible-typed-array-names@1.0.0: + resolution: {integrity: sha512-d7Uw+eZoloe0EHDIYoe+bQ5WXnGMOpmiZFTuMWCwpjzzkL2nTjcKiAk4hh8TjnGye2TwWOk3UXucZ+3rbmBa8Q==} + engines: {node: '>= 0.4'} dev: true - /postcss-import@15.1.0(postcss@8.4.23): + /postcss-import@15.1.0(postcss@8.4.35): resolution: {integrity: sha512-hpr+J05B2FVYUAXHeK1YyI267J/dDDhMU6B6civm8hSY1jYJnBXxzKDKDswzJmtLHryrjhnDjqqp/49t8FALew==} engines: {node: '>=14.0.0'} peerDependencies: postcss: ^8.0.0 dependencies: - postcss: 8.4.23 + postcss: 8.4.35 postcss-value-parser: 4.2.0 read-cache: 1.0.0 - resolve: 1.22.2 + resolve: 1.22.8 dev: true - /postcss-js@4.0.1(postcss@8.4.23): + /postcss-js@4.0.1(postcss@8.4.35): resolution: {integrity: sha512-dDLF8pEO191hJMtlHFPRa8xsizHaM82MLfNkUHdUtVEV3tgTp5oj+8qbEqYM57SLfc74KSbw//4SeJma2LRVIw==} engines: {node: ^12 || ^14 || >= 16} peerDependencies: postcss: ^8.4.21 dependencies: camelcase-css: 2.0.1 - postcss: 8.4.23 + postcss: 8.4.35 dev: true - /postcss-load-config@3.1.4(postcss@8.4.23): + /postcss-load-config@3.1.4(postcss@8.4.35): resolution: {integrity: sha512-6DiM4E7v4coTE4uzA8U//WhtPwyhiim3eyjEMFCnUpzbrkK9wJHgKDT2mR+HbtSrd/NubVaYTOpSpjUl8NQeRg==} engines: {node: '>= 10'} peerDependencies: @@ -9856,12 +9328,12 @@ packages: optional: true dependencies: lilconfig: 2.1.0 - postcss: 8.4.23 + postcss: 8.4.35 yaml: 1.10.2 dev: true - /postcss-load-config@4.0.1(postcss@8.4.23): - resolution: {integrity: sha512-vEJIc8RdiBRu3oRAI0ymerOn+7rPuMvRXslTvZUKZonDHFIczxztIyJ1urxM1x9JXEikvpWWTUUqal5j/8QgvA==} + /postcss-load-config@4.0.2(postcss@8.4.35): + resolution: {integrity: sha512-bSVhyJGL00wMVoPUzAVAnbEoWyqRxkjv64tUl427SKnPrENtq6hJwUojroMz2VB+Q1edmi4IfrAPpami5VVgMQ==} engines: {node: '>= 14'} peerDependencies: postcss: '>=8.0.9' @@ -9872,23 +9344,23 @@ packages: ts-node: optional: true dependencies: - lilconfig: 2.1.0 - postcss: 8.4.23 - yaml: 2.2.2 + lilconfig: 3.1.1 + postcss: 8.4.35 + yaml: 2.4.0 dev: true - /postcss-nested@6.0.1(postcss@8.4.23): + /postcss-nested@6.0.1(postcss@8.4.35): resolution: {integrity: sha512-mEp4xPMi5bSWiMbsgoPfcP74lsWLHkQbZc3sY+jWYd65CUwXrUaTp0fmNpa01ZcETKlIgUdFN/MpS2xZtqL9dQ==} engines: {node: '>=12.0'} peerDependencies: postcss: ^8.2.14 dependencies: - postcss: 8.4.23 - postcss-selector-parser: 6.0.11 + postcss: 8.4.35 + postcss-selector-parser: 6.0.15 dev: true - /postcss-selector-parser@6.0.11: - resolution: {integrity: sha512-zbARubNdogI9j7WY4nQJBiNqQf3sLS3wCP4WfOidu+p28LofJqDH1tcXypGrcmMHhDk2t9wGhCsYe/+szLTy1g==} + /postcss-selector-parser@6.0.15: + resolution: {integrity: sha512-rEYkQOMUCEMhsKbK66tbEU9QVIxbhN18YiniAwA7XQYTVBqrBy+P2p5JcdqsHgKM2zWylp8d7J6eszocfds5Sw==} engines: {node: '>=4'} dependencies: cssesc: 3.0.0 @@ -9899,11 +9371,11 @@ packages: resolution: {integrity: sha512-1NNCs6uurfkVbeXG4S8JFT9t19m45ICnif8zWLd5oPSZ50QnwMfK+H3jv408d4jw/7Bttv5axS5IiHoLaVNHeQ==} dev: true - /postcss@8.4.23: - resolution: {integrity: sha512-bQ3qMcpF6A/YjR55xtoTr0jGOlnPOKAIMdOWiv0EIT6HVPEaJiJB4NLljSbiHoC2RX7DN5Uvjtpbg1NPdwv1oA==} + /postcss@8.4.35: + resolution: {integrity: sha512-u5U8qYpBCpN13BsiEB0CbR1Hhh4Gc0zLFuedrHJKMctHCHAGrMdG0PRM/KErzAL3CU6/eckEtmHNB3x6e3c0vA==} engines: {node: ^10 || ^12 || >=14} dependencies: - nanoid: 3.3.6 + nanoid: 3.3.7 picocolors: 1.0.0 source-map-js: 1.0.2 dev: true @@ -9912,8 +9384,8 @@ packages: resolution: {integrity: sha512-+JD93VELV9gHkqpV5gdL5/70HdGtEw4/XE1S4BC8f1mcPmdib3K5XsKVbnR1XcAyC41zOnifJ+9YRKxdIsXiUw==} dev: false - /prebuild-install@7.1.1: - resolution: {integrity: sha512-jAXscXWMcCK8GgCoHOfIr0ODh5ai8mj63L2nWrjuAgXE6tDyYGnx4/8o/rCgU+B4JSyZBKbeZqzhtwtC3ovxjw==} + /prebuild-install@7.1.2: + resolution: {integrity: sha512-UnNke3IQb6sgarcZIDU3gbMeTp/9SSU1DAIkil7PrqG1vZlBtY5msYccSKSHDqa3hNg436IXK+SNImReuA1wEQ==} engines: {node: '>=10'} hasBin: true dependencies: @@ -9923,7 +9395,7 @@ packages: minimist: 1.2.8 mkdirp-classic: 0.5.3 napi-build-utils: 1.0.2 - node-abi: 3.45.0 + node-abi: 3.56.0 pump: 3.0.0 rc: 1.2.8 simple-get: 4.0.1 @@ -9931,8 +9403,8 @@ packages: tunnel-agent: 0.6.0 dev: false - /preferred-pm@3.0.3: - resolution: {integrity: sha512-+wZgbxNES/KlJs9q40F/1sfOd/j7f1O9JaHcW5Dsn3aUUOZg3L2bjpVUcKV2jvtElYfoTuQiNeMfQJ4kwUAhCQ==} + /preferred-pm@3.1.3: + resolution: {integrity: sha512-MkXsENfftWSRpzCzImcp4FRsCc3y1opwB73CfCNWyzMqArju2CrlMHlqB7VexKiPEOjGMbttv1r9fSCn5S610w==} engines: {node: '>=10'} dependencies: find-up: 5.0.0 @@ -9941,39 +9413,46 @@ packages: which-pm: 2.0.0 dev: true - /prelude-ls@1.1.2: - resolution: {integrity: sha512-ESF23V4SKG6lVSGZgYNpbsiaAkdab6ZgOxe52p7+Kid3W3u3bxR4Vfd/o21dmN7jSt0IwgZ4v5MUd26FEtXE9w==} - engines: {node: '>= 0.8.0'} - dev: true - /prelude-ls@1.2.1: resolution: {integrity: sha512-vkcDPrRZo1QZLbn5RLGPpg/WmIQ65qoWWhcGKf/b5eplkkarX0m9z8ppCat4mlOqUsWpyNuYgO3VRyrYHSzX5g==} engines: {node: '>= 0.8.0'} dev: true - /prettier-plugin-solidity@1.1.3(prettier@2.8.4): + /prettier-plugin-solidity@1.1.3(prettier@2.8.8): resolution: {integrity: sha512-fQ9yucPi2sBbA2U2Xjh6m4isUTJ7S7QLc/XDDsktqqxYfTwdYKJ0EnnywXHwCGAaYbQNK+HIYPL1OemxuMsgeg==} engines: {node: '>=12'} peerDependencies: prettier: '>=2.3.0 || >=3.0.0-alpha.0' dependencies: - '@solidity-parser/parser': 0.16.0 - prettier: 2.8.4 - semver: 7.5.0 + '@solidity-parser/parser': 0.16.2 + prettier: 2.8.8 + semver: 7.6.0 solidity-comments-extractor: 0.0.7 + dev: true - /prettier@1.19.1: - resolution: {integrity: sha512-s7PoyDv/II1ObgQunCbB9PdLmUcBZcnWOcxDh7O0N/UwDEsHyqkW+Qh28jW+mVuCdx7gLB0BotYI1Y6uI9iyew==} - engines: {node: '>=4'} + /prettier-plugin-solidity@1.1.3(prettier@3.2.5): + resolution: {integrity: sha512-fQ9yucPi2sBbA2U2Xjh6m4isUTJ7S7QLc/XDDsktqqxYfTwdYKJ0EnnywXHwCGAaYbQNK+HIYPL1OemxuMsgeg==} + engines: {node: '>=12'} + peerDependencies: + prettier: '>=2.3.0 || >=3.0.0-alpha.0' + dependencies: + '@solidity-parser/parser': 0.16.2 + prettier: 3.2.5 + semver: 7.6.0 + solidity-comments-extractor: 0.0.7 + dev: false + + /prettier@2.8.8: + resolution: {integrity: sha512-tdN8qQGvNjw4CHbY+XXk0JgCXn9QiF21a55rBe5LJAU+kDyC4WQn4+awm2Xfk2lQMk5fKup9XgzTZtGkjBdP9Q==} + engines: {node: '>=10.13.0'} hasBin: true - requiresBuild: true dev: true - optional: true - /prettier@2.8.4: - resolution: {integrity: sha512-vIS4Rlc2FNh0BySk3Wkd6xmwxB0FpOndW5fisM5H8hsZSxU2VWVB5CWIkIjWvrHjIhxk2g3bfMKM87zNTrZddw==} - engines: {node: '>=10.13.0'} + /prettier@3.2.5: + resolution: {integrity: sha512-3/GWa9aOC0YeD7LUfvOG2NiDyhOWRvt1k+rcKhOuYnMY24iiCphgneUfJDyFXd6rZCAnuLBv6UeAULtrhT/F4A==} + engines: {node: '>=14'} hasBin: true + dev: false /pretty-format@27.5.1: resolution: {integrity: sha512-Qb1gy5OrP5+zDf2Bvnzdl3jsTf1qXVMazbvCoKhtKqVs4/YK4ozX4gKQJJVyNe+cajNPn0KoC0MC3FUmaHWEmQ==} @@ -9984,11 +9463,11 @@ packages: react-is: 17.0.2 dev: true - /pretty-format@29.5.0: - resolution: {integrity: sha512-V2mGkI31qdttvTFX7Mt4efOqHXqJWMu4/r66Xh3Z3BwZaPfPJgp6/gbwoujRpPUtfEF6AUUWx3Jim3GCw5g/Qw==} + /pretty-format@29.7.0: + resolution: {integrity: sha512-Pdlw/oPxN+aXdmM9R00JVC9WVFoCLTKJvDVLgmJ+qAffBMxsV85l/Lu7sNx4zSzPyoL2euImuEwHhOXdEgNFZQ==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} dependencies: - '@jest/schemas': 29.4.3 + '@jest/schemas': 29.6.3 ansi-styles: 5.2.0 react-is: 18.2.0 dev: true @@ -9997,8 +9476,12 @@ packages: resolution: {integrity: sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag==} dev: false - /process-warning@2.2.0: - resolution: {integrity: sha512-/1WZ8+VQjR6avWOgHeEPd7SDQmFQ1B5mC1eRXsCm5TarlNmx/wCsa5GEaxGm05BORRtyG/Ex/3xq3TuRvq57qg==} + /process-warning@2.3.2: + resolution: {integrity: sha512-n9wh8tvBe5sFmsqlg+XQhaQLumwpqoAUruLwjCopgTmUBjJ/fjtBsJzKleCaIGBOMXYEhp1YfKl4d7rJ5ZKJGA==} + dev: false + + /process-warning@3.0.0: + resolution: {integrity: sha512-mqn0kFRl0EoqhnL0GQ0veqFHyIN1yig9RHh/InzORTUiZHFRAur+aMtRkELNwGs9aNwKS6tg/An4NYBPGwvtzQ==} dev: false /process@0.11.10: @@ -10006,28 +9489,6 @@ packages: engines: {node: '>= 0.6.0'} dev: false - /progress@2.0.3: - resolution: {integrity: sha512-7PiHtLll5LdnKIMw100I+8xJXR5gW2QwWYkT6iJva0bXitZKa/XMrSbdmg3r2Xnaidz9Qumd0VPaMrZlF9V9sA==} - engines: {node: '>=0.4.0'} - dev: true - - /promise-inflight@1.0.1: - resolution: {integrity: sha512-6zWPyEOFaQBJYcGMHBKTKJ3u6TBsnMFOIZSa6ce1e/ZrrsOlnHRHbabMjLiBYKp+n44X9eUI6VUPaukCXHuG4g==} - peerDependencies: - bluebird: '*' - peerDependenciesMeta: - bluebird: - optional: true - dev: false - - /promise-retry@2.0.1: - resolution: {integrity: sha512-y+WKFlBR8BGXnsNlIHFGPZmyDf3DFMoLhaflAnyZgV6rG6xu+JwesTo2Q9R6XwYmtmwAFCkAk3e35jEdoeh/3g==} - engines: {node: '>=10'} - dependencies: - err-code: 2.0.3 - retry: 0.12.0 - dev: false - /prompts@2.4.2: resolution: {integrity: sha512-NxNv/kLguCA7p3jE8oL2aEBsrJWgAakBpgmgK6lpPWV+WuOmY6r2/zbAVnP+T8bQlA0nzHXSJSJW0Hq7ylaD2Q==} engines: {node: '>= 6'} @@ -10044,28 +9505,8 @@ packages: react-is: 16.13.1 dev: true - /protobufjs@6.11.3: - resolution: {integrity: sha512-xL96WDdCZYdU7Slin569tFX712BxsxslWwAfAhCYjQKGTq7dAU91Lomy6nLLhh/dyGhk/YH4TwTSRxTzhuHyZg==} - hasBin: true - requiresBuild: true - dependencies: - '@protobufjs/aspromise': 1.1.2 - '@protobufjs/base64': 1.1.2 - '@protobufjs/codegen': 2.0.4 - '@protobufjs/eventemitter': 1.1.0 - '@protobufjs/fetch': 1.1.0 - '@protobufjs/float': 1.0.2 - '@protobufjs/inquire': 1.1.0 - '@protobufjs/path': 1.1.2 - '@protobufjs/pool': 1.1.0 - '@protobufjs/utf8': 1.1.0 - '@types/long': 4.0.2 - '@types/node': 18.15.11 - long: 4.0.0 - dev: true - - /protobufjs@7.2.3: - resolution: {integrity: sha512-TtpvOqwB5Gdz/PQmOjgsrGH1nHjAQVCN7JG4A6r1sXRWESL5rNMAiRcBQlCAdKxZcAbstExQePYG8xof/JVRgg==} + /protobufjs@7.2.6: + resolution: {integrity: sha512-dgJaEDDL6x8ASUZ1YqWciTRrdOuYNzoOf27oHNfdyvKqHr5i0FV7FSLU+aIeFjyFgVxrpTOtQUi0BLLBymZaBw==} engines: {node: '>=12.0.0'} requiresBuild: true dependencies: @@ -10079,9 +9520,8 @@ packages: '@protobufjs/path': 1.1.2 '@protobufjs/pool': 1.1.0 '@protobufjs/utf8': 1.1.0 - '@types/node': 18.15.11 - long: 5.2.1 - dev: false + '@types/node': 18.19.21 + long: 5.2.3 /proxy-addr@2.0.7: resolution: {integrity: sha512-llQsMLSUDUPT44jdrU/O37qlnifitDP+ZwrmmZcoSKyLKvtZxpyV0n2/bD/N4tBAAZ/gJEdZU7KMraoK1+XYAg==} @@ -10095,10 +9535,6 @@ packages: resolution: {integrity: sha512-kppbvLUNJ4IOMZds9/4gz/rtT5OFiesy3XosLsgMKlF3vb6GA5Y3ptyDlzKLcOcUBW+zaY+RiMINTsgE+O6e+Q==} dev: false - /prr@1.0.1: - resolution: {integrity: sha512-yPw4Sng1gWghHQWj0B3ZggWUm4qVbPwPFcRG8KyxiU7J2OHFSoEHKS+EZ3fv5l1t9CyCiop6l/ZYeWbrgoQejw==} - dev: true - /pseudomap@1.0.2: resolution: {integrity: sha512-b/YwNhb8lk1Zz2+bXXpS/LK9OisiZZ1SNsSLxN1x2OXVEhW2Ckr/7mWE5vrC1ZTiJlD9g19jWszTmJsB+oEpFQ==} dev: true @@ -10112,6 +9548,7 @@ packages: dependencies: end-of-stream: 1.4.4 once: 1.4.0 + dev: false /pumpify@2.0.1: resolution: {integrity: sha512-m7KOje7jZxrmutanlkS1daj1dS6z6BgslzOXmcSEpIlCxM3VJH7lG5QLeck/6hgF6F4crFf01UtQmNsJfweTAw==} @@ -10121,24 +9558,12 @@ packages: pump: 3.0.0 dev: false - /punycode@2.1.1: - resolution: {integrity: sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A==} + /punycode@2.3.1: + resolution: {integrity: sha512-vYt7UD1U9Wg6138shLtLOvdAu+8DsC/ilFtEVHcH+wydcSpNE20AfSOduf6MkRFahL5FY7X1oU7nKVZFtfq8Fg==} engines: {node: '>=6'} - dev: true - - /punycode@2.3.0: - resolution: {integrity: sha512-rRV+zQD8tVFys26lAGR9WUuS4iUAngJScM+ZRSKtvl5tKeZ2t5bvdNFdNHBW9FWR4guGHlgmsZ1G7BSm2wTbuA==} - engines: {node: '>=6'} - - /pure-rand@6.0.1: - resolution: {integrity: sha512-t+x1zEHDjBwkDGY5v5ApnZ/utcd4XYDiJsaQQoptTXgUXX95sDg1elCdJghzicm7n2mbCBJ3uYWr6M22SO19rg==} - dev: true - /qs@6.11.0: - resolution: {integrity: sha512-MvjoMCJwEarSbUYk5O+nmoSzSutSsTwF85zcHPQ9OrlFoZOYIjaqBAJIqIXjptyD5vThxGq52Xu/MaJzRkIk4Q==} - engines: {node: '>=0.6'} - dependencies: - side-channel: 1.0.4 + /pure-rand@6.0.4: + resolution: {integrity: sha512-LA0Y9kxMYv47GIPJy6MI84fqTd2HmYZI83W/kM/SkKfDlajnZYfmXFTxkbY+xSBPkLJxltMa9hIkmdc29eguMA==} dev: true /querystringify@2.2.0: @@ -10199,7 +9624,7 @@ packages: peerDependencies: react: '>=16.13.1' dependencies: - '@babel/runtime': 7.21.0 + '@babel/runtime': 7.24.0 react: 18.2.0 dev: true @@ -10220,26 +9645,26 @@ packages: engines: {node: '>=0.10.0'} dev: true - /react-router-dom@6.11.0(react-dom@18.2.0)(react@18.2.0): - resolution: {integrity: sha512-Q3mK1c/CYoF++J6ZINz7EZzwlgSOZK/kc7lxIA7PhtWhKju4KfF1WHqlx0kVCIFJAWztuYVpXZeljEbds8z4Og==} - engines: {node: '>=14'} + /react-router-dom@6.22.2(react-dom@18.2.0)(react@18.2.0): + resolution: {integrity: sha512-WgqxD2qySEIBPZ3w0sHH+PUAiamDeszls9tzqMPBDA1YYVucTBXLU7+gtRfcSnhe92A3glPnvSxK2dhNoAVOIQ==} + engines: {node: '>=14.0.0'} peerDependencies: react: '>=16.8' react-dom: '>=16.8' dependencies: - '@remix-run/router': 1.6.0 + '@remix-run/router': 1.15.2 react: 18.2.0 react-dom: 18.2.0(react@18.2.0) - react-router: 6.11.0(react@18.2.0) + react-router: 6.22.2(react@18.2.0) dev: false - /react-router@6.11.0(react@18.2.0): - resolution: {integrity: sha512-hTm6KKNpj9SDG4syIWRjCU219O0RZY8RUPobCFt9p+PlF7nnkRgMoh2DieTKvw3F3Mw6zg565HGnSv8BuoY5oQ==} - engines: {node: '>=14'} + /react-router@6.22.2(react@18.2.0): + resolution: {integrity: sha512-YD3Dzprzpcq+tBMHBS822tCjnWD3iIZbTeSXMY9LPSG541EfoBGyZ3bS25KEnaZjLcmQpw2AVLkFyfgXY8uvcw==} + engines: {node: '>=14.0.0'} peerDependencies: react: '>=16.8' dependencies: - '@remix-run/router': 1.6.0 + '@remix-run/router': 1.15.2 react: 18.2.0 dev: false @@ -10289,7 +9714,7 @@ packages: resolution: {integrity: sha512-Ug69mNOpfvKDAc2Q8DRpMjjzdtrnv9HcSMX+4VsZxD1aZ6ZzrIE7rlzXBtWTyhULSMKg076AW6WR5iZpD0JiOg==} engines: {node: '>=8'} dependencies: - '@types/normalize-package-data': 2.4.1 + '@types/normalize-package-data': 2.4.4 normalize-package-data: 2.5.0 parse-json: 5.2.0 type-fest: 0.6.0 @@ -10317,16 +9742,16 @@ packages: util-deprecate: 1.0.2 dev: false - /readable-stream@3.6.0: - resolution: {integrity: sha512-BViHy7LKeTz4oNnkcLJ+lVSL6vpiFeX6/d3oSH8zCW7UxP2onchk+vTGB143xuFjHS3deTgkKoXXymXqymiIdA==} + /readable-stream@3.6.2: + resolution: {integrity: sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==} engines: {node: '>= 6'} dependencies: inherits: 2.0.4 string_decoder: 1.3.0 util-deprecate: 1.0.2 - /readable-stream@4.4.2: - resolution: {integrity: sha512-Lk/fICSyIhodxy1IDK2HazkeGjSmezAWX2egdtJnYhtzKEsBPJowlI6F6LPb5tqIQILrMbx22S5o3GuJavPusA==} + /readable-stream@4.5.2: + resolution: {integrity: sha512-yjavECdqeZ3GLXNgRXgeQEdz9fvDDkNKyHnbHRFtOr7/LcfgBcmct7t/ET+HaCTqfh06OzoAxrkN/IfjJBVe+g==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} dependencies: abort-controller: 3.0.0 @@ -10359,21 +9784,17 @@ packages: resolution: {integrity: sha512-MguG95oij0fC3QV3URf4V2SDYGJhJnJGqvIIgdECeODCT98wSWDAJ94SSuVpYQUoTcGUIL6L4yNB7j1DFFHSBg==} dev: false - /regenerator-runtime@0.13.11: - resolution: {integrity: sha512-kY1AZVr2Ra+t+piVaJ4gxaFaReZVH40AKNo7UCX6W+dEwBo/2oZJzqfuN1qLq1oL45o56cPaTXELwrTh8Fpggg==} + /regenerator-runtime@0.14.1: + resolution: {integrity: sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==} - /regexp.prototype.flags@1.4.3: - resolution: {integrity: sha512-fjggEOO3slI6Wvgjwflkc4NFRCTZAu5CnNfBd5qOMYhWdn67nJBBu34/TkD++eeFmd8C9r9jfXJ27+nSiRkSUA==} + /regexp.prototype.flags@1.5.2: + resolution: {integrity: sha512-NcDiDkTLuPR+++OCKB0nWafEmhg/Da8aUPLPMQbK+bxKKCm1/S5he+AqYa4PlMCVBalb4/yxIRub6qkEx5yJbw==} engines: {node: '>= 0.4'} dependencies: - call-bind: 1.0.2 - define-properties: 1.1.4 - functions-have-names: 1.2.3 - dev: true - - /regexpp@2.0.1: - resolution: {integrity: sha512-lv0M6+TkDVniA3aD1Eg0DVpfU/booSu7Eev3TDO/mZKHBfVjgCGTV4t4buppESEYDtkArYFOxTJWv6S5C+iaNw==} - engines: {node: '>=6.5.0'} + call-bind: 1.0.7 + define-properties: 1.2.1 + es-errors: 1.3.0 + set-function-name: 2.0.2 dev: true /regexpp@3.2.0: @@ -10403,11 +9824,6 @@ packages: resolve-from: 5.0.0 dev: true - /resolve-from@3.0.0: - resolution: {integrity: sha512-GnlH6vxLymXJNMBo7XP1fJIzBFbdYt49CuTwmB/6N53t+kMPRMFKz783LlQ4tv28XoQfMWinAJX6WCGf2IlaIw==} - engines: {node: '>=4'} - dev: true - /resolve-from@4.0.0: resolution: {integrity: sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g==} engines: {node: '>=4'} @@ -10418,6 +9834,10 @@ packages: engines: {node: '>=8'} dev: true + /resolve-pkg-maps@1.0.0: + resolution: {integrity: sha512-seS2Tj26TBVOC2NIc2rOe2y2ZO7efxITtLZcGSOnHHNOQ7CkiUBfw0Iw2ck6xkIhPwLhKNLS8BO+hEpngQlqzw==} + dev: true + /resolve.exports@2.0.2: resolution: {integrity: sha512-X2UW6Nw3n/aMgDVy+0rSqgHlv39WZAlZrXCdnbyEiKm17DSqHX4MmQMaST3FbeWR5FTuRcUwYAziZajji0Y7mg==} engines: {node: '>=10'} @@ -10429,32 +9849,24 @@ packages: path-parse: 1.0.7 dev: true - /resolve@1.22.2: - resolution: {integrity: sha512-Sb+mjNHOULsBv818T40qSPeRiuWLyaGMa5ewydRLFimneixmVy2zdivRl+AF6jaYPC8ERxGDmFSiqui6SfPd+g==} + /resolve@1.22.8: + resolution: {integrity: sha512-oKWePCxqpd6FlLvGV1VU0x7bkPmmCNolxzjMf4NczoDnQcIWrAF+cPtZn5i6n+RfD2d9i0tzpKnG6Yk168yIyw==} hasBin: true dependencies: - is-core-module: 2.12.0 + is-core-module: 2.13.1 path-parse: 1.0.7 supports-preserve-symlinks-flag: 1.0.0 dev: true - /resolve@2.0.0-next.4: - resolution: {integrity: sha512-iMDbmAWtfU+MHpxt/I5iWI7cY6YVEZUQ3MBgPQ++XD1PELuJHIl82xBmObyP2KyQmkNB2dsqF7seoQQiAn5yDQ==} + /resolve@2.0.0-next.5: + resolution: {integrity: sha512-U7WjGVG9sH8tvjW5SmGbQuui75FiyjAX72HX15DwBBwF9dNiQZRQAg9nnPhYy+TUnE0+VcrttuvNI8oSxZcocA==} hasBin: true dependencies: - is-core-module: 2.12.0 + is-core-module: 2.13.1 path-parse: 1.0.7 supports-preserve-symlinks-flag: 1.0.0 dev: true - /restore-cursor@2.0.0: - resolution: {integrity: sha512-6IzJLuGi4+R14vwagDHX+JrXmPVtPpn4mffDJ1UdR7/Edm87fl6yi8mMBIVvFtJaNTUvjughmW4hwLhRG7gC1Q==} - engines: {node: '>=4'} - dependencies: - onetime: 2.0.1 - signal-exit: 3.0.7 - dev: true - /restore-cursor@3.1.0: resolution: {integrity: sha512-l+sSefzHpj5qimhFSE5a8nufZYAM3sBSVMAPtYkmC+4EH2anSGaEMXSD0izRQbu9nfyQ9y5JrVmp7E8oZrUjvA==} engines: {node: '>=8'} @@ -10463,14 +9875,17 @@ packages: signal-exit: 3.0.7 dev: false - /ret@0.2.2: - resolution: {integrity: sha512-M0b3YWQs7R3Z917WRQy1HHA7Ba7D8hvZg6UE5mLykJxQVE2ju0IXbGlaHPPlkY+WN7wFP+wUMXmBFA0aV6vYGQ==} - engines: {node: '>=4'} - dev: false + /restore-cursor@4.0.0: + resolution: {integrity: sha512-I9fPXU9geO9bHOt9pHHOhOkYerIMsmVaWB0rA2AI9ERh/+x/i7MV5HKBNrg+ljO5eoPVgCcnFuRjJ9uH6I/3eg==} + engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} + dependencies: + onetime: 5.1.2 + signal-exit: 3.0.7 + dev: true - /retry@0.12.0: - resolution: {integrity: sha512-9LkiTwjUh6rT555DtE9rTX+BKByPfrMzEAtnlEtdEwr3Nkffwiihqe2bWADg+OQRjt9gl6ICdmB/ZFDCGAtSow==} - engines: {node: '>= 4'} + /ret@0.2.2: + resolution: {integrity: sha512-M0b3YWQs7R3Z917WRQy1HHA7Ba7D8hvZg6UE5mLykJxQVE2ju0IXbGlaHPPlkY+WN7wFP+wUMXmBFA0aV6vYGQ==} + engines: {node: '>=4'} dev: false /retry@0.13.1: @@ -10482,22 +9897,14 @@ packages: resolution: {integrity: sha512-U9nH88a3fc/ekCF1l0/UP1IosiuIjyTh7hBvXVMHYgVcfGvt897Xguj2UOLDeI5BG2m7/uwyaLVT6fbtCwTyzw==} engines: {iojs: '>=1.0.0', node: '>=0.10.0'} - /rfdc@1.3.0: - resolution: {integrity: sha512-V2hovdzFbOi77/WajaSMXk2OLm+xNIeQdMMuB7icj7bk6zi2F8GGAxigcnDFpJHbNyNcgyJDiP+8nOrY5cZGrA==} - dev: false - - /rimraf@2.6.3: - resolution: {integrity: sha512-mwqeW5XsA2qAejG46gYdENaxXjx9onRNCfn7L0duuP4hCuTIi/QO7PDK07KJfp1d+izWPrzEJDcSqBa0OZQriA==} - hasBin: true - dependencies: - glob: 7.2.3 - dev: true + /rfdc@1.3.1: + resolution: {integrity: sha512-r5a3l5HzYlIC68TpmYKlxWjmOP6wiPJ1vWv2HeLhNsRZMrCkxeqxiHlQ21oXmQ4F3SiryXBHhAD7JZqvOJjFmg==} /rimraf@2.7.1: resolution: {integrity: sha512-uWjbaKIK3T1OSVptzX7Nl6PvQ3qAGtKEtVRjRuazjfL3Bx5eI409VZSqgND+4UNnmzLVdPj9FqFJNPqBZFve4w==} hasBin: true dependencies: - glob: 7.2.3 + glob: 7.2.0 dev: true /rimraf@3.0.2: @@ -10505,6 +9912,7 @@ packages: hasBin: true dependencies: glob: 7.2.3 + dev: true /ripemd160@2.0.2: resolution: {integrity: sha512-ii4iagi25WusVoiC4B4lq7pbXfAp3D9v5CwfkY33vffw2+pkDjY1D8GaN7spsxvCSx8dkPqOZCEZyfxcmJG2IA==} @@ -10520,8 +9928,8 @@ packages: bn.js: 5.2.1 dev: true - /rollup@3.21.8: - resolution: {integrity: sha512-SSFV2T2fWtQ/vvBip85u2Nr0GNKireabH9d7nXswBg+XSH+jbVDSYptRAEbCEsquhs503rpPA9POYAp0/Jhasw==} + /rollup@3.29.4: + resolution: {integrity: sha512-oWzmBZwvYrU0iJHtDmhsm662rC15FRXmcjCk1xD771dFDx5jJ02ufAQQTn0etB2emNk4J9EZg/yWKpsn9BWGRw==} engines: {node: '>=14.18.0', npm: '>=8.0.0'} hasBin: true optionalDependencies: @@ -10535,14 +9943,21 @@ packages: /run-async@2.4.1: resolution: {integrity: sha512-tvVnVv01b8c1RrA6Ep7JkStj85Guv/YrMcwqYQnwjsAS2cTmmPGBBjAjpCW7RrSodNSoE2/qg9O4bceNvUuDgQ==} engines: {node: '>=0.12.0'} + dev: false /run-parallel@1.2.0: resolution: {integrity: sha512-5l4VyZR86LZ/lDxZTR6jqL8AFE2S0IFLMP26AbjsLVADxHdhB/c0GUsH+y39UfCi3dzz8OlQuPmnaJOMoDHQBA==} dependencies: queue-microtask: 1.2.3 - /rustbn.js@0.2.0: - resolution: {integrity: sha512-4VlvkRUuCJvr2J6Y0ImW7NvTCriMi7ErOAqWk1y69vAdoNIzCF3yPmgeNzx+RQTLEDFq5sHfscn1MwHxP9hNfA==} + /rust-verkle-wasm@0.0.1: + resolution: {integrity: sha512-BN6fiTsxcd2dCECz/cHtGTt9cdLJR925nh7iAuRcj8ymKw7OOaPmCneQZ7JePOJ/ia27TjEL91VdOi88Yf+mcA==} + dev: true + + /rustbn-wasm@0.2.0: + resolution: {integrity: sha512-FThvYFNTqrEKGqXuseeg0zR7yROh/6U1617mCHF68OVqrN1tNKRN7Tdwy4WayPVsCmmK+eMxtIZX1qL6JxTkMg==} + dependencies: + '@scure/base': 1.1.5 dev: true /rxjs@6.6.7: @@ -10550,31 +9965,42 @@ packages: engines: {npm: '>=2.0.0'} dependencies: tslib: 1.14.1 + dev: false /rxjs@7.5.5: resolution: {integrity: sha512-sy+H0pQofO95VDmFLzyaw9xNJU4KTRSwQIGM6+iG3SypAtCiLDzpeG8sJrNCWn2Up9km+KhkvTdbkrdy+yzZdw==} dependencies: - tslib: 2.5.0 + tslib: 2.6.2 dev: false /rxjs@7.8.1: resolution: {integrity: sha512-AA3TVj+0A2iuIoQkWEK/tqFjBq2j+6PO6Y0zJcvzLAFhEFIO3HL0vls9hWLncZbAAbK0mar7oZ4V079I/qPMxg==} dependencies: - tslib: 2.5.0 + tslib: 2.6.2 + dev: true + + /safe-array-concat@1.1.0: + resolution: {integrity: sha512-ZdQ0Jeb9Ofti4hbt5lX3T2JcAamT9hfzYU1MNB+z/jaEbB6wfFfPIR/zEORmZqobkCCJhSjodobH6WHNmJ97dg==} + engines: {node: '>=0.4'} + dependencies: + call-bind: 1.0.7 + get-intrinsic: 1.2.4 + has-symbols: 1.0.3 + isarray: 2.0.5 dev: true /safe-buffer@5.1.2: resolution: {integrity: sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==} - dev: false /safe-buffer@5.2.1: resolution: {integrity: sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==} - /safe-regex-test@1.0.0: - resolution: {integrity: sha512-JBUUzyOgEwXQY1NuPtvcj/qcBDbDmEvWufhlnXZIm75DEHp+afM1r1ujJpJsV/gSM4t59tpDyPi1sd6ZaPFfsA==} + /safe-regex-test@1.0.3: + resolution: {integrity: sha512-CdASjNJPvRa7roO6Ra/gLYBTzYzzPyyBXxIMdGW3USQLyjWEls2RgW5UBTXaQVp+OrpeCK3bLem8smtmheoRuw==} + engines: {node: '>= 0.4'} dependencies: - call-bind: 1.0.2 - get-intrinsic: 1.1.3 + call-bind: 1.0.7 + es-errors: 1.3.0 is-regex: 1.1.4 dev: true @@ -10614,34 +10040,25 @@ packages: dependencies: elliptic: 6.5.4 node-addon-api: 2.0.2 - node-gyp-build: 4.5.0 + node-gyp-build: 4.8.0 dev: true /secure-json-parse@2.7.0: resolution: {integrity: sha512-6aU+Rwsezw7VR8/nyvKTx8QpWH9FrcYiXXlqC4z5d5XQBDRqtbfsRjnwGyqbi3gddNtWHuEk9OANUotL26qKUw==} dev: false - /semaphore-async-await@1.5.1: - resolution: {integrity: sha512-b/ptP11hETwYWpeilHXXQiV5UJNJl7ZWWooKRE5eBIYWoom6dZ0SluCIdCtKycsMtZgKWE01/qAw6jblw1YVhg==} - engines: {node: '>=4.1'} - dev: true - - /semver-compare@1.0.0: - resolution: {integrity: sha512-YM3/ITh2MJ5MtzaM429anh+x2jiLVjqILF4m4oyQB18W7Ggea7BfqdH/wGMK7dDiMghv/6WG7znWMwUDzJiXow==} - dev: true - - /semver@5.7.1: - resolution: {integrity: sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==} + /semver@5.7.2: + resolution: {integrity: sha512-cBznnQ9KjJqU67B52RMC65CMarK2600WFnbkcaiwWq3xy/5haFJlshgnpjovMVJ+Hff49d8GEn0b87C5pDQ10g==} hasBin: true dev: true - /semver@6.3.0: - resolution: {integrity: sha512-b39TBaTSfV6yBrapU89p5fKekE2m/NwnDocOVruQFS1/veMgdzuPcnOM34M6CwxW8jH/lxEa5rBoDeUwu5HHTw==} + /semver@6.3.1: + resolution: {integrity: sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==} hasBin: true dev: true - /semver@7.5.0: - resolution: {integrity: sha512-+XC0AD/R7Q2mPSRuy2Id0+CGTZ98+8f+KvwirxOKIEyid+XSx6HbC63p+O4IndTHuX5Z+JxQ0TghCkO5Cg/2HA==} + /semver@7.6.0: + resolution: {integrity: sha512-EnwXhrlwXMk9gKu5/flx5sv/an57AkRplG3hTK68W7FRDN+k+OWBj65M7719OkA82XLBxrcX0KSHj+X5COhOVg==} engines: {node: '>=10'} hasBin: true dependencies: @@ -10660,6 +10077,28 @@ packages: resolution: {integrity: sha512-RVnVQxTXuerk653XfuliOxBP81Sf0+qfQE73LIYKcyMYHG94AuH0kgrQpRDuTZnSmjpysHmzxJXKNfa6PjFhyQ==} dev: false + /set-function-length@1.2.1: + resolution: {integrity: sha512-j4t6ccc+VsKwYHso+kElc5neZpjtq9EnRICFZtWyBsLojhmeF/ZBd/elqm22WJh/BziDe/SBiOeAt0m2mfLD0g==} + engines: {node: '>= 0.4'} + dependencies: + define-data-property: 1.1.4 + es-errors: 1.3.0 + function-bind: 1.1.2 + get-intrinsic: 1.2.4 + gopd: 1.0.1 + has-property-descriptors: 1.0.2 + dev: true + + /set-function-name@2.0.2: + resolution: {integrity: sha512-7PGFlmtwsEADb0WYyvCMa1t+yke6daIG4Wirafur5kcf+MhUnPms1UeR0CKQdTZD81yESwMHbtn+TR+dMviakQ==} + engines: {node: '>= 0.4'} + dependencies: + define-data-property: 1.1.4 + es-errors: 1.3.0 + functions-have-names: 1.2.3 + has-property-descriptors: 1.0.2 + dev: true + /setimmediate@1.0.5: resolution: {integrity: sha512-MATJdZp8sLqDl/68LfQmbP8zKPLQNV6BIZoIgrscFDQ+RsvK/BxeDQOgyxKKoh0y/8h3BqVFnCqQ/gd+reiIXA==} dev: true @@ -10701,12 +10140,14 @@ packages: resolution: {integrity: sha512-6j1W9l1iAs/4xYBI1SYOVZyFcCis9b4KCLQ8fgAGG07QvzaRLVVRQvAy85yNmmZSjYjg4MWh4gNvlPujU/5LpA==} dev: true - /side-channel@1.0.4: - resolution: {integrity: sha512-q5XPytqFEIKHkGdiMIrY10mvLRvnQh42/+GoBlFW3b2LXLE2xxJpZFdm94we0BaoV3RwJyGqg5wS7epxTv0Zvw==} + /side-channel@1.0.6: + resolution: {integrity: sha512-fDW/EZ6Q9RiO8eFG8Hj+7u/oW+XrPTIChwCOM2+th2A6OblDtYYIpve9m+KvI9Z4C9qSEXlaGR6bTEYHReuglA==} + engines: {node: '>= 0.4'} dependencies: - call-bind: 1.0.2 - get-intrinsic: 1.1.3 - object-inspect: 1.12.2 + call-bind: 1.0.7 + es-errors: 1.3.0 + get-intrinsic: 1.2.4 + object-inspect: 1.13.1 dev: true /siginfo@2.0.0: @@ -10716,6 +10157,11 @@ packages: /signal-exit@3.0.7: resolution: {integrity: sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ==} + /signal-exit@4.1.0: + resolution: {integrity: sha512-bzyZ1e88w9O1iNJbKnOlvYTrWPDl46O1bG0D3XInv+9tkPrxrN8jUUTiFlDkkmKWgn1M6CfIA13SuGqOa9Korw==} + engines: {node: '>=14'} + dev: true + /simple-concat@1.0.1: resolution: {integrity: sha512-cSFtAPtRhljv69IK0hTVZQ+OfE9nePi/rtJmw5UjHeVyVroEqJXP1sFztKUy1qU+xvz3u/sfYJLa947b7nAN2Q==} dev: false @@ -10736,20 +10182,6 @@ packages: resolution: {integrity: sha512-g9Q1haeby36OSStwb4ntCGGGaKsaVSjQ68fBxoQcutl5fS1vuY18H3wSt3jFyFtrkx+Kz0V1G85A4MyAdDMi2Q==} engines: {node: '>=8'} - /slice-ansi@0.0.4: - resolution: {integrity: sha512-up04hB2hR92PgjpyU3y/eg91yIBILyjVY26NvvciY3EVVPjybkMszMpXQ9QAkcS3I5rtJBDLoTxxg+qvW8c7rw==} - engines: {node: '>=0.10.0'} - dev: true - - /slice-ansi@2.1.0: - resolution: {integrity: sha512-Qu+VC3EwYLldKa1fCxuuvULvSJOKEgk9pi8dZeCVK7TqBfUNTH4sFkk4joj8afVSfAYgJoSOetjx9QWOJ5mYoQ==} - engines: {node: '>=6'} - dependencies: - ansi-styles: 3.2.1 - astral-regex: 1.0.0 - is-fullwidth-code-point: 2.0.0 - dev: true - /slice-ansi@4.0.0: resolution: {integrity: sha512-qMCMfhY040cVHT43K9BFygqYbUPFZKHOg7K73mtTWJRb8pyP3fzf4Ixd5SzdEJQ6MRUg/WBnOLxghZtKKurENQ==} engines: {node: '>=10'} @@ -10757,19 +10189,29 @@ packages: ansi-styles: 4.3.0 astral-regex: 2.0.0 is-fullwidth-code-point: 3.0.0 - dev: false - /smart-buffer@4.2.0: - resolution: {integrity: sha512-94hK0Hh8rPqQl2xXc3HsaBoOXKV20MToPkcXvwbISWLEs+64sBq5kFgn2kJDHb1Pry9yrP0dxrCI9RRci7RXKg==} - engines: {node: '>= 6.0.0', npm: '>= 3.0.0'} - dev: false + /slice-ansi@5.0.0: + resolution: {integrity: sha512-FC+lgizVPfie0kkhqUScwRu1O/lF6NOgJmlCgK+/LYxDCTk8sGelYaHDhFcDN+Sn3Cv+3VSa4Byeo+IMCzpMgQ==} + engines: {node: '>=12'} + dependencies: + ansi-styles: 6.2.1 + is-fullwidth-code-point: 4.0.0 + dev: true + + /slice-ansi@7.1.0: + resolution: {integrity: sha512-bSiSngZ/jWeX93BqeIAbImyTbEihizcwNjFoRUIY/T1wWQsfsm2Vw1agPKylXvQTU7iASGdHhyqRlqQzfz+Htg==} + engines: {node: '>=18'} + dependencies: + ansi-styles: 6.2.1 + is-fullwidth-code-point: 5.0.0 + dev: true /smartwrap@2.0.2: resolution: {integrity: sha512-vCsKNQxb7PnCNd2wY1WClWifAc2lwqsG8OaswpJkVJsvMGcnEntdTCDajZCkk93Ay1U3t/9puJmb525Rg5MZBA==} engines: {node: '>=6'} hasBin: true dependencies: - array.prototype.flat: 1.3.1 + array.prototype.flat: 1.3.2 breakword: 1.0.6 grapheme-splitter: 1.0.4 strip-ansi: 6.0.1 @@ -10777,25 +10219,6 @@ packages: yargs: 15.4.1 dev: true - /socks-proxy-agent@7.0.0: - resolution: {integrity: sha512-Fgl0YPZ902wEsAyiQ+idGd1A7rSFx/ayC1CQVMw5P+EQx2V0SgpGtf6OKFhVjPflPUl9YMmEOnmfjCdMUsygww==} - engines: {node: '>= 10'} - dependencies: - agent-base: 6.0.2 - debug: 4.3.4(supports-color@8.1.1) - socks: 2.7.1 - transitivePeerDependencies: - - supports-color - dev: false - - /socks@2.7.1: - resolution: {integrity: sha512-7maUZy1N7uo6+WVEX6psASxtNlKaNVMlGQKkG/63nEDdLOWNbiUMoLK7X4uYoLhQstau72mLgfEWcXcwsaHbYQ==} - engines: {node: '>= 10.13.0', npm: '>= 3.0.0'} - dependencies: - ip: 2.0.0 - smart-buffer: 4.2.0 - dev: false - /solc@0.7.3(debug@4.3.4): resolution: {integrity: sha512-GAsWNAjGzIDg7VxzP6mPjdurby3IkGCjQcM8GFYZT6RyaoUZKmMU6Y7YwG+tFGhv7dwZ8rmR4iwFDrrD99JwqA==} engines: {node: '>=8.0.0'} @@ -10803,46 +10226,49 @@ packages: dependencies: command-exists: 1.2.9 commander: 3.0.2 - follow-redirects: 1.15.2(debug@4.3.4) + follow-redirects: 1.15.5(debug@4.3.4) fs-extra: 0.30.0 js-sha3: 0.8.0 memorystream: 0.3.1 require-from-string: 2.0.2 - semver: 5.7.1 + semver: 5.7.2 tmp: 0.0.33 transitivePeerDependencies: - debug dev: true - /solhint@3.3.7: - resolution: {integrity: sha512-NjjjVmXI3ehKkb3aNtRJWw55SUVJ8HMKKodwe0HnejA+k0d2kmhw7jvpa+MCTbcEgt8IWSwx0Hu6aCo/iYOZzQ==} + /solhint@3.6.2(typescript@5.1.6): + resolution: {integrity: sha512-85EeLbmkcPwD+3JR7aEMKsVC9YrRSxd4qkXuMzrlf7+z2Eqdfm1wHWq1ffTuo5aDhoZxp2I9yF3QkxZOxOL7aQ==} hasBin: true dependencies: - '@solidity-parser/parser': 0.14.5 + '@solidity-parser/parser': 0.16.2 ajv: 6.12.6 - antlr4: 4.7.1 + antlr4: 4.13.1 ast-parents: 0.0.1 - chalk: 2.4.2 - commander: 2.18.0 - cosmiconfig: 5.2.1 - eslint: 5.16.0 - fast-diff: 1.2.0 - glob: 7.2.3 - ignore: 4.0.6 - js-yaml: 3.14.1 + chalk: 4.1.2 + commander: 10.0.1 + cosmiconfig: 8.3.6(typescript@5.1.6) + fast-diff: 1.3.0 + glob: 8.1.0 + ignore: 5.3.1 + js-yaml: 4.1.0 lodash: 4.17.21 - semver: 6.3.0 + pluralize: 8.0.0 + semver: 7.6.0 + strip-ansi: 6.0.1 + table: 6.8.1 + text-table: 0.2.0 optionalDependencies: - prettier: 1.19.1 + prettier: 2.8.8 transitivePeerDependencies: - - supports-color + - typescript dev: true /solidity-comments-extractor@0.0.7: resolution: {integrity: sha512-wciNMLg/Irp8OKGrh3S2tfvZiZ0NEyILfcRCXCD4mp7SgK/i9gzLfhY2hY7VMCQJ3kH9UB9BzNdibIVMchzyYw==} - /sonic-boom@3.3.0: - resolution: {integrity: sha512-LYxp34KlZ1a2Jb8ZQgFCK3niIHzibdwtwNUWKg0qQRzsDoJ3Gfgkf8KdBTFU3SkejDEIlWwnSnpVdOZIhFMl/g==} + /sonic-boom@3.8.0: + resolution: {integrity: sha512-ybz6OYOUjoQQCQ/i4LU8kaToD8ACtYP+Cj5qd2AO36bwbdewxWJ3ArmJ2cr6AvxlL2o0PqnCcPGUgkILbfkaCA==} dependencies: atomic-sleep: 1.0.0 dev: false @@ -10892,22 +10318,22 @@ packages: resolution: {integrity: sha512-kN9dJbvnySHULIluDHy32WHRUu3Og7B9sbY7tsFLctQkIqnMh3hErYgdMjTYuqmcXX+lK5T1lnUt3G7zNswmZA==} dependencies: spdx-expression-parse: 3.0.1 - spdx-license-ids: 3.0.13 + spdx-license-ids: 3.0.17 dev: true - /spdx-exceptions@2.3.0: - resolution: {integrity: sha512-/tTrYOC7PPI1nUAgx34hUpqXuyJG+DTHJTnIULG4rDygi4xu/tfgmq1e1cIRwRzwZgo4NLySi+ricLkZkw4i5A==} + /spdx-exceptions@2.5.0: + resolution: {integrity: sha512-PiU42r+xO4UbUS1buo3LPJkjlO7430Xn5SVAhdpzzsPHsjbYVflnnFdATgabnLude+Cqu25p6N+g2lw/PFsa4w==} dev: true /spdx-expression-parse@3.0.1: resolution: {integrity: sha512-cbqHunsQWnJNE6KhVSMsMeH5H/L9EpymbzqTQ3uLwNCLZ1Q481oWaofqH7nO6V07xlXwY6PhQdQ2IedWx/ZK4Q==} dependencies: - spdx-exceptions: 2.3.0 - spdx-license-ids: 3.0.13 + spdx-exceptions: 2.5.0 + spdx-license-ids: 3.0.17 dev: true - /spdx-license-ids@3.0.13: - resolution: {integrity: sha512-XkD+zwiqXHikFZm4AX/7JSCXA98U5Db4AFd5XUg/+9UNtnH75+Z9KxtpYiJZx36mUDVOwH83pl7yvCer6ewM3w==} + /spdx-license-ids@3.0.17: + resolution: {integrity: sha512-sh8PWc/ftMqAAdFiBu6Fy6JUOYjqDJBJvIhpfDMyHrr0Rbp5liZqd4TjtQ/RgfLjKFZb+LMx5hpml5qOWy0qvg==} dev: true /split2@4.2.0: @@ -10919,15 +10345,8 @@ packages: resolution: {integrity: sha512-D9cPgkvLlV3t3IzL0D0YLvGA9Ahk4PcvVwUbN0dSGr1aP0Nrt4AEnTUbuGvquEC0mA64Gqt1fzirlRs5ibXx8g==} dev: true - /sql.js@1.8.0: - resolution: {integrity: sha512-3HD8pSkZL+5YvYUI8nlvNILs61ALqq34xgmF+BHpqxe68yZIJ1H+sIVIODvni25+CcxHUxDyrTJUL0lE/m7afw==} - dev: false - - /ssri@9.0.1: - resolution: {integrity: sha512-o57Wcn66jMQvfHG1FlYbWeZWW/dHZhJXjpIcTfXldXEk5nz5lStPo3mK0OJQfGR3RbZUlbISexbljkJzuEj/8Q==} - engines: {node: ^12.13.0 || ^14.15.0 || >=16.0.0} - dependencies: - minipass: 3.3.6 + /sql.js@1.10.2: + resolution: {integrity: sha512-jnKFtdHxuVUNgu1vHwFoTjjwfTuVDVqzGpw7H05Zq3YMNMDOpLFyFGvpgTRIQGd/mqcYntuMy7iygYCytD62jQ==} dev: false /stack-utils@2.0.6: @@ -10961,8 +10380,8 @@ packages: resolution: {integrity: sha512-JPbdCEQLj1w5GilpiHAx3qJvFndqybBysA3qUOnznweH4QbNYUsW/ea8QzSrnh0vNsezMMw5bcVool8lM0gwzg==} dev: true - /stream-shift@1.0.1: - resolution: {integrity: sha512-AiisoFqQ0vbGcZgQPY1cdP2I76glaVA/RauYR4G4thNFgkTqr90yXTo4LYX60Jl+sIlPNHHdGSwo01AvbKUSVQ==} + /stream-shift@1.0.3: + resolution: {integrity: sha512-76ORR0DO1o1hlKwTbi/DM3EXWGf3ZJYO8cXX5RJwnul2DEg2oyoZyjLNoQM8WsvZiFKCRfC1O0J7iCvie3RZmQ==} dev: false /stream-to-array@2.3.0: @@ -10974,12 +10393,12 @@ packages: /stream-transform@2.1.3: resolution: {integrity: sha512-9GHUiM5hMiCi6Y03jD2ARC1ettBXkQBoQAe7nJsPknnI0ow10aXjTnew8QtYQmLjzn974BnmWEAJgCY6ZP1DeQ==} dependencies: - mixme: 0.5.9 + mixme: 0.5.10 dev: true - /streamsearch@1.1.0: - resolution: {integrity: sha512-Mcc5wHehp9aXz1ax6bZUyY5afg9u2rv5cqQI3mRrYkGC8rW2hM02jWuwjtL++LS5qinSyhj2QfLyNsuc+VsExg==} - engines: {node: '>=10.0.0'} + /string-argv@0.3.2: + resolution: {integrity: sha512-aqD2Q0144Z+/RqG52NeHEkZauTAUWJO8c6yTftGJKO3Tja5tUgIfmIl6kExvhtxSDP7fXB6DvzkfMpCd/F3G+Q==} + engines: {node: '>=0.6.19'} dev: true /string-length@4.0.2: @@ -10990,23 +10409,6 @@ packages: strip-ansi: 6.0.1 dev: true - /string-width@1.0.2: - resolution: {integrity: sha512-0XsVpQLnVCXHJfyEs8tC0zpTVIr5PKKsQtkT29IwupnPTjtPmQ3xT/4yCREF9hYkV/3M3kzcUTSAZT6a6h81tw==} - engines: {node: '>=0.10.0'} - dependencies: - code-point-at: 1.1.0 - is-fullwidth-code-point: 1.0.0 - strip-ansi: 3.0.1 - dev: true - - /string-width@2.1.1: - resolution: {integrity: sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw==} - engines: {node: '>=4'} - dependencies: - is-fullwidth-code-point: 2.0.0 - strip-ansi: 4.0.0 - dev: true - /string-width@3.1.0: resolution: {integrity: sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==} engines: {node: '>=6'} @@ -11014,6 +10416,7 @@ packages: emoji-regex: 7.0.3 is-fullwidth-code-point: 2.0.0 strip-ansi: 5.2.0 + dev: false /string-width@4.2.3: resolution: {integrity: sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==} @@ -11023,33 +10426,61 @@ packages: is-fullwidth-code-point: 3.0.0 strip-ansi: 6.0.1 - /string.prototype.matchall@4.0.8: - resolution: {integrity: sha512-6zOCOcJ+RJAQshcTvXPHoxoQGONa3e/Lqx90wUA+wEzX78sg5Bo+1tQo4N0pohS0erG9qtCqJDjNCQBjeWVxyg==} + /string-width@5.1.2: + resolution: {integrity: sha512-HnLOCR3vjcY8beoNLtcjZ5/nxn2afmME6lhrDrebokqMap+XbeW8n9TXpPDOqdGK5qcI3oT0GKTW6wC7EMiVqA==} + engines: {node: '>=12'} + dependencies: + eastasianwidth: 0.2.0 + emoji-regex: 9.2.2 + strip-ansi: 7.1.0 + dev: true + + /string-width@7.1.0: + resolution: {integrity: sha512-SEIJCWiX7Kg4c129n48aDRwLbFb2LJmXXFrWBG4NGaRtMQ3myKPKbwrD1BKqQn74oCoNMBVrfDEr5M9YxCsrkw==} + engines: {node: '>=18'} + dependencies: + emoji-regex: 10.3.0 + get-east-asian-width: 1.2.0 + strip-ansi: 7.1.0 + dev: true + + /string.prototype.matchall@4.0.10: + resolution: {integrity: sha512-rGXbGmOEosIQi6Qva94HUjgPs9vKW+dkG7Y8Q5O2OYkWL6wFaTRZO8zM4mhP94uX55wgyrXzfS2aGtGzUL7EJQ==} dependencies: - call-bind: 1.0.2 - define-properties: 1.1.4 - es-abstract: 1.20.5 - get-intrinsic: 1.1.3 + call-bind: 1.0.7 + define-properties: 1.2.1 + es-abstract: 1.22.5 + get-intrinsic: 1.2.4 has-symbols: 1.0.3 - internal-slot: 1.0.3 - regexp.prototype.flags: 1.4.3 - side-channel: 1.0.4 + internal-slot: 1.0.7 + regexp.prototype.flags: 1.5.2 + set-function-name: 2.0.2 + side-channel: 1.0.6 + dev: true + + /string.prototype.trim@1.2.8: + resolution: {integrity: sha512-lfjY4HcixfQXOfaqCvcBuOIapyaroTXhbkfJN3gcB1OtyupngWK4sEET9Knd0cXd28kTUqu/kHoV4HKSJdnjiQ==} + engines: {node: '>= 0.4'} + dependencies: + call-bind: 1.0.7 + define-properties: 1.2.1 + es-abstract: 1.22.5 dev: true - /string.prototype.trimend@1.0.6: - resolution: {integrity: sha512-JySq+4mrPf9EsDBEDYMOb/lM7XQLulwg5R/m1r0PXEFqrV0qHvl58sdTilSXtKOflCsK2E8jxf+GKC0T07RWwQ==} + /string.prototype.trimend@1.0.7: + resolution: {integrity: sha512-Ni79DqeB72ZFq1uH/L6zJ+DKZTkOtPIHovb3YZHQViE+HDouuU4mBrLOLDn5Dde3RF8qw5qVETEjhu9locMLvA==} dependencies: - call-bind: 1.0.2 - define-properties: 1.1.4 - es-abstract: 1.20.5 + call-bind: 1.0.7 + define-properties: 1.2.1 + es-abstract: 1.22.5 dev: true - /string.prototype.trimstart@1.0.6: - resolution: {integrity: sha512-omqjMDaY92pbn5HOX7f9IccLA+U1tA9GvtU4JrodiXFfYB7jPzzHpRzpglLAjtUV6bB557zwClJezTqnAiYnQA==} + /string.prototype.trimstart@1.0.7: + resolution: {integrity: sha512-NGhtDFu3jCEm7B4Fy0DpLewdJQOZcQ0rGbwQ/+stjnrp2i+rlKeCvos9hOIeCmqwratM47OBxY7uFZzjxHXmrg==} dependencies: - call-bind: 1.0.2 - define-properties: 1.1.4 - es-abstract: 1.20.5 + call-bind: 1.0.7 + define-properties: 1.2.1 + es-abstract: 1.22.5 dev: true /string_decoder@1.1.1: @@ -11068,34 +10499,12 @@ packages: engines: {node: '>=8', npm: '>=5'} dev: false - /stringify-object@3.3.0: - resolution: {integrity: sha512-rHqiFh1elqCQ9WPLIC8I0Q/g/wj5J1eMkyoiD6eoQApWHP0FtlK7rqnhmabL5VUY9JQCcqwwvlOaSuutekgyrw==} - engines: {node: '>=4'} - dependencies: - get-own-enumerable-property-symbols: 3.0.2 - is-obj: 1.0.1 - is-regexp: 1.0.0 - dev: true - - /strip-ansi@3.0.1: - resolution: {integrity: sha512-VhumSSbBqDTP8p2ZLKj40UjBCV4+v8bUSEpUb4KjRgWk9pbqGF4REFj6KEagidb2f/M6AzC0EmFyDNGaw9OCzg==} - engines: {node: '>=0.10.0'} - dependencies: - ansi-regex: 2.1.1 - dev: true - - /strip-ansi@4.0.0: - resolution: {integrity: sha512-4XaJ2zQdCzROZDivEVIDPkcQn8LMFSa8kj8Gxb/Lnwzv9A8VctNZ+lfivC/sV3ivW8ElJTERXZoPBRrZKkNKow==} - engines: {node: '>=4'} - dependencies: - ansi-regex: 3.0.1 - dev: true - /strip-ansi@5.2.0: resolution: {integrity: sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==} engines: {node: '>=6'} dependencies: ansi-regex: 4.1.1 + dev: false /strip-ansi@6.0.1: resolution: {integrity: sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==} @@ -11108,7 +10517,7 @@ packages: engines: {node: '>=12'} dependencies: ansi-regex: 6.0.1 - dev: false + dev: true /strip-bom@3.0.0: resolution: {integrity: sha512-vavAMRXOgBVNF6nyEEmL3DBK19iRpDcoIwW+swQ+CbGiu7lju6t+JklA1MHweoWtadgt4ISVUsXLyDq34ddcwA==} @@ -11127,6 +10536,7 @@ packages: /strip-final-newline@3.0.0: resolution: {integrity: sha512-dOESqjYr96iWYylGObzd39EuNTa5VJxyvVAEm5Jnh7KGo75V43Hk1odPQkNDyXNmUR6k+gEiDVXnjB8HJ3crXw==} engines: {node: '>=12'} + dev: true /strip-hex-prefix@1.0.0: resolution: {integrity: sha512-q8d4ue7JGEiVcypji1bALTos+0pWtyGlivAWyPuTkHzuTCJqrK9sWxYQZUq6Nq3cuyv3bm734IhHvHtGGURU6A==} @@ -11145,6 +10555,7 @@ packages: /strip-json-comments@2.0.1: resolution: {integrity: sha512-4gB8na07fecVVkOI6Rs4e7T6NOTki5EmL7TUduTs6bu3EdnSycntVJ4re8kgZA+wx9IueI2Y11bfbgwtzuE0KQ==} engines: {node: '>=0.10.0'} + dev: false /strip-json-comments@3.1.1: resolution: {integrity: sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig==} @@ -11157,32 +10568,27 @@ packages: acorn: 8.11.3 dev: true - /sucrase@3.32.0: - resolution: {integrity: sha512-ydQOU34rpSyj2TGyz4D2p8rbktIOZ8QY9s+DGLvFU1i5pWJE8vkpruCjGCMHsdXwnD7JDcS+noSwM/a7zyNFDQ==} - engines: {node: '>=8'} + /sucrase@3.35.0: + resolution: {integrity: sha512-8EbVDiu9iN/nESwxeSxDKe0dunta1GOlHufmSSXxMD2z2/tMZpDMpvXQGsc+ajGo8y2uYUmixaSRUc/QPoQ0GA==} + engines: {node: '>=16 || 14 >=14.17'} hasBin: true dependencies: - '@jridgewell/gen-mapping': 0.3.3 + '@jridgewell/gen-mapping': 0.3.4 commander: 4.1.1 - glob: 7.1.6 + glob: 10.3.10 lines-and-columns: 1.2.4 mz: 2.7.0 - pirates: 4.0.5 + pirates: 4.0.6 ts-interface-checker: 0.1.13 dev: true - /superjson@1.12.4: - resolution: {integrity: sha512-vkpPQAxdCg9SLfPv5GPC5fnGrui/WryktoN9O5+Zif/14QIMjw+RITf/5LbBh+9QpBFb3KNvJth+puz2H8o6GQ==} + /superjson@1.13.3: + resolution: {integrity: sha512-mJiVjfd2vokfDxsQPOwJ/PtanO87LhpYY88ubI5dUB1Ab58Txbyje3+jpm+/83R/fevaq/107NNhtYBLuoTrFg==} engines: {node: '>=10'} dependencies: copy-anything: 3.0.5 dev: false - /supports-color@2.0.0: - resolution: {integrity: sha512-KKNVtd6pCYgPIKU4cp2733HWYCpplQhddZLBUryaAHou723x+FRzQ5Df824Fj+IyyuiQTRoub4SnIFfIcrp70g==} - engines: {node: '>=0.8.0'} - dev: true - /supports-color@5.5.0: resolution: {integrity: sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==} engines: {node: '>=4'} @@ -11207,25 +10613,10 @@ packages: engines: {node: '>= 0.4'} dev: true - /symbol-observable@1.2.0: - resolution: {integrity: sha512-e900nM8RRtGhlV36KGEU9k65K3mPb1WV70OdjfxlG2EAuM1noi/E/BaW/uMhL7bPEssK8QV57vN3esixjUvcXQ==} - engines: {node: '>=0.10.0'} - dev: true - /symbol-tree@3.2.4: resolution: {integrity: sha512-9QNk5KwDF+Bvz+PyObkmSYjI5ksVUYtjW7AU22r2NKcfLJcXp96hkDWU3+XndOsUb+AQ9QhfzfCT2O+CNWT5Tw==} dev: true - /table@5.4.6: - resolution: {integrity: sha512-wmEc8m4fjnob4gt5riFRtTu/6+4rSe12TpAELNSqHMfF3IqnA+CH37USM6/YR3qRZv7e56kAEAtd6nKZaxe0Ug==} - engines: {node: '>=6.0.0'} - dependencies: - ajv: 6.12.6 - lodash: 4.17.21 - slice-ansi: 2.1.0 - string-width: 3.1.0 - dev: true - /table@6.8.1: resolution: {integrity: sha512-Y4X9zqrCftUhMeH2EptSSERdVKt/nEdijTOacGD/97EKjhQ/Qs8RTlEGABSJNNN8lac9kheH+af7yAkEWlgneA==} engines: {node: '>=10.0.0'} @@ -11235,40 +10626,38 @@ packages: slice-ansi: 4.0.0 string-width: 4.2.3 strip-ansi: 6.0.1 - dev: false - /tailwind-merge@1.12.0: - resolution: {integrity: sha512-Y17eDp7FtN1+JJ4OY0Bqv9OA41O+MS8c1Iyr3T6JFLnOgLg3EvcyMKZAnQ8AGyvB5Nxm3t9Xb5Mhe139m8QT/g==} + /tailwind-merge@1.14.0: + resolution: {integrity: sha512-3mFKyCo/MBcgyOTlrY8T7odzZFx+w+qKSMAmdFzRvqBfLlSigU6TZnlFHK0lkMwj9Bj8OYU+9yW9lmGuS0QEnQ==} dev: false - /tailwindcss@3.3.2: - resolution: {integrity: sha512-9jPkMiIBXvPc2KywkraqsUfbfj+dHDb+JPWtSJa9MLFdrPyazI7q6WX2sUrm7R9eVR7qqv3Pas7EvQFzxKnI6w==} + /tailwindcss@3.4.1: + resolution: {integrity: sha512-qAYmXRfk3ENzuPBakNK0SRrUDipP8NQnEY6772uDhflcQz5EhRdD7JNZxyrFHVQNCwULPBn6FNPp9brpO7ctcA==} engines: {node: '>=14.0.0'} hasBin: true dependencies: '@alloc/quick-lru': 5.2.0 arg: 5.0.2 - chokidar: 3.5.3 + chokidar: 3.6.0 didyoumean: 1.2.2 dlv: 1.1.3 - fast-glob: 3.2.12 + fast-glob: 3.3.2 glob-parent: 6.0.2 is-glob: 4.0.3 - jiti: 1.18.2 + jiti: 1.21.0 lilconfig: 2.1.0 micromatch: 4.0.5 normalize-path: 3.0.0 object-hash: 3.0.0 picocolors: 1.0.0 - postcss: 8.4.23 - postcss-import: 15.1.0(postcss@8.4.23) - postcss-js: 4.0.1(postcss@8.4.23) - postcss-load-config: 4.0.1(postcss@8.4.23) - postcss-nested: 6.0.1(postcss@8.4.23) - postcss-selector-parser: 6.0.11 - postcss-value-parser: 4.2.0 - resolve: 1.22.2 - sucrase: 3.32.0 + postcss: 8.4.35 + postcss-import: 15.1.0(postcss@8.4.35) + postcss-js: 4.0.1(postcss@8.4.35) + postcss-load-config: 4.0.2(postcss@8.4.35) + postcss-nested: 6.0.1(postcss@8.4.35) + postcss-selector-parser: 6.0.15 + resolve: 1.22.8 + sucrase: 3.35.0 transitivePeerDependencies: - ts-node dev: true @@ -11290,19 +10679,7 @@ packages: end-of-stream: 1.4.4 fs-constants: 1.0.0 inherits: 2.0.4 - readable-stream: 3.6.0 - dev: false - - /tar@6.2.0: - resolution: {integrity: sha512-/Wo7DcT0u5HUV486xg675HtjNd3BXZ6xDbzsCUZPt5iw8bTQ63bP0Raut3mvro9u+CUyq7YQd8Cx55fsZXxqLQ==} - engines: {node: '>=10'} - dependencies: - chownr: 2.0.0 - fs-minipass: 2.1.0 - minipass: 5.0.0 - minizlib: 2.1.2 - mkdirp: 1.0.4 - yallist: 4.0.0 + readable-stream: 3.6.2 dev: false /term-size@2.2.1: @@ -11336,8 +10713,8 @@ packages: any-promise: 1.3.0 dev: true - /thread-stream@2.3.0: - resolution: {integrity: sha512-kaDqm1DET9pp3NXwR8382WHbnpXnRkN9xGN9dQt3B2+dmXiW8X1SOwmFOxAErEQ47ObhZ96J6yhZNXuyCOL7KA==} + /thread-stream@2.4.1: + resolution: {integrity: sha512-d/Ex2iWd1whipbT681JmTINKw0ZwOUBZm7+Gjs64DHuX34mmw8vJL2bFAaNacaW72zYiTJxSHi5abUuOi5nsfg==} dependencies: real-require: 0.2.0 dev: false @@ -11356,19 +10733,15 @@ packages: /through@2.3.8: resolution: {integrity: sha512-w89qg7PI8wAdvX60bMDP+bFoD5Dvhm9oLheFp5O4a2QF0cSBGsBX4qZmadPMvVqlLJBBci+WqGGOAPvcDeNSVg==} + dev: false /timers-ext@0.1.7: resolution: {integrity: sha512-b85NUNzTSdodShTIbky6ZF02e8STtVVfD+fu4aXXShEELpozH+bCpJLYMPZbsABN2wDH7fJpqIoXxJpzbf0NqQ==} dependencies: - es5-ext: 0.10.62 + es5-ext: 0.10.64 next-tick: 1.1.0 dev: false - /tiny-lru@11.0.1: - resolution: {integrity: sha512-iNgFugVuQgBKrqeO/mpiTTgmBsTP0WL6yeuLfLs/Ctf0pI/ixGqIRm8sDCwMcXGe9WWvt2sGXI5mNqZbValmJg==} - engines: {node: '>=12'} - dev: false - /tinybench@2.6.0: resolution: {integrity: sha512-N8hW3PG/3aOoZAN5V/NSAEDz0ZixDSSt5b/a05iqtpgfLWMSVuCo7w0k2vVvEjdrIoeGqZzweX2WlyioNIHchA==} dev: true @@ -11378,8 +10751,8 @@ packages: engines: {node: '>=14.0.0'} dev: true - /tinyspy@2.2.0: - resolution: {integrity: sha512-d2eda04AN/cPOR89F7Xv5bK/jrQEhmcLFe6HFldoeO9AJtps+fqEnh486vnT/8y4bw38pSyxDcTCAq+Ks2aJTg==} + /tinyspy@2.2.1: + resolution: {integrity: sha512-KYad6Vy5VDWV4GH3fjpseMQ/XU2BhIYP7Vzd0LG44qRWm/Yt2WCOTicFdvmgo6gWaqooMQCawTtILVQJupKu7A==} engines: {node: '>=14.0.0'} dev: true @@ -11404,6 +10777,11 @@ packages: dependencies: is-number: 7.0.0 + /toad-cache@3.7.0: + resolution: {integrity: sha512-/m8M+2BJUpoJdgAHoG+baCwBT+tf2VraSfkBgl0Y00qIWt41DJ8R5B8nsEw0I58YwF5IZH6z24/2TobDKnqSWw==} + engines: {node: '>=12'} + dev: false + /toidentifier@1.0.1: resolution: {integrity: sha512-o5sSPKEkg/DIQNmH43V0/uerLrpzVedkUh8tGNvaeXpfpuwjKenlSox/2O/BTlZUtEe+JG7s5YhEz608PlAHRA==} engines: {node: '>=0.6'} @@ -11413,7 +10791,7 @@ packages: engines: {node: '>=6'} dependencies: psl: 1.9.0 - punycode: 2.1.1 + punycode: 2.3.1 universalify: 0.2.0 url-parse: 1.5.10 dev: true @@ -11425,14 +10803,14 @@ packages: /tr46@1.0.1: resolution: {integrity: sha512-dTpowEjclQ7Kgx5SdBkqRzVhERQXov8/l9Ft9dVM9fmg0W0KQSVaXX9T4i6twCPNtYiZM53lpSSUAwJbFPOHxA==} dependencies: - punycode: 2.3.0 + punycode: 2.3.1 dev: true /tr46@4.1.1: resolution: {integrity: sha512-2lv/66T7e5yNyhAAC4NaKe5nVavzuGJQVVtRYLyQ2OI8tsJ61PMLlelehb0wi2Hx6+hT/OJUWZcw8MjlSRnxvw==} engines: {node: '>=14'} dependencies: - punycode: 2.3.0 + punycode: 2.3.1 dev: true /tree-kill@1.2.2: @@ -11445,20 +10823,16 @@ packages: engines: {node: '>=8'} dev: true - /trpc-koa-adapter@1.1.3(@trpc/server@10.34.0)(koa@2.14.2): + /trpc-koa-adapter@1.1.3(@trpc/server@10.34.0)(koa@2.15.0): resolution: {integrity: sha512-2rdmVuuFGLMyrUtW6ktroAzBsp2fc8oFuOEhNAcroJBei3DPF/UISr9qAeQX4MUEi9FCT2+bi4pBPcm8HKj8PA==} peerDependencies: '@trpc/server': ^10.0.0-rc.4 koa: '>=2.13.0' dependencies: '@trpc/server': 10.34.0 - koa: 2.14.2 + koa: 2.15.0 dev: false - /true-case-path@2.2.1: - resolution: {integrity: sha512-0z3j8R7MCjy10kc/g+qg7Ln3alJTodw9aDuVWZa3uiWqfuBMKeAeP2ocWcxoyM3D73yz3Jt/Pu4qPr4wHSdB/Q==} - dev: true - /ts-error@1.0.6: resolution: {integrity: sha512-tLJxacIQUM82IR7JO1UUkKlYuUTmoY9HBJAmNWFzheSlDS5SPMcNIepejHJa4BpPQLAcbRhRf3GDJzyj6rbKvA==} dev: false @@ -11467,9 +10841,9 @@ packages: resolution: {integrity: sha512-Y/arvbn+rrz3JCKl9C4kVNfTfSm2/mEp5FSz5EsZSANGPSlQrpRI5M4PKF+mJnE52jOO90PnPSc3Ur3bTQw0gA==} dev: true - /ts-jest@29.0.5(@babel/core@7.21.4)(esbuild@0.17.17)(jest@29.5.0)(typescript@5.1.6): - resolution: {integrity: sha512-PL3UciSgIpQ7f6XjVOmbi96vmDHUqAyqDr8YxzopDqX3kfgYtX1cuNeBjP+L9sFXi6nzsGGA6R3fP3DDDJyrxA==} - engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} + /ts-jest@29.1.2(@babel/core@7.24.0)(esbuild@0.17.19)(jest@29.7.0)(typescript@5.1.6): + resolution: {integrity: sha512-br6GJoH/WUX4pu7FbZXuWGKGNDuU7b8Uj77g/Sp7puZV6EXzuByl6JrECvm0MzVzSTkSHWTihsXt+5XYER5b+g==} + engines: {node: ^16.10.0 || ^18.0.0 || >=20.0.0} hasBin: true peerDependencies: '@babel/core': '>=7.0.0-beta.0 <8' @@ -11477,7 +10851,7 @@ packages: babel-jest: ^29.0.0 esbuild: '*' jest: ^29.0.0 - typescript: '>=4.3' + typescript: '>=4.3 <6' peerDependenciesMeta: '@babel/core': optional: true @@ -11488,51 +10862,48 @@ packages: esbuild: optional: true dependencies: - '@babel/core': 7.21.4 + '@babel/core': 7.24.0 bs-logger: 0.2.6 - esbuild: 0.17.17 + esbuild: 0.17.19 fast-json-stable-stringify: 2.1.0 - jest: 29.5.0(@types/node@18.15.11) - jest-util: 29.5.0 + jest: 29.7.0(@types/node@18.19.21) + jest-util: 29.7.0 json5: 2.2.3 lodash.memoize: 4.1.2 make-error: 1.3.6 - semver: 7.5.0 + semver: 7.6.0 typescript: 5.1.6 yargs-parser: 21.1.1 dev: true - /ts-poet@6.4.1: - resolution: {integrity: sha512-AjZEs4h2w4sDfwpHMxQKHrTlNh2wRbM5NRXmLz0RiH+yPGtSQFbe9hBpNocU8vqVNgfh0BIOiXR80xDz3kKxUQ==} + /ts-poet@6.7.0: + resolution: {integrity: sha512-A0wvFtpkTCWPw7ftTIwbEH+L+7ul4CU0x3jXKQ+kCnmEQIAOwhpUaBmcAYKxZCxHae9/MUl4LbyTqw25BpzW5Q==} dependencies: - dprint-node: 1.0.7 + dprint-node: 1.0.8 dev: true - /ts-proto-descriptors@1.8.0: - resolution: {integrity: sha512-iV20plcI8+GRkeZIAygxOOH0p2xpOsKfw9kI1W20NCwawi1/4bG/YRd9rQY9XSJP+lD9j7XbSy3tFFuikfsljw==} + /ts-proto-descriptors@1.15.0: + resolution: {integrity: sha512-TYyJ7+H+7Jsqawdv+mfsEpZPTIj9siDHS6EMCzG/z3b/PZiphsX+mWtqFfFVe5/N0Th6V3elK9lQqjnrgTOfrg==} dependencies: - long: 4.0.0 - protobufjs: 6.11.3 + long: 5.2.3 + protobufjs: 7.2.6 dev: true - /ts-proto@1.146.0: - resolution: {integrity: sha512-OyBZRjmqqw+aatLEUbRooWO6VKTtOLJQyaQFMciigEZPNgTsWtApqHpQDtqDMQFWEXhIARqEV+B7ZJx8cljhZA==} + /ts-proto@1.167.9: + resolution: {integrity: sha512-zqZ15CzqvupSpoTl/fzOs5gG7SFvj1ENmWeKMgD4Yl2BSx8I5F+qgYkr9EZYMu7Ho7u+QtwzfudROo+/jwM2pg==} hasBin: true dependencies: - '@types/object-hash': 1.3.4 - case-anything: 2.1.10 - dataloader: 1.4.0 - object-hash: 1.3.1 - protobufjs: 6.11.3 - ts-poet: 6.4.1 - ts-proto-descriptors: 1.8.0 + case-anything: 2.1.13 + protobufjs: 7.2.6 + ts-poet: 6.7.0 + ts-proto-descriptors: 1.15.0 dev: true /tslib@1.14.1: resolution: {integrity: sha512-Xni35NKzjgMrwevysHTCArtLDpPvye8zV/0E4EyYn43P7/7qvQwPh9BGkHewbMulVntbigmcT7rdX3BNo9wRJg==} - /tslib@2.5.0: - resolution: {integrity: sha512-336iVw3rtn2BUK7ORdIAHTyxHGRIHVReokCR3XjbckJMK7ms8FysBfhLR8IXnAgy7T0PTPNBWKiH514FOW/WSg==} + /tslib@2.6.2: + resolution: {integrity: sha512-AEYxH93jGFPn/a2iVAwW87VuUIkR1FVUKB77NwMF7nBTDkDrrT/Hpt/IrCJ0QXhW27jTBDcf5ZY7w6RiqTMw2Q==} /tsort@0.0.1: resolution: {integrity: sha512-Tyrf5mxF8Ofs1tNoxA13lFeZ2Zrbd6cKbuH3V+MQ5sb6DtBj5FjrXVsRWT8YvNAQTqNoz66dz1WsbigI22aEnw==} @@ -11543,7 +10914,7 @@ packages: engines: {node: '>=0.6.x'} dev: false - /tsup@6.7.0(postcss@8.4.23)(typescript@5.1.6): + /tsup@6.7.0(postcss@8.4.35)(typescript@5.1.6): resolution: {integrity: sha512-L3o8hGkaHnu5TdJns+mCqFsDBo83bJ44rlK7e6VdanIvpea4ArPcU3swWGsLVbXak1PqQx/V+SSmFPujBK+zEQ==} engines: {node: '>=14.18'} hasBin: true @@ -11559,20 +10930,20 @@ packages: typescript: optional: true dependencies: - bundle-require: 4.0.1(esbuild@0.17.17) + bundle-require: 4.0.2(esbuild@0.17.19) cac: 6.7.14 - chokidar: 3.5.3 + chokidar: 3.6.0 debug: 4.3.4(supports-color@8.1.1) - esbuild: 0.17.17 + esbuild: 0.17.19 execa: 5.1.1 globby: 11.1.0 joycon: 3.1.1 - postcss: 8.4.23 - postcss-load-config: 3.1.4(postcss@8.4.23) + postcss: 8.4.35 + postcss-load-config: 3.1.4(postcss@8.4.35) resolve-from: 5.0.0 - rollup: 3.21.8 + rollup: 3.29.4 source-map: 0.8.0-beta.0 - sucrase: 3.32.0 + sucrase: 3.35.0 tree-kill: 1.2.2 typescript: 5.1.6 transitivePeerDependencies: @@ -11590,19 +10961,19 @@ packages: typescript: 5.1.6 dev: true - /tsx@3.12.6: - resolution: {integrity: sha512-q93WgS3lBdHlPgS0h1i+87Pt6n9K/qULIMNYZo07nSeu2z5QE2CellcAZfofVXBo2tQg9av2ZcRMQ2S2i5oadQ==} + /tsx@3.14.0: + resolution: {integrity: sha512-xHtFaKtHxM9LOklMmJdI3BEnQq/D5F73Of2E1GDrITi9sgoVkvIsrQUTY1G8FlmGtA+awCI4EBlTRRYxkL2sRg==} hasBin: true dependencies: - '@esbuild-kit/cjs-loader': 2.4.2 - '@esbuild-kit/core-utils': 3.1.0 - '@esbuild-kit/esm-loader': 2.5.5 + esbuild: 0.18.20 + get-tsconfig: 4.7.2 + source-map-support: 0.5.21 optionalDependencies: fsevents: 2.3.3 dev: true - /tty-table@4.2.1: - resolution: {integrity: sha512-xz0uKo+KakCQ+Dxj1D/tKn2FSyreSYWzdkL/BYhgN6oMW808g8QRMuh1atAV9fjTPbWBjfbkKQpI/5rEcnAc7g==} + /tty-table@4.2.3: + resolution: {integrity: sha512-Fs15mu0vGzCrj8fmJNP7Ynxt5J7praPXqFN0leZeZBXJwkMxv9cb2D454k1ltrtUSJbZ4yH4e0CynsHLxmUfFA==} engines: {node: '>=8.0.0'} hasBin: true dependencies: @@ -11612,7 +10983,7 @@ packages: smartwrap: 2.0.2 strip-ansi: 6.0.1 wcwidth: 1.0.1 - yargs: 17.7.1 + yargs: 17.7.2 dev: true /tunnel-agent@0.6.0: @@ -11621,65 +10992,64 @@ packages: safe-buffer: 5.2.1 dev: false - /turbo-darwin-64@1.9.3: - resolution: {integrity: sha512-0dFc2cWXl82kRE4Z+QqPHhbEFEpUZho1msHXHWbz5+PqLxn8FY0lEVOHkq5tgKNNEd5KnGyj33gC/bHhpZOk5g==} + /turbo-darwin-64@1.12.4: + resolution: {integrity: sha512-dBwFxhp9isTa9RS/fz2gDVk5wWhKQsPQMozYhjM7TT4jTrnYn0ZJMzr7V3B/M/T8QF65TbniW7w1gtgxQgX5Zg==} cpu: [x64] os: [darwin] requiresBuild: true dev: true optional: true - /turbo-darwin-arm64@1.9.3: - resolution: {integrity: sha512-1cYbjqLBA2zYE1nbf/qVnEkrHa4PkJJbLo7hnuMuGM0bPzh4+AnTNe98gELhqI1mkTWBu/XAEeF5u6dgz0jLNA==} + /turbo-darwin-arm64@1.12.4: + resolution: {integrity: sha512-1Uo5iI6xsJ1j9ObsqxYRsa3W26mEbUe6fnj4rQYV6kDaqYD54oAMJ6hM53q9rB8JvFxwdrUXGp3PwTw9A0qqkA==} cpu: [arm64] os: [darwin] requiresBuild: true dev: true optional: true - /turbo-linux-64@1.9.3: - resolution: {integrity: sha512-UuBPFefawEwpuxh5pM9Jqq3q4C8M0vYxVYlB3qea/nHQ80pxYq7ZcaLGEpb10SGnr3oMUUs1zZvkXWDNKCJb8Q==} + /turbo-linux-64@1.12.4: + resolution: {integrity: sha512-ONg2aSqKP7LAQOg7ysmU5WpEQp4DGNxSlAiR7um+LKtbmC/UxogbR5+T+Uuq6zGuQ5kJyKjWJ4NhtvUswOqBsA==} cpu: [x64] os: [linux] requiresBuild: true dev: true optional: true - /turbo-linux-arm64@1.9.3: - resolution: {integrity: sha512-vUrNGa3hyDtRh9W0MkO+l1dzP8Co2gKnOVmlJQW0hdpOlWlIh22nHNGGlICg+xFa2f9j4PbQlWTsc22c019s8Q==} + /turbo-linux-arm64@1.12.4: + resolution: {integrity: sha512-9FPufkwdgfIKg/9jj87Cdtftw8o36y27/S2vLN7FTR2pp9c0MQiTBOLVYadUr1FlShupddmaMbTkXEhyt9SdrA==} cpu: [arm64] os: [linux] requiresBuild: true dev: true optional: true - /turbo-windows-64@1.9.3: - resolution: {integrity: sha512-0BZ7YaHs6r+K4ksqWus1GKK3W45DuDqlmfjm/yuUbTEVc8szmMCs12vugU2Zi5GdrdJSYfoKfEJ/PeegSLIQGQ==} + /turbo-windows-64@1.12.4: + resolution: {integrity: sha512-2mOtxHW5Vjh/5rDVu/aFwsMzI+chs8XcEuJHlY1sYOpEymYTz+u6AXbnzRvwZFMrLKr7J7fQOGl+v96sLKbNdA==} cpu: [x64] os: [win32] requiresBuild: true dev: true optional: true - /turbo-windows-arm64@1.9.3: - resolution: {integrity: sha512-QJUYLSsxdXOsR1TquiOmLdAgtYcQ/RuSRpScGvnZb1hY0oLc7JWU0llkYB81wVtWs469y8H9O0cxbKwCZGR4RQ==} + /turbo-windows-arm64@1.12.4: + resolution: {integrity: sha512-nOY5wae9qnxPOpT1fRuYO0ks6dTwpKMPV6++VkDkamFDLFHUDVM/9kmD2UTeh1yyrKnrZksbb9zmShhmfj1wog==} cpu: [arm64] os: [win32] requiresBuild: true dev: true optional: true - /turbo@1.9.3: - resolution: {integrity: sha512-ID7mxmaLUPKG/hVkp+h0VuucB1U99RPCJD9cEuSEOdIPoSIuomcIClEJtKamUsdPLhLCud+BvapBNnhgh58Nzw==} + /turbo@1.12.4: + resolution: {integrity: sha512-yUJ7elEUSToiGwFZogXpYKJpQ0BvaMbkEuQECIWtkBLcmWzlMOt6bActsIm29oN83mRU0WbzGt4e8H1KHWedhg==} hasBin: true - requiresBuild: true optionalDependencies: - turbo-darwin-64: 1.9.3 - turbo-darwin-arm64: 1.9.3 - turbo-linux-64: 1.9.3 - turbo-linux-arm64: 1.9.3 - turbo-windows-64: 1.9.3 - turbo-windows-arm64: 1.9.3 + turbo-darwin-64: 1.12.4 + turbo-darwin-arm64: 1.12.4 + turbo-linux-64: 1.12.4 + turbo-linux-arm64: 1.12.4 + turbo-windows-64: 1.12.4 + turbo-windows-arm64: 1.12.4 dev: true /tweetnacl-util@0.15.1: @@ -11690,13 +11060,6 @@ packages: resolution: {integrity: sha512-6rt+RN7aOi1nGMyC4Xa5DdYiukl2UWCbcJft7YhxReBGQD7OAM8Pbxw6YMo4r2diNEA8FEmu32YOn9rhaiE5yw==} dev: true - /type-check@0.3.2: - resolution: {integrity: sha512-ZCmOJdvOWDBYJlzAoFkC+Q0+bUyEOS1ltgp1MGU03fqHG+dbi9tBFU2Rd9QKiDZFAYrhPh2JUf7rZRIuHRKtOg==} - engines: {node: '>= 0.8.0'} - dependencies: - prelude-ls: 1.1.2 - dev: true - /type-check@0.4.0: resolution: {integrity: sha512-XleUoc9uwGXqjWwXaUTZAmzMcFZ5858QA2vvx1Ur5xIcixXIP+8LnFDgRplU30us6teqdlskFfu+ae4K79Ooew==} engines: {node: '>= 0.8.0'} @@ -11738,11 +11101,16 @@ packages: engines: {node: '>=8'} dev: true - /type-fest@2.14.0: - resolution: {integrity: sha512-hQnTQkFjL5ik6HF2fTAM8ycbr94UbQXK364wF930VHb0dfBJ5JBP8qwrR8TaK9zwUEk7meruo2JAUDMwvuxd/w==} + /type-fest@2.19.0: + resolution: {integrity: sha512-RAH822pAdBgcNMAfWnCBU3CFZcfZ/i1eZjwFU/dsLKumyuuP3niueg2UAukXYF0E2AAoc82ZSSf9J0WQBinzHA==} engines: {node: '>=12.20'} dev: true + /type-fest@3.13.1: + resolution: {integrity: sha512-tLq3bSNx+xSpwvAJnzrK0Ep5CLNWjvFTOp71URMaAEWBfRb9nnJiBoUe0tF8bI4ZFO3omgBR6NvnbzVUT3Ly4g==} + engines: {node: '>=14.16'} + dev: true + /type-is@1.6.18: resolution: {integrity: sha512-TkRKr9sUTxEH8MdfuCSP7VizJyzRNMjj2J2do2Jr3Kym598JVdEksuzPQCnlFPW4ky9Q+iA+ma9BGm06XQBy8g==} engines: {node: '>= 0.6'} @@ -11759,13 +11127,57 @@ packages: resolution: {integrity: sha512-dzlvlNlt6AXU7EBSfpAscydQ7gXB+pPGsPnfJnZpiNJBDj7IaJzQlBZYGdEi4R9HmPdBv2XmWJ6YUtoTa7lmCw==} dev: false + /typed-array-buffer@1.0.2: + resolution: {integrity: sha512-gEymJYKZtKXzzBzM4jqa9w6Q1Jjm7x2d+sh19AdsD4wqnMPDYyvwpsIc2Q/835kHuo3BEQ7CjelGhfTsoBb2MQ==} + engines: {node: '>= 0.4'} + dependencies: + call-bind: 1.0.7 + es-errors: 1.3.0 + is-typed-array: 1.1.13 + dev: true + + /typed-array-byte-length@1.0.1: + resolution: {integrity: sha512-3iMJ9q0ao7WE9tWcaYKIptkNBuOIcZCCT0d4MRvuuH88fEoEH62IuQe0OtraD3ebQEoTRk8XCBoknUNc1Y67pw==} + engines: {node: '>= 0.4'} + dependencies: + call-bind: 1.0.7 + for-each: 0.3.3 + gopd: 1.0.1 + has-proto: 1.0.3 + is-typed-array: 1.1.13 + dev: true + + /typed-array-byte-offset@1.0.2: + resolution: {integrity: sha512-Ous0vodHa56FviZucS2E63zkgtgrACj7omjwd/8lTEMEPFFyjfixMZ1ZXenpgCFBBt4EC1J2XsyVS2gkG0eTFA==} + engines: {node: '>= 0.4'} + dependencies: + available-typed-arrays: 1.0.7 + call-bind: 1.0.7 + for-each: 0.3.3 + gopd: 1.0.1 + has-proto: 1.0.3 + is-typed-array: 1.1.13 + dev: true + + /typed-array-length@1.0.5: + resolution: {integrity: sha512-yMi0PlwuznKHxKmcpoOdeLwxBoVPkqZxd7q2FgMkmD3bNwvF5VW0+UlUQ1k1vmktTu4Yu13Q0RIxEP8+B+wloA==} + engines: {node: '>= 0.4'} + dependencies: + call-bind: 1.0.7 + for-each: 0.3.3 + gopd: 1.0.1 + has-proto: 1.0.3 + is-typed-array: 1.1.13 + possible-typed-array-names: 1.0.0 + dev: true + /typescript@5.1.6: resolution: {integrity: sha512-zaWCozRZ6DLEWAWFrVDz1H6FVXzUSfTy5FUMWsQlU8Ym5JP9eO4xkTIROFCQvhQf61z6O/G6ugw3SgAnvvm+HA==} engines: {node: '>=14.17'} hasBin: true - /ufo@1.3.2: - resolution: {integrity: sha512-o+ORpgGwaYQXgqGDwd+hkS4PuZ3QnmqMMxRuajK/a38L6fTpcE5GPIfrf+L/KemFzfUpeUQc1rRS1iDBozvnFA==} + /ufo@1.4.0: + resolution: {integrity: sha512-Hhy+BhRBleFjpJ2vchUNN40qgkh0366FWJGqVLYBHev0vpHTrXSA0ryT+74UiW6KWsldNurQMKGqCm1M2zBciQ==} dev: true /uglify-js@3.17.4: @@ -11779,32 +11191,21 @@ packages: /unbox-primitive@1.0.2: resolution: {integrity: sha512-61pPlCD9h51VoreyJ0BReideM3MDKMKnh6+V9L08331ipq6Q8OFXZYiqP6n/tbHx4s5I9uRhcye6BrbkizkBDw==} dependencies: - call-bind: 1.0.2 + call-bind: 1.0.7 has-bigints: 1.0.2 has-symbols: 1.0.3 which-boxed-primitive: 1.0.2 dev: true - /undici@5.21.0: - resolution: {integrity: sha512-HOjK8l6a57b2ZGXOcUsI5NLfoTrfmbOl90ixJDl0AEFG4wgHNDQxtZy15/ZQp7HhjkpaGlp/eneMgtsu1dIlUA==} - engines: {node: '>=12.18'} - dependencies: - busboy: 1.6.0 - dev: true - - /unique-filename@2.0.1: - resolution: {integrity: sha512-ODWHtkkdx3IAR+veKxFV+VBkUMcN+FaqzUUd7IZzt+0zhDZFPFxhlqwPF3YQvMHx1TD0tdgYl+kuPnJ8E6ql7A==} - engines: {node: ^12.13.0 || ^14.15.0 || >=16.0.0} - dependencies: - unique-slug: 3.0.0 - dev: false + /undici-types@5.26.5: + resolution: {integrity: sha512-JlCMO+ehdEIKqlFxk6IfVoAUVmgz7cU7zD/h9XZ0qzeosSHmUJVOzSQvvYSYWXkFXC+IfLKSIffhv0sVZup6pA==} - /unique-slug@3.0.0: - resolution: {integrity: sha512-8EyMynh679x/0gqE9fT9oilG+qEt+ibFyqjuVTsZn1+CMxH+XLlpvr2UZx4nVcCwTpx81nICr2JQFkM+HPLq4w==} - engines: {node: ^12.13.0 || ^14.15.0 || >=16.0.0} + /undici@5.28.3: + resolution: {integrity: sha512-3ItfzbrhDlINjaP0duwnNsKpDQk3acHI3gVJ1z4fmwMK31k5G9OVIAMLSIaP6w4FaGkaAkN6zaQO9LUvZ1t7VA==} + engines: {node: '>=14.0'} dependencies: - imurmurhash: 0.1.4 - dev: false + '@fastify/busboy': 2.1.1 + dev: true /universalify@0.1.2: resolution: {integrity: sha512-rBJeI5CXAlmy1pV+617WB9J63U6XcazHHF2f2dbJix4XzpUF0RS3Zbj0FGIOCAva5P/d/GBOYaACQ1w+0azUkg==} @@ -11821,21 +11222,21 @@ packages: engines: {node: '>= 0.8'} dev: true - /update-browserslist-db@1.0.10(browserslist@4.21.5): - resolution: {integrity: sha512-OztqDenkfFkbSG+tRxBeAnCVPckDBcvibKd35yDONx6OU8N7sqgwc7rCbkJ/WcYtVRZ4ba68d6byhC21GFh7sQ==} + /update-browserslist-db@1.0.13(browserslist@4.23.0): + resolution: {integrity: sha512-xebP81SNcPuNpPP3uzeW1NYXxI3rxyJzF3pD6sH4jE7o/IX+WtSpwnVU+qIsDPyk0d3hmFQ7mjqc6AtV604hbg==} hasBin: true peerDependencies: browserslist: '>= 4.21.0' dependencies: - browserslist: 4.21.5 - escalade: 3.1.1 + browserslist: 4.23.0 + escalade: 3.1.2 picocolors: 1.0.0 dev: true /uri-js@4.4.1: resolution: {integrity: sha512-7rKUyy33Q1yc98pQ1DAmLtwX109F7TIfWlW1Ydo8Wl1ii1SeHieeh0HHfPeL2fMXK6z0s8ecKs9frCuLJvndBg==} dependencies: - punycode: 2.3.0 + punycode: 2.3.1 /url-parse@1.5.10: resolution: {integrity: sha512-WypcfiRhfeUP9vvF0j6rw0J3hrWrw6iZv3+22h6iRMJ/8z1Tj6XfLP4DsUix5MhMPnXpiHDoKyoZ/bdCkwBCiQ==} @@ -11844,8 +11245,8 @@ packages: requires-port: 1.0.0 dev: true - /use-local-storage-state@18.3.2(react-dom@18.2.0)(react@18.2.0): - resolution: {integrity: sha512-JiTuQsJmmKvc0mH0hiSjaTkKFlwtwXTeOlJ+cdg7rRJzZWwv+s/Rr2S2r2NR68O0W5ogwwt1MX1y+P2wQ1lY4w==} + /use-local-storage-state@18.3.3(react-dom@18.2.0)(react@18.2.0): + resolution: {integrity: sha512-SwwW6LPbxf3q5XimJyYE2jBefpvEJTjAgBO47wCs0+ZkL/Hx8heF/0wtBJ7Df0SiSwyfNDIPHo+8Z3q569jlow==} engines: {node: '>=12'} peerDependencies: react: '>=18' @@ -11880,13 +11281,13 @@ packages: resolution: {integrity: sha512-+NYs2QeMWy+GWFOEm9xnn6HCDp0l7QBD7ml8zLUmJ+93Q5NF0NocErnwkTkXVFNiX3/fpC6afS8Dhb/gz7R7eg==} hasBin: true - /v8-to-istanbul@9.1.0: - resolution: {integrity: sha512-6z3GW9x8G1gd+JIIgQQQxXuiJtCXeAjp6RaPEPLv62mH3iPHPxV6W3robxtCzNErRo6ZwTmzWhsbNvjyEBKzKA==} + /v8-to-istanbul@9.2.0: + resolution: {integrity: sha512-/EH/sDgxU2eGxajKdwLCDmQ4FWq+kpi3uCmBGpw1xJtnAxEjlD8j8PEiGWpCIMIs3ciNAgH0d3TTJiUkYzyZjA==} engines: {node: '>=10.12.0'} dependencies: - '@jridgewell/trace-mapping': 0.3.18 - '@types/istanbul-lib-coverage': 2.0.4 - convert-source-map: 1.9.0 + '@jridgewell/trace-mapping': 0.3.23 + '@types/istanbul-lib-coverage': 2.0.6 + convert-source-map: 2.0.0 dev: true /validate-npm-package-license@3.0.4: @@ -11901,7 +11302,7 @@ packages: engines: {node: '>= 0.8'} dev: false - /viem@2.7.12(typescript@5.1.6)(zod@3.21.4): + /viem@2.7.12(typescript@5.1.6)(zod@3.22.4): resolution: {integrity: sha512-NbV+Bycw0I4X8y6A04mgJ6+Imt7xXwflgnqisR3JXoJRNc77YSaQCscFN/dmwGLESTkgegJvi+j4nZY32GTpwQ==} peerDependencies: typescript: '>=5.0.4' @@ -11914,7 +11315,7 @@ packages: '@noble/hashes': 1.3.2 '@scure/bip32': 1.3.2 '@scure/bip39': 1.2.1 - abitype: 1.0.0(typescript@5.1.6)(zod@3.21.4) + abitype: 1.0.0(typescript@5.1.6)(zod@3.22.4) isows: 1.0.3(ws@8.13.0) typescript: 5.1.6 ws: 8.13.0 @@ -11924,20 +11325,21 @@ packages: - zod dev: false - /vite-node@0.34.6(@types/node@18.15.11): + /vite-node@0.34.6(@types/node@18.19.21): resolution: {integrity: sha512-nlBMJ9x6n7/Amaz6F3zJ97EBwR2FkzhBRxF5e+jE6LA3yi6Wtc2lyTij1OnDMIr34v5g/tVQtsVAzhT0jc5ygA==} engines: {node: '>=v14.18.0'} hasBin: true dependencies: cac: 6.7.14 debug: 4.3.4(supports-color@8.1.1) - mlly: 1.5.0 + mlly: 1.6.1 pathe: 1.1.2 picocolors: 1.0.0 - vite: 4.3.6(@types/node@18.15.11) + vite: 4.5.2(@types/node@18.19.21) transitivePeerDependencies: - '@types/node' - less + - lightningcss - sass - stylus - sugarss @@ -11945,13 +11347,14 @@ packages: - terser dev: true - /vite@4.3.6(@types/node@18.15.11): - resolution: {integrity: sha512-cqIyLSbA6gornMS659AXTVKF7cvSHMdKmJJwQ9DXq3lwsT1uZSdktuBRlpHQ8VnOWx0QHtjDwxPpGtyo9Fh/Qg==} + /vite@4.5.2(@types/node@18.19.21): + resolution: {integrity: sha512-tBCZBNSBbHQkaGyhGCDUGqeo2ph8Fstyp6FMSvTtsXeZSPpSMGlviAOav2hxVTqFcx8Hj/twtWKsMJXNY0xI8w==} engines: {node: ^14.18.0 || >=16.0.0} hasBin: true peerDependencies: '@types/node': '>= 14' less: '*' + lightningcss: ^1.21.0 sass: '*' stylus: '*' sugarss: '*' @@ -11961,6 +11364,8 @@ packages: optional: true less: optional: true + lightningcss: + optional: true sass: optional: true stylus: @@ -11970,10 +11375,10 @@ packages: terser: optional: true dependencies: - '@types/node': 18.15.11 - esbuild: 0.17.17 - postcss: 8.4.23 - rollup: 3.21.8 + '@types/node': 18.19.21 + esbuild: 0.18.20 + postcss: 8.4.35 + rollup: 3.29.4 optionalDependencies: fsevents: 2.3.3 dev: true @@ -12009,9 +11414,9 @@ packages: webdriverio: optional: true dependencies: - '@types/chai': 4.3.5 - '@types/chai-subset': 1.3.3 - '@types/node': 18.15.11 + '@types/chai': 4.3.12 + '@types/chai-subset': 1.3.5 + '@types/node': 18.19.21 '@vitest/expect': 0.34.6 '@vitest/runner': 0.34.6 '@vitest/snapshot': 0.34.6 @@ -12024,18 +11429,19 @@ packages: debug: 4.3.4(supports-color@8.1.1) jsdom: 22.1.0 local-pkg: 0.4.3 - magic-string: 0.30.5 + magic-string: 0.30.7 pathe: 1.1.2 picocolors: 1.0.0 std-env: 3.7.0 strip-literal: 1.3.0 tinybench: 2.6.0 tinypool: 0.7.0 - vite: 4.3.6(@types/node@18.15.11) - vite-node: 0.34.6(@types/node@18.15.11) + vite: 4.5.2(@types/node@18.19.21) + vite-node: 0.34.6(@types/node@18.19.21) why-is-node-running: 2.2.2 transitivePeerDependencies: - less + - lightningcss - sass - stylus - sugarss @@ -12062,13 +11468,14 @@ packages: defaults: 1.0.4 dev: true - /web3-utils@1.8.0: - resolution: {integrity: sha512-7nUIl7UWpLVka2f09CMbKOSEvorvHnaugIabU4mj7zfMvm0tSByLcEu3eyV9qgS11qxxLuOkzBIwCstTflhmpQ==} + /web3-utils@1.10.4: + resolution: {integrity: sha512-tsu8FiKJLk2PzhDl9fXbGUWTkkVXYhtTA+SmEFkKft+9BgwLxfCRpU96sWv7ICC8zixBNd3JURVoiR3dUXgP8A==} engines: {node: '>=8.0.0'} dependencies: + '@ethereumjs/util': 8.1.0 bn.js: 5.2.1 ethereum-bloom-filters: 1.0.10 - ethereumjs-util: 7.1.5 + ethereum-cryptography: 2.1.3 ethjs-unit: 0.1.6 number-to-bn: 1.7.0 randombytes: 2.1.0 @@ -12133,8 +11540,8 @@ packages: is-symbol: 1.0.4 dev: true - /which-module@2.0.0: - resolution: {integrity: sha512-B+enWhmw6cjfVC7kS8Pj9pCrKSc5txArRyaYGe088shv/FGWH+0Rjx/xPgtsWfsUtS27FkP697E4DDhgrgoc0Q==} + /which-module@2.0.1: + resolution: {integrity: sha512-iBdZ57RDvnOR9AGBhML2vFZf7h8vmBjhoaZqODJBFWHVtKkDmKuHai3cx5PgVMrX5YDNp27AofYbAwctSS+vhQ==} /which-pm@2.0.0: resolution: {integrity: sha512-Lhs9Pmyph0p5n5Z3mVnN0yWcbQYUAD7rbQUiMsQxOJ3T57k7RFe35SUwWMf7dsbDZks1uOmw4AecB/JMDj3v/w==} @@ -12144,6 +11551,17 @@ packages: path-exists: 4.0.0 dev: true + /which-typed-array@1.1.14: + resolution: {integrity: sha512-VnXFiIW8yNn9kIHN88xvZ4yOWchftKDsRJ8fEPacX/wl1lOvBrhsJ/OeJCXq7B0AaijRuqgzSKalJoPk+D8MPg==} + engines: {node: '>= 0.4'} + dependencies: + available-typed-arrays: 1.0.7 + call-bind: 1.0.7 + for-each: 0.3.3 + gopd: 1.0.1 + has-tostringtag: 1.0.2 + dev: true + /which@1.3.1: resolution: {integrity: sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ==} hasBin: true @@ -12167,15 +11585,11 @@ packages: stackback: 0.0.2 dev: true - /wide-align@1.1.5: - resolution: {integrity: sha512-eDMORYaPNZ4sQIuuYPDHdQvf4gyCF9rEEV/yPxGfwPkRodwEgiMUUXTx/dex+Me0wxx53S+NgUHaP7y3MGlDmg==} + /widest-line@3.1.0: + resolution: {integrity: sha512-NsmoXalsWVDMGupxZ5R08ka9flZjjiLvHVAWYOKtiKM8ujtZWr9cRffak+uSE48+Ob8ObalXpwyeUiyDD6QFgg==} + engines: {node: '>=8'} dependencies: string-width: 4.2.3 - dev: false - - /word-wrap@1.2.3: - resolution: {integrity: sha512-Hz/mrNwitNRh/HUAtM/VT/5VH+ygD6DV7mYKZAtHOrbs8U7lvPS6xf7EJKMF0uW1KJCl0H701g3ZGus+muE5vQ==} - engines: {node: '>=0.10.0'} dev: true /wordwrap@1.0.0: @@ -12186,14 +11600,6 @@ packages: resolution: {integrity: sha512-ILEIE97kDZvF9Wb9f6h5aXK4swSlKGUcOEGiIYb2OOu/IrDU9iwj0fD//SsA6E5ibwJxpEvhullJY4Sl4GcpAw==} dev: true - /wrap-ansi@3.0.1: - resolution: {integrity: sha512-iXR3tDXpbnTpzjKSylUJRkLuOrEC7hwEB221cgn6wtF8wpmz28puFXAEfPT5zrjM3wahygB//VuWEr1vTkDcNQ==} - engines: {node: '>=4'} - dependencies: - string-width: 2.1.1 - strip-ansi: 4.0.0 - dev: true - /wrap-ansi@5.1.0: resolution: {integrity: sha512-QC1/iN/2/RPVJ5jYK8BGttj5z83LmSKmvbvrXPNCLZSEb32KKVDJDl/MOt2N01qU2H/FkzEa9PKto1BqDjtd7Q==} engines: {node: '>=6'} @@ -12220,6 +11626,24 @@ packages: string-width: 4.2.3 strip-ansi: 6.0.1 + /wrap-ansi@8.1.0: + resolution: {integrity: sha512-si7QWI6zUMq56bESFvagtmzMdGOtoxfR+Sez11Mobfc7tm+VkUckk9bW2UeffTGVUbOksxmSw0AA2gs8g71NCQ==} + engines: {node: '>=12'} + dependencies: + ansi-styles: 6.2.1 + string-width: 5.1.2 + strip-ansi: 7.1.0 + dev: true + + /wrap-ansi@9.0.0: + resolution: {integrity: sha512-G8ura3S+3Z2G+mkgNRq8dqaFZAuxfsxpBB8OCTGRTCtp+l/v9nbFNmCUP1BZMts3G1142MsZfn6eeUKrr4PD1Q==} + engines: {node: '>=18'} + dependencies: + ansi-styles: 6.2.1 + string-width: 7.1.0 + strip-ansi: 7.1.0 + dev: true + /wrappy@1.0.2: resolution: {integrity: sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==} @@ -12231,13 +11655,6 @@ packages: signal-exit: 3.0.7 dev: true - /write@1.0.3: - resolution: {integrity: sha512-/lg70HAjtkUgWPVZhZcm+T4hkL8Zbtp1nFNOn3lRrxnlv50SRBv7cR7RqR+GMsd3hUXy9hWBo4CHTbFTcOYwig==} - engines: {node: '>=4'} - dependencies: - mkdirp: 0.5.6 - dev: true - /ws@7.4.6: resolution: {integrity: sha512-YmhHDO4MzaDLB+M9ym/mDA5z0naX8j7SIlT8f8z+I0VtzsRbekxEutHSme7NPS2qE8StCYQNUnfWdXta/Yu85A==} engines: {node: '>=8.3.0'} @@ -12274,6 +11691,20 @@ packages: optional: true utf-8-validate: optional: true + dev: false + + /ws@8.16.0: + resolution: {integrity: sha512-HS0c//TP7Ina87TfiPUz1rQzMhHrl/SG2guqRcTOIUYD2q8uhUdNHZYJUaQ8aTGPzCh+c6oawMKW35nFl1dxyQ==} + engines: {node: '>=10.0.0'} + peerDependencies: + bufferutil: ^4.0.1 + utf-8-validate: '>=5.0.2' + peerDependenciesMeta: + bufferutil: + optional: true + utf-8-validate: + optional: true + dev: true /xml-name-validator@4.0.0: resolution: {integrity: sha512-ICP2e+jsHvAj2E2lIHxa5tjXRlKDJo4IdvPvCXbXQGdzSfmSpNVyIKMvoZHjDY9DP0zV17iI85o90vRFXNccRw==} @@ -12287,6 +11718,7 @@ packages: /xtend@4.0.2: resolution: {integrity: sha512-LKYU1iAXJXUgAXn9URjiu+MWhyUXHsvfp7mcuYm9dSUKK0/CjtrUwFAxD82/mCWbtLsGjFIad0wIsod4zrTAEQ==} engines: {node: '>=0.4'} + dev: false /y18n@4.0.3: resolution: {integrity: sha512-JKhqTOwSrqNA1NY5lSztJ1GrBiUodLMmIZuLiDaMRJ+itFd+ABVE8XBjOvIWL+rSqNDC74LCSFmlb/U4UZ4hJQ==} @@ -12311,9 +11743,15 @@ packages: engines: {node: '>= 6'} dev: true - /yaml@2.2.2: - resolution: {integrity: sha512-CBKFWExMn46Foo4cldiChEzn7S7SRV+wqiluAb6xmueD/fGyRHIhX8m14vVGgeFWjN540nKCNVj6P21eQjgTuA==} + /yaml@2.3.4: + resolution: {integrity: sha512-8aAvwVUSHpfEqTQ4w/KMlf3HcRdt50E5ODIQJBw1fQ5RL34xabzxtUlzTXVqc4rkZsPbvrXKWnABCD7kWSmocA==} + engines: {node: '>= 14'} + dev: true + + /yaml@2.4.0: + resolution: {integrity: sha512-j9iR8g+/t0lArF4V6NE/QCfT+CO7iLqrXAHZbJdo+LfjqP1vR8Fg5bSiaq6Q2lOD1AUEVrEVIgABvBFYojJVYQ==} engines: {node: '>= 14'} + hasBin: true dev: true /yargs-interactive@3.0.1: @@ -12344,11 +11782,6 @@ packages: engines: {node: '>=10'} dev: true - /yargs-parser@20.2.9: - resolution: {integrity: sha512-y11nGElTIV+CT3Zv9t7VKl+Q3hTQoT9a1Qzezhhl6Rp21gJ/IVTW7Z3y9EWXhuUBC2Shnf+DX0antecpAwSP8w==} - engines: {node: '>=10'} - dev: true - /yargs-parser@21.1.1: resolution: {integrity: sha512-tVpsJW7DdjecAiFpbIB1e3qxIQsE6NoPc5/eTdrbbIC4h0LVsWhnoa3g+m2HclBIujHzsxZ4VJVA+GUuc2/LBw==} engines: {node: '>=12'} @@ -12374,7 +11807,7 @@ packages: require-main-filename: 2.0.0 set-blocking: 2.0.0 string-width: 3.1.0 - which-module: 2.0.0 + which-module: 2.0.1 y18n: 4.0.3 yargs-parser: 15.0.3 dev: false @@ -12391,7 +11824,7 @@ packages: require-main-filename: 2.0.0 set-blocking: 2.0.0 string-width: 4.2.3 - which-module: 2.0.0 + which-module: 2.0.1 y18n: 4.0.3 yargs-parser: 18.1.3 dev: true @@ -12401,38 +11834,25 @@ packages: engines: {node: '>=10'} dependencies: cliui: 7.0.4 - escalade: 3.1.1 + escalade: 3.1.2 get-caller-file: 2.0.5 require-directory: 2.1.1 string-width: 4.2.3 y18n: 5.0.8 - yargs-parser: 20.2.9 + yargs-parser: 20.2.4 dev: true - /yargs@17.7.1: - resolution: {integrity: sha512-cwiTb08Xuv5fqF4AovYacTFNxk62th7LKJ6BL9IGUpTJrWoU7/7WdQGTP2SjKf1dUNBGzDd28p/Yfs/GI6JrLw==} - engines: {node: '>=12'} - dependencies: - cliui: 8.0.1 - escalade: 3.1.1 - get-caller-file: 2.0.5 - require-directory: 2.1.1 - string-width: 4.2.3 - y18n: 5.0.8 - yargs-parser: 21.1.1 - /yargs@17.7.2: resolution: {integrity: sha512-7dSzzRQ++CKnNI/krKnYRV7JKKPUXMEh61soaHKg9mrWEhzFWhFnxPxGl+69cD1Ou63C13NUPCnmIcrvqCuM6w==} engines: {node: '>=12'} dependencies: cliui: 8.0.1 - escalade: 3.1.1 + escalade: 3.1.2 get-caller-file: 2.0.5 require-directory: 2.1.1 string-width: 4.2.3 y18n: 5.0.8 yargs-parser: 21.1.1 - dev: true /ylru@1.3.2: resolution: {integrity: sha512-RXRJzMiK6U2ye0BlGGZnmpwJDPgakn6aNQ0A7gHRbD4I0uvK4TW6UqkK1V0pp9jskjJBAXd3dRrbzWkqJ+6cxA==} @@ -12442,37 +11862,41 @@ packages: /yocto-queue@0.1.0: resolution: {integrity: sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q==} engines: {node: '>=10'} - dev: true /yocto-queue@1.0.0: resolution: {integrity: sha512-9bnSc/HEW2uRy67wc+T8UwauLuPJVn28jb+GtJY16iiKWyvmYJRXVT4UamsAEGQfPohgr2q4Tq0sQbQlxTfi1g==} engines: {node: '>=12.20'} + dev: true - /zod-validation-error@1.3.0(zod@3.21.4): - resolution: {integrity: sha512-4WoQnuWnj06kwKR4A+cykRxFmy+CTvwMQO5ogTXLiVx1AuvYYmMjixh7sbkSsQTr1Fvtss6d5kVz8PGeMPUQjQ==} + /zod-validation-error@1.5.0(zod@3.22.4): + resolution: {integrity: sha512-/7eFkAI4qV0tcxMBB/3+d2c1P6jzzZYdYSlBuAklzMuCrJu5bzJfHS0yVAS87dRHVlhftd6RFJDIvv03JgkSbw==} engines: {node: '>=16.0.0'} peerDependencies: zod: ^3.18.0 dependencies: - zod: 3.21.4 + zod: 3.22.4 dev: false - /zod@3.21.4: - resolution: {integrity: sha512-m46AKbrzKVzOzs/DZgVnG5H55N1sv1M8qZU3A8RIKbs3mrACDNeIOeilDymVb2HdmP8uwshOCF4uJ8uM9rCqJw==} + /zod@3.22.4: + resolution: {integrity: sha512-iC+8Io04lddc+mVqQ9AZ7OQ2MrUKGN+oIQyq1vemgt46jwCwLfhq7/pwnBnNXXXZb8VTVLKwp9EDkx+ryxIWmg==} dev: false - /zustand@4.3.7(react@18.2.0): - resolution: {integrity: sha512-dY8ERwB9Nd21ellgkBZFhudER8KVlelZm8388B5nDAXhO/+FZDhYMuRnqDgu5SYyRgz/iaf8RKnbUs/cHfOGlQ==} + /zustand@4.5.1(@types/react@18.2.22)(react@18.2.0): + resolution: {integrity: sha512-XlauQmH64xXSC1qGYNv00ODaQ3B+tNPoy22jv2diYiP4eoDKr9LA+Bh5Bc3gplTrFdb6JVI+N4kc1DZ/tbtfPg==} engines: {node: '>=12.7.0'} peerDependencies: - immer: '>=9.0' + '@types/react': '>=16.8' + immer: '>=9.0.6' react: '>=16.8' peerDependenciesMeta: + '@types/react': + optional: true immer: optional: true react: optional: true dependencies: + '@types/react': 18.2.22 react: 18.2.0 use-sync-external-store: 1.2.0(react@18.2.0) dev: false @@ -12493,14 +11917,14 @@ packages: version: 7.3.0 hasBin: true dependencies: - '@types/yargs-interactive': 2.1.3 + '@types/yargs-interactive': 2.1.6 chalk: 4.1.2 cross-spawn: 7.0.3 epicfail: 3.0.0 execa: 5.1.1 gitconfig: 2.0.8 globby: 11.1.0 - handlebars: 4.7.7 + handlebars: 4.7.8 is-utf8: 0.2.1 license.js: 3.1.2 slash: 3.0.0 diff --git a/scripts/changelog.ts b/scripts/changelog.ts index 9daee85ea1..60a4849b83 100644 --- a/scripts/changelog.ts +++ b/scripts/changelog.ts @@ -3,7 +3,7 @@ * central changelog (https://github.com/changesets/changesets/issues/1059). */ -import { execa } from "execa"; +import execa from "execa"; import { readFileSync, writeFileSync } from "node:fs"; import path from "path"; diff --git a/scripts/render-api-docs.ts b/scripts/render-api-docs.ts index 24cb0b6d3d..5bcf9e5a73 100644 --- a/scripts/render-api-docs.ts +++ b/scripts/render-api-docs.ts @@ -2,7 +2,7 @@ * Parse raw `forge doc` output from contract packages, clean it up, and render as markdown in docs. */ -import { execa } from "execa"; +import execa from "execa"; import prettier from "prettier"; import { readFileSync, readdirSync, writeFileSync } from "fs"; import path from "path"; diff --git a/templates/phaser/packages/client/package.json b/templates/phaser/packages/client/package.json index 53c4f827d8..0795f2e439 100644 --- a/templates/phaser/packages/client/package.json +++ b/templates/phaser/packages/client/package.json @@ -3,7 +3,6 @@ "version": "0.0.0", "private": true, "license": "MIT", - "type": "module", "scripts": { "build": "vite build", "dev": "wait-port localhost:8545 && vite", diff --git a/templates/react-ecs/packages/client/package.json b/templates/react-ecs/packages/client/package.json index d5943713ef..12938f6273 100644 --- a/templates/react-ecs/packages/client/package.json +++ b/templates/react-ecs/packages/client/package.json @@ -3,7 +3,6 @@ "version": "0.0.0", "private": true, "license": "MIT", - "type": "module", "scripts": { "build": "vite build", "dev": "wait-port localhost:8545 && vite", diff --git a/templates/react/packages/client/package.json b/templates/react/packages/client/package.json index bcd7943147..6a34afc583 100644 --- a/templates/react/packages/client/package.json +++ b/templates/react/packages/client/package.json @@ -3,7 +3,6 @@ "version": "0.0.0", "private": true, "license": "MIT", - "type": "module", "scripts": { "build": "vite build", "dev": "wait-port localhost:8545 && vite", diff --git a/templates/threejs/packages/client/package.json b/templates/threejs/packages/client/package.json index 272a46de64..4a43214e78 100644 --- a/templates/threejs/packages/client/package.json +++ b/templates/threejs/packages/client/package.json @@ -3,7 +3,6 @@ "version": "0.0.0", "private": true, "license": "MIT", - "type": "module", "scripts": { "build": "vite build", "dev": "wait-port localhost:8545 && vite", diff --git a/templates/vanilla/packages/client/package.json b/templates/vanilla/packages/client/package.json index b691535615..dc66a8a4f3 100644 --- a/templates/vanilla/packages/client/package.json +++ b/templates/vanilla/packages/client/package.json @@ -3,7 +3,6 @@ "version": "0.0.0", "private": true, "license": "MIT", - "type": "module", "scripts": { "build": "vite build", "dev": "wait-port localhost:8545 && vite",