Boost logo

Boost :

Subject: Re: [boost] [rfc] rcpp
From: Mathias Gaunard (mathias.gaunard_at_[hidden])
Date: 2010-02-22 13:59:55


Ivan Sorokin wrote:
> Hello.
>
> Thanks for feedback, Mathias!
>
> Mathias Gaunard wrote:
>> You might want to use proper move emulation in the absence of C++0x,
>> as is provided by Boost.Move.
> There is no such library Boost.Move.

It is in the review queue to be included as a first-class Boost citizen,
but it seems it is already used by Boost.Interprocess and shipped with it.

> If copy constructor or move constructor can throw an exception the only
> function that works incorrect is release.

My bad, I assumed the operator= was implemented as you described in the
documentation (clear current resource first), but you're actually using
a temporary then swap, which means the new resource is moved *before*
the old resource is released.


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk