Propagate the potentially "void" allocator to the underlying vector to shorten symbol name lengths.

This commit is contained in:
Ion Gaztañaga
2024-09-11 21:22:54 +02:00
parent 49440c3525
commit 4cc14fc42c

View File

@@ -469,21 +469,21 @@ class flat_tree_value_compare
/////////////////////////////////////// ///////////////////////////////////////
// //
// select_container_type // select_flat_tree_container_type
// //
/////////////////////////////////////// ///////////////////////////////////////
template < class Value, class AllocatorOrContainer template < class Value, class AllocatorOrContainer
, bool = boost::container::dtl::is_container<AllocatorOrContainer>::value , bool = boost::container::dtl::is_container<AllocatorOrContainer>::value
> >
struct select_container_type struct select_flat_tree_container_type
{ {
typedef AllocatorOrContainer type; typedef AllocatorOrContainer type;
}; };
template <class Value, class AllocatorOrContainer> template <class Value, class AllocatorOrVoid>
struct select_container_type<Value, AllocatorOrContainer, false> struct select_flat_tree_container_type<Value, AllocatorOrVoid, false>
{ {
typedef boost::container::vector<Value, typename real_allocator<Value, AllocatorOrContainer>::type> type; typedef boost::container::vector<Value, AllocatorOrVoid> type;
}; };
@@ -497,7 +497,7 @@ template <class Value, class KeyOfValue,
class flat_tree class flat_tree
{ {
public: public:
typedef typename select_container_type<Value, AllocatorOrContainer>::type container_type; typedef typename select_flat_tree_container_type<Value, AllocatorOrContainer>::type container_type;
typedef container_type sequence_type; //For backwards compatibility typedef container_type sequence_type; //For backwards compatibility
private: private: