mirror of
https://github.com/denoland/deno.git
synced 2025-07-24 13:44:08 +00:00
Make Deno.kill unstable (#4950)
This commit is contained in:
parent
22b1a302f4
commit
15099cc016
2 changed files with 8 additions and 0 deletions
7
cli/js/lib.deno.ns.d.ts
vendored
7
cli/js/lib.deno.ns.d.ts
vendored
|
@ -2177,6 +2177,13 @@ declare namespace Deno {
|
||||||
* This calls `close()` on stderr after its done. */
|
* This calls `close()` on stderr after its done. */
|
||||||
stderrOutput(): Promise<Uint8Array>;
|
stderrOutput(): Promise<Uint8Array>;
|
||||||
close(): void;
|
close(): void;
|
||||||
|
|
||||||
|
/** **UNSTABLE**: The `signo` argument may change to require the Deno.Signal
|
||||||
|
* enum.
|
||||||
|
*
|
||||||
|
* Send a signal to process. This functionality currently only works on
|
||||||
|
* Linux and Mac OS.
|
||||||
|
*/
|
||||||
kill(signo: number): void;
|
kill(signo: number): void;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -229,6 +229,7 @@ fn op_kill(
|
||||||
args: Value,
|
args: Value,
|
||||||
_zero_copy: Option<ZeroCopyBuf>,
|
_zero_copy: Option<ZeroCopyBuf>,
|
||||||
) -> Result<JsonOp, OpError> {
|
) -> Result<JsonOp, OpError> {
|
||||||
|
state.check_unstable("Deno.kill");
|
||||||
state.check_run()?;
|
state.check_run()?;
|
||||||
|
|
||||||
let args: KillArgs = serde_json::from_value(args)?;
|
let args: KillArgs = serde_json::from_value(args)?;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue