Exchange the stored exception with that of another instance of std::exception_ptr
.
void swap(exception_ptr& other);
*this
references the stored exception referenced by other
prior to the call (if any); other
references the stored exception referenced by *this
prior to the call (if any).
Nothing.
#include <exception_ptr>