2 Oct
2013
2 Oct
'13
7:02 p.m.
On Wed, Oct 2, 2013 at 6:01 AM, Thorsten Ottosen < thorsten.ottosen@dezide.com> wrote:
a) swap would always work because both arguments must be non-null.
From the way he was talking about inter-operability with shared_ptr, I
think he's referring to a swap with a shared_ptr. b) this smart pointer cannot be moved (no move-assignment, no
move-constructor).
It can be moved. A copy is just a move that happens to not alter the state of the original object. Nothing about move operations requires that the moved-from object is in some different state (I.E. C++03 types with just copy constructors are still movable types). In other words, don't explicitly delete the move function. -- -Matt Calabrese