Trait std::finally::FinallyExperimental
[-]
[+]
[src]
pub trait Finally<T> { fn finally<F>(&mut self, dtor: F) -> T; }
A trait for executing a destructor unconditionally after a block of code, regardless of whether the blocked fails.
Required Methods
fn finally<F>(&mut self, dtor: F) -> T
Executes this object, unconditionally running dtor
after this block of
code has run.
Implementors
impl<T, F> Finally<T> for F