From: David Abrahams (dave_at_[hidden])
Date: 2008-07-29 09:34:57
on Tue Jul 29 2008, "Niels Dekker - mail address until 2008-12-31" <nd_mail_address_valid_until_2008-12-31-AT-xs4all.nl> wrote:
> 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."
> 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:
> 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:
> The ADL barrier test is at:
Try replacing the using declaration with a using directive in swap.hpp
Appears to work for GCC.
-- Dave Abrahams BoostPro Computing http://www.boostpro.com
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk