about summary refs log tree commit diff
path: root/library/std/src/io
diff options
context:
space:
mode:
Diffstat (limited to 'library/std/src/io')
-rw-r--r--library/std/src/io/buffered/linewriter.rs2
-rw-r--r--library/std/src/io/mod.rs8
2 files changed, 2 insertions, 8 deletions
diff --git a/library/std/src/io/buffered/linewriter.rs b/library/std/src/io/buffered/linewriter.rs
index 502c6e3c6c0..d7b620d6f91 100644
--- a/library/std/src/io/buffered/linewriter.rs
+++ b/library/std/src/io/buffered/linewriter.rs
@@ -227,6 +227,6 @@ where
                 "buffer",
                 &format_args!("{}/{}", self.inner.buffer().len(), self.inner.capacity()),
             )
-            .finish()
+            .finish_non_exhaustive()
     }
 }
diff --git a/library/std/src/io/mod.rs b/library/std/src/io/mod.rs
index 5316305a303..9953bcd556d 100644
--- a/library/std/src/io/mod.rs
+++ b/library/std/src/io/mod.rs
@@ -2114,6 +2114,7 @@ pub trait BufRead: Read {
 ///
 /// [`chain`]: Read::chain
 #[stable(feature = "rust1", since = "1.0.0")]
+#[derive(Debug)]
 pub struct Chain<T, U> {
     first: T,
     second: U,
@@ -2195,13 +2196,6 @@ impl<T, U> Chain<T, U> {
     }
 }
 
-#[stable(feature = "std_debug", since = "1.16.0")]
-impl<T: fmt::Debug, U: fmt::Debug> fmt::Debug for Chain<T, U> {
-    fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
-        f.debug_struct("Chain").field("t", &self.first).field("u", &self.second).finish()
-    }
-}
-
 #[stable(feature = "rust1", since = "1.0.0")]
 impl<T: Read, U: Read> Read for Chain<T, U> {
     fn read(&mut self, buf: &mut [u8]) -> Result<usize> {