mirror of
https://github.com/async-rs/async-std.git
synced 2025-01-16 10:49:55 +00:00
fix counting lines example
This commit is contained in:
parent
0156dc879b
commit
04cafeab2c
1 changed files with 1 additions and 1 deletions
|
@ -149,7 +149,7 @@ pub trait BufRead {
|
||||||
/// let mut lines = BufReader::new(file).lines();
|
/// let mut lines = BufReader::new(file).lines();
|
||||||
/// let mut count = 0;
|
/// let mut count = 0;
|
||||||
///
|
///
|
||||||
/// for line in lines.next().await {
|
/// while let Some(line) = lines.next().await {
|
||||||
/// line?;
|
/// line?;
|
||||||
/// count += 1;
|
/// count += 1;
|
||||||
/// }
|
/// }
|
||||||
|
|
Loading…
Reference in a new issue