diff --git a/library/core/src/task/poll.rs b/library/core/src/task/poll.rs index 25b61c0e66641..af5bf441bb25f 100644 --- a/library/core/src/task/poll.rs +++ b/library/core/src/task/poll.rs @@ -45,6 +45,7 @@ impl Poll { /// assert_eq!(poll_some_len, Poll::Ready(13)); /// ``` #[stable(feature = "futures_api", since = "1.36.0")] + #[inline] pub fn map(self, f: F) -> Poll where F: FnOnce(T) -> U, @@ -144,6 +145,7 @@ impl Poll> { /// assert_eq!(squared, Poll::Ready(Ok(144))); /// ``` #[stable(feature = "futures_api", since = "1.36.0")] + #[inline] pub fn map_ok(self, f: F) -> Poll> where F: FnOnce(T) -> U, @@ -171,6 +173,7 @@ impl Poll> { /// assert_eq!(res, Poll::Ready(Err(0))); /// ``` #[stable(feature = "futures_api", since = "1.36.0")] + #[inline] pub fn map_err(self, f: F) -> Poll> where F: FnOnce(E) -> U, @@ -199,6 +202,7 @@ impl Poll>> { /// assert_eq!(squared, Poll::Ready(Some(Ok(144)))); /// ``` #[stable(feature = "poll_map", since = "1.51.0")] + #[inline] pub fn map_ok(self, f: F) -> Poll>> where F: FnOnce(T) -> U, @@ -228,6 +232,7 @@ impl Poll>> { /// assert_eq!(res, Poll::Ready(Some(Err(0)))); /// ``` #[stable(feature = "poll_map", since = "1.51.0")] + #[inline] pub fn map_err(self, f: F) -> Poll>> where F: FnOnce(E) -> U,