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:
Ion Gaztañaga
2018-09-15 00:54:16 +02:00
parent e25607d88e
commit 5e2e0f944e

View File

@ -60,7 +60,11 @@
#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
#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 {
@ -70,7 +74,7 @@
//
//////////////////////////////////////////////////////////////////////////////
template <class T>
class BOOST_MOVE_ATTRIBUTE_MAY_ALIAS rv
class BOOST_RV_ATTRIBUTE_MAY_ALIAS rv
: public ::boost::move_detail::if_c
< ::boost::move_detail::is_class<T>::value
, T