mirror of
https://github.com/boostorg/move.git
synced 2025-08-01 05:14:27 +02:00
Use BOOST_MAY_ALIAS only for GCC 4.4, as other MSVC, GCC, and Clang don't seem to need it.
This commit is contained in:
@@ -60,7 +60,11 @@
|
|||||||
#define BOOST_MOVE_TO_RV_CAST(RV_TYPE, ARG) reinterpret_cast<RV_TYPE>(ARG)
|
#define BOOST_MOVE_TO_RV_CAST(RV_TYPE, ARG) reinterpret_cast<RV_TYPE>(ARG)
|
||||||
|
|
||||||
//Move emulation rv breaks standard aliasing rules so add workarounds for some compilers
|
//Move emulation rv breaks standard aliasing rules so add workarounds for some compilers
|
||||||
#define BOOST_MOVE_ATTRIBUTE_MAY_ALIAS BOOST_MAY_ALIAS
|
#if defined(BOOST_GCC) && (BOOST_GCC >= 40400) && (BOOST_GCC < 40500)
|
||||||
|
#define BOOST_RV_ATTRIBUTE_MAY_ALIAS BOOST_MAY_ALIAS
|
||||||
|
#else
|
||||||
|
#define BOOST_RV_ATTRIBUTE_MAY_ALIAS BOOST_MAY_ALIAS
|
||||||
|
#endif
|
||||||
|
|
||||||
namespace boost {
|
namespace boost {
|
||||||
|
|
||||||
@@ -70,7 +74,7 @@
|
|||||||
//
|
//
|
||||||
//////////////////////////////////////////////////////////////////////////////
|
//////////////////////////////////////////////////////////////////////////////
|
||||||
template <class T>
|
template <class T>
|
||||||
class BOOST_MOVE_ATTRIBUTE_MAY_ALIAS rv
|
class BOOST_RV_ATTRIBUTE_MAY_ALIAS rv
|
||||||
: public ::boost::move_detail::if_c
|
: public ::boost::move_detail::if_c
|
||||||
< ::boost::move_detail::is_class<T>::value
|
< ::boost::move_detail::is_class<T>::value
|
||||||
, T
|
, T
|
||||||
|
Reference in New Issue
Block a user