diff --git a/include/boost/intrusive/bstree.hpp b/include/boost/intrusive/bstree.hpp index 1eeab55..ac67e86 100644 --- a/include/boost/intrusive/bstree.hpp +++ b/include/boost/intrusive/bstree.hpp @@ -255,7 +255,8 @@ struct get_key_of_value template struct bst_key_types { - typedef typename pointer_element::type value_type; + typedef typename + boost::movelib::pointer_element::type value_type; typedef typename get_key_of_value < VoidOrKeyOfValue, value_type>::type key_of_value; typedef typename key_of_value::type key_type; diff --git a/include/boost/intrusive/detail/default_header_holder.hpp b/include/boost/intrusive/detail/default_header_holder.hpp index 288f8a0..ba561b5 100644 --- a/include/boost/intrusive/detail/default_header_holder.hpp +++ b/include/boost/intrusive/detail/default_header_holder.hpp @@ -23,7 +23,7 @@ #include #include -#include +#include namespace boost { namespace intrusive { @@ -48,7 +48,7 @@ struct default_header_holder : public NodeTraits::node // (unsafe) downcast used to implement container-from-iterator BOOST_INTRUSIVE_FORCEINLINE static default_header_holder* get_holder(const node_ptr &p) - { return static_cast< default_header_holder* >(boost::intrusive::detail::to_raw_pointer(p)); } + { return static_cast< default_header_holder* >(boost::movelib::to_raw_pointer(p)); } }; // type function producing the header node holder diff --git a/include/boost/intrusive/detail/hashtable_node.hpp b/include/boost/intrusive/detail/hashtable_node.hpp index 8f8718e..d3b11d1 100644 --- a/include/boost/intrusive/detail/hashtable_node.hpp +++ b/include/boost/intrusive/detail/hashtable_node.hpp @@ -246,7 +246,7 @@ class hashtable_iterator void increment() { const bucket_traits &rbuck_traits = this->priv_bucket_traits(); - bucket_type* const buckets = boost::intrusive::detail::to_raw_pointer(rbuck_traits.bucket_begin()); + bucket_type* const buckets = boost::movelib::to_raw_pointer(rbuck_traits.bucket_begin()); const size_type buckets_len = rbuck_traits.bucket_count(); ++slist_it_; diff --git a/include/boost/intrusive/detail/hook_traits.hpp b/include/boost/intrusive/detail/hook_traits.hpp index 2a16061..7a6f206 100644 --- a/include/boost/intrusive/detail/hook_traits.hpp +++ b/include/boost/intrusive/detail/hook_traits.hpp @@ -26,7 +26,7 @@ #include #include #include -#include +#include #include namespace boost { @@ -128,14 +128,14 @@ struct mhtraits { return pointer_traits::pointer_to (*detail::parent_from_member - (static_cast(boost::intrusive::detail::to_raw_pointer(n)), P)); + (static_cast(boost::movelib::to_raw_pointer(n)), P)); } BOOST_INTRUSIVE_FORCEINLINE static const_pointer to_value_ptr(const const_node_ptr & n) { return pointer_traits::pointer_to (*detail::parent_from_member - (static_cast(boost::intrusive::detail::to_raw_pointer(n)), P)); + (static_cast(boost::movelib::to_raw_pointer(n)), P)); } }; @@ -161,10 +161,10 @@ struct fhtraits static const link_mode_type link_mode = hook_type::hooktags::link_mode; static node_ptr to_node_ptr(reference value) - { return static_cast(boost::intrusive::detail::to_raw_pointer(Functor::to_hook_ptr(value))); } + { return static_cast(boost::movelib::to_raw_pointer(Functor::to_hook_ptr(value))); } static const_node_ptr to_node_ptr(const_reference value) - { return static_cast(boost::intrusive::detail::to_raw_pointer(Functor::to_hook_ptr(value))); } + { return static_cast(boost::movelib::to_raw_pointer(Functor::to_hook_ptr(value))); } static pointer to_value_ptr(const node_ptr & n) { return Functor::to_value_ptr(to_hook_ptr(n)); } diff --git a/include/boost/intrusive/detail/node_to_value.hpp b/include/boost/intrusive/detail/node_to_value.hpp index 5af3347..218e78e 100644 --- a/include/boost/intrusive/detail/node_to_value.hpp +++ b/include/boost/intrusive/detail/node_to_value.hpp @@ -59,7 +59,7 @@ struct constptr {} const void *get_ptr() const - { return boost::intrusive::detail::to_raw_pointer(const_void_ptr_); } + { return boost::movelib::to_raw_pointer(const_void_ptr_); } ConstVoidPtr const_void_ptr_; }; diff --git a/include/boost/intrusive/detail/pointer_element.hpp b/include/boost/intrusive/detail/pointer_element.hpp deleted file mode 100644 index 235ecf4..0000000 --- a/include/boost/intrusive/detail/pointer_element.hpp +++ /dev/null @@ -1,42 +0,0 @@ -////////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2014-2014. Distributed under the Boost -// Software License, Version 1.0. (See accompanying file -// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/intrusive for documentation. -// -////////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTRUSIVE_DETAIL_POINTER_ELEMENT_HPP -#define BOOST_INTRUSIVE_DETAIL_POINTER_ELEMENT_HPP - -#ifndef BOOST_CONFIG_HPP -# include -#endif - -#if defined(BOOST_HAS_PRAGMA_ONCE) -# pragma once -#endif - -#ifndef BOOST_INTRUSIVE_DETAIL_WORKAROUND_HPP -#include -#endif //BOOST_INTRUSIVE_DETAIL_WORKAROUND_HPP - -#include - -namespace boost { -namespace intrusive { - -using ::boost::movelib::pointer_element; - -namespace detail { - -using ::boost::movelib::detail::first_param; - -} - -} //namespace intrusive { -} //namespace boost { - -#endif // defined(BOOST_INTRUSIVE_DETAIL_POINTER_ELEMENT_HPP) diff --git a/include/boost/intrusive/detail/to_raw_pointer.hpp b/include/boost/intrusive/detail/to_raw_pointer.hpp deleted file mode 100644 index 1b78750..0000000 --- a/include/boost/intrusive/detail/to_raw_pointer.hpp +++ /dev/null @@ -1,40 +0,0 @@ -///////////////////////////////////////////////////////////////////////////// -// -// (C) Copyright Ion Gaztanaga 2014-2014 -// -// Distributed under the Boost Software License, Version 1.0. -// (See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) -// -// See http://www.boost.org/libs/intrusive for documentation. -// -///////////////////////////////////////////////////////////////////////////// - -#ifndef BOOST_INTRUSIVE_DETAIL_TO_RAW_POINTER_HPP -#define BOOST_INTRUSIVE_DETAIL_TO_RAW_POINTER_HPP - -#ifndef BOOST_CONFIG_HPP -# include -#endif - -#if defined(BOOST_HAS_PRAGMA_ONCE) -# pragma once -#endif - -#include -#include -#include - -namespace boost { -namespace intrusive { -namespace detail { - -using ::boost::movelib::to_raw_pointer; - -} //namespace detail -} //namespace intrusive -} //namespace boost - -#include - -#endif //BOOST_INTRUSIVE_DETAIL_UTILITIES_HPP diff --git a/include/boost/intrusive/detail/tree_value_compare.hpp b/include/boost/intrusive/detail/tree_value_compare.hpp index c8f596f..f6dd01d 100644 --- a/include/boost/intrusive/detail/tree_value_compare.hpp +++ b/include/boost/intrusive/detail/tree_value_compare.hpp @@ -37,7 +37,8 @@ struct disable_if_smartref_to || detail::is_same ::type>::type> + < ValuePtr + , const typename boost::movelib::pointer_element::type>::type> ::reference>::value > {}; @@ -45,11 +46,13 @@ struct disable_if_smartref_to //This function object takes a KeyCompare function object //and compares values that contains keys using KeyOfValue template< class ValuePtr, class KeyCompare, class KeyOfValue - , bool = boost::intrusive::detail::is_same::type, typename KeyOfValue::type>::value > + , bool = boost::intrusive::detail::is_same + ::type, typename KeyOfValue::type>::value > struct tree_value_compare : public boost::intrusive::detail::ebo_functor_holder { - typedef typename pointer_element::type value_type; + typedef typename + boost::movelib::pointer_element::type value_type; typedef KeyCompare key_compare; typedef KeyOfValue key_of_value; typedef typename KeyOfValue::type key_type; @@ -114,7 +117,8 @@ template struct tree_value_compare : public boost::intrusive::detail::ebo_functor_holder { - typedef typename pointer_element::type value_type; + typedef typename + boost::movelib::pointer_element::type value_type; typedef KeyCompare key_compare; typedef KeyOfValue key_of_value; typedef typename KeyOfValue::type key_type; diff --git a/include/boost/intrusive/hashtable.hpp b/include/boost/intrusive/hashtable.hpp index 5f3145c..bae9d52 100644 --- a/include/boost/intrusive/hashtable.hpp +++ b/include/boost/intrusive/hashtable.hpp @@ -1910,7 +1910,7 @@ class hashtable_impl } else{ size_type bucket_cnt = this->bucket_count(); - const bucket_type *b = boost::intrusive::detail::to_raw_pointer(this->priv_bucket_pointer()); + const bucket_type *b = boost::movelib::to_raw_pointer(this->priv_bucket_pointer()); for (size_type n = 0; n < bucket_cnt; ++n, ++b){ if(!b->empty()){ return false; @@ -1933,7 +1933,7 @@ class hashtable_impl else{ size_type len = 0; size_type bucket_cnt = this->bucket_count(); - const bucket_type *b = boost::intrusive::detail::to_raw_pointer(this->priv_bucket_pointer()); + const bucket_type *b = boost::movelib::to_raw_pointer(this->priv_bucket_pointer()); for (size_type n = 0; n < bucket_cnt; ++n, ++b){ len += b->size(); } diff --git a/include/boost/intrusive/member_value_traits.hpp b/include/boost/intrusive/member_value_traits.hpp index 4efe79e..0ab7ffb 100644 --- a/include/boost/intrusive/member_value_traits.hpp +++ b/include/boost/intrusive/member_value_traits.hpp @@ -18,7 +18,7 @@ #include #include -#include +#include #include #if defined(BOOST_HAS_PRAGMA_ONCE) @@ -66,13 +66,13 @@ struct member_value_traits BOOST_INTRUSIVE_FORCEINLINE static pointer to_value_ptr(const node_ptr &n) { return pointer_traits::pointer_to(*detail::parent_from_member - (boost::intrusive::detail::to_raw_pointer(n), PtrToMember)); + (boost::movelib::to_raw_pointer(n), PtrToMember)); } BOOST_INTRUSIVE_FORCEINLINE static const_pointer to_value_ptr(const const_node_ptr &n) { return pointer_traits::pointer_to(*detail::parent_from_member - (boost::intrusive::detail::to_raw_pointer(n), PtrToMember)); + (boost::movelib::to_raw_pointer(n), PtrToMember)); } }; diff --git a/include/boost/intrusive/pointer_traits.hpp b/include/boost/intrusive/pointer_traits.hpp index 5baf5e8..4216c7e 100644 --- a/include/boost/intrusive/pointer_traits.hpp +++ b/include/boost/intrusive/pointer_traits.hpp @@ -20,7 +20,7 @@ #include #include #include -#include +#include #include #include @@ -97,7 +97,7 @@ struct pointer_traits // typedef BOOST_INTRUSIVE_OBTAIN_TYPE_WITH_EVAL_DEFAULT ( boost::intrusive::detail::, Ptr, element_type - , boost::intrusive::detail::first_param) element_type; + , boost::movelib::detail::first_param) element_type; // typedef BOOST_INTRUSIVE_OBTAIN_TYPE_WITH_DEFAULT (boost::intrusive::detail::, Ptr, difference_type, std::ptrdiff_t) difference_type; diff --git a/proj/vc7ide/_intrusivelib/_intrusivelib.vcproj b/proj/vc7ide/_intrusivelib/_intrusivelib.vcproj index 03bbd15..de144c3 100644 --- a/proj/vc7ide/_intrusivelib/_intrusivelib.vcproj +++ b/proj/vc7ide/_intrusivelib/_intrusivelib.vcproj @@ -337,9 +337,6 @@ - - @@ -361,9 +358,6 @@ - - diff --git a/test/common_functors.hpp b/test/common_functors.hpp index 4e6ac8d..b84a84a 100644 --- a/test/common_functors.hpp +++ b/test/common_functors.hpp @@ -16,6 +16,7 @@ #include #include #include +#include namespace boost { namespace intrusive { @@ -30,7 +31,7 @@ class delete_disposer { typedef typename boost::intrusive::iterator_traits::value_type value_type; BOOST_STATIC_ASSERT(( detail::is_same::value )); - delete boost::intrusive::detail::to_raw_pointer(p); + delete boost::movelib::to_raw_pointer(p); } }; diff --git a/test/nonhook_node.hpp b/test/nonhook_node.hpp index 8e3d6d3..e2c666e 100644 --- a/test/nonhook_node.hpp +++ b/test/nonhook_node.hpp @@ -15,11 +15,12 @@ #include #include -#include -#include -#include #include +#include + +#include +#include namespace boost{ namespace intrusive{ @@ -103,14 +104,14 @@ struct nonhook_node_member_value_traits { return pointer_traits::pointer_to (*detail::parent_from_member - (static_cast(boost::intrusive::detail::to_raw_pointer(n)), P)); + (static_cast(boost::movelib::to_raw_pointer(n)), P)); } static const_pointer to_value_ptr(const_node_ptr n) { return pointer_traits::pointer_to (*detail::parent_from_member - (static_cast(boost::intrusive::detail::to_raw_pointer(n)), P)); + (static_cast(boost::movelib::to_raw_pointer(n)), P)); } };