[atomic] errors since the introduction of constexpr noexcept.
Hi, There are some errors since the introduction of constexpr noexcept. Could you apply this patch? Best, Vicente svn diff boost/atomic Index: boost/atomic/detail/cas64strong.hpp =================================================================== --- boost/atomic/detail/cas64strong.hpp (revision 82919) +++ boost/atomic/detail/cas64strong.hpp (working copy) @@ -13,6 +13,7 @@ // atomic, so they are funnelled through cmpxchg as well. #include <cstddef> +#include <boost/config.hpp> #include <boost/cstdint.hpp> #include <boost/memory_order.hpp> #include <boost/atomic/detail/config.hpp> @@ -34,7 +35,8 @@ typedef T value_type; typedef T difference_type; public: - BOOST_CONSTEXPR base_atomic(atomic_type v) BOOST_NOEXCEPT: v_(v) {} + int xxx; + BOOST_CONSTEXPR base_atomic(value_type v) BOOST_NOEXCEPT: v_(v) {} base_atomic(void) {} void @@ -158,7 +160,7 @@ typedef void * value_type; typedef ptrdiff_t difference_type; public: - BOOST_CONSTEXPR base_atomic(atomic_type v) BOOST_NOEXCEPT: v_(v) {} + BOOST_CONSTEXPR base_atomic(value_type v) BOOST_NOEXCEPT: v_(v) {} base_atomic(void) {} void @@ -253,7 +255,7 @@ typedef T * value_type; typedef ptrdiff_t difference_type; public: - BOOST_CONSTEXPR base_atomic(atomic_type v) BOOST_NOEXCEPT: v_(v) {} + BOOST_CONSTEXPR base_atomic(value_type v) BOOST_NOEXCEPT: v_(v) {} base_atomic(void) {} void Index: boost/atomic/detail/gcc-x86.hpp =================================================================== --- boost/atomic/detail/gcc-x86.hpp (revision 82919) +++ boost/atomic/detail/gcc-x86.hpp (working copy) @@ -1621,7 +1621,7 @@ template<typename T> inline T -platform_load64(const volatile BOOST_NOEXCEPT T * ptr) +platform_load64(const volatile T * ptr) BOOST_NOEXCEPT { T expected = *ptr; for (; !platform_cmpxchg64_strong(expected, expected, const_cast<volatile T*>(ptr));)
Le 17/02/13 13:25, Tim Blechmann a écrit :
> hi vicente,
>
>> There are some errors since the introduction of constexpr noexcept.
>> Could you apply this patch?
> thanks for the patch! please commit yourself, except for this line in
> cas64strong.hpp:
> + int xxx;
>
>
yes, of course.
There are two more files that should need to be patched. Not tested
Should I commit them also?
svn diff boost/atomic/detail/cas32strong.hpp
boost/atomic/detail/cas32weak.hpp
Index: boost/atomic/detail/cas32strong.hpp
===================================================================
--- boost/atomic/detail/cas32strong.hpp (revision 82919)
+++ boost/atomic/detail/cas32strong.hpp (working copy)
@@ -35,7 +35,7 @@
typedef T difference_type;
typedef uint32_t storage_type;
public:
- BOOST_CONSTEXPR base_atomic(atomic_type v) BOOST_NOEXCEPT: v_(v) {}
+ BOOST_CONSTEXPR base_atomic(value_type v) BOOST_NOEXCEPT: v_(v) {}
base_atomic(void) {}
void
@@ -162,7 +162,7 @@
typedef T difference_type;
typedef uint32_t storage_type;
public:
- BOOST_CONSTEXPR base_atomic(atomic_type v) BOOST_NOEXCEPT: v_(v) {}
+ BOOST_CONSTEXPR base_atomic(value_type v) BOOST_NOEXCEPT: v_(v) {}
base_atomic(void) {}
void
@@ -288,7 +288,7 @@
typedef T value_type;
typedef T difference_type;
public:
- BOOST_CONSTEXPR base_atomic(atomic_type v) BOOST_NOEXCEPT: v_(v) {}
+ BOOST_CONSTEXPR base_atomic(value_type v) BOOST_NOEXCEPT: v_(v) {}
base_atomic(void) {}
void
@@ -412,7 +412,7 @@
typedef void * value_type;
typedef ptrdiff_t difference_type;
public:
- BOOST_CONSTEXPR base_atomic(atomic_type v) BOOST_NOEXCEPT: v_(v) {}
+ BOOST_CONSTEXPR base_atomic(value_type v) BOOST_NOEXCEPT: v_(v) {}
base_atomic(void) {}
void
@@ -507,7 +507,7 @@
typedef T * value_type;
typedef ptrdiff_t difference_type;
public:
- BOOST_CONSTEXPR base_atomic(atomic_type v) BOOST_NOEXCEPT: v_(v) {}
+ BOOST_CONSTEXPR base_atomic(value_type v) BOOST_NOEXCEPT: v_(v) {}
base_atomic(void) {}
void
Index: boost/atomic/detail/cas32weak.hpp
===================================================================
--- boost/atomic/detail/cas32weak.hpp (revision 82919)
+++ boost/atomic/detail/cas32weak.hpp (working copy)
@@ -167,7 +167,7 @@
typedef T difference_type;
typedef uint32_t storage_type;
public:
- BOOST_CONSTEXPR base_atomic(atomic_type v) BOOST_NOEXCEPT: v_(v) {}
+ BOOST_CONSTEXPR base_atomic(value_type v) BOOST_NOEXCEPT: v_(v) {}
base_atomic(void) {}
void
@@ -301,7 +301,7 @@
typedef T value_type;
typedef T difference_type;
public:
- BOOST_CONSTEXPR base_atomic(atomic_type v) BOOST_NOEXCEPT: v_(v) {}
+ BOOST_CONSTEXPR base_atomic(value_type v) BOOST_NOEXCEPT: v_(v) {}
base_atomic(void) {}
void
@@ -433,7 +433,7 @@
typedef void * value_type;
typedef ptrdiff_t difference_type;
public:
- BOOST_CONSTEXPR base_atomic(atomic_type v) BOOST_NOEXCEPT: v_(v) {}
+ BOOST_CONSTEXPR base_atomic(value_type v) BOOST_NOEXCEPT: v_(v) {}
base_atomic(void) {}
void
@@ -518,7 +518,7 @@
typedef T * value_type;
typedef ptrdiff_t difference_type;
public:
- BOOST_CONSTEXPR base_atomic(atomic_type v) BOOST_NOEXCEPT: v_(v) {}
+ BOOST_CONSTEXPR base_atomic(value_type v) BOOST_NOEXCEPT: v_(v) {}
base_atomic(void) {}
void
participants (2)
-
Tim Blechmann -
Vicente J. Botet Escriba