Reference-counting helpers - Copy/move cons/ass w/ casts
Added tests and fixed a few bugs.
This commit is contained in:
parent
e8e0e8101d
commit
6afe127d13
3 changed files with 189 additions and 2 deletions
include/ebcl/inline
|
@ -168,7 +168,9 @@ template<
|
|||
T_RcPtr< Q >&& other ) noexcept
|
||||
: target_{ nullptr }
|
||||
{
|
||||
std::swap( target_ , other.target_ );
|
||||
T* const ptr{ (T*) other.target_ };
|
||||
other.target_ = nullptr;
|
||||
target_ = ptr;
|
||||
}
|
||||
|
||||
template< typename T >
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue