#![stable(feature = "futures_api", since = "1.36.0")]
use crate::ptr::NonNull;
use crate::task::Context;
mod async_drop;
mod future;
mod into_future;
mod join;
mod pending;
mod poll_fn;
mod ready;
#[unstable(feature = "async_drop", issue = "126482")]
pub use async_drop::{AsyncDrop, AsyncDropInPlace, async_drop, async_drop_in_place};
#[stable(feature = "into_future", since = "1.64.0")]
pub use into_future::IntoFuture;
#[stable(feature = "future_readiness_fns", since = "1.48.0")]
pub use pending::{Pending, pending};
#[stable(feature = "future_poll_fn", since = "1.64.0")]
pub use poll_fn::{PollFn, poll_fn};
#[stable(feature = "future_readiness_fns", since = "1.48.0")]
pub use ready::{Ready, ready};
#[stable(feature = "futures_api", since = "1.36.0")]
pub use self::future::Future;
#[unstable(feature = "future_join", issue = "91642")]
pub use self::join::join;
#[lang = "ResumeTy"]
#[doc(hidden)]
#[unstable(feature = "gen_future", issue = "50547")]
#[derive(Debug, Copy, Clone)]
pub struct ResumeTy(NonNull<Context<'static>>);
#[unstable(feature = "gen_future", issue = "50547")]
unsafe impl Send for ResumeTy {}
#[unstable(feature = "gen_future", issue = "50547")]
unsafe impl Sync for ResumeTy {}
#[lang = "get_context"]
#[doc(hidden)]
#[unstable(feature = "gen_future", issue = "50547")]
#[must_use]
#[inline]
pub unsafe fn get_context<'a, 'b>(cx: ResumeTy) -> &'a mut Context<'b> {
unsafe { &mut *cx.0.as_ptr().cast() }
}