1
0
Fork 0
mirror of https://github.com/denoland/deno.git synced 2025-01-10 16:11:13 -05:00

refactor: remove stdio interfaces, use intersection types (#4952)

This commit is contained in:
Bartek Iwańczuk 2020-04-28 02:01:00 +02:00 committed by GitHub
parent e6f70c77ee
commit 76641eb05e
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -776,24 +776,12 @@ declare namespace Deno {
close(): void; close(): void;
} }
export interface Stdin extends Reader, SyncReader, Closer {
readonly rid: number;
}
export interface Stdout extends Writer, SyncWriter, Closer {
readonly rid: number;
}
export interface Stderr extends Writer, SyncWriter, Closer {
readonly rid: number;
}
/** A handle for `stdin`. */ /** A handle for `stdin`. */
export const stdin: Stdin; export const stdin: Reader & SyncReader & Closer & { rid: number };
/** A handle for `stdout`. */ /** A handle for `stdout`. */
export const stdout: Stdout; export const stdout: Writer & SyncWriter & Closer & { rid: number };
/** A handle for `stderr`. */ /** A handle for `stderr`. */
export const stderr: Stderr; export const stderr: Writer & SyncWriter & Closer & { rid: number };
export interface OpenOptions { export interface OpenOptions {
/** Sets the option for read access. This option, when `true`, means that the /** Sets the option for read access. This option, when `true`, means that the