Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ maintenance = { status = "experimental" }

[dependencies]
pin-utils = "=0.1.0-alpha.4"
async-trait = "0.1.3"

[dependencies.futures]
version = "=0.3.0-alpha.18"
Expand Down
2 changes: 1 addition & 1 deletion benches/future.rs
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ fn bench_map(c: &mut Criterion) {
b.iter(async move || {
use futures_async_combinators::future::*;
let fut = ready(40);
let fut = map(fut, |x| x + 2);
let fut = fut.map(|x| x + 2);
black_box(fut).await
})
});
Expand Down
4 changes: 2 additions & 2 deletions examples/future.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ use futures_async_combinators::future::*;
fn main() {
executor::block_on(async {
let future = ready(Ok::<i32, i32>(1));
let future = and_then(future, |x| ready(Ok::<i32, i32>(x + 3)));
let future = inspect(future, |x| {
let future = future.and_then(|x| ready(Ok::<i32, i32>(x + 3)));
let future = future.inspect(|x| {
dbg!(x);
});
assert_eq!(future.await, Ok(4));
Expand Down
Loading