1
0
Fork 0
mirror of https://github.com/denoland/deno.git synced 2024-12-22 15:24:46 -05:00

Make Deno.kill unstable (#4950)

This commit is contained in:
Luca Casonato 2020-04-28 05:36:43 +02:00 committed by GitHub
parent 22b1a302f4
commit 15099cc016
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 8 additions and 0 deletions

View file

@ -2177,6 +2177,13 @@ declare namespace Deno {
* This calls `close()` on stderr after its done. */
stderrOutput(): Promise<Uint8Array>;
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;
}

View file

@ -229,6 +229,7 @@ fn op_kill(
args: Value,
_zero_copy: Option<ZeroCopyBuf>,
) -> Result<JsonOp, OpError> {
state.check_unstable("Deno.kill");
state.check_run()?;
let args: KillArgs = serde_json::from_value(args)?;