Template:cpp/experimental/scope guard/destructor

Calls the exit function if the  is active, then destroys the stored  (if it is a function object) and any other non-static data members.{{#ifeq:{{{1|}}}|scope_success|

Exceptions
Throws any exception thrown by calling the exit function.}}{{#switch:{{{1|}}}|scope_fail|scope_success=