std::shared_ptr::swap
From cppreference.com
< cpp | memory | shared ptr
void swap( shared_ptr& r ); |
(since C++11) | |
Exchanges the contents of *this and r
Parameters
r | - | smart pointer to exchange the contents with |
Return value
(none)
Exceptions
noexcept specification:
noexcept