mirror of
https://github.com/boostorg/smart_ptr.git
synced 2025-11-20 17:29:48 +01:00
Code consistency: Use the same style of #if conditional compilation checks in allocate_shared_array.hpp and make_shared_array.hpp.
[SVN r81643]
This commit is contained in:
@@ -122,7 +122,7 @@ namespace boost {
|
||||
return boost::shared_ptr<T>(s1, p1);
|
||||
}
|
||||
#endif
|
||||
#ifndef BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX
|
||||
#if !defined(BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX)
|
||||
template<typename T, typename A>
|
||||
inline typename boost::detail::sp_if_size_array<T>::type
|
||||
allocate_shared(const A& allocator, const T& list) {
|
||||
|
||||
@@ -40,7 +40,6 @@ namespace boost {
|
||||
}
|
||||
}
|
||||
#endif
|
||||
#if !defined(BOOST_NO_CXX11_HDR_INITIALIZER_LIST)
|
||||
void construct_list(T* memory, std::size_t count, const T* list) {
|
||||
for (object = memory; size < count; size++) {
|
||||
void* p1 = object + size;
|
||||
@@ -53,7 +52,6 @@ namespace boost {
|
||||
::new(p1) T(list[size % n]);
|
||||
}
|
||||
}
|
||||
#endif
|
||||
void construct_noinit(T* memory, std::size_t count) {
|
||||
for (object = memory; size < count; size++) {
|
||||
void* p1 = object + size;
|
||||
@@ -98,7 +96,6 @@ namespace boost {
|
||||
}
|
||||
}
|
||||
#endif
|
||||
#if !defined(BOOST_NO_CXX11_HDR_INITIALIZER_LIST)
|
||||
void construct_list(T* memory, const T* list) {
|
||||
object = memory;
|
||||
for (std::size_t i = 0; i < N; i++) {
|
||||
@@ -113,7 +110,6 @@ namespace boost {
|
||||
::new(p1) T(list[i % n]);
|
||||
}
|
||||
}
|
||||
#endif
|
||||
void construct_noinit(T* memory) {
|
||||
object = memory;
|
||||
for (std::size_t i = 0; i < N; i++) {
|
||||
|
||||
@@ -121,7 +121,7 @@ namespace boost {
|
||||
return boost::shared_ptr<T>(s1, p1);
|
||||
}
|
||||
#endif
|
||||
#ifndef BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX
|
||||
#if !defined(BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX)
|
||||
template<typename T>
|
||||
inline typename boost::detail::sp_if_size_array<T>::type
|
||||
make_shared(const T& list) {
|
||||
|
||||
Reference in New Issue
Block a user