Boost C++ Libraries: Ticket #9403: [ranges] typo in equal_impl causes O(N) impl to be selected instead of O(1) impl https://svn.boost.org/trac10/ticket/9403 <p> The following overload of <code>equal_impl</code> will never be selected because it doesn't take the extra two tag parameters that the others do: </p> <pre class="wiki"> template&lt; class RandomAccessTraversalReadableIterator1, class RandomAccessTraversalReadableIterator2, class BinaryPredicate &gt; inline bool equal_impl( RandomAccessTraversalReadableIterator1 first1, RandomAccessTraversalReadableIterator1 last1, RandomAccessTraversalReadableIterator2 first2, RandomAccessTraversalReadableIterator2 last2, BinaryPredicate pred ) { return ((last1 - first1) == (last2 - first2)) &amp;&amp; std::equal(first1, last1, first2, pred); } </pre> en-us Boost C++ Libraries /htdocs/site/boost.png https://svn.boost.org/trac10/ticket/9403 Trac 1.4.3 Neil Groves Fri, 21 Feb 2014 20:18:01 GMT status changed https://svn.boost.org/trac10/ticket/9403#comment:1 https://svn.boost.org/trac10/ticket/9403#comment:1 <ul> <li><strong>status</strong> <span class="trac-field-old">new</span> → <span class="trac-field-new">assigned</span> </li> </ul> Ticket Neil Groves Wed, 26 Feb 2014 21:36:11 GMT status changed; resolution set https://svn.boost.org/trac10/ticket/9403#comment:2 https://svn.boost.org/trac10/ticket/9403#comment:2 <ul> <li><strong>status</strong> <span class="trac-field-old">assigned</span> → <span class="trac-field-new">closed</span> </li> <li><strong>resolution</strong> → <span class="trac-field-new">fixed</span> </li> </ul> <p> Argh, what a school boy error - sorry. </p> Ticket Eric Niebler Wed, 26 Feb 2014 21:38:08 GMT <link>https://svn.boost.org/trac10/ticket/9403#comment:3 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/9403#comment:3</guid> <description> <p> Ha! These errors are hard to spot. The code compiles and yields the correct results, after all. Don't sweat it. </p> </description> <category>Ticket</category> </item> </channel> </rss>