1 /* Copyright 2003-2015 Joaquin M Lopez Munoz.
2 * Distributed under the Boost Software License, Version 1.0.
3 * (See accompanying file LICENSE_1_0.txt or copy at
4 * http://www.boost.org/LICENSE_1_0.txt)
6 * See http://www.boost.org/libs/multi_index for library home page.
9 #ifndef BOOST_MULTI_INDEX_DETAIL_VALUE_COMPARE_HPP
10 #define BOOST_MULTI_INDEX_DETAIL_VALUE_COMPARE_HPP
16 #include <boost/config.hpp> /* keep it first to prevent nasty warns in MSVC */
17 #include <boost/call_traits.hpp>
21 namespace multi_index{
25 template<typename Value,typename KeyFromValue,typename Compare>
26 struct value_comparison
28 typedef Value first_argument_type;
29 typedef Value second_argument_type;
30 typedef bool result_type;
33 const KeyFromValue& key_=KeyFromValue(),const Compare& comp_=Compare()):
39 typename call_traits<Value>::param_type x,
40 typename call_traits<Value>::param_type y)const
42 return comp(key(x),key(y));
50 } /* namespace multi_index::detail */
52 } /* namespace multi_index */
54 } /* namespace boost */