- Notifications
You must be signed in to change notification settings - Fork 13.9k
Closed
Labels
C-feature-requestCategory: A feature request, i.e: not implemented / a PR.Category: A feature request, i.e: not implemented / a PR.T-libs-apiRelevant to the library API team, which will review and decide on the PR/issue.Relevant to the library API team, which will review and decide on the PR/issue.
Description
The implementations of Write which are MT-safe under the covers can implement a trait along the lines of
impl Write for &'_ Self { ... } and some already do:
impl<'a> Write for &'a UnixStream { ... } impl<'_> Write for &'_ TcpStream { ... } impl<'_> Write for &'_ File { ... } However, these appear to be the extent of the current implementations. The following types could also do the same:
Sink– does not inspect data andWritemethods are a no-op;Stdin/Stdout– internally aMutex(and even if theMutexwas removed in the future, the underlying syscalls are MT-safe – much like they are for a regularFile);ChildStdin– similar toFileor*Streams;
Metadata
Metadata
Assignees
Labels
C-feature-requestCategory: A feature request, i.e: not implemented / a PR.Category: A feature request, i.e: not implemented / a PR.T-libs-apiRelevant to the library API team, which will review and decide on the PR/issue.Relevant to the library API team, which will review and decide on the PR/issue.