diff options
author | Asher Gomez <ashersaupingomez@gmail.com> | 2024-04-07 15:42:53 +1000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-04-07 15:42:53 +1000 |
commit | d3f3e0d717fdbbf531fde0c9e7259f6bb887fa10 (patch) | |
tree | 71643d608635fb1eb1be9796bb5c01d83264ea03 /runtime/js/99_main.js | |
parent | b74a4f29f20c2435ea7c6d192353c1e99760edb0 (diff) |
FUTURE(ext/fs): make `Deno.FsFile` constructor illegal (#23235)
I'm unsure whether we're planning to make the `Deno.FsFile` constructor
illegal or remove `FsFile` from the `Deno.*` namspace in Deno 2. Either
way, this PR works towards the former. I'll create a superceding PR if
the latter is planned instead.
Towards #23089
Diffstat (limited to 'runtime/js/99_main.js')
-rw-r--r-- | runtime/js/99_main.js | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/runtime/js/99_main.js b/runtime/js/99_main.js index c66732331..a66a1660e 100644 --- a/runtime/js/99_main.js +++ b/runtime/js/99_main.js @@ -678,6 +678,11 @@ function bootstrapMainRuntime(runtimeOptions, warmup = false) { 9: future, } = runtimeOptions; + // TODO(iuioiua): remove in Deno v2. This allows us to dynamically delete + // class properties within constructors for classes that are not defined + // within the Deno namespace. + internals.future = future; + removeImportedOps(); deprecatedApiWarningDisabled = shouldDisableDeprecatedApiWarning; @@ -840,6 +845,11 @@ function bootstrapWorkerRuntime( 9: future, } = runtimeOptions; + // TODO(iuioiua): remove in Deno v2. This allows us to dynamically delete + // class properties within constructors for classes that are not defined + // within the Deno namespace. + internals.future = future; + deprecatedApiWarningDisabled = shouldDisableDeprecatedApiWarning; verboseDeprecatedApiWarning = shouldUseVerboseDeprecatedApiWarning; performance.setTimeOrigin(DateNow()); |