1
0
Fork 0
mirror of https://github.com/denoland/deno.git synced 2024-11-28 16:20:57 -05:00

refactor: pull 'core', 'internals', 'primordials' from ES module (#21462)

This commit refactors how we access "core", "internals" and
"primordials" objects coming from `deno_core`, in our internal JavaScript code.

Instead of capturing them from "globalThis.__bootstrap" namespace, we
import them from recently added "ext:core/mod.js" file.
This commit is contained in:
Bartek Iwańczuk 2023-12-07 14:21:01 +01:00 committed by GitHub
parent 5dd9b26155
commit c1fc7b2cd5
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
71 changed files with 72 additions and 126 deletions

View file

@ -2,7 +2,7 @@
/// <reference path="../../core/internal.d.ts" />
const core = globalThis.Deno.core;
import { core, primordials } from "ext:core/mod.js";
const ops = core.ops;
import * as webidl from "ext:deno_webidl/00_webidl.js";
import { createFilteredInspectProxy } from "ext:deno_console/01_console.js";
@ -13,7 +13,6 @@ import {
setTarget,
} from "ext:deno_web/02_event.js";
import DOMException from "ext:deno_web/01_dom_exception.js";
const primordials = globalThis.__bootstrap.primordials;
const {
ArrayPrototypeIndexOf,
ArrayPrototypePush,

View file

@ -1,7 +1,6 @@
// Copyright 2018-2023 the Deno authors. All rights reserved. MIT license.
const core = globalThis.Deno.core;
import { core, primordials } from "ext:core/mod.js";
import * as webidl from "ext:deno_webidl/00_webidl.js";
const primordials = globalThis.__bootstrap.primordials;
const {
ArrayPrototypePush,
ObjectPrototypeIsPrototypeOf,

View file

@ -2,9 +2,7 @@
/// <reference path="../../core/internal.d.ts" />
const core = globalThis.Deno.core;
const internals = globalThis.__bootstrap.internals;
const primordials = globalThis.__bootstrap.primordials;
import { core, internals, primordials } from "ext:core/mod.js";
const {
AggregateErrorPrototype,
Array,

View file

@ -6,9 +6,8 @@
/// <reference path="../webidl/internal.d.ts" />
/// <reference path="../web/lib.deno_web.d.ts" />
const core = globalThis.Deno.core;
import { core, primordials } from "ext:core/mod.js";
const ops = core.ops;
const primordials = globalThis.__bootstrap.primordials;
import * as webidl from "ext:deno_webidl/00_webidl.js";
import { createFilteredInspectProxy } from "ext:deno_console/01_console.js";
import DOMException from "ext:deno_web/01_dom_exception.js";

View file

@ -19,7 +19,7 @@ import {
HTTP_TOKEN_CODE_POINT_RE,
httpTrim,
} from "ext:deno_web/00_infra.js";
const primordials = globalThis.__bootstrap.primordials;
import { primordials } from "ext:core/mod.js";
const {
ArrayIsArray,
ArrayPrototypePush,

View file

@ -9,7 +9,7 @@
/// <reference path="./lib.deno_fetch.d.ts" />
/// <reference lib="esnext" />
const core = globalThis.Deno.core;
import { core, primordials } from "ext:core/mod.js";
import * as webidl from "ext:deno_webidl/00_webidl.js";
import {
Blob,
@ -17,7 +17,6 @@ import {
File,
FilePrototype,
} from "ext:deno_web/09_file.js";
const primordials = globalThis.__bootstrap.primordials;
const {
ArrayPrototypePush,
ArrayPrototypeSlice,

View file

@ -11,7 +11,7 @@
/// <reference path="./lib.deno_fetch.d.ts" />
/// <reference lib="esnext" />
const core = globalThis.Deno.core;
import { core, primordials } from "ext:core/mod.js";
import * as webidl from "ext:deno_webidl/00_webidl.js";
import {
parseUrlEncoded,
@ -36,7 +36,6 @@ import {
readableStreamTee,
readableStreamThrowIfErrored,
} from "ext:deno_web/06_streams.js";
const primordials = globalThis.__bootstrap.primordials;
const {
ArrayBufferPrototype,
ArrayBufferIsView,

View file

@ -10,7 +10,7 @@
/// <reference path="./lib.deno_fetch.d.ts" />
/// <reference lib="esnext" />
const core = globalThis.Deno.core;
import { core } from "ext:core/mod.js";
const ops = core.ops;
import { SymbolDispose } from "ext:deno_web/00_infra.js";

View file

@ -30,7 +30,7 @@ import {
} from "ext:deno_fetch/20_headers.js";
import { HttpClientPrototype } from "ext:deno_fetch/22_http_client.js";
import * as abortSignal from "ext:deno_web/03_abort_signal.js";
const primordials = globalThis.__bootstrap.primordials;
import { primordials } from "ext:core/mod.js";
const {
ArrayPrototypeMap,
ArrayPrototypeSlice,

View file

@ -10,7 +10,7 @@
/// <reference path="./lib.deno_fetch.d.ts" />
/// <reference lib="esnext" />
const core = globalThis.Deno.core;
import { core, primordials } from "ext:core/mod.js";
import * as webidl from "ext:deno_webidl/00_webidl.js";
import { createFilteredInspectProxy } from "ext:deno_console/01_console.js";
import {
@ -30,7 +30,6 @@ import {
headerListFromHeaders,
headersFromHeaderList,
} from "ext:deno_fetch/20_headers.js";
const primordials = globalThis.__bootstrap.primordials;
const {
ArrayPrototypeMap,
ArrayPrototypePush,

View file

@ -10,7 +10,7 @@
/// <reference path="./lib.deno_fetch.d.ts" />
/// <reference lib="esnext" />
const core = globalThis.Deno.core;
import { core, primordials } from "ext:core/mod.js";
const ops = core.ops;
import * as webidl from "ext:deno_webidl/00_webidl.js";
import { byteLowerCase } from "ext:deno_web/00_infra.js";
@ -32,7 +32,6 @@ import {
toInnerResponse,
} from "ext:deno_fetch/23_response.js";
import * as abortSignal from "ext:deno_web/03_abort_signal.js";
const primordials = globalThis.__bootstrap.primordials;
const {
ArrayPrototypePush,
ArrayPrototypeSplice,

View file

@ -2,7 +2,7 @@
/// <reference path="../../core/internal.d.ts" />
const core = globalThis.Deno.core;
import { core, primordials } from "ext:core/mod.js";
import * as webidl from "ext:deno_webidl/00_webidl.js";
import { createFilteredInspectProxy } from "ext:deno_console/01_console.js";
@ -19,7 +19,6 @@ import { getLocationHref } from "ext:deno_web/12_location.js";
import { newInnerRequest } from "ext:deno_fetch/23_request.js";
import { mainFetch } from "ext:deno_fetch/26_fetch.js";
const primordials = globalThis.__bootstrap.primordials;
const {
ArrayPrototypeFind,
Number,

View file

@ -1,8 +1,7 @@
// Copyright 2018-2023 the Deno authors. All rights reserved. MIT license.
const core = globalThis.Deno.core;
import { core, primordials } from "ext:core/mod.js";
const ops = core.ops;
const primordials = globalThis.__bootstrap.primordials;
const {
ArrayBufferIsView,
ArrayBufferPrototype,

View file

@ -1,6 +1,6 @@
// Copyright 2018-2023 the Deno authors. All rights reserved. MIT license.
const core = globalThis.Deno.core;
import { core, primordials } from "ext:core/mod.js";
const ops = core.ops;
const {
op_fs_chmod_async,
@ -9,7 +9,6 @@ const {
op_fs_link_async,
op_fs_flock_async,
} = Deno.core.ensureFastOps();
const primordials = globalThis.__bootstrap.primordials;
const {
ArrayPrototypeFilter,
Date,

View file

@ -1,8 +1,6 @@
// Copyright 2018-2023 the Deno authors. All rights reserved. MIT license.
const core = globalThis.Deno.core;
const primordials = globalThis.__bootstrap.primordials;
const internals = globalThis.__bootstrap.internals;
import { core, internals, primordials } from "ext:core/mod.js";
const { BadResourcePrototype, InterruptedPrototype } = core;
import { InnerBody } from "ext:deno_fetch/22_body.js";

View file

@ -1,8 +1,6 @@
// Copyright 2018-2023 the Deno authors. All rights reserved. MIT license.
const core = globalThis.Deno.core;
const internals = globalThis.__bootstrap.internals;
const primordials = globalThis.__bootstrap.primordials;
import { core, internals, primordials } from "ext:core/mod.js";
const { BadResourcePrototype, InterruptedPrototype, ops } = core;
const { op_http_write } = Deno.core.ensureFastOps();
import * as webidl from "ext:deno_webidl/00_webidl.js";

View file

@ -4,9 +4,8 @@
// Documentation liberally lifted from them too.
// Thank you! We love Go! <3
const core = globalThis.Deno.core;
import { core, primordials } from "ext:core/mod.js";
const ops = core.ops;
const primordials = globalThis.__bootstrap.primordials;
import {
readableStreamForRid,
writableStreamForRid,

View file

@ -1,6 +1,6 @@
// Copyright 2018-2023 the Deno authors. All rights reserved. MIT license.
const core = globalThis.Deno.core;
import { core, primordials } from "ext:core/mod.js";
const { BadResourcePrototype, InterruptedPrototype, ops } = core;
import {
readableStreamForRidUnrefable,
@ -11,7 +11,6 @@ import {
import * as abortSignal from "ext:deno_web/03_abort_signal.js";
import { SymbolDispose } from "ext:deno_web/00_infra.js";
const primordials = globalThis.__bootstrap.primordials;
const {
Error,
Number,

View file

@ -1,9 +1,8 @@
// Copyright 2018-2023 the Deno authors. All rights reserved. MIT license.
const core = globalThis.Deno.core;
import { core, primordials } from "ext:core/mod.js";
const ops = core.ops;
import { Conn, Listener } from "ext:deno_net/01_net.js";
const primordials = globalThis.__bootstrap.primordials;
const { Number, TypeError } = primordials;
function opStartTls(args) {

View file

@ -2,10 +2,8 @@
// deno-lint-ignore-file
const core = globalThis.Deno.core;
import { core, internals, primordials } from "ext:core/mod.js";
const ops = core.ops;
const internals = globalThis.__bootstrap.internals;
const primordials = globalThis.__bootstrap.primordials;
const {
ArrayIsArray,
ArrayPrototypeIncludes,

View file

@ -7,7 +7,7 @@
// The following are all the process APIs that don't depend on the stream module
// They have to be split this way to prevent a circular dependency
const core = globalThis.Deno.core;
import { core } from "ext:core/mod.js";
import { nextTick as _nextTick } from "ext:deno_node/_next_tick.ts";
import { _exiting } from "ext:deno_node/_process/exiting.ts";
import * as fs from "ext:deno_fs/30_fs.js";

View file

@ -4,7 +4,7 @@
// TODO(petamoriken): enable prefer-primordials for node polyfills
// deno-lint-ignore-file prefer-primordials
const core = globalThis.Deno.core;
import { core } from "ext:core/mod.js";
import { notImplemented, warnNotImplemented } from "ext:deno_node/_utils.ts";
import { EventEmitter } from "node:events";
import { Buffer } from "node:buffer";

View file

@ -3,7 +3,8 @@
// TODO(petamoriken): enable prefer-primordials for node polyfills
// deno-lint-ignore-file prefer-primordials
const ops = globalThis.Deno.core.ops;
import { core } from "ext:core/mod.js";
const ops = core.ops;
export default function randomInt(max: number): number;
export default function randomInt(min: number, max: number): number;

View file

@ -32,7 +32,7 @@ export {
} from "ext:deno_node/internal/crypto/_randomFill.mjs";
export { default as randomInt } from "ext:deno_node/internal/crypto/_randomInt.ts";
const primordials = globalThis.__bootstrap.primordials;
import { primordials } from "ext:core/mod.js";
const { StringPrototypePadStart, StringPrototypeToString } = primordials;
const { core } = globalThis.__bootstrap;

View file

@ -3,7 +3,7 @@
import { arch, versions } from "ext:deno_node/_process/process.ts";
import { cpus, hostname, networkInterfaces } from "node:os";
const primordials = globalThis.__bootstrap.primordials;
import { primordials } from "ext:core/mod.js";
const {
Error,
StringPrototypeToUpperCase,

View file

@ -4,7 +4,7 @@
// TODO(petamoriken): enable prefer-primordials for node polyfills
// deno-lint-ignore-file prefer-primordials
const primordials = globalThis.__bootstrap.primordials;
import { primordials } from "ext:core/mod.js";
const {
MapPrototypeDelete,
MapPrototypeSet,

View file

@ -1,7 +1,7 @@
// Copyright 2018-2023 the Deno authors. All rights reserved. MIT license.
// Copyright Joyent and Node contributors. All rights reserved. MIT license.
const primordials = globalThis.__bootstrap.primordials;
import { primordials } from "ext:core/mod.js";
const {
ArrayPrototypeForEach,
ArrayPrototypeIncludes,

View file

@ -1,7 +1,7 @@
// Copyright 2018-2023 the Deno authors. All rights reserved. MIT license.
// Copyright Joyent and Node contributors. All rights reserved. MIT license.
const primordials = globalThis.__bootstrap.primordials;
import { primordials } from "ext:core/mod.js";
const {
ArrayPrototypeFind,
ObjectEntries,

View file

@ -9,7 +9,7 @@ import { hideStackFrames } from "ext:deno_node/internal/hide_stack_frames.ts";
import { isArrayBufferView } from "ext:deno_node/internal/util/types.ts";
import { normalizeEncoding } from "ext:deno_node/internal/normalize_encoding.mjs";
const primordials = globalThis.__bootstrap.primordials;
import { primordials } from "ext:core/mod.js";
const {
ArrayPrototypeIncludes,
ArrayPrototypeJoin,

View file

@ -40,7 +40,7 @@ import {
} from "ext:deno_node/internal_binding/async_wrap.ts";
import { codeMap } from "ext:deno_node/internal_binding/uv.ts";
const core = globalThis.Deno.core;
import { core } from "ext:core/mod.js";
const { ops } = core;
interface Reader {

View file

@ -23,7 +23,7 @@
// TODO(petamoriken): enable prefer-primordials for node polyfills
// deno-lint-ignore-file prefer-primordials
const core = globalThis.Deno.core;
import { core } from "ext:core/mod.js";
const ops = core.ops;
import {
AsyncWrap,

View file

@ -28,7 +28,7 @@
// TODO(petamoriken): enable prefer-primordials for node polyfills
// deno-lint-ignore-file prefer-primordials
const core = globalThis.Deno.core;
import { core } from "ext:core/mod.js";
const ops = core.ops;
const handleTypes = ["TCP", "TTY", "UDP", "FILE", "PIPE", "UNKNOWN"];

View file

@ -3,7 +3,7 @@
// TODO(petamoriken): enable prefer-primordials for node polyfills
// deno-lint-ignore-file prefer-primordials
const primordials = globalThis.__bootstrap.primordials;
import { primordials } from "ext:core/mod.js";
const {
MapPrototypeGet,
MapPrototypeDelete,

View file

@ -16,7 +16,7 @@ import { isDeepStrictEqual } from "ext:deno_node/internal/util/comparisons.ts";
import process from "node:process";
import { validateString } from "ext:deno_node/internal/validators.mjs";
import { parseArgs } from "ext:deno_node/internal/util/parse_args/parse_args.js";
const primordials = globalThis.__bootstrap.primordials;
import { primordials } from "ext:core/mod.js";
const {
ArrayIsArray,
ArrayPrototypeJoin,

View file

@ -5,11 +5,10 @@
/// <reference path="../../core/lib.deno_core.d.ts" />
/// <reference path="../webidl/internal.d.ts" />
const core = globalThis.Deno.core;
import { core, primordials } from "ext:core/mod.js";
const ops = core.ops;
import * as webidl from "ext:deno_webidl/00_webidl.js";
import { createFilteredInspectProxy } from "ext:deno_console/01_console.js";
const primordials = globalThis.__bootstrap.primordials;
const {
ArrayIsArray,
ArrayPrototypeMap,

View file

@ -7,11 +7,10 @@
/// <reference path="./internal.d.ts" />
/// <reference path="./lib.deno_url.d.ts" />
const core = globalThis.Deno.core;
import { core, primordials } from "ext:core/mod.js";
const ops = core.ops;
import * as webidl from "ext:deno_webidl/00_webidl.js";
import { createFilteredInspectProxy } from "ext:deno_console/01_console.js";
const primordials = globalThis.__bootstrap.primordials;
const {
ArrayPrototypePop,
RegExpPrototypeExec,

View file

@ -6,10 +6,8 @@
/// <reference path="../web/internal.d.ts" />
/// <reference path="../web/lib.deno_web.d.ts" />
const core = globalThis.Deno.core;
const internals = globalThis.__bootstrap.internals;
import { core, internals, primordials } from "ext:core/mod.js";
const ops = core.ops;
const primordials = globalThis.__bootstrap.primordials;
const {
ArrayPrototypeJoin,
ArrayPrototypeMap,

View file

@ -7,7 +7,7 @@
/// <reference path="../web/internal.d.ts" />
/// <reference path="../web/lib.deno_web.d.ts" />
const primordials = globalThis.__bootstrap.primordials;
import { primordials } from "ext:core/mod.js";
const {
ArrayPrototypeSlice,
Error,

View file

@ -6,7 +6,7 @@
/// <reference path="../web/internal.d.ts" />
/// <reference path="../web/lib.deno_web.d.ts" />
const primordials = globalThis.__bootstrap.primordials;
import { primordials } from "ext:core/mod.js";
const {
ArrayPrototypeIncludes,
MapPrototypeGet,

View file

@ -5,11 +5,10 @@
// parts still exists. This means you will observe a lot of strange structures
// and impossible logic branches based on what Deno currently supports.
const core = globalThis.Deno.core;
import { core, primordials } from "ext:core/mod.js";
import * as webidl from "ext:deno_webidl/00_webidl.js";
import DOMException from "ext:deno_web/01_dom_exception.js";
import { createFilteredInspectProxy } from "ext:deno_console/01_console.js";
const primordials = globalThis.__bootstrap.primordials;
const {
ArrayPrototypeFilter,
ArrayPrototypeIncludes,

View file

@ -6,9 +6,8 @@
/// <reference path="../web/internal.d.ts" />
/// <reference path="../web/lib.deno_web.d.ts" />
const core = globalThis.Deno.core;
import { core, primordials } from "ext:core/mod.js";
import DOMException from "ext:deno_web/01_dom_exception.js";
const primordials = globalThis.__bootstrap.primordials;
const {
ArrayBuffer,
ArrayBufferPrototype,

View file

@ -1,8 +1,7 @@
// Copyright 2018-2023 the Deno authors. All rights reserved. MIT license.
const core = globalThis.Deno.core;
import { core, primordials } from "ext:core/mod.js";
const ops = core.ops;
const primordials = globalThis.__bootstrap.primordials;
const {
ArrayPrototypePush,
ArrayPrototypeShift,

View file

@ -13,7 +13,7 @@ import {
listenerCount,
setIsTrusted,
} from "ext:deno_web/02_event.js";
const primordials = globalThis.__bootstrap.primordials;
import { primordials } from "ext:core/mod.js";
const {
ArrayPrototypeEvery,
ArrayPrototypePush,

View file

@ -4,7 +4,7 @@
/// <reference path="../../core/internal.d.ts" />
import { EventTarget } from "ext:deno_web/02_event.js";
const primordials = globalThis.__bootstrap.primordials;
import { primordials } from "ext:core/mod.js";
const {
Symbol,
SymbolToStringTag,

View file

@ -6,11 +6,10 @@
/// <reference path="../web/internal.d.ts" />
/// <reference lib="esnext" />
const core = globalThis.Deno.core;
import { core, primordials } from "ext:core/mod.js";
const ops = core.ops;
import * as webidl from "ext:deno_webidl/00_webidl.js";
import DOMException from "ext:deno_web/01_dom_exception.js";
const primordials = globalThis.__bootstrap.primordials;
const {
ObjectPrototypeIsPrototypeOf,
TypeErrorPrototype,

View file

@ -6,8 +6,7 @@
/// <reference path="./lib.deno_web.d.ts" />
/// <reference lib="esnext" />
const core = globalThis.Deno.core;
const internals = globalThis.__bootstrap.internals;
import { core, internals, primordials } from "ext:core/mod.js";
const {
op_arraybuffer_was_detached,
op_transfer_arraybuffer,
@ -29,7 +28,6 @@ import {
remove,
signalAbort,
} from "ext:deno_web/03_abort_signal.js";
const primordials = globalThis.__bootstrap.primordials;
const {
ArrayBuffer,
ArrayBufferIsView,

View file

@ -9,11 +9,10 @@
/// <reference path="../web/lib.deno_web.d.ts" />
/// <reference lib="esnext" />
const core = globalThis.Deno.core;
import { core, primordials } from "ext:core/mod.js";
const ops = core.ops;
import * as webidl from "ext:deno_webidl/00_webidl.js";
import { createFilteredInspectProxy } from "ext:deno_console/01_console.js";
const primordials = globalThis.__bootstrap.primordials;
const {
DataViewPrototypeGetBuffer,
DataViewPrototypeGetByteLength,

View file

@ -10,12 +10,11 @@
/// <reference path="./internal.d.ts" />
/// <reference lib="esnext" />
const core = globalThis.Deno.core;
import { core, primordials } from "ext:core/mod.js";
const ops = core.ops;
import * as webidl from "ext:deno_webidl/00_webidl.js";
import { ReadableStream } from "ext:deno_web/06_streams.js";
import { URL } from "ext:deno_url/00_url.js";
const primordials = globalThis.__bootstrap.primordials;
const {
ArrayBufferPrototype,
ArrayBufferPrototypeSlice,

View file

@ -10,11 +10,10 @@
/// <reference path="./internal.d.ts" />
/// <reference lib="esnext" />
const core = globalThis.Deno.core;
import { core, primordials } from "ext:core/mod.js";
const ops = core.ops;
import * as webidl from "ext:deno_webidl/00_webidl.js";
import { createFilteredInspectProxy } from "ext:deno_console/01_console.js";
const primordials = globalThis.__bootstrap.primordials;
import { forgivingBase64Encode } from "ext:deno_web/00_infra.js";
import { EventTarget, ProgressEvent } from "ext:deno_web/02_event.js";
import { decode, TextDecoder } from "ext:deno_web/08_text_encoding.js";

View file

@ -4,7 +4,7 @@
import { URL } from "ext:deno_url/00_url.js";
import DOMException from "ext:deno_web/01_dom_exception.js";
const primordials = globalThis.__bootstrap.primordials;
import { primordials } from "ext:core/mod.js";
const {
Error,
ObjectDefineProperties,

View file

@ -6,7 +6,7 @@
/// <reference path="./internal.d.ts" />
/// <reference path="./lib.deno_web.d.ts" />
const core = globalThis.Deno.core;
import { core, primordials } from "ext:core/mod.js";
const { InterruptedPrototype, ops } = core;
import * as webidl from "ext:deno_webidl/00_webidl.js";
import { createFilteredInspectProxy } from "ext:deno_console/01_console.js";
@ -18,7 +18,6 @@ import {
setIsTrusted,
} from "ext:deno_web/02_event.js";
import DOMException from "ext:deno_web/01_dom_exception.js";
const primordials = globalThis.__bootstrap.primordials;
const {
ArrayBufferPrototype,
ArrayBufferPrototypeGetByteLength,

View file

@ -5,9 +5,8 @@
/// <reference path="./internal.d.ts" />
/// <reference path="./lib.deno_web.d.ts" />
const core = globalThis.Deno.core;
import { core, primordials } from "ext:core/mod.js";
const ops = core.ops;
const primordials = globalThis.__bootstrap.primordials;
const {
SymbolFor,
ObjectPrototypeIsPrototypeOf,

View file

@ -1,6 +1,6 @@
// Copyright 2018-2023 the Deno authors. All rights reserved. MIT license.
const primordials = globalThis.__bootstrap.primordials;
import { primordials } from "ext:core/mod.js";
const {
ArrayPrototypeFilter,
ArrayPrototypeFind,

View file

@ -6,8 +6,7 @@
/// <reference path="../../core/internal.d.ts" />
const core = globalThis.Deno.core;
const primordials = globalThis.__bootstrap.primordials;
import { core, primordials } from "ext:core/mod.js";
const {
ArrayBufferPrototype,
ArrayBufferIsView,

View file

@ -2,7 +2,7 @@
/// <reference path="../../core/internal.d.ts" />
const core = globalThis.Deno.core;
import { core, primordials } from "ext:core/mod.js";
import { URL } from "ext:deno_url/00_url.js";
import * as webidl from "ext:deno_webidl/00_webidl.js";
import { createFilteredInspectProxy } from "ext:deno_console/01_console.js";
@ -20,7 +20,6 @@ import {
} from "ext:deno_web/02_event.js";
import { Blob, BlobPrototype } from "ext:deno_web/09_file.js";
import { getLocationHref } from "ext:deno_web/12_location.js";
const primordials = globalThis.__bootstrap.primordials;
const {
ArrayBufferPrototype,
ArrayBufferIsView,

View file

@ -2,7 +2,7 @@
/// <reference path="../../core/internal.d.ts" />
const core = globalThis.Deno.core;
import { core, primordials } from "ext:core/mod.js";
const ops = core.ops;
import * as webidl from "ext:deno_webidl/00_webidl.js";
import { createFilteredInspectProxy } from "ext:deno_console/01_console.js";
@ -14,7 +14,6 @@ import {
headerListFromHeaders,
headersFromHeaderList,
} from "ext:deno_fetch/20_headers.js";
const primordials = globalThis.__bootstrap.primordials;
const {
ArrayPrototypeJoin,
ArrayPrototypeMap,

View file

@ -2,10 +2,9 @@
/// <reference path="../../core/internal.d.ts" />
const core = globalThis.Deno.core;
import { core, primordials } from "ext:core/mod.js";
const ops = core.ops;
import * as webidl from "ext:deno_webidl/00_webidl.js";
const primordials = globalThis.__bootstrap.primordials;
const {
Symbol,
SymbolFor,

View file

@ -1,8 +1,7 @@
// Copyright 2018-2023 the Deno authors. All rights reserved. MIT license.
const core = globalThis.Deno.core;
import { core, primordials } from "ext:core/mod.js";
const { BadResource, Interrupted } = core;
const primordials = globalThis.__bootstrap.primordials;
const { Error } = primordials;
class NotFound extends Error {

View file

@ -1,8 +1,7 @@
// Copyright 2018-2023 the Deno authors. All rights reserved. MIT license.
const core = globalThis.Deno.core;
import { core, primordials } from "ext:core/mod.js";
const ops = core.ops;
const primordials = globalThis.__bootstrap.primordials;
const {
Promise,
SafeArrayIterator,

View file

@ -1,11 +1,9 @@
// Copyright 2018-2023 the Deno authors. All rights reserved. MIT license.
const core = globalThis.Deno.core;
import { core, internals, primordials } from "ext:core/mod.js";
const ops = core.ops;
import { pathFromURL } from "ext:deno_web/00_infra.js";
import { Event, EventTarget } from "ext:deno_web/02_event.js";
const internals = globalThis.__bootstrap.internals;
const primordials = globalThis.__bootstrap.primordials;
const {
ArrayIsArray,
ArrayPrototypeIncludes,

View file

@ -1,8 +1,7 @@
// Copyright 2018-2023 the Deno authors. All rights reserved. MIT license.
const core = globalThis.Deno.core;
import { core, primordials } from "ext:core/mod.js";
const ops = core.ops;
const primordials = globalThis.__bootstrap.primordials;
const {
ArrayPrototypeFilter,
Error,

View file

@ -1,10 +1,8 @@
// Copyright 2018-2023 the Deno authors. All rights reserved. MIT license.
const core = globalThis.Deno.core;
import { core, internals, primordials } from "ext:core/mod.js";
const ops = core.ops;
const internals = globalThis.__bootstrap.internals;
import { Event, EventTarget } from "ext:deno_web/02_event.js";
const primordials = globalThis.__bootstrap.primordials;
const {
Error,
FunctionPrototypeBind,

View file

@ -1,8 +1,7 @@
// Copyright 2018-2023 the Deno authors. All rights reserved. MIT license.
const core = globalThis.Deno.core;
import { core, primordials } from "ext:core/mod.js";
const { BadResourcePrototype, InterruptedPrototype, ops } = core;
const primordials = globalThis.__bootstrap.primordials;
const {
ArrayIsArray,
ObjectPrototypeIsPrototypeOf,

View file

@ -1,5 +1,5 @@
// Copyright 2018-2023 the Deno authors. All rights reserved. MIT license.
const core = globalThis.Deno.core;
import { core } from "ext:core/mod.js";
const ops = core.ops;
import { HttpConn } from "ext:deno_http/01_http.js";

View file

@ -1,8 +1,7 @@
// Copyright 2018-2023 the Deno authors. All rights reserved. MIT license.
const core = globalThis.Deno.core;
import { core, primordials } from "ext:core/mod.js";
const ops = core.ops;
const primordials = globalThis.__bootstrap.primordials;
const {
ArrayPrototypeMap,
ArrayPrototypeSlice,

View file

@ -1,8 +1,7 @@
// Copyright 2018-2023 the Deno authors. All rights reserved. MIT license.
const core = globalThis.Deno.core;
import { core, primordials } from "ext:core/mod.js";
const ops = core.ops;
const primordials = globalThis.__bootstrap.primordials;
const {
SafeSet,
SafeSetIterator,

View file

@ -1,7 +1,6 @@
// Copyright 2018-2023 the Deno authors. All rights reserved. MIT license.
const core = globalThis.Deno.core;
import { core, primordials } from "ext:core/mod.js";
const ops = core.ops;
const primordials = globalThis.__bootstrap.primordials;
const {
Uint32Array,
} = primordials;

View file

@ -1,6 +1,5 @@
// Copyright 2018-2023 the Deno authors. All rights reserved. MIT license.
const core = globalThis.Deno.core;
const primordials = globalThis.__bootstrap.primordials;
import { core, primordials } from "ext:core/mod.js";
import { isatty } from "ext:runtime/40_tty.js";
import { stdin } from "ext:deno_io/12_io.js";
const { ArrayPrototypePush, StringPrototypeCharCodeAt, Uint8Array } =

View file

@ -1,6 +1,6 @@
// Copyright 2018-2023 the Deno authors. All rights reserved. MIT license.
const core = globalThis.Deno.core;
import { core } from "ext:core/mod.js";
const ops = core.ops;
import * as timers from "ext:deno_web/02_timers.js";

View file

@ -1,8 +1,7 @@
// Copyright 2018-2023 the Deno authors. All rights reserved. MIT license.
const core = globalThis.Deno.core;
import { core, primordials } from "ext:core/mod.js";
const ops = core.ops;
const primordials = globalThis.__bootstrap.primordials;
const {
ObjectDefineProperties,
ObjectPrototypeIsPrototypeOf,

View file

@ -3,10 +3,8 @@
// Remove Intl.v8BreakIterator because it is a non-standard API.
delete Intl.v8BreakIterator;
const core = globalThis.Deno.core;
import { core, internals, primordials } from "ext:core/mod.js";
const ops = core.ops;
const internals = globalThis.__bootstrap.internals;
const primordials = globalThis.__bootstrap.primordials;
const {
ArrayPrototypeFilter,
ArrayPrototypeIncludes,