Boost logo

Boost :

From: Niels Dekker - mail address until 2008-12-31 (nd_mail_address_valid_until_2008-12-31_at_[hidden])
Date: 2008-07-29 04:45:51


The boost::swap utility from Joseph Gauterin has an ADL barrier against
infinite recursion or ambiguity, as recommended by Steven Watanabe and
David Abrahams, last year at the mailing list: "Re: [boost] Koenig
lookup swap." http://lists.boost.org/Archives/boost/2007/08/125938.php

Last Friday I added "test_adl_barrier" to test this ADL barrier.
Unfortunately it fails on many compilers, including XL (AIX), Intel
(version 9 and 10), GCC, Sun and Como:
http://www.boost.org/development/tests/trunk/developer/utility-swap_.html

While I usually use MSVC, and for that specific compiler, the ADL
barrier appears successful! Do you know how to fix the ADL barrier for
the other compilers? I'm afraid we'll need to have #if BOOST_WORKAROUND
statements in there...

FYI, the boost::swap utility is at:
http://svn.boost.org/svn/boost/trunk/boost/utility/swap.hpp

The ADL barrier test is at:
http://svn.boost.org/svn/boost/trunk/libs/utility/swap/test/test_adl_barrier.cpp

Kind regards,

--
Niels Dekker
http://www.xs4all.nl/~nd/dekkerware
Scientific programmer at LKEB, Leiden University Medical Center 

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