If active() == true, and invoking the condition function object returns true, invokes the wrapped callable action function object. Destroys the function objects.

Synopsis

Declared in header <boost/scope/scope_exit.hpp>

~scope_exit() noexcept(detail::conjunction<detail::is_nothrow_invocable<Func &>, detail::is_nothrow_invocable<Cond &>>::value);

Description

Throws: Nothing, unless invoking a function object throws.