1
0
Fork 0
mirror of https://github.com/denoland/deno.git synced 2024-12-22 07:14:47 -05:00
denoland-deno/runtime/ops
Luke Edwards 13723f267e
feat: Add Deno.exitCode API (#23609)
This commits adds the ability to set a would-be exit code 
for the Deno process without forcing an immediate exit, 
through the new `Deno.exitCode` API.

- **Implements `Deno.exitCode` getter and setter**: Adds support for
setting
and retrieving a would-be exit code via `Deno.exitCode`.
This allows for asynchronous cleanup before process termination 
without immediately exiting.
- **Ensures type safety**: The setter for `Deno.exitCode` validates that
the provided value is a number, throwing a TypeError if not, to ensure
that
only valid exit codes are set.

Closes to #23605

---------

Co-authored-by: Bartek Iwańczuk <biwanczuk@gmail.com>
2024-05-29 23:16:27 +00:00
..
os feat: Add Deno.exitCode API (#23609) 2024-05-29 23:16:27 +00:00
web_worker fix(workers): importScripts concurrently and use a new reqwest::Client per importScripts (#23699) 2024-05-05 10:07:21 -04:00
bootstrap.rs fix: empty process.platform with __runtime_js_sources (#24005) 2024-05-28 13:20:19 +02:00
fs_events.rs chore: update copyright to 2024 (#21753) 2024-01-01 19:58:21 +00:00
http.rs feat(unstable): remove Deno.upgradeHttp API (#21856) 2024-01-22 21:35:39 +00:00
mod.rs chore: update copyright to 2024 (#21753) 2024-01-01 19:58:21 +00:00
permissions.rs refactor: add deno_permissions crate (#22236) 2024-03-12 10:42:26 -07:00
process.rs chore: update to Rust 1.75 (#21731) 2024-01-01 23:22:48 +01:00
runtime.rs fix(runtime): return number from op_ppid instead of bigint (#22169) 2024-01-30 15:34:31 +09:00
signal.rs fix(runtime): Restore default signal handler after user handlers are unregistered (#22757) 2024-03-11 10:22:28 -07:00
tty.rs fix(ext/node): windows cancel stdin read in line mode (#23969) 2024-05-29 22:23:04 +05:30
utils.rs chore: update copyright to 2024 (#21753) 2024-01-01 19:58:21 +00:00
web_worker.rs Reland refactor(cli): use new sanitizer for resources (#22226) 2024-02-05 12:21:29 -07:00
worker_host.rs fix(ext/node): support MessagePort in WorkerOptions.workerData (#22950) 2024-03-16 01:59:18 +01:00