Skip to content

Commit

Permalink
Remove unused variable in sample documentation
Browse files Browse the repository at this point in the history
`line` is actually declared later in `while let ...`, so this line is not necessary 

```
warning: unused variable: `line`
   --> src/mpv.rs:125:9
    |
125 |     let mut line = String::new();
    |         ^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_line`
```
  • Loading branch information
derlaft committed Apr 25, 2021
1 parent ace8e58 commit 0dc0904
Showing 1 changed file with 0 additions and 1 deletion.
1 change: 0 additions & 1 deletion src/io.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1465,7 1465,6 @@ pub trait AsyncBufReadExt: AsyncBufRead {
/// let mut reader = BufReader::new(input);
/// let mut lines = reader.lines();
///
/// let mut line = String::new();
/// while let Some(line) = lines.next().await {
/// println!("{}", line?);
/// }
Expand Down

0 comments on commit 0dc0904

Please sign in to comment.