[Boost-bugs] [Boost C++ Libraries] #10678: search by a compatible key and default predicates

Subject: [Boost-bugs] [Boost C++ Libraries] #10678: search by a compatible key and default predicates
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2014-10-19 19:47:07


#10678: search by a compatible key and default predicates
---------------------------------+-------------------------
 Reporter: maxim.yegorushkin@… | Owner: joaquin
     Type: Bugs | Status: new
Milestone: To Be Determined | Component: multi_index
  Version: Boost 1.56.0 | Severity: Problem
 Keywords: |
---------------------------------+-------------------------
 Ordered and hashed indexes require predicates for comparing elements,
 which default to std::equal_to<Key> and std::less<Key> respectively.

 At the same time find functions take a compatible key, that does not need
 to be convertible to Key.

 Using std::equal_to<Key> and std::less<Key> breaks find when the
 compatible key is not convertible to Key because these predicates require
 both arguments to be of type Key.

 Something like C++14 std::equal_to<void> and std::less<void> should be
 used as the default predicates.

-- 
Ticket URL: <https://svn.boost.org/trac/boost/ticket/10678>
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:17 UTC