mrdocs::ScopeExit

Execute a callable when the enclosing scope exits unless dismissed.

Synopsis

template<class F>
class ScopeExit;

Member Functions

Name

Description

ScopeExit [constructor]

Construct with a callable to invoke on scope exit.

~ScopeExit [destructor]

Invoke the stored callable if the guard was not dismissed.

dismiss

Prevent the callable from running on destruction.

Deduction Guides

Name

Description

ScopeExit<F>

Deduction guide for ScopeExit.

Created with MrDocs