Boost C++ Libraries: Ticket #2251: Bad comment, I think https://svn.boost.org/trac10/ticket/2251 <pre class="wiki"> // - swap_impl has a using-directive, rather than a using-declaration, // because some compilers (including MSVC 7.1, Borland 5.9.3, and // Intel 8.1) don't do argument-dependent lookup when it has a // using-declaration instead. </pre><p> IIUC, this isn't because of a peculiarity of any compiler: the standard says that ADL operates on names brought in to associated namespaces through using-declarations, but not on those visible by using-directives. A using-declaration is a declaration, while a using-directive is not :-) </p> en-us Boost C++ Libraries /htdocs/site/boost.png https://svn.boost.org/trac10/ticket/2251 Trac 1.4.3 niels_dekker Wed, 27 Aug 2008 16:59:04 GMT owner changed; cc set https://svn.boost.org/trac10/ticket/2251#comment:1 https://svn.boost.org/trac10/ticket/2251#comment:1 <ul> <li><strong>cc</strong> <span class="trac-author">niels_dekker</span> added </li> <li><strong>owner</strong> changed from <span class="trac-author">niels_dekker</span> to <span class="trac-author">Dave Abrahams</span> </li> </ul> <p> The quoted lines of comment are intended to provide an explanation to revision <a class="changeset" href="https://svn.boost.org/trac10/changeset/47967" title="Changed 'using std::swap;' to 'using namesapce std;' in swap_impl ...">[47967]</a>, by Joseph Gauterin, following a suggestion by Steven Watanabe. </p> <p> MSVC 7.1 and Borland didn't do ADL, when we still had a using-declaration (<em>using std::swap</em>), inside swap_impl. So Steven suggested to do a using-directive (<em>using namespace std</em>) instead: <a class="ext-link" href="http://lists.boost.org/Archives/boost/2008/08/140589.php"><span class="icon">​</span>http://lists.boost.org/Archives/boost/2008/08/140589.php</a> (suggestion a) </p> <p> Now that we have a using-directive, ADL appears to be done whenever appropriate, even for those specific compilers. As confirmed by the test results of <em>specialized_in_global</em> and <em>specialized_in_other</em>, at <a href="http://www.boost.org/development/tests/trunk/developer/utility-swap_.html">http://www.boost.org/development/tests/trunk/developer/utility-swap_.html</a> </p> <p> So would it be okay to you to have the ticket resolved as "invalid"? </p> Ticket joseph.gauterin Thu, 28 Aug 2008 19:04:58 GMT cc changed https://svn.boost.org/trac10/ticket/2251#comment:2 https://svn.boost.org/trac10/ticket/2251#comment:2 <ul> <li><strong>cc</strong> <span class="trac-author">joseph.gauterin</span> added </li> </ul> Ticket Dave Abrahams Fri, 29 Aug 2008 03:33:19 GMT status changed; resolution set https://svn.boost.org/trac10/ticket/2251#comment:3 https://svn.boost.org/trac10/ticket/2251#comment:3 <ul> <li><strong>status</strong> <span class="trac-field-old">new</span> → <span class="trac-field-new">closed</span> </li> <li><strong>resolution</strong> → <span class="trac-field-new">invalid</span> </li> </ul> <p> Replying to <a class="ticket" href="https://svn.boost.org/trac10/ticket/2251#comment:1" title="Comment 1">niels_dekker</a>: </p> <blockquote class="citation"> <p> So would it be okay to you to have the ticket resolved as "invalid"? </p> </blockquote> <p> Yes, in fact I think I misread the comment. Sorry! </p> Ticket