Fixes Trac #11802 ("Incorrect ordering after using insert() with ordered_range_t on a flat_multiset with a non-default sort order")

This commit is contained in:
Ion Gaztañaga
2016-08-12 00:43:16 +02:00
parent b13ba0f911
commit d5adae2eda
2 changed files with 3 additions and 2 deletions

View File

@@ -1218,6 +1218,7 @@ use [*Boost.Container]? There are several reasons for that:
* Fixed bugs:
* [@https://svn.boost.org/trac/boost/ticket/9481 Trac #9481: ['"Minor comment typo in Boost.Container"]].
* [@https://svn.boost.org/trac/boost/ticket/11170 Trac #11170: ['"Doc slip for index_of"]].
* [@https://svn.boost.org/trac/boost/ticket/11802 Trac #11802: ['"Incorrect ordering after using insert() with ordered_range_t on a flat_multiset with a non-default sort order"]].
* [@https://svn.boost.org/trac/boost/ticket/12177 Trac #12177: ['"vector::priv_merge uses unqualified uintptr_t"]].
* [@https://svn.boost.org/trac/boost/ticket/12183 Trac #12183: ['"GCC 6.1 thinks boost::container::string violates strict aliasing"]].
* [@https://svn.boost.org/trac/boost/ticket/12256 Trac #12256: ['"set<std::pair<int,int>>::insert cause compilation error in debug configuration in Visual Studio 2012"]].

View File

@@ -483,7 +483,7 @@ class flat_tree
>::type * = 0
#endif
)
{ this->m_data.m_vect.merge(first, last); }
{ this->m_data.m_vect.merge(first, last, static_cast<const value_compare &>(this->m_data)); }
template <class InIt>
void insert_unique(ordered_unique_range_t, InIt first, InIt last
@@ -512,7 +512,7 @@ class flat_tree
>::type * = 0
#endif
)
{ this->m_data.m_vect.merge_unique(first, last, value_compare()); }
{ this->m_data.m_vect.merge_unique(first, last, static_cast<const value_compare &>(this->m_data)); }
#if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES)