pub unsafe trait AsContext<T>: AsRef<Context<T>>where
    T: Sync,
{ }
Expand description

A marker trait promising AsRef<Context<T>> is safely implemented

Safety

When assigned to a thread local, the pin drop guarantee must be upheld for Context<T>: it cannot be wrapped in a pointer type nor cell type and it must not be invalidated nor repurposed until when drop happens as a consequence of the thread dropping.

Implementors§