Skip to content

Commit 03c9171

Browse files
authored
Rollup merge of #157603 - innin-jam:fix-doc-comment-typo-in-std, r=jhpratt
Fixed Doc Comment Typo in Linewritershim The doc comment of the `flush_if_completed_line` function spelt 'if' as 'iff'.
2 parents e43ec0c + d412ac1 commit 03c9171

1 file changed

Lines changed: 4 additions & 3 deletions

File tree

library/std/src/io/buffered/linewritershim.rs

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -40,9 +40,10 @@ impl<'a, W: ?Sized + Write> LineWriterShim<'a, W> {
4040
self.buffer.buffer()
4141
}
4242

43-
/// Flushes the buffer iff the last byte is a newline (indicating that an
44-
/// earlier write only succeeded partially, and we want to retry flushing
45-
/// the buffered line before continuing with a subsequent write).
43+
/// Flushes the buffer if and only if the last byte is a newline
44+
/// (indicating that an earlier write only succeeded partially, and we
45+
/// want to retry flushing the buffered line before continuing with a
46+
/// subsequent write).
4647
fn flush_if_completed_line(&mut self) -> io::Result<()> {
4748
match self.buffered().last().copied() {
4849
Some(b'\n') => self.buffer.flush_buf(),

0 commit comments

Comments
 (0)