Skip to content

Commit

Permalink
link to Future::poll from the Poll docs
Browse files Browse the repository at this point in the history
The most important thing about Poll is that Future::poll returns it, but
previously the docs didn't emphasize this.
  • Loading branch information
oconnor663 committed Aug 25, 2024
1 parent 8dafd33 commit 22ec897
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions core/src/task/poll.rs
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@ use crate::ops::{self, ControlFlow};

/// Indicates whether a value is available or if the current task has been
/// scheduled to receive a wakeup instead.
///
/// This is returned by [`Future::poll`](core::future::Future::poll).
#[must_use = "this `Poll` may be a `Pending` variant, which should be handled"]
#[derive(Copy, Clone, Debug, Eq, PartialEq, Ord, PartialOrd, Hash)]
#[lang = "Poll"]
Expand Down

0 comments on commit 22ec897

Please sign in to comment.