Subject: Re: [Boost-bugs] [Boost C++ Libraries] #7294: boost::hash does not compile with ranges
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2012-08-27 08:52:24
#7294: boost::hash does not compile with ranges
-----------------------------------------------+----------------------------
Reporter: Gennady Proskurin <gpr@â¦> | Owner: neilgroves
Type: Feature Requests | Status: new
Milestone: To Be Determined | Component: range
Version: Boost 1.51.0 | Severity: Problem
Resolution: | Keywords:
-----------------------------------------------+----------------------------
Changes (by danieljames):
* owner: danieljames => neilgroves
* type: Bugs => Feature Requests
* component: hash => range
Comment:
That's a bug fix, iterator_range has an implicit conversion to bool, which
is why is was hashing - you really don't want that because it will only
hash to 0 or 1. So it might have worked, but you get terrible performance
for more than a few items.
If you want hashing support for `iterator_range` it will need to be added
to that library. For an example of how to do that, open boost/array.hpp
and search for 'hash'. It shouldn't be too hard to implement.
-- Ticket URL: <https://svn.boost.org/trac/boost/ticket/7294#comment:3> Boost C++ Libraries <http://www.boost.org/> Boost provides free peer-reviewed portable C++ source libraries.
This archive was generated by hypermail 2.1.7 : 2017-02-16 18:50:10 UTC