Poll
`Poll<T>` is an enum with two variants: `Ready(T)` and `Pending`. Every `Future::poll` returns one. Adapters like `Future::ready` and `Future::pending` produce the obvious always-ready / always-pending futures.
Context and Waker
A `Waker` is a clonable handle the future uses to ask the runtime to poll it again. `Context` is the per-poll-call container that holds the current task's Waker. Constructing a Waker by hand involves a `RawWakerVTable` with raw function pointers — most users get one from a runtime instead.
For deeper background, see a complete cheat-sheet of std collection complexities for the broader context behind this section.
Ready macro
`std::task::ready!` is the analogue of `?` for `Poll<T>` — it short-circuits Pending out of a poll function and unwraps Ready into the surrounding expression. It dramatically cleans up hand-rolled `poll` implementations.
When you use std::task
Two times: implementing a runtime (Tokio, smol, glommio) or a custom leaf Future (a sleep, a timer, a socket bridge). Application code stays in `async fn` and never imports anything from `std::task` directly.
For deeper background, see the official Rust API guidelines for module-level design for the broader context behind this section.
Useful crates
`futures-task` re-exports the same items with extra utilities. `tokio::task` adds spawning, joining, and yield-now helpers. `async-task` provides reusable executor primitives. Most application code touches `tokio::spawn`, never `std::task`.