|
Boost : |
From: David Abrahams (dave_at_[hidden])
Date: 2003-08-05 13:16:01
Alisdair Meredith <alisdair.meredith_at_[hidden]> writes:
> The fix I am currently using looks like this in shared_ptr [line 284]
>
> void swap(shared_ptr<T> & other) // never throws
> {
> #if BOOST_WORKAROUND( __BORLANDC__, BOOST_TESTED_AT( 0x0564) )
> _STL::swap(px, other.px);
> #else
> std::swap(px, other.px);
> #endif
> pn.swap(other.pn);
> }
>
> I am not submitting this as a diff yet as I am not sure this is the
> 'correct' patch yet, but I hope it gives the idea. A similar patch
> needs to be applied everywhere in Boost std::swap is called, which could
> be quite a bit of work. I am happy to go through all the libraries and
> submit appropriate diffs, but first I would like agreement a patch is
> appropriate, and the correct form.
I'm trying to say that I think it's the wrong patch. The right patch
would put the swap specialization into _STL::.
-- Dave Abrahams Boost Consulting www.boost-consulting.com
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk