Skip to content

Commit

Permalink
Add #[must_use] to core::task::Poll
Browse files Browse the repository at this point in the history
  • Loading branch information
taiki-e committed Feb 4, 2019
1 parent 8ae730a commit 4847c09
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/libcore/task/poll.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ use result::Result;

/// Indicates whether a value is available or if the current task has been
/// scheduled to receive a wakeup instead.
#[must_use = "this `Poll` may be a `Pending` variant, which should be handled"]
#[derive(Copy, Clone, Debug, Eq, PartialEq, Ord, PartialOrd, Hash)]
pub enum Poll<T> {
/// Represents that a value is immediately ready.
Expand Down

0 comments on commit 4847c09

Please sign in to comment.