Skip to main content
Journey Uncommon Logo
JourneyUncommon
hardRustasync/await state machineSingle-choice MCQ

Consider the async state machine the compiler generates for this function. Across how many distinct states (variants of the generated state enum) can the executor observe `x` to potentially be live, and why does that matter for the future's size?

async fn f() -> i32 { let x = 41; other().await; x + 1 }