Skip to content

Commit 526259e

Browse files
jimblandycramertj
authored andcommitted
Minor doc fixes for future::stream.
1 parent c30adf5 commit 526259e

File tree

3 files changed

+4
-4
lines changed

3 files changed

+4
-4
lines changed

futures-util/src/stream/mod.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1051,7 +1051,7 @@ pub trait StreamExt: Stream {
10511051
///
10521052
/// # Panics
10531053
///
1054-
/// This method will panic of `capacity` is zero.
1054+
/// This method will panic if `capacity` is zero.
10551055
#[cfg(feature = "alloc")]
10561056
fn chunks(self, capacity: usize) -> Chunks<Self>
10571057
where Self: Sized

futures-util/src/stream/once.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ use futures_core::stream::Stream;
44
use futures_core::task::{Context, Poll};
55
use pin_utils::unsafe_pinned;
66

7-
/// Creates a stream of single element
7+
/// Creates a stream of a single element.
88
///
99
/// ```
1010
/// #![feature(async_await)]

futures-util/src/stream/poll_fn.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,9 @@ pub struct PollFn<F> {
1313

1414
impl<F> Unpin for PollFn<F> {}
1515

16-
/// Creates a new stream wrapping around a function returning `Poll`.
16+
/// Creates a new stream wrapping a function returning `Poll<Option<T>>`.
1717
///
18-
/// Polling the returned stream delegates to the wrapped function.
18+
/// Polling the returned stream calls the wrapped function.
1919
///
2020
/// # Examples
2121
///

0 commit comments

Comments
 (0)