diff options
Diffstat (limited to 'src/future/ready.rs')
-rw-r--r-- | src/future/ready.rs | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/future/ready.rs b/src/future/ready.rs index 35f01c9..e3d791b 100644 --- a/src/future/ready.rs +++ b/src/future/ready.rs @@ -1,3 +1,4 @@ +use super::assert_future; use core::pin::Pin; use futures_core::future::{FusedFuture, Future}; use futures_core::task::{Context, Poll}; @@ -45,7 +46,7 @@ impl<T> Future for Ready<T> { /// # }); /// ``` pub fn ready<T>(t: T) -> Ready<T> { - Ready(Some(t)) + assert_future::<T, _>(Ready(Some(t))) } /// Create a future that is immediately ready with a success value. |