mirror of
https://github.com/denoland/deno.git
synced 2025-02-01 20:25:12 -05:00
Mark signal APIs as unstable (#3779)
This commit is contained in:
parent
11a29fdb44
commit
fe427eedb1
1 changed files with 10 additions and 3 deletions
13
cli/js/lib.deno_runtime.d.ts
vendored
13
cli/js/lib.deno_runtime.d.ts
vendored
|
@ -2130,8 +2130,11 @@ declare namespace Deno {
|
||||||
*/
|
*/
|
||||||
export const args: string[];
|
export const args: string[];
|
||||||
|
|
||||||
/** SignalStream represents the stream of signals, implements both
|
/** UNSTABLE new API.
|
||||||
* AsyncIterator and PromiseLike */
|
*
|
||||||
|
* SignalStream represents the stream of signals, implements both
|
||||||
|
* AsyncIterator and PromiseLike
|
||||||
|
*/
|
||||||
export class SignalStream implements AsyncIterator<void>, PromiseLike<void> {
|
export class SignalStream implements AsyncIterator<void>, PromiseLike<void> {
|
||||||
constructor(signal: typeof Deno.Signal);
|
constructor(signal: typeof Deno.Signal);
|
||||||
then<T, S>(
|
then<T, S>(
|
||||||
|
@ -2142,7 +2145,9 @@ declare namespace Deno {
|
||||||
[Symbol.asyncIterator](): AsyncIterator<void>;
|
[Symbol.asyncIterator](): AsyncIterator<void>;
|
||||||
dispose(): void;
|
dispose(): void;
|
||||||
}
|
}
|
||||||
/**
|
|
||||||
|
/** UNSTABLE new API.
|
||||||
|
*
|
||||||
* Returns the stream of the given signal number. You can use it as an async
|
* Returns the stream of the given signal number. You can use it as an async
|
||||||
* iterator.
|
* iterator.
|
||||||
*
|
*
|
||||||
|
@ -2168,6 +2173,8 @@ declare namespace Deno {
|
||||||
* The above for-await loop exits after 5 seconds when sig.dispose() is called.
|
* The above for-await loop exits after 5 seconds when sig.dispose() is called.
|
||||||
*/
|
*/
|
||||||
export function signal(signo: number): SignalStream;
|
export function signal(signo: number): SignalStream;
|
||||||
|
|
||||||
|
/** UNSTABLE new API. */
|
||||||
export const signals: {
|
export const signals: {
|
||||||
/** Returns the stream of SIGALRM signals.
|
/** Returns the stream of SIGALRM signals.
|
||||||
* This method is the shorthand for Deno.signal(Deno.Signal.SIGALRM). */
|
* This method is the shorthand for Deno.signal(Deno.Signal.SIGALRM). */
|
||||||
|
|
Loading…
Add table
Reference in a new issue