|
Boost-Commit : |
Subject: [Boost-commit] svn:boost r83704 - in trunk/boost/geometry/index: . detail detail/rtree/node
From: adam.wulkiewicz_at_[hidden]
Date: 2013-04-01 20:13:52
Author: awulkiew
Date: 2013-04-01 20:13:51 EDT (Mon, 01 Apr 2013)
New Revision: 83704
URL: http://svn.boost.org/trac/boost/changeset/83704
Log:
rtree: added Allocators copy assignments for C++11, warning disabled.
Text files modified:
trunk/boost/geometry/index/detail/config_begin.hpp | 3 +++
trunk/boost/geometry/index/detail/rtree/node/node_d_mem_dynamic.hpp | 12 +++++++++++-
trunk/boost/geometry/index/detail/rtree/node/node_d_mem_static.hpp | 12 +++++++++++-
trunk/boost/geometry/index/detail/rtree/node/node_s_mem_dynamic.hpp | 11 ++++++++++-
trunk/boost/geometry/index/detail/rtree/node/node_s_mem_static.hpp | 11 ++++++++++-
trunk/boost/geometry/index/rtree.hpp | 3 ++-
6 files changed, 47 insertions(+), 5 deletions(-)
Modified: trunk/boost/geometry/index/detail/config_begin.hpp
==============================================================================
--- trunk/boost/geometry/index/detail/config_begin.hpp (original)
+++ trunk/boost/geometry/index/detail/config_begin.hpp 2013-04-01 20:13:51 EDT (Mon, 01 Apr 2013)
@@ -16,6 +16,9 @@
#pragma warning (disable : 4512) // assignment operator could not be generated
#pragma warning (disable : 4127) // conditional expression is constant
+ // temporary?
+ #pragma warning (disable : 4180) // qualifier applied to function type has no meaning
+
#else //BOOST_MSVC
#define BOOST_GEOMETRY_INDEX_DETAIL_USE_PARAM(A)
Modified: trunk/boost/geometry/index/detail/rtree/node/node_d_mem_dynamic.hpp
==============================================================================
--- trunk/boost/geometry/index/detail/rtree/node/node_d_mem_dynamic.hpp (original)
+++ trunk/boost/geometry/index/detail/rtree/node/node_d_mem_dynamic.hpp 2013-04-01 20:13:51 EDT (Mon, 01 Apr 2013)
@@ -188,7 +188,8 @@
, leaf_allocator_type()
{}
- inline explicit allocators(Allocator const& alloc)
+ template <typename Alloc>
+ inline explicit allocators(Alloc const& alloc)
: internal_node_allocator_type(alloc)
, leaf_allocator_type(alloc)
{}
@@ -205,6 +206,15 @@
return *this;
}
+#ifndef BOOST_NO_CXX11_RVALUE_REFERENCES
+ inline allocators & operator=(allocators const& a)
+ {
+ internal_node_allocator() = a.internal_node_allocator();
+ leaf_allocator() = a.leaf_allocator();
+ return *this;
+ }
+#endif
+
void swap(allocators & a)
{
boost::swap(internal_node_allocator(), a.internal_node_allocator());
Modified: trunk/boost/geometry/index/detail/rtree/node/node_d_mem_static.hpp
==============================================================================
--- trunk/boost/geometry/index/detail/rtree/node/node_d_mem_static.hpp (original)
+++ trunk/boost/geometry/index/detail/rtree/node/node_d_mem_static.hpp 2013-04-01 20:13:51 EDT (Mon, 01 Apr 2013)
@@ -137,7 +137,8 @@
, leaf_allocator_type()
{}
- inline explicit allocators(Allocator const& alloc)
+ template <typename Alloc>
+ inline explicit allocators(Alloc const& alloc)
: internal_node_allocator_type(alloc)
, leaf_allocator_type(alloc)
{}
@@ -154,6 +155,15 @@
return *this;
}
+#ifndef BOOST_NO_CXX11_RVALUE_REFERENCES
+ inline allocators & operator=(allocators const& a)
+ {
+ internal_node_allocator() = a.internal_node_allocator();
+ leaf_allocator() = a.leaf_allocator();
+ return *this;
+ }
+#endif
+
void swap(allocators & a)
{
boost::swap(internal_node_allocator(), a.internal_node_allocator());
Modified: trunk/boost/geometry/index/detail/rtree/node/node_s_mem_dynamic.hpp
==============================================================================
--- trunk/boost/geometry/index/detail/rtree/node/node_s_mem_dynamic.hpp (original)
+++ trunk/boost/geometry/index/detail/rtree/node/node_s_mem_dynamic.hpp 2013-04-01 20:13:51 EDT (Mon, 01 Apr 2013)
@@ -115,7 +115,8 @@
: node_allocator_type()
{}
- inline explicit allocators(Allocator const& alloc)
+ template <typename Alloc>
+ inline explicit allocators(Alloc const& alloc)
: node_allocator_type(alloc)
{}
@@ -129,6 +130,14 @@
return *this;
}
+#ifndef BOOST_NO_CXX11_RVALUE_REFERENCES
+ inline allocators & operator=(allocators const& a)
+ {
+ node_allocator() = a.node_allocator();
+ return *this;
+ }
+#endif
+
void swap(allocators & a)
{
boost::swap(node_allocator(), a.node_allocator());
Modified: trunk/boost/geometry/index/detail/rtree/node/node_s_mem_static.hpp
==============================================================================
--- trunk/boost/geometry/index/detail/rtree/node/node_s_mem_static.hpp (original)
+++ trunk/boost/geometry/index/detail/rtree/node/node_s_mem_static.hpp 2013-04-01 20:13:51 EDT (Mon, 01 Apr 2013)
@@ -113,7 +113,8 @@
: node_allocator_type()
{}
- inline explicit allocators(Allocator const& alloc)
+ template <typename Alloc>
+ inline explicit allocators(Alloc const& alloc)
: node_allocator_type(alloc)
{}
@@ -127,6 +128,14 @@
return *this;
}
+#ifndef BOOST_NO_CXX11_RVALUE_REFERENCES
+ inline allocators & operator=(allocators const& a)
+ {
+ node_allocator() = a.node_allocator();
+ return *this;
+ }
+#endif
+
void swap(allocators & a)
{
boost::swap(node_allocator(), a.node_allocator());
Modified: trunk/boost/geometry/index/rtree.hpp
==============================================================================
--- trunk/boost/geometry/index/rtree.hpp (original)
+++ trunk/boost/geometry/index/rtree.hpp 2013-04-01 20:13:51 EDT (Mon, 01 Apr 2013)
@@ -349,7 +349,7 @@
: m_members(src.m_members.indexable_getter(),
src.m_members.equal_to(),
src.m_members.parameters(),
- boost::move(allocator))
+ allocator)
{
if ( src.m_members.allocators() == allocator )
{
@@ -1142,6 +1142,7 @@
{
private:
members_holder(members_holder const&);
+ members_holder & operator=(members_holder const&);
public:
template <typename IndGet, typename ValEq, typename Alloc>
Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk