Subject: Re: [boost] [utility] [swap] How about Boost.Move?
From: Marc Glisse (marc.glisse_at_[hidden])
Date: 2013-07-30 03:51:19
On Mon, 29 Jul 2013, Joseph Gauterin wrote:
> Given a user define types that specializes std::swap but isn't moveable (a
> reasonable scenario for C++03 code still being compiled with a C++03
> compiler), wouldn't this change result in 3 copies instead of a single call
> to the specialized std:swap?
The recommended way is to overload swap for your type, not specialize
std::swap. As long as that case still works, the rest might be
-- Marc Glisse
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk