Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Refer to Poll::Pending in ReadMe. #45

Merged
merged 2 commits into from
Jan 16, 2024
Merged
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
12 changes: 5 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ with the `async` / `await` model.

The [`WouldBlock`](enum.Error.html) error variant signals that the operation
can't be completed *right now* and would need to block to complete.
[`WouldBlock`](enum.Error.html) is a special error in the sense that's not
[`WouldBlock`](enum.Error.html) is a special error in the sense that it's not
*fatal*; the operation can still be completed by retrying again later.

[`nb::Result`](type.Result.html) is based on the API of
Expand All @@ -32,12 +32,10 @@ which has a `WouldBlock` variant in its
We can map [`WouldBlock`](enum.Error.html) to different blocking and
non-blocking models:

- In blocking mode: [`WouldBlock`](enum.Error.html) means try again right
now (i.e. busy wait)
- In `futures` mode: [`WouldBlock`](enum.Error.html) means
[`Async::NotReady`](https://docs.rs/futures)
- In `await` mode: [`WouldBlock`](enum.Error.html) means `yield`
(suspend the generator)
- In blocking mode, [`WouldBlock`](enum.Error.html) means try again right
now, i.e. busy waiting.
- In `async` mode, [`WouldBlock`](enum.Error.html) means
[`Poll::Pending`](https://doc.rust-lang.org/core/task/enum.Poll.html#variant.Pending).


## Minimum Supported Rust Version (MSRV)
Expand Down