diff options
Diffstat (limited to 'boost/intrusive/avltree.hpp')
-rw-r--r-- | boost/intrusive/avltree.hpp | 28 |
1 files changed, 13 insertions, 15 deletions
diff --git a/boost/intrusive/avltree.hpp b/boost/intrusive/avltree.hpp index d2adf24917..1996d69c68 100644 --- a/boost/intrusive/avltree.hpp +++ b/boost/intrusive/avltree.hpp @@ -12,15 +12,11 @@ #ifndef BOOST_INTRUSIVE_AVLTREE_HPP #define BOOST_INTRUSIVE_AVLTREE_HPP -#if defined(_MSC_VER) -# pragma once -#endif - #include <boost/intrusive/detail/config_begin.hpp> #include <boost/intrusive/intrusive_fwd.hpp> #include <cstddef> -#include <functional> -#include <utility> +#include <boost/intrusive/detail/minimal_less_equal_header.hpp> +#include <boost/intrusive/detail/minimal_pair_header.hpp> #include <boost/static_assert.hpp> #include <boost/intrusive/avl_set_hook.hpp> @@ -35,6 +31,10 @@ #include <boost/intrusive/link_mode.hpp> #include <boost/move/utility_core.hpp> +#if defined(BOOST_HAS_PRAGMA_ONCE) +# pragma once +#endif + namespace boost { namespace intrusive { @@ -86,7 +86,7 @@ class avltree_impl /// @cond typedef bstree_impl< ValueTraits, VoidOrKeyComp, SizeType , ConstantTimeSize, AvlTreeAlgorithms - , HeaderHolder> tree_type; + , HeaderHolder> tree_type; typedef tree_type implementation_defined; /// @endcond @@ -140,12 +140,12 @@ class avltree_impl //! @copydoc ::boost::intrusive::bstree::bstree(bstree &&) avltree_impl(BOOST_RV_REF(avltree_impl) x) - : tree_type(::boost::move(static_cast<tree_type&>(x))) + : tree_type(BOOST_MOVE_BASE(tree_type, x)) {} //! @copydoc ::boost::intrusive::bstree::operator=(bstree &&) avltree_impl& operator=(BOOST_RV_REF(avltree_impl) x) - { return static_cast<avltree_impl&>(tree_type::operator=(::boost::move(static_cast<tree_type&>(x)))); } + { return static_cast<avltree_impl&>(tree_type::operator=(BOOST_MOVE_BASE(tree_type, x))); } #ifdef BOOST_INTRUSIVE_DOXYGEN_INVOKED @@ -307,7 +307,7 @@ class avltree_impl //! @copydoc ::boost::intrusive::bstree::lower_bound(const_reference) iterator lower_bound(const_reference value); - + //! @copydoc ::boost::intrusive::bstree::lower_bound(const KeyType&,KeyValueCompare) template<class KeyType, class KeyValueCompare> iterator lower_bound(const KeyType& key, KeyValueCompare comp); @@ -455,15 +455,13 @@ struct make_avltree typedef typename detail::get_value_traits <T, typename packed_options::proto_value_traits>::type value_traits; - typedef typename detail::get_header_holder_type - < value_traits, typename packed_options::header_holder_type >::type header_holder_type; typedef avltree_impl < value_traits , typename packed_options::compare , typename packed_options::size_type , packed_options::constant_time_size - , header_holder_type + , typename packed_options::header_holder_type > implementation_defined; /// @endcond typedef implementation_defined type; @@ -520,11 +518,11 @@ class avltree {} avltree(BOOST_RV_REF(avltree) x) - : Base(::boost::move(static_cast<Base&>(x))) + : Base(BOOST_MOVE_BASE(Base, x)) {} avltree& operator=(BOOST_RV_REF(avltree) x) - { return static_cast<avltree &>(this->Base::operator=(::boost::move(static_cast<Base&>(x)))); } + { return static_cast<avltree &>(this->Base::operator=(BOOST_MOVE_BASE(Base, x))); } static avltree &container_from_end_iterator(iterator end_iterator) { return static_cast<avltree &>(Base::container_from_end_iterator(end_iterator)); } |