Deduplicates io::Write implementations
This commit is contained in:
parent
28db5214d2
commit
ec7f9b927f
2 changed files with 18 additions and 18 deletions
|
@ -246,19 +246,19 @@ pub struct ChildStdin {
|
|||
#[stable(feature = "process", since = "1.0.0")]
|
||||
impl Write for ChildStdin {
|
||||
fn write(&mut self, buf: &[u8]) -> io::Result<usize> {
|
||||
self.inner.write(buf)
|
||||
(&*self).write(buf)
|
||||
}
|
||||
|
||||
fn write_vectored(&mut self, bufs: &[IoSlice<'_>]) -> io::Result<usize> {
|
||||
self.inner.write_vectored(bufs)
|
||||
(&*self).write_vectored(bufs)
|
||||
}
|
||||
|
||||
fn is_write_vectored(&self) -> bool {
|
||||
self.inner.is_write_vectored()
|
||||
io::Write::is_write_vectored(&&*self)
|
||||
}
|
||||
|
||||
fn flush(&mut self) -> io::Result<()> {
|
||||
Ok(())
|
||||
(&*self).flush()
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue