diff --git a/include/boost/unordered/unordered_map.hpp b/include/boost/unordered/unordered_map.hpp index 41419b9d..985e9142 100644 --- a/include/boost/unordered/unordered_map.hpp +++ b/include/boost/unordered/unordered_map.hpp @@ -581,6 +581,33 @@ template class unordered_map return this->emplace_hint(hint, boost::forward(obj)); } + template void insert(InputIt, InputIt); + +#if !defined(BOOST_NO_CXX11_HDR_INITIALIZER_LIST) + void insert(std::initializer_list); +#endif + + insert_return_type insert(BOOST_RV_REF(node_type) np) + { + insert_return_type result; + table_.move_insert_node_type(np, result); + return boost::move(result); + } + + iterator insert(const_iterator hint, BOOST_RV_REF(node_type) np) + { + return table_.move_insert_node_type_with_hint(hint, np); + } + +#if defined(BOOST_NO_CXX11_RVALUE_REFERENCES) + private: + // Note: Use r-value node_type to insert. + insert_return_type insert(node_type&); + iterator insert(const_iterator, node_type& np); + + public: +#endif + template std::pair insert_or_assign( key_type const& k, BOOST_FWD_REF(M) obj) @@ -612,33 +639,6 @@ template class unordered_map .first; } - template void insert(InputIt, InputIt); - -#if !defined(BOOST_NO_CXX11_HDR_INITIALIZER_LIST) - void insert(std::initializer_list); -#endif - - insert_return_type insert(BOOST_RV_REF(node_type) np) - { - insert_return_type result; - table_.move_insert_node_type(np, result); - return boost::move(result); - } - - iterator insert(const_iterator hint, BOOST_RV_REF(node_type) np) - { - return table_.move_insert_node_type_with_hint(hint, np); - } - -#if defined(BOOST_NO_CXX11_RVALUE_REFERENCES) - private: - // Note: Use r-value node_type to insert. - insert_return_type insert(node_type&); - iterator insert(const_iterator, node_type& np); - - public: -#endif - iterator erase(const_iterator); size_type erase(const key_type&); iterator erase(const_iterator, const_iterator);