@@ -10,7 +10,6 @@ use crate::task::{Context, Poll};
1010/// # Examples
1111///
1212/// ```
13- /// #![feature(future_poll_fn)]
1413/// # async fn run() {
1514/// use core::future::poll_fn;
1615/// use std::task::{Context, Poll};
@@ -23,7 +22,7 @@ use crate::task::{Context, Poll};
2322/// assert_eq!(read_future.await, "Hello, World!".to_owned());
2423/// # }
2524/// ```
26- #[ unstable ( feature = "future_poll_fn" , issue = "72302 " ) ]
25+ #[ stable ( feature = "future_poll_fn" , since = "1.64.0 " ) ]
2726pub fn poll_fn < T , F > ( f : F ) -> PollFn < F >
2827where
2928 F : FnMut ( & mut Context < ' _ > ) -> Poll < T > ,
@@ -36,22 +35,22 @@ where
3635/// This `struct` is created by [`poll_fn()`]. See its
3736/// documentation for more.
3837#[ must_use = "futures do nothing unless you `.await` or poll them" ]
39- #[ unstable ( feature = "future_poll_fn" , issue = "72302 " ) ]
38+ #[ stable ( feature = "future_poll_fn" , since = "1.64.0 " ) ]
4039pub struct PollFn < F > {
4140 f : F ,
4241}
4342
44- #[ unstable ( feature = "future_poll_fn" , issue = "72302 " ) ]
43+ #[ stable ( feature = "future_poll_fn" , since = "1.64.0 " ) ]
4544impl < F > Unpin for PollFn < F > { }
4645
47- #[ unstable ( feature = "future_poll_fn" , issue = "72302 " ) ]
46+ #[ stable ( feature = "future_poll_fn" , since = "1.64.0 " ) ]
4847impl < F > fmt:: Debug for PollFn < F > {
4948 fn fmt ( & self , f : & mut fmt:: Formatter < ' _ > ) -> fmt:: Result {
5049 f. debug_struct ( "PollFn" ) . finish ( )
5150 }
5251}
5352
54- #[ unstable ( feature = "future_poll_fn" , issue = "72302 " ) ]
53+ #[ stable ( feature = "future_poll_fn" , since = "1.64.0 " ) ]
5554impl < T , F > Future for PollFn < F >
5655where
5756 F : FnMut ( & mut Context < ' _ > ) -> Poll < T > ,
0 commit comments