Boost logo

Boost :

From: Peter Dimov (pdimov_at_[hidden])
Date: 2023-11-29 16:04:13


Andrey Semashev wrote:
> You can think of BOOST_SCOPE_FINAL as a keyword that begins the
> declaration of a scope guard. The scope guard action then is what
> follows this keyword, and indeed it is not limited to just lambda
> functions.

Other languages call this "defer". E.g.

    defer fclose( fp );

or

    defer { fclose( fp ); }


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk