BDLB_SCOPEEXIT_GUARD

Create a local variable with a generated unique name and with a type that is an instantiation of bdlb::ScopeExit initialized with the specified EXIT_FUNC. Note that the specific type of bdlb::ScopeExit used will depend on available language features. The behavior is undefined if this macro is used (expanded) more than once on the same source line. Note that using this macro in another macro more than once is equivalent to using it more than once on the same source line.

Synopsis

Declared in <bdlb_scopeexit.h>

#define BDLB_SCOPEEXIT_GUARD(EXIT_FUNC)