]> git.lizzy.rs Git - rust.git/commitdiff
Document std::fs::File close behavior ignoring errors
authorChris Gregory <czipperz@gmail.com>
Wed, 27 Mar 2019 20:37:50 +0000 (16:37 -0400)
committerChris Gregory <czipperz@gmail.com>
Wed, 27 Mar 2019 20:37:50 +0000 (16:37 -0400)
src/libstd/fs.rs

index dfff44b88ea784e3598285ca9555f18db0d5255c..06d8ee99b64d1b92e333e1fa15bf3af45cdfb57d 100644 (file)
 /// it was opened with. Files also implement [`Seek`] to alter the logical cursor
 /// that the file contains internally.
 ///
-/// Files are automatically closed when they go out of scope.
+/// Files are automatically closed when they go out of scope.  All errors are
+/// ignored due to complications with correctly handling them.  For instance, an
+/// error in closing a file could mean that closing failed, or that the file had
+/// an error before closing that was only unearthed by closing the file.
 ///
 /// # Examples
 ///