Skip to content

Commit

Permalink
Rollup merge of rust-lang#58145 - taiki-e:poll, r=cramertj
Browse files Browse the repository at this point in the history
Add #[must_use] to core::task::Poll

cc rust-lang/rfcs#2592

r? @withoutboats
  • Loading branch information
kennytm authored Feb 5, 2019
2 parents ff097ca + 4847c09 commit 64f0032
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 64f0032

Please sign in to comment.