//@endcond
public:
+ typedef Traits traits;
typedef cds::gc::nogc gc; ///< Garbage collector
#ifdef CDS_DOXYGEN_INVOKED
typedef Key key_type ; ///< Key type
protected:
//@cond
- typedef typename base_class::value_type node_type;
- typedef typename maker::cxx_allocator cxx_allocator;
- typedef typename maker::node_deallocator node_deallocator;
- typedef typename maker::intrusive_traits::compare intrusive_key_comparator;
- typedef typename base_class::node_type head_type;
+ typedef typename base_class::value_type node_type;
+ typedef typename maker::cxx_allocator cxx_allocator;
+ typedef typename maker::node_deallocator node_deallocator;
+ typedef typename base_class::predicate_type intrusive_predicate_type;
+ typedef typename base_class::node_type head_type;
//@endcond
protected:
template <typename Q>
iterator find( Q const& key )
{
- return node_to_iterator( find_at( head(), key, intrusive_key_comparator() ) );
+ return node_to_iterator( find_at( head(), key, intrusive_predicate_type() ) );
}
/// Finds the key \p val using \p pred predicate for searching
\p Less functor has the interface like \p std::less.
\p pred must imply the same element order as the comparator used for building the list.
*/
- template <typename Q, typename Less>
- iterator find_with( Q const& key, Less pred )
+ template <typename Q, typename Less, bool Sort = traits::sort>
+ typename std::enable_if<Sort, iterator>::type find_with( Q const& key, Less pred )
{
CDS_UNUSED( pred );
return node_to_iterator( find_at( head(), key, typename maker::template less_wrapper<Less>::type() ) );