Skip to content

Commit

Permalink
io: add must_use to Interest::remove
Browse files Browse the repository at this point in the history
  • Loading branch information
nylonicious committed Sep 10, 2023
1 parent a8824f8 commit 85e1aa1
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions tokio/src/io/interest.rs
Expand Up @@ -190,6 +190,7 @@ impl Interest {
/// // Remove all interests at once.
/// assert_eq!(RW_INTEREST.remove(RW_INTEREST), None);
/// ```
#[must_use = "this returns the result of the operation, without modifying the original"]
pub fn remove(self, other: Interest) -> Option<Interest> {
let value = self.0 & !other.0;

Expand Down

0 comments on commit 85e1aa1

Please sign in to comment.