pub trait LocalContextExt: Runtime {
    fn scope_local<F, R>(
        locals: TaskLocals,
        fut: F
    ) -> Pin<Box<dyn Future<Output = R>>>
    where
        F: Future<Output = R> + 'static
; }
Expand description

Adds the ability to scope task-local data for !Send futures

Required Methods

Set the task locals for the given !Send future

Implementors