|
Boost-Commit : |
Subject: [Boost-commit] svn:boost r81865 - trunk/boost/smart_ptr
From: glenfe_at_[hidden]
Date: 2012-12-11 15:51:06
Author: glenfe
Date: 2012-12-11 15:51:05 EST (Tue, 11 Dec 2012)
New Revision: 81865
URL: http://svn.boost.org/trac/boost/changeset/81865
Log:
Use _internal_get_untyped_deleter in allocate_shared_array and make_shared_array
Text files modified:
trunk/boost/smart_ptr/allocate_shared_array.hpp | 92 ++++++++++++++++++++--------------------
trunk/boost/smart_ptr/make_shared_array.hpp | 90 +++++++++++++++++++-------------------
2 files changed, 91 insertions(+), 91 deletions(-)
Modified: trunk/boost/smart_ptr/allocate_shared_array.hpp
==============================================================================
--- trunk/boost/smart_ptr/allocate_shared_array.hpp (original)
+++ trunk/boost/smart_ptr/allocate_shared_array.hpp 2012-12-11 15:51:05 EST (Tue, 11 Dec 2012)
@@ -1,9 +1,9 @@
/*
- * Copyright (c) 2012 Glen Joseph Fernandes
+ * Copyright (c) 2012 Glen Joseph Fernandes
* glenfe at live dot com
*
- * Distributed under the Boost Software License,
- * Version 1.0. (See accompanying file LICENSE_1_0.txt
+ * Distributed under the Boost Software License,
+ * Version 1.0. (See accompanying file LICENSE_1_0.txt
* or copy at http://boost.org/LICENSE_1_0.txt)
*/
#ifndef BOOST_SMART_PTR_ALLOCATE_SHARED_ARRAY_HPP
@@ -20,7 +20,7 @@
namespace boost {
template<typename T, typename A>
- inline typename boost::detail::sp_if_array<T>::type
+ inline typename boost::detail::sp_if_array<T>::type
allocate_shared(const A& allocator, std::size_t size) {
typedef typename boost::detail::array_inner<T>::type T1;
typedef typename boost::detail::array_base<T1>::type T2;
@@ -30,9 +30,9 @@
boost::detail::allocate_array_helper<A, T2[]> a1(allocator, n1, &p2);
boost::detail::array_deleter<T2[]> d1(n1);
boost::shared_ptr<T> s1(p1, d1, a1);
- boost::detail::array_deleter<T2[]>* d2;
+ typedef boost::detail::array_deleter<T2[]>* D2;
p1 = reinterpret_cast<T1*>(p2);
- d2 = get_deleter<boost::detail::array_deleter<T2[]> >(s1);
+ D2 d2 = static_cast<D2>(s1._internal_get_untyped_deleter());
d2->construct(p2);
return boost::shared_ptr<T>(s1, p1);
}
@@ -48,9 +48,9 @@
boost::detail::allocate_array_helper<A, T2[]> a1(allocator, n1, &p2);
boost::detail::array_deleter<T2[]> d1(n1);
boost::shared_ptr<T> s1(p1, d1, a1);
- boost::detail::array_deleter<T2[]>* d2;
+ typedef boost::detail::array_deleter<T2[]>* D2;
p1 = reinterpret_cast<T1*>(p2);
- d2 = get_deleter<boost::detail::array_deleter<T2[]> >(s1);
+ D2 d2 = static_cast<D2>(s1._internal_get_untyped_deleter());
d2->construct(p2, boost::detail::sp_forward<Args>(args)...);
return boost::shared_ptr<T>(s1, p1);
}
@@ -59,17 +59,17 @@
allocate_shared(const A& allocator, Args&&... args) {
typedef typename boost::detail::array_inner<T>::type T1;
typedef typename boost::detail::array_base<T1>::type T2;
- enum {
- N = boost::detail::array_total<T>::size
+ enum {
+ N = boost::detail::array_total<T>::size
};
T1* p1 = 0;
T2* p2 = 0;
boost::detail::allocate_array_helper<A, T2[N]> a1(allocator, &p2);
boost::detail::array_deleter<T2[N]> d1;
boost::shared_ptr<T> s1(p1, d1, a1);
- boost::detail::array_deleter<T2[N]>* d2;
+ typedef boost::detail::array_deleter<T2[N]>* D2;
p1 = reinterpret_cast<T1*>(p2);
- d2 = get_deleter<boost::detail::array_deleter<T2[N]> >(s1);
+ D2 d2 = static_cast<D2>(s1._internal_get_untyped_deleter());
d2->construct(p2, boost::detail::sp_forward<Args>(args)...);
return boost::shared_ptr<T>(s1, p1);
}
@@ -77,7 +77,7 @@
#if !defined(BOOST_NO_CXX11_HDR_INITIALIZER_LIST)
template<typename T, typename A>
inline typename boost::detail::sp_if_array<T>::type
- allocate_shared(const A& allocator,
+ allocate_shared(const A& allocator,
std::initializer_list<typename boost::detail::array_inner<T>::type> list) {
typedef typename boost::detail::array_inner<T>::type T1;
typedef typename boost::detail::array_base<T1>::type T2;
@@ -89,10 +89,10 @@
boost::detail::allocate_array_helper<A, T2[]> a1(allocator, n1, &p2);
boost::detail::array_deleter<T2[]> d1(n1);
boost::shared_ptr<T> s1(p1, d1, a1);
- boost::detail::array_deleter<T2[]>* d2;
+ typedef boost::detail::array_deleter<T2[]>* D2;
p3 = reinterpret_cast<T3*>(list.begin());
p1 = reinterpret_cast<T1*>(p2);
- d2 = get_deleter<boost::detail::array_deleter<T2[]> >(s1);
+ D2 d2 = static_cast<D2>(s1._internal_get_untyped_deleter());
d2->construct_list(p2, p3);
return boost::shared_ptr<T>(s1, p1);
}
@@ -104,8 +104,8 @@
typedef typename boost::detail::array_inner<T>::type T1;
typedef typename boost::detail::array_base<T1>::type T2;
typedef const T2 T3;
- enum {
- N = boost::detail::array_total<T>::size
+ enum {
+ N = boost::detail::array_total<T>::size
};
T1* p1 = 0;
T2* p2 = 0;
@@ -113,21 +113,21 @@
boost::detail::allocate_array_helper<A, T2[N]> a1(allocator, &p2);
boost::detail::array_deleter<T2[N]> d1;
boost::shared_ptr<T> s1(p1, d1, a1);
- boost::detail::array_deleter<T2[N]>* d2;
+ typedef boost::detail::array_deleter<T2[N]>* D2;
p3 = reinterpret_cast<T3*>(list);
p1 = reinterpret_cast<T1*>(p2);
- d2 = get_deleter<boost::detail::array_deleter<T2[N]> >(s1);
+ D2 d2 = static_cast<D2>(s1._internal_get_untyped_deleter());
d2->construct_list(p2, p3);
return boost::shared_ptr<T>(s1, p1);
}
template<typename T, typename A>
inline typename boost::detail::sp_if_array<T>::type
- allocate_shared(const A& allocator, std::size_t size,
+ allocate_shared(const A& allocator, std::size_t size,
const typename boost::detail::array_inner<T>::type& list) {
typedef typename boost::detail::array_inner<T>::type T1;
typedef typename boost::detail::array_base<T1>::type T2;
typedef const T2 T3;
- enum {
+ enum {
M = boost::detail::array_total<T1>::size
};
T1* p1 = 0;
@@ -137,41 +137,41 @@
boost::detail::allocate_array_helper<A, T2[]> a1(allocator, n1, &p2);
boost::detail::array_deleter<T2[]> d1(n1);
boost::shared_ptr<T> s1(p1, d1, a1);
- boost::detail::array_deleter<T2[]>* d2;
+ typedef boost::detail::array_deleter<T2[]>* D2;
p3 = reinterpret_cast<T3*>(list);
p1 = reinterpret_cast<T1*>(p2);
- d2 = get_deleter<boost::detail::array_deleter<T2[]> >(s1);
+ D2 d2 = static_cast<D2>(s1._internal_get_untyped_deleter());
d2->construct_list<M>(p2, p3);
return boost::shared_ptr<T>(s1, p1);
}
template<typename T, typename A>
inline typename boost::detail::sp_if_size_array<T>::type
- allocate_shared(const A& allocator,
+ allocate_shared(const A& allocator,
const typename boost::detail::array_inner<T>::type& list) {
typedef typename boost::detail::array_inner<T>::type T1;
typedef typename boost::detail::array_base<T1>::type T2;
typedef const T2 T3;
- enum {
- M = boost::detail::array_total<T1>::size,
- N = boost::detail::array_total<T>::size
+ enum {
+ M = boost::detail::array_total<T1>::size,
+ N = boost::detail::array_total<T>::size
};
T1* p1 = 0;
T2* p2 = 0;
- T3* p3 = 0;
+ T3* p3 = 0;
boost::detail::allocate_array_helper<A, T2[N]> a1(allocator, &p2);
boost::detail::array_deleter<T2[N]> d1;
boost::shared_ptr<T> s1(p1, d1, a1);
- boost::detail::array_deleter<T2[N]>* d2;
+ typedef boost::detail::array_deleter<T2[N]>* D2;
p3 = reinterpret_cast<T3*>(list);
p1 = reinterpret_cast<T1*>(p2);
- d2 = get_deleter<boost::detail::array_deleter<T2[N]> >(s1);
+ D2 d2 = static_cast<D2>(s1._internal_get_untyped_deleter());
d2->construct_list<M>(p2, p3);
return boost::shared_ptr<T>(s1, p1);
}
#if defined(BOOST_HAS_RVALUE_REFS)
template<typename T, typename A>
inline typename boost::detail::sp_if_array<T>::type
- allocate_shared(const A& allocator, std::size_t size,
+ allocate_shared(const A& allocator, std::size_t size,
typename boost::detail::array_base<T>::type&& value) {
typedef typename boost::detail::array_inner<T>::type T1;
typedef typename boost::detail::array_base<T1>::type T2;
@@ -181,29 +181,29 @@
boost::detail::allocate_array_helper<A, T2[]> a1(allocator, n1, &p2);
boost::detail::array_deleter<T2[]> d1(n1);
boost::shared_ptr<T> s1(p1, d1, a1);
- boost::detail::array_deleter<T2[]>* d2;
+ typedef boost::detail::array_deleter<T2[]>* D2;
p1 = reinterpret_cast<T1*>(p2);
- d2 = get_deleter<boost::detail::array_deleter<T2[]> >(s1);
+ D2 d2 = static_cast<D2>(s1._internal_get_untyped_deleter());
d2->construct(p2, boost::detail::sp_forward<T2>(value));
return boost::shared_ptr<T>(s1, p1);
}
template<typename T, typename A>
inline typename boost::detail::sp_if_size_array<T>::type
- allocate_shared(const A& allocator,
+ allocate_shared(const A& allocator,
typename boost::detail::array_base<T>::type&& value) {
typedef typename boost::detail::array_inner<T>::type T1;
typedef typename boost::detail::array_base<T1>::type T2;
- enum {
- N = boost::detail::array_total<T>::size
+ enum {
+ N = boost::detail::array_total<T>::size
};
T1* p1 = 0;
T2* p2 = 0;
boost::detail::allocate_array_helper<A, T2[N]> a1(allocator, &p2);
boost::detail::array_deleter<T2[N]> d1;
boost::shared_ptr<T> s1(p1, d1, a1);
- boost::detail::array_deleter<T2[N]>* d2;
+ typedef boost::detail::array_deleter<T2[N]>* D2;
p1 = reinterpret_cast<T1*>(p2);
- d2 = get_deleter<boost::detail::array_deleter<T2[N]> >(s1);
+ D2 d2 = static_cast<D2>(s1._internal_get_untyped_deleter());
d2->construct(p2, boost::detail::sp_forward<T2>(value));
return boost::shared_ptr<T>(s1, p1);
}
@@ -220,9 +220,9 @@
boost::detail::allocate_array_helper<A, T2[]> a1(allocator, n1, &p2);
boost::detail::array_deleter<T2[]> d1(n1);
boost::shared_ptr<T> s1(p1, d1, a1);
- boost::detail::array_deleter<T2[]>* d2;
- p1 = reinterpret_cast<T1*>(p2);
- d2 = get_deleter<boost::detail::array_deleter<T2[]> >(s1);
+ typedef boost::detail::array_deleter<T2[]>* D2;
+ p1 = reinterpret_cast<T1*>(p2);
+ D2 d2 = static_cast<D2>(s1._internal_get_untyped_deleter());
d2->construct_noinit(p2);
return boost::shared_ptr<T>(s1, p1);
}
@@ -231,17 +231,17 @@
allocate_shared_noinit(const A& allocator) {
typedef typename boost::detail::array_inner<T>::type T1;
typedef typename boost::detail::array_base<T1>::type T2;
- enum {
- N = boost::detail::array_total<T>::size
+ enum {
+ N = boost::detail::array_total<T>::size
};
T1* p1 = 0;
T2* p2 = 0;
boost::detail::allocate_array_helper<A, T2[N]> a1(allocator, &p2);
boost::detail::array_deleter<T2[N]> d1;
boost::shared_ptr<T> s1(p1, d1, a1);
- boost::detail::array_deleter<T2[N]>* d2;
- p1 = reinterpret_cast<T1*>(p2);
- d2 = get_deleter<boost::detail::array_deleter<T2[N]> >(s1);
+ typedef boost::detail::array_deleter<T2[N]>* D2;
+ p1 = reinterpret_cast<T1*>(p2);
+ D2 d2 = static_cast<D2>(s1._internal_get_untyped_deleter());
d2->construct_noinit(p2);
return boost::shared_ptr<T>(s1, p1);
}
Modified: trunk/boost/smart_ptr/make_shared_array.hpp
==============================================================================
--- trunk/boost/smart_ptr/make_shared_array.hpp (original)
+++ trunk/boost/smart_ptr/make_shared_array.hpp 2012-12-11 15:51:05 EST (Tue, 11 Dec 2012)
@@ -1,9 +1,9 @@
/*
- * Copyright (c) 2012 Glen Joseph Fernandes
+ * Copyright (c) 2012 Glen Joseph Fernandes
* glenfe at live dot com
*
- * Distributed under the Boost Software License,
- * Version 1.0. (See accompanying file LICENSE_1_0.txt
+ * Distributed under the Boost Software License,
+ * Version 1.0. (See accompanying file LICENSE_1_0.txt
* or copy at http://boost.org/LICENSE_1_0.txt)
*/
#ifndef BOOST_SMART_PTR_MAKE_SHARED_ARRAY_HPP
@@ -30,9 +30,9 @@
boost::detail::make_array_helper<T2[]> a1(n1, &p2);
boost::detail::array_deleter<T2[]> d1(n1);
boost::shared_ptr<T> s1(p1, d1, a1);
- boost::detail::array_deleter<T2[]>* d2;
- p1 = reinterpret_cast<T1*>(p2);
- d2 = get_deleter<boost::detail::array_deleter<T2[]> >(s1);
+ typedef boost::detail::array_deleter<T2[]>* D2;
+ p1 = reinterpret_cast<T1*>(p2);
+ D2 d2 = static_cast<D2>(s1._internal_get_untyped_deleter());
d2->construct(p2);
return boost::shared_ptr<T>(s1, p1);
}
@@ -48,9 +48,9 @@
boost::detail::make_array_helper<T2[]> a1(n1, &p2);
boost::detail::array_deleter<T2[]> d1(n1);
boost::shared_ptr<T> s1(p1, d1, a1);
- boost::detail::array_deleter<T2[]>* d2;
- p1 = reinterpret_cast<T1*>(p2);
- d2 = get_deleter<boost::detail::array_deleter<T2[]> >(s1);
+ typedef boost::detail::array_deleter<T2[]>* D2;
+ p1 = reinterpret_cast<T1*>(p2);
+ D2 d2 = static_cast<D2>(s1._internal_get_untyped_deleter());
d2->construct(p2, boost::detail::sp_forward<Args>(args)...);
return boost::shared_ptr<T>(s1, p1);
}
@@ -59,17 +59,17 @@
make_shared(Args&&... args) {
typedef typename boost::detail::array_inner<T>::type T1;
typedef typename boost::detail::array_base<T1>::type T2;
- enum {
- N = boost::detail::array_total<T>::size
+ enum {
+ N = boost::detail::array_total<T>::size
};
T1* p1 = 0;
T2* p2 = 0;
boost::detail::make_array_helper<T2[N]> a1(&p2);
boost::detail::array_deleter<T2[N]> d1;
boost::shared_ptr<T> s1(p1, d1, a1);
- boost::detail::array_deleter<T2[N]>* d2;
- p1 = reinterpret_cast<T1*>(p2);
- d2 = get_deleter<boost::detail::array_deleter<T2[N]> >(s1);
+ typedef boost::detail::array_deleter<T2[N]>* D2;
+ p1 = reinterpret_cast<T1*>(p2);
+ D2 d2 = static_cast<D2>(s1._internal_get_untyped_deleter());
d2->construct(p2, boost::detail::sp_forward<Args>(args)...);
return boost::shared_ptr<T>(s1, p1);
}
@@ -88,13 +88,13 @@
boost::detail::make_array_helper<T2[]> a1(n1, &p2);
boost::detail::array_deleter<T2[]> d1(n1);
boost::shared_ptr<T> s1(p1, d1, a1);
- boost::detail::array_deleter<T2[]>* d2;
+ typedef boost::detail::array_deleter<T2[]>* D2;
p3 = reinterpret_cast<T3*>(list.begin());
p1 = reinterpret_cast<T1*>(p2);
- d2 = get_deleter<boost::detail::array_deleter<T2[]> >(s1);
+ D2 d2 = static_cast<D2>(s1._internal_get_untyped_deleter());
d2->construct_list(p2, p3);
return boost::shared_ptr<T>(s1, p1);
- }
+ }
#endif
#if !defined(BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX)
template<typename T>
@@ -103,8 +103,8 @@
typedef typename boost::detail::array_inner<T>::type T1;
typedef typename boost::detail::array_base<T1>::type T2;
typedef const T2 T3;
- enum {
- N = boost::detail::array_total<T>::size
+ enum {
+ N = boost::detail::array_total<T>::size
};
T1* p1 = 0;
T2* p2 = 0;
@@ -112,22 +112,22 @@
boost::detail::make_array_helper<T2[N]> a1(&p2);
boost::detail::array_deleter<T2[N]> d1;
boost::shared_ptr<T> s1(p1, d1, a1);
- boost::detail::array_deleter<T2[N]>* d2;
+ typedef boost::detail::array_deleter<T2[N]>* D2;
p3 = reinterpret_cast<T3*>(list);
p1 = reinterpret_cast<T1*>(p2);
- d2 = get_deleter<boost::detail::array_deleter<T2[N]> >(s1);
+ D2 d2 = static_cast<D2>(s1._internal_get_untyped_deleter());
d2->construct_list(p2, p3);
return boost::shared_ptr<T>(s1, p1);
}
template<typename T>
inline typename boost::detail::sp_if_array<T>::type
- make_shared(std::size_t size,
+ make_shared(std::size_t size,
const typename boost::detail::array_inner<T>::type& list) {
typedef typename boost::detail::array_inner<T>::type T1;
typedef typename boost::detail::array_base<T1>::type T2;
typedef const T2 T3;
- enum {
- M = boost::detail::array_total<T1>::size
+ enum {
+ M = boost::detail::array_total<T1>::size
};
T1* p1 = 0;
T2* p2 = 0;
@@ -136,10 +136,10 @@
boost::detail::make_array_helper<T2[]> a1(n1, &p2);
boost::detail::array_deleter<T2[]> d1(n1);
boost::shared_ptr<T> s1(p1, d1, a1);
- boost::detail::array_deleter<T2[]>* d2;
+ typedef boost::detail::array_deleter<T2[]>* D2;
p3 = reinterpret_cast<T3*>(list);
p1 = reinterpret_cast<T1*>(p2);
- d2 = get_deleter<boost::detail::array_deleter<T2[]> >(s1);
+ D2 d2 = static_cast<D2>(s1._internal_get_untyped_deleter());
d2->construct_list<M>(p2, p3);
return boost::shared_ptr<T>(s1, p1);
}
@@ -149,9 +149,9 @@
typedef typename boost::detail::array_inner<T>::type T1;
typedef typename boost::detail::array_base<T1>::type T2;
typedef const T2 T3;
- enum {
+ enum {
M = boost::detail::array_total<T1>::size,
- N = boost::detail::array_total<T>::size
+ N = boost::detail::array_total<T>::size
};
T1* p1 = 0;
T2* p2 = 0;
@@ -159,17 +159,17 @@
boost::detail::make_array_helper<T2[N]> a1(&p2);
boost::detail::array_deleter<T2[N]> d1;
boost::shared_ptr<T> s1(p1, d1, a1);
- boost::detail::array_deleter<T2[N]>* d2;
+ typedef boost::detail::array_deleter<T2[N]>* D2;
p3 = reinterpret_cast<T3*>(list);
p1 = reinterpret_cast<T1*>(p2);
- d2 = get_deleter<boost::detail::array_deleter<T2[N]> >(s1);
+ D2 d2 = static_cast<D2>(s1._internal_get_untyped_deleter());
d2->construct_list<M>(p2, p3);
return boost::shared_ptr<T>(s1, p1);
}
#if defined(BOOST_HAS_RVALUE_REFS)
template<typename T>
inline typename boost::detail::sp_if_array<T>::type
- make_shared(std::size_t size,
+ make_shared(std::size_t size,
typename boost::detail::array_base<T>::type&& value) {
typedef typename boost::detail::array_inner<T>::type T1;
typedef typename boost::detail::array_base<T1>::type T2;
@@ -179,9 +179,9 @@
boost::detail::make_array_helper<T2[]> a1(n1, &p2);
boost::detail::array_deleter<T2[]> d1(n1);
boost::shared_ptr<T> s1(p1, d1, a1);
- boost::detail::array_deleter<T2[]>* d2;
+ typedef boost::detail::array_deleter<T2[]>* D2;
p1 = reinterpret_cast<T1*>(p2);
- d2 = get_deleter<boost::detail::array_deleter<T2[]> >(s1);
+ D2 d2 = static_cast<D2>(s1._internal_get_untyped_deleter());
d2->construct(p2, boost::detail::sp_forward<T2>(value));
return boost::shared_ptr<T>(s1, p1);
}
@@ -190,17 +190,17 @@
make_shared(typename boost::detail::array_base<T>::type&& value) {
typedef typename boost::detail::array_inner<T>::type T1;
typedef typename boost::detail::array_base<T1>::type T2;
- enum {
- N = boost::detail::array_total<T>::size
+ enum {
+ N = boost::detail::array_total<T>::size
};
T1* p1 = 0;
T2* p2 = 0;
boost::detail::make_array_helper<T2[N]> a1(&p2);
boost::detail::array_deleter<T2[N]> d1;
boost::shared_ptr<T> s1(p1, d1, a1);
- boost::detail::array_deleter<T2[N]>* d2;
+ typedef boost::detail::array_deleter<T2[N]>* D2;
p1 = reinterpret_cast<T1*>(p2);
- d2 = get_deleter<boost::detail::array_deleter<T2[N]> >(s1);
+ D2 d2 = static_cast<D2>(s1._internal_get_untyped_deleter());
d2->construct(p2, boost::detail::sp_forward<T2>(value));
return boost::shared_ptr<T>(s1, p1);
}
@@ -217,9 +217,9 @@
boost::detail::make_array_helper<T2[]> a1(n1, &p2);
boost::detail::array_deleter<T2[]> d1(n1);
boost::shared_ptr<T> s1(p1, d1, a1);
- boost::detail::array_deleter<T2[]>* d2;
- p1 = reinterpret_cast<T1*>(p2);
- d2 = get_deleter<boost::detail::array_deleter<T2[]> >(s1);
+ typedef boost::detail::array_deleter<T2[]>* D2;
+ p1 = reinterpret_cast<T1*>(p2);
+ D2 d2 = static_cast<D2>(s1._internal_get_untyped_deleter());
d2->construct_noinit(p2);
return boost::shared_ptr<T>(s1, p1);
}
@@ -228,17 +228,17 @@
make_shared_noinit() {
typedef typename boost::detail::array_inner<T>::type T1;
typedef typename boost::detail::array_base<T1>::type T2;
- enum {
- N = boost::detail::array_total<T>::size
+ enum {
+ N = boost::detail::array_total<T>::size
};
T1* p1 = 0;
T2* p2 = 0;
boost::detail::make_array_helper<T2[N]> a1(&p2);
boost::detail::array_deleter<T2[N]> d1;
boost::shared_ptr<T> s1(p1, d1, a1);
- boost::detail::array_deleter<T2[N]>* d2;
- p1 = reinterpret_cast<T1*>(p2);
- d2 = get_deleter<boost::detail::array_deleter<T2[N]> >(s1);
+ typedef boost::detail::array_deleter<T2[N]>* D2;
+ p1 = reinterpret_cast<T1*>(p2);
+ D2 d2 = static_cast<D2>(s1._internal_get_untyped_deleter());
d2->construct_noinit(p2);
return boost::shared_ptr<T>(s1, p1);
}
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