Boost logo

Boost :

From: Robert Ramey (ramey_at_[hidden])
Date: 2019-06-27 16:32:15


On 6/27/19 8:43 AM, Andrey Semashev via Boost wrote:
- From the caller's perspective, a noexcept function will never throw.
>
>> In anycase I should have phrased the above as:
>>
>> Is swap guaranteed to succeed?
>
> In general, no. It is only guaranteed to succeed if it is noexcept. See
> above when it is noexcept.

A... - I'm still confused. How can one say that swap is guaranteed to
succeed when it can result in calling terminate()?

In C++17 there is is_nothrow_swappbale trait
> that allows to test this.
this leads to useful information
>
> _______________________________________________
> Unsubscribe & other changes:
> http://lists.boost.org/mailman/listinfo.cgi/boost


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