#ifndef BOOST_HEAP_MERGE_HPP
#define BOOST_HEAP_MERGE_HPP
+#include <algorithm>
+
#include <boost/concept/assert.hpp>
#include <boost/heap/heap_concepts.hpp>
+#include <boost/type_traits/conditional.hpp>
#include <boost/type_traits/is_same.hpp>
#ifdef BOOST_HAS_PRAGMA_ONCE
}
};
- typedef typename boost::mpl::if_c<Heap1::has_reserve,
+ typedef typename boost::conditional<Heap1::has_reserve,
reserver,
dummy_reserver>::type space_reserver;
struct heap_merge_same
{
static const bool is_mergable = Heap::is_mergable;
- typedef typename boost::mpl::if_c<is_mergable,
+ typedef typename boost::conditional<is_mergable,
heap_merge_same_mergable<Heap>,
heap_merge_emulate<Heap, Heap>
>::type heap_merger;
const bool same_heaps = boost::is_same<Heap1, Heap2>::value;
- typedef typename boost::mpl::if_c<same_heaps,
+ typedef typename boost::conditional<same_heaps,
detail::heap_merge_same<Heap1>,
detail::heap_merge_emulate<Heap1, Heap2>
>::type heap_merger;