Boost logo

Boost :

From: Andrey Semashev (andrey.semashev_at_[hidden])
Date: 2023-11-28 18:13:42


On 11/28/23 21:09, Jeff Garland via Boost wrote:
>
> Maybe another thought would be to have a section that actually describes
> the extensions from the TS proposal (like the boost scoped exit compare) --
> or did I miss it in the docs? My quick comparison looks to be mostly the
> fd_deleter and unique_fd stuff and not so much in the core api? Which are
> pure extensions and could be clearly marked as such -- and could later be
> converted to work with std::scope_* if people wanted?

Yes, this has already been requested and answered; I will add a section
in the docs.

https://github.com/Lastique/scope/issues/5

In the meantime, I'll reproduce the list of extensions below:

* A new scope_final scope guard, which is a more lightweight alternative
to scope_exit. It is accompanied with the BOOST_SCOPE_FINAL macro that
allows to simplify scope guard declaration syntax.
* Scope guards can be activated/deactivated multiple times.
* Scope guards can be created inactive initially.
* Scope guard factory functions, for compatibility with C++11.
* Support for custom condition functions for checking scope guards.
This, for example, allows one to check for error codes instead of
exceptions in scope_fail/scope_success.
* Support for optional resource traits in unique_resource wrapper, which
improves usage with resources having unallocated values.
* unique_resource supports swapping.
* unique_resource supports dereferencing for any resource types that
support dereferencing, not only pointers.
* More flexible constructors for unique_resource.


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