Make insert from node_handle move only on old GCC

This commit is contained in:
Daniel James
2017-05-19 09:42:56 +01:00
parent 4f5a2dabe9
commit 5b97fbc292
2 changed files with 8 additions and 4 deletions

View File

@ -445,7 +445,8 @@ template <class K, class T, class H, class P, class A> class unordered_map
return table_.move_insert_node_type_with_hint_unique(hint, np); return table_.move_insert_node_type_with_hint_unique(hint, np);
} }
#if defined(BOOST_NO_CXX11_RVALUE_REFERENCES) #if defined(BOOST_NO_CXX11_RVALUE_REFERENCES) || \
(BOOST_COMP_GNUC && BOOST_COMP_GNUC < BOOST_VERSION_NUMBER(4, 6, 0))
private: private:
// Note: Use r-value node_type to insert. // Note: Use r-value node_type to insert.
insert_return_type insert(node_type&); insert_return_type insert(node_type&);
@ -1239,7 +1240,8 @@ template <class K, class T, class H, class P, class A> class unordered_multimap
return table_.move_insert_node_type_with_hint_equiv(hint, np); return table_.move_insert_node_type_with_hint_equiv(hint, np);
} }
#if defined(BOOST_NO_CXX11_RVALUE_REFERENCES) #if defined(BOOST_NO_CXX11_RVALUE_REFERENCES) || \
(BOOST_COMP_GNUC && BOOST_COMP_GNUC < BOOST_VERSION_NUMBER(4, 6, 0))
private: private:
// Note: Use r-value node_type to insert. // Note: Use r-value node_type to insert.
iterator insert(node_type&); iterator insert(node_type&);

View File

@ -425,7 +425,8 @@ template <class T, class H, class P, class A> class unordered_set
return table_.move_insert_node_type_with_hint_unique(hint, np); return table_.move_insert_node_type_with_hint_unique(hint, np);
} }
#if defined(BOOST_NO_CXX11_RVALUE_REFERENCES) #if defined(BOOST_NO_CXX11_RVALUE_REFERENCES) || \
(BOOST_COMP_GNUC && BOOST_COMP_GNUC < BOOST_VERSION_NUMBER(4, 6, 0))
private: private:
// Note: Use r-value node_type to insert. // Note: Use r-value node_type to insert.
insert_return_type insert(node_type&); insert_return_type insert(node_type&);
@ -927,7 +928,8 @@ template <class T, class H, class P, class A> class unordered_multiset
return table_.move_insert_node_type_with_hint_equiv(hint, np); return table_.move_insert_node_type_with_hint_equiv(hint, np);
} }
#if defined(BOOST_NO_CXX11_RVALUE_REFERENCES) #if defined(BOOST_NO_CXX11_RVALUE_REFERENCES) || \
(BOOST_COMP_GNUC && BOOST_COMP_GNUC < BOOST_VERSION_NUMBER(4, 6, 0))
private: private:
// Note: Use r-value node_type to insert. // Note: Use r-value node_type to insert.
iterator insert(node_type&); iterator insert(node_type&);