Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
Added comparison with futures
  • Loading branch information
zesterer committed May 11, 2023
1 parent 767e6db commit 5764258
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -71,3 +71,7 @@ async fn main() {
```

You can also use `#[pollster::test]` for tests.

## Comparison with `futures::executor::block_on`

`pollster` does approximately the same thing as the `block_on` function from the `futures` crate. If you already have `futures` in your dependency tree, you might as well use it instead. `pollster` is primarily for applications that don't care to pull all of `futures` or another runtime like `tokio` into their dependency tree for the sake of evaluating simple futures.

0 comments on commit 5764258

Please sign in to comment.