1
0
Fork 0
mirror of https://github.com/denoland/deno.git synced 2024-12-27 01:29:14 -05:00
denoland-deno/cli/dts
Aapo Alasuutari 75acec0aea
fix(ext/ffi): Fix UnsafeCallback ref'ing making Deno enter a live-loop (#16216)
Fixes #15136

Currently `UnsafeCallback` class' `ref()` and `unref()` methods rely on
the `event_loop_middleware` implementation in core. If even a single
`UnsafeCallback` is ref'ed, then the FFI event loop middleware will
always return `true` to signify that there may still be more work for
the event loop to do.

The middleware handling in core does not wait a moment to check again,
but will instead synchronously directly re-poll the event loop and
middlewares for more work. This becomes a live-loop.

This PR introduces a `Future` implementation for the `CallbackInfo`
struct that acts as the intermediary data storage between an
`UnsafeCallback` and the `libffi` C callback. Ref'ing a callback now
means calling an async op that binds to the `CallbackInfo` Future and
only resolves once the callback is unref'ed. The `libffi` C callback
will call the waker of this Future when it fires to make sure that the
main thread wakes up to receive the callback.
2022-10-15 19:19:46 +05:30
..
lib.d.ts Reduce size of TypeScript Compiler snapshot (#6809) 2020-07-22 12:03:46 -04:00
lib.deno.ns.d.ts docs(fs): add default info of OpenOptions (#16104) 2022-10-03 17:22:40 +02:00
lib.deno.shared_globals.d.ts chore: improve JSDoc for built-in APIs (#16048) 2022-09-28 22:21:08 +02:00
lib.deno.unstable.d.ts fix(ext/ffi): Fix UnsafeCallback ref'ing making Deno enter a live-loop (#16216) 2022-10-15 19:19:46 +05:30
lib.deno.window.d.ts chore: Added onbeforeunload to window type definition (#16251) 2022-10-13 10:47:47 +02:00
lib.deno.worker.d.ts feat: implement Web Cache API (#15829) 2022-09-28 17:41:12 +05:30
lib.deno_webgpu.d.ts fix(ext/webgpu): make GPUDevice.features SetLike (#15853) 2022-09-20 03:43:32 +02:00
lib.dom.asynciterable.d.ts chore: update copyright year (#13434) 2022-01-20 16:10:16 +09:00
lib.dom.d.ts fix: TypeScript 4.8 update (#16040) 2022-09-27 09:38:21 +10:00
lib.dom.extras.d.ts feat: update to TypeScript 4.7 (#14242) 2022-06-01 10:19:18 +10:00
lib.dom.iterable.d.ts feat(cli): update to TypeScript 4.8 (#15064) 2022-09-20 07:00:01 +10:00
lib.es5.d.ts feat(cli): update to TypeScript 4.8 (#15064) 2022-09-20 07:00:01 +10:00
lib.es6.d.ts Reduce size of TypeScript Compiler snapshot (#6809) 2020-07-22 12:03:46 -04:00
lib.es2015.collection.d.ts feat(cli): update to TypeScript 4.8 (#15064) 2022-09-20 07:00:01 +10:00
lib.es2015.core.d.ts feat: update to TypeScript 4.7 (#14242) 2022-06-01 10:19:18 +10:00
lib.es2015.d.ts Reduce size of TypeScript Compiler snapshot (#6809) 2020-07-22 12:03:46 -04:00
lib.es2015.generator.d.ts Reduce size of TypeScript Compiler snapshot (#6809) 2020-07-22 12:03:46 -04:00
lib.es2015.iterable.d.ts feat(cli): update to TypeScript 4.6.2 (#13474) 2022-03-02 07:44:43 +11:00
lib.es2015.promise.d.ts feat(cli): update to TypeScript 4.5 (#12410) 2021-12-10 09:12:21 +11:00
lib.es2015.proxy.d.ts feat(cli): update to TypeScript 4.8 (#15064) 2022-09-20 07:00:01 +10:00
lib.es2015.reflect.d.ts feat: update to TypeScript 4.7 (#14242) 2022-06-01 10:19:18 +10:00
lib.es2015.symbol.d.ts Reduce size of TypeScript Compiler snapshot (#6809) 2020-07-22 12:03:46 -04:00
lib.es2015.symbol.wellknown.d.ts feat(cli): Update to TypeScript 4.4 (#11678) 2021-08-27 10:12:59 +10:00
lib.es2016.array.include.d.ts Reduce size of TypeScript Compiler snapshot (#6809) 2020-07-22 12:03:46 -04:00
lib.es2016.d.ts Reduce size of TypeScript Compiler snapshot (#6809) 2020-07-22 12:03:46 -04:00
lib.es2016.full.d.ts Reduce size of TypeScript Compiler snapshot (#6809) 2020-07-22 12:03:46 -04:00
lib.es2017.d.ts Reduce size of TypeScript Compiler snapshot (#6809) 2020-07-22 12:03:46 -04:00
lib.es2017.full.d.ts Reduce size of TypeScript Compiler snapshot (#6809) 2020-07-22 12:03:46 -04:00
lib.es2017.intl.d.ts feat(cli): update to TypeScript 4.8 (#15064) 2022-09-20 07:00:01 +10:00
lib.es2017.object.d.ts Reduce size of TypeScript Compiler snapshot (#6809) 2020-07-22 12:03:46 -04:00
lib.es2017.sharedmemory.d.ts feat(cli): update to TypeScript 4.1 (#7573) 2020-11-24 09:31:10 +11:00
lib.es2017.string.d.ts Reduce size of TypeScript Compiler snapshot (#6809) 2020-07-22 12:03:46 -04:00
lib.es2017.typedarrays.d.ts Reduce size of TypeScript Compiler snapshot (#6809) 2020-07-22 12:03:46 -04:00
lib.es2018.asyncgenerator.d.ts Reduce size of TypeScript Compiler snapshot (#6809) 2020-07-22 12:03:46 -04:00
lib.es2018.asynciterable.d.ts feat(cli): upgrade to TypeScript 4.3 (#9960) 2021-05-28 09:33:11 +10:00
lib.es2018.d.ts Reduce size of TypeScript Compiler snapshot (#6809) 2020-07-22 12:03:46 -04:00
lib.es2018.full.d.ts Reduce size of TypeScript Compiler snapshot (#6809) 2020-07-22 12:03:46 -04:00
lib.es2018.intl.d.ts feat(cli): update to TypeScript 4.5 (#12410) 2021-12-10 09:12:21 +11:00
lib.es2018.promise.d.ts Reduce size of TypeScript Compiler snapshot (#6809) 2020-07-22 12:03:46 -04:00
lib.es2018.regexp.d.ts Reduce size of TypeScript Compiler snapshot (#6809) 2020-07-22 12:03:46 -04:00
lib.es2019.array.d.ts Reduce size of TypeScript Compiler snapshot (#6809) 2020-07-22 12:03:46 -04:00
lib.es2019.d.ts Reduce size of TypeScript Compiler snapshot (#6809) 2020-07-22 12:03:46 -04:00
lib.es2019.full.d.ts Reduce size of TypeScript Compiler snapshot (#6809) 2020-07-22 12:03:46 -04:00
lib.es2019.object.d.ts Reduce size of TypeScript Compiler snapshot (#6809) 2020-07-22 12:03:46 -04:00
lib.es2019.string.d.ts feat(cli): update to TypeScript 4.5 (#12410) 2021-12-10 09:12:21 +11:00
lib.es2019.symbol.d.ts Reduce size of TypeScript Compiler snapshot (#6809) 2020-07-22 12:03:46 -04:00
lib.es2020.bigint.d.ts feat: update to TypeScript 4.7 (#14242) 2022-06-01 10:19:18 +10:00
lib.es2020.d.ts feat: update to TypeScript 4.7 (#14242) 2022-06-01 10:19:18 +10:00
lib.es2020.date.d.ts feat: update to TypeScript 4.7 (#14242) 2022-06-01 10:19:18 +10:00
lib.es2020.full.d.ts Reduce size of TypeScript Compiler snapshot (#6809) 2020-07-22 12:03:46 -04:00
lib.es2020.intl.d.ts feat(cli): update to TypeScript 4.8 (#15064) 2022-09-20 07:00:01 +10:00
lib.es2020.number.d.ts feat: update to TypeScript 4.7 (#14242) 2022-06-01 10:19:18 +10:00
lib.es2020.promise.d.ts feat(cli): update to TypeScript 4.5 (#12410) 2021-12-10 09:12:21 +11:00
lib.es2020.sharedmemory.d.ts feat(cli): update to TypeScript 4.1 (#7573) 2020-11-24 09:31:10 +11:00
lib.es2020.string.d.ts Reduce size of TypeScript Compiler snapshot (#6809) 2020-07-22 12:03:46 -04:00
lib.es2020.symbol.wellknown.d.ts feat(cli): upgrade to TypeScript 4.3 (#9960) 2021-05-28 09:33:11 +10:00
lib.es2021.d.ts feat(cli): update to TypeScript 4.5 (#12410) 2021-12-10 09:12:21 +11:00
lib.es2021.full.d.ts feat(cli): upgrade to TypeScript 4.3 (#9960) 2021-05-28 09:33:11 +10:00
lib.es2021.intl.d.ts feat(cli): update to TypeScript 4.8 (#15064) 2022-09-20 07:00:01 +10:00
lib.es2021.promise.d.ts feat(cli): update to TypeScript 4.5 (#12410) 2021-12-10 09:12:21 +11:00
lib.es2021.string.d.ts feat(cli): upgrade to TypeScript 4.3 (#9960) 2021-05-28 09:33:11 +10:00
lib.es2021.weakref.d.ts feat(cli): upgrade to TypeScript 4.3 (#9960) 2021-05-28 09:33:11 +10:00
lib.es2022.array.d.ts feat(cli): update to TypeScript 4.6.2 (#13474) 2022-03-02 07:44:43 +11:00
lib.es2022.d.ts feat(cli): update to TypeScript 4.8 (#15064) 2022-09-20 07:00:01 +10:00
lib.es2022.error.d.ts feat(cli): update to TypeScript 4.8 (#15064) 2022-09-20 07:00:01 +10:00
lib.es2022.full.d.ts feat(cli): update to TypeScript 4.6.2 (#13474) 2022-03-02 07:44:43 +11:00
lib.es2022.intl.d.ts feat: update to TypeScript 4.7 (#14242) 2022-06-01 10:19:18 +10:00
lib.es2022.object.d.ts feat: update to TypeScript 4.7 (#14242) 2022-06-01 10:19:18 +10:00
lib.es2022.sharedmemory.d.ts feat(cli): update to TypeScript 4.8 (#15064) 2022-09-20 07:00:01 +10:00
lib.es2022.string.d.ts feat(cli): update to TypeScript 4.6.2 (#13474) 2022-03-02 07:44:43 +11:00
lib.esnext.array.d.ts feat(cli): update to TypeScript 4.6.2 (#13474) 2022-03-02 07:44:43 +11:00
lib.esnext.d.ts feat(cli): update to TypeScript 4.6.2 (#13474) 2022-03-02 07:44:43 +11:00
lib.esnext.full.d.ts Reduce size of TypeScript Compiler snapshot (#6809) 2020-07-22 12:03:46 -04:00
lib.esnext.intl.d.ts feat(cli): update to TypeScript 4.8 (#15064) 2022-09-20 07:00:01 +10:00
lib.scripthost.d.ts Reduce size of TypeScript Compiler snapshot (#6809) 2020-07-22 12:03:46 -04:00
lib.webworker.d.ts feat(cli): update to TypeScript 4.8 (#15064) 2022-09-20 07:00:01 +10:00
lib.webworker.importscripts.d.ts Reduce size of TypeScript Compiler snapshot (#6809) 2020-07-22 12:03:46 -04:00
lib.webworker.iterable.d.ts feat(cli): update to TypeScript 4.8 (#15064) 2022-09-20 07:00:01 +10:00
README.md chore: fixed various misspellings and other typos (#8691) 2020-12-11 06:45:45 +11:00
typescript.d.ts feat(cli): update to TypeScript 4.8 (#15064) 2022-09-20 07:00:01 +10:00

How to upgrade TypeScript.

The files in this directory are mostly from the TypeScript repository. We currently (unfortunately) have a rather manual process for upgrading TypeScript. It works like this currently:

  1. Checkout typescript repo in a separate directory.
  2. Copy typescript.js into Deno repo.
  3. Copy d.ts files into dts directory.

So that might look something like this:

git clone https://github.com/microsoft/TypeScript.git
cd typescript
git checkout v3.9.7
rsync lib/typescript.js ~/src/deno/cli/tsc/00_typescript.js
rsync --exclude=protocol.d.ts --exclude=tsserverlibrary.d.ts --exclude=typescriptServices.d.ts lib/*.d.ts ~/src/deno/cli/dts/