Skip to content

Commit 3b06481

Browse files
authored
Merge pull request #18 from kpp/fix_doc
Fix doc ^C^V
2 parents 62cf6db + e733973 commit 3b06481

File tree

2 files changed

+3
-5
lines changed

2 files changed

+3
-5
lines changed

src/future.rs

+3-3
Original file line numberDiff line numberDiff line change
@@ -100,11 +100,11 @@ pub async fn then<FutA, FutB, F>(future: FutA, f: F) -> FutB::Output
100100
///
101101
/// ```
102102
/// #![feature(async_await)]
103-
/// use futures::future::{self, TryFutureExt};
103+
/// use futures_async_combinators::future::{ready, and_then};
104104
///
105105
/// # futures::executor::block_on(async {
106-
/// let future = future::ready(Ok::<i32, i32>(1));
107-
/// let future = future.and_then(|x| future::ready(Ok::<i32, i32>(x + 3)));
106+
/// let future = ready(Ok::<i32, i32>(1));
107+
/// let future = and_then(future, |x| ready(Ok::<i32, i32>(x + 3)));
108108
/// assert_eq!(future.await, Ok(4));
109109
/// # });
110110
/// ```

src/stream.rs

-2
Original file line numberDiff line numberDiff line change
@@ -473,7 +473,6 @@ pub fn flatten<St, SubSt, T>(stream: St) -> impl Stream<Item = T>
473473
/// ```
474474
/// #![feature(async_await)]
475475
/// # futures::executor::block_on(async {
476-
/// use futures::future;
477476
/// use futures_async_combinators::{future::ready, stream::{iter, then, collect}};
478477
///
479478
/// let stream = iter(1..=3);
@@ -634,7 +633,6 @@ pub fn chain<St>(stream: St, other: St) -> impl Stream<Item = St::Item>
634633
/// ```
635634
/// #![feature(async_await)]
636635
/// # futures::executor::block_on(async {
637-
/// use futures::future;
638636
/// use futures_async_combinators::{future::ready, stream::{iter, take_while, collect}};
639637
///
640638
/// let stream = iter(1..=10);

0 commit comments

Comments
 (0)