From 38050c3370a39180b9431cf9a9f2cac1886a9b19 Mon Sep 17 00:00:00 2001 From: Marek Kuskowski <50183564+nylonicious@users.noreply.github.com> Date: Thu, 28 Sep 2023 23:01:44 +0200 Subject: [PATCH] io: mark Interest::add as must_use --- tokio/src/io/interest.rs | 1 + 1 file changed, 1 insertion(+) diff --git a/tokio/src/io/interest.rs b/tokio/src/io/interest.rs index cf6d270e0c6..e823910d1b6 100644 --- a/tokio/src/io/interest.rs +++ b/tokio/src/io/interest.rs @@ -163,6 +163,7 @@ impl Interest { /// /// assert!(BOTH.is_readable()); /// assert!(BOTH.is_writable()); + #[must_use = "this returns the result of the operation, without modifying the original"] pub const fn add(self, other: Interest) -> Interest { Self(self.0 | other.0) }