Update of /cvsroot/boost/boost/boost/interprocess/allocators
In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv29345/allocators
Modified Files:
adaptive_pool.hpp allocator.hpp cached_adaptive_pool.hpp
cached_node_allocator.hpp
Log Message:
no message
Index: adaptive_pool.hpp
===================================================================
RCS file: /cvsroot/boost/boost/boost/interprocess/allocators/adaptive_pool.hpp,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- adaptive_pool.hpp 12 Jun 2007 17:07:07 -0000 1.3
+++ adaptive_pool.hpp 23 Jun 2007 12:51:56 -0000 1.4
@@ -19,12 +19,9 @@
#include <boost/interprocess/detail/workaround.hpp>
#include <boost/interprocess/interprocess_fwd.hpp>
-#include <boost/utility/addressof.hpp>
-#include <boost/detail/workaround.hpp>
-#include <boost/config.hpp>
#include <boost/assert.hpp>
#include <boost/interprocess/detail/utilities.hpp>
-#include <boost/interprocess/detail/workaround.hpp>
+#include <boost/interprocess/detail/type_traits.hpp>
#include <boost/interprocess/allocators/detail/adaptive_node_pool.hpp>
#include <boost/interprocess/exceptions.hpp>
#include <memory>
@@ -71,10 +68,10 @@
typedef typename detail::
pointer_to_other<void_pointer, const T>::type const_pointer;
typedef T value_type;
- typedef typename workaround::random_it
- <value_type>::reference reference;
- typedef typename workaround::random_it
- <value_type>::const_reference const_reference;
+ typedef typename detail::add_reference
+ <value_type>::type reference;
+ typedef typename detail::add_reference
+ <const value_type>::type const_reference;
typedef std::size_t size_type;
typedef std::ptrdiff_t difference_type;
@@ -140,26 +137,26 @@
(detail::get_pointer(mp_node_pool));
return node_pool->get_segment_manager();
}
-
- /*!Return address of mutable value. Never throws*/
+/*
+ //!Return address of mutable value. Never throws
pointer address(reference value) const
- { return pointer(boost::addressof(value)); }
+ { return pointer(addressof(value)); }
- /*!Return address of nonmutable value. Never throws*/
+ //!Return address of nonmutable value. Never throws
const_pointer address(const_reference value) const
- { return const_pointer(boost::addressof(value)); }
+ { return const_pointer(addressof(value)); }
- /*!Construct object, calling constructor.
- Throws if T(const Convertible &) throws*/
+ //!Construct object, calling constructor.
+ //!Throws if T(const Convertible &) throws
template<class Convertible>
void construct(const pointer &ptr, const Convertible &value)
{ new(detail::get_pointer(ptr)) value_type(value); }
- /*!Destroys object. Throws if object's destructor throws*/
+ //!Destroys object. Throws if object's destructor throws
void destroy(const pointer &ptr)
{ BOOST_ASSERT(ptr != 0); (*ptr).~value_type(); }
-
- /*!Returns the number of elements that could be allocated. Never throws*/
+*/
+ //!Returns the number of elements that could be allocated. Never throws
size_type max_size() const
{ return this->get_segment_manager()->get_size()/sizeof(value_type); }
Index: allocator.hpp
===================================================================
RCS file: /cvsroot/boost/boost/boost/interprocess/allocators/allocator.hpp,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -d -r1.5 -r1.6
--- allocator.hpp 12 Jun 2007 17:07:07 -0000 1.5
+++ allocator.hpp 23 Jun 2007 12:51:56 -0000 1.6
@@ -20,12 +20,11 @@
#include <boost/interprocess/interprocess_fwd.hpp>
#include <boost/interprocess/allocators/allocation_type.hpp>
-#include <boost/utility/addressof.hpp>
#include <boost/interprocess/detail/utilities.hpp>
#include <boost/interprocess/detail/version_type.hpp>
#include <boost/interprocess/exceptions.hpp>
#include <boost/assert.hpp>
-#include <boost/type_traits/alignment_of.hpp>
+#include <boost/interprocess/detail/type_traits.hpp>
#include <memory>
#include <algorithm>
@@ -85,10 +84,10 @@
<cvoid_ptr, T>::type pointer;
typedef typename detail::
pointer_to_other<pointer, const T>::type const_pointer;
- typedef typename workaround::random_it
- <value_type>::reference reference;
- typedef typename workaround::random_it
- <value_type>::const_reference const_reference;
+ typedef typename detail::add_reference
+ <value_type>::type reference;
+ typedef typename detail::add_reference
+ <const value_type>::type const_reference;
typedef std::size_t size_type;
typedef std::ptrdiff_t difference_type;
@@ -104,15 +103,15 @@
/*!Returns the segment manager. Never throws*/
segment_manager* get_segment_manager()const
{ return detail::get_pointer(mp_mngr); }
+/*
+ //!Returns address of mutable object. Never throws
+ pointer address(reference value)
+ { return pointer(addressof(value)); }
- /*!Returns address of mutable object. Never throws*/
- pointer address(reference value) const
- { return pointer(boost::addressof(value)); }
-
- /*!Returns address of non mutable object. Never throws*/
+ //!Returns address of non mutable object. Never throws
const_pointer address(const_reference value) const
- { return const_pointer(boost::addressof(value)); }
-
+ { return const_pointer(addressof(value)); }
+*/
/*!Constructor from the segment manager. Never throws*/
allocator(segment_manager *segment_mngr)
: mp_mngr(segment_mngr) { }
@@ -176,7 +175,7 @@
mp_mngr->allocation_command
(command, l_size, p_size, r_size, detail::get_pointer(reuse),
sizeof(value_type));
received_size = r_size/sizeof(value_type);
- BOOST_ASSERT(0 == ((std::size_t)result.first %
boost::alignment_of<value_type>::value));
+ BOOST_ASSERT(0 == ((std::size_t)result.first %
detail::alignment_of<value_type>::value));
return std::pair<pointer, bool>
(static_cast<value_type*>(result.first), result.second);
}
@@ -224,8 +223,9 @@
template<class T, class SegmentManager>
struct has_trivial_destructor
<boost::interprocess::allocator <T, SegmentManager> >
- : public ::boost::true_type
-{};
+{
+ enum { value = true };
+};
/// @endcond
} //namespace boost {
Index: cached_adaptive_pool.hpp
===================================================================
RCS file:
/cvsroot/boost/boost/boost/interprocess/allocators/cached_adaptive_pool.hpp,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- cached_adaptive_pool.hpp 12 Jun 2007 17:07:07 -0000 1.3
+++ cached_adaptive_pool.hpp 23 Jun 2007 12:51:56 -0000 1.4
@@ -20,7 +20,6 @@
#include <boost/interprocess/interprocess_fwd.hpp>
#include <boost/interprocess/detail/utilities.hpp>
-#include <boost/utility/addressof.hpp>
#include <boost/assert.hpp>
#include <boost/interprocess/allocators/detail/adaptive_node_pool.hpp>
#include <boost/interprocess/detail/workaround.hpp>
@@ -72,10 +71,10 @@
typedef typename detail::
pointer_to_other<void_pointer, const T>::type const_pointer;
typedef T value_type;
- typedef typename workaround::random_it
- <value_type>::reference reference;
- typedef typename workaround::random_it
- <value_type>::const_reference const_reference;
+ typedef typename detail::add_reference
+ <value_type>::type reference;
+ typedef typename detail::add_reference
+ <const value_type>::type const_reference;
typedef std::size_t size_type;
typedef std::ptrdiff_t difference_type;
@@ -162,25 +161,25 @@
/*!Returns the max cached nodes parameter. Never throws*/
std::size_t get_max_cached_nodes() const
{ return m_max_cached_nodes; }
-
- /*!Return address of mutable value. Never throws*/
- pointer address(reference value) const
- { return pointer(boost::addressof(value)); }
+/*
+ //!Return address of mutable value. Never throws
+ pointer address(reference value)
+ { return pointer(addressof(value)); }
- /*!Return address of non mutable value. Never throws*/
+ //!Return address of non mutable value. Never throws
const_pointer address(const_reference value) const
- { return const_pointer(boost::addressof(value)); }
+ { return const_pointer(addressof(value)); }
- /*!Construct object, calling constructor.
- Throws if T(const Convertible &) throws*/
+ //!Construct object, calling constructor.
+ //!Throws if T(const Convertible &) throws
template<class Convertible>
void construct(const pointer &ptr, const Convertible &value)
{ new(detail::get_pointer(ptr)) value_type(value); }
- /*!Destroys object. Throws if object's destructor throws*/
+ //!Destroys object. Throws if object's destructor throws
void destroy(const pointer &ptr)
{ BOOST_ASSERT(ptr != 0); (*ptr).~value_type(); }
-
+*/
/*!Returns the number of elements that could be allocated. Never throws*/
size_type max_size() const
{ return this->get_segment_manager()->get_size()/sizeof(value_type); }
Index: cached_node_allocator.hpp
===================================================================
RCS file:
/cvsroot/boost/boost/boost/interprocess/allocators/cached_node_allocator.hpp,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -d -r1.5 -r1.6
--- cached_node_allocator.hpp 12 Jun 2007 17:07:07 -0000 1.5
+++ cached_node_allocator.hpp 23 Jun 2007 12:51:56 -0000 1.6
@@ -20,7 +20,6 @@
#include <boost/interprocess/interprocess_fwd.hpp>
#include <boost/interprocess/detail/utilities.hpp>
-#include <boost/utility/addressof.hpp>
#include <boost/assert.hpp>
#include <boost/interprocess/allocators/detail/node_pool.hpp>
#include <boost/interprocess/detail/workaround.hpp>
@@ -70,10 +69,10 @@
typedef typename detail::
pointer_to_other<void_pointer, const T>::type const_pointer;
typedef T value_type;
- typedef typename workaround::random_it
- <value_type>::reference reference;
- typedef typename workaround::random_it
- <value_type>::const_reference const_reference;
+ typedef typename detail::add_reference
+ <value_type>::type reference;
+ typedef typename detail::add_reference
+ <const value_type>::type const_reference;
typedef std::size_t size_type;
typedef std::ptrdiff_t difference_type;
@@ -160,26 +159,26 @@
/*!Returns the max cached nodes parameter. Never throws*/
std::size_t get_max_cached_nodes() const
{ return m_max_cached_nodes; }
-
- /*!Return address of mutable value. Never throws*/
+/*
+ //!Return address of mutable value. Never throws
pointer address(reference value) const
- { return pointer(boost::addressof(value)); }
+ { return pointer(addressof(value)); }
- /*!Return address of non mutable value. Never throws*/
+ //!Return address of non mutable value. Never throws
const_pointer address(const_reference value) const
- { return const_pointer(boost::addressof(value)); }
+ { return const_pointer(addressof(value)); }
- /*!Construct object, calling constructor.
- Throws if T(const Convertible &) throws*/
+ //!Construct object, calling constructor.
+ //!Throws if T(const Convertible &) throws
template<class Convertible>
void construct(const pointer &ptr, const Convertible &value)
{ new(detail::get_pointer(ptr)) value_type(value); }
- /*!Destroys object. Throws if object's destructor throws*/
+ //!Destroys object. Throws if object's destructor throws
void destroy(const pointer &ptr)
{ BOOST_ASSERT(ptr != 0); (*ptr).~value_type(); }
-
- /*!Returns the number of elements that could be allocated. Never throws*/
+*/
+ //!Returns the number of elements that could be allocated. Never throws
size_type max_size() const
{ return this->get_segment_manager()->get_size()/sizeof(value_type); }
-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Boost-cvs mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/boost-cvs