pub trait GroupTokenFuncExt<T, Output>: Sized {
// Required method
fn release_on_return(self, token: T) -> impl FnOnce() -> Output + Send;
}Expand description
Extension trait for FnOnce to automatically release group tokens.
Required Methods§
Sourcefn release_on_return(self, token: T) -> impl FnOnce() -> Output + Send
fn release_on_return(self, token: T) -> impl FnOnce() -> Output + Send
Releases the group token when the closure returns.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.