diff --git a/CMakeLists.txt b/CMakeLists.txt index 976738b..75ea336 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -17,7 +17,6 @@ target_link_libraries(boost_optional Boost::assert Boost::config Boost::core - Boost::move Boost::static_assert Boost::throw_exception Boost::type_traits diff --git a/build.jam b/build.jam index 5c8089b..6f1fcf6 100644 --- a/build.jam +++ b/build.jam @@ -9,7 +9,6 @@ constant boost_dependencies : /boost/assert//boost_assert /boost/config//boost_config /boost/core//boost_core - /boost/move//boost_move /boost/static_assert//boost_static_assert /boost/throw_exception//boost_throw_exception /boost/type_traits//boost_type_traits ; diff --git a/doc/90_dependencies.qbk b/doc/90_dependencies.qbk index 365f2be..8f849a1 100644 --- a/doc/90_dependencies.qbk +++ b/doc/90_dependencies.qbk @@ -17,7 +17,6 @@ The implementation uses the following other Boost modules: # assert # config # core -# move # static_assert # throw_exception # type_traits diff --git a/include/boost/optional/detail/optional_reference_spec.hpp b/include/boost/optional/detail/optional_reference_spec.hpp index 9cb2b5c..30824c2 100644 --- a/include/boost/optional/detail/optional_reference_spec.hpp +++ b/include/boost/optional/detail/optional_reference_spec.hpp @@ -39,7 +39,7 @@ BOOST_DEDUCED_TYPENAME boost::remove_reference::type& forward_reference(T&& r { BOOST_STATIC_ASSERT_MSG(boost::is_lvalue_reference::value, "binding rvalue references to optional lvalue references is disallowed"); - return boost::forward(r); + return optional_detail::forward(r); } #endif // BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES diff --git a/include/boost/optional/detail/optional_swap.hpp b/include/boost/optional/detail/optional_swap.hpp index f4eceab..0c708c6 100644 --- a/include/boost/optional/detail/optional_swap.hpp +++ b/include/boost/optional/detail/optional_swap.hpp @@ -54,7 +54,7 @@ struct swap_selector #endif #ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES -# define BOOST_OPTIONAL_DETAIL_MOVE(EXPR_) boost::move(EXPR_) +# define BOOST_OPTIONAL_DETAIL_MOVE(EXPR_) optional_detail::move(EXPR_) #else # define BOOST_OPTIONAL_DETAIL_MOVE(EXPR_) EXPR_ #endif diff --git a/include/boost/optional/detail/optional_trivially_copyable_base.hpp b/include/boost/optional/detail/optional_trivially_copyable_base.hpp index a8e0371..3a08f7d 100644 --- a/include/boost/optional/detail/optional_trivially_copyable_base.hpp +++ b/include/boost/optional/detail/optional_trivially_copyable_base.hpp @@ -54,7 +54,7 @@ class tc_optional_base : public optional_tag : m_initialized(false) { - construct(boost::forward(expr),tag); + construct(optional_detail::forward(expr),tag); } // tc_optional_base& operator= ( tc_optional_base const& ) = default; @@ -102,7 +102,7 @@ class tc_optional_base : public optional_tag template void assign_expr ( Expr&& expr, ExprPtr const* tag ) { - construct(boost::forward(expr),tag); + construct(optional_detail::forward(expr),tag); } #endif @@ -138,14 +138,14 @@ class tc_optional_base : public optional_tag template void construct ( in_place_init_t, Args&&... args ) { - m_storage = value_type( boost::forward(args)... ) ; + m_storage = value_type( optional_detail::forward(args)... ) ; m_initialized = true ; } template void emplace_assign ( Args&&... args ) { - construct(in_place_init, boost::forward(args)...); + construct(in_place_init, optional_detail::forward(args)...); } template @@ -153,7 +153,7 @@ class tc_optional_base : public optional_tag : m_initialized(false) { - construct(in_place_init, boost::forward(args)...); + construct(in_place_init, optional_detail::forward(args)...); } template @@ -162,7 +162,7 @@ class tc_optional_base : public optional_tag m_initialized(false) { if ( cond ) - construct(in_place_init, boost::forward(args)...); + construct(in_place_init, optional_detail::forward(args)...); } #ifndef BOOST_OPTIONAL_NO_INPLACE_FACTORY_SUPPORT @@ -207,7 +207,7 @@ class tc_optional_base : public optional_tag template void construct ( Expr&& expr, void const* ) { - m_storage = value_type(boost::forward(expr)) ; + m_storage = value_type(optional_detail::forward(expr)) ; m_initialized = true ; } @@ -218,7 +218,7 @@ class tc_optional_base : public optional_tag template void assign_expr_to_initialized ( Expr&& expr, void const* ) { - assign_value( boost::forward(expr) ); + assign_value( optional_detail::forward(expr) ); } #ifdef BOOST_OPTIONAL_WEAK_OVERLOAD_RESOLUTION @@ -243,7 +243,7 @@ class tc_optional_base : public optional_tag { // An exception can be thrown here. // It it happens, THIS will be left uninitialized. - m_storage = value_type(boost::move(expr.get())) ; + m_storage = value_type(optional_detail::move(expr.get())) ; m_initialized = true ; } } diff --git a/include/boost/optional/detail/optional_utility.hpp b/include/boost/optional/detail/optional_utility.hpp new file mode 100644 index 0000000..6fd2fd2 --- /dev/null +++ b/include/boost/optional/detail/optional_utility.hpp @@ -0,0 +1,38 @@ +// Copyright (C) 2024 Andrzej Krzemienski. +// +// Use, modification, and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) +// +// See http://www.boost.org/libs/optional for documentation. +// +// You are welcome to contact the author at: +// akrzemi1@gmail.com + +#ifndef BOOST_OPTIONAL_OPTIONAL_DETAIL_OPTIONAL_UTILITY_HPP +#define BOOST_OPTIONAL_OPTIONAL_DETAIL_OPTIONAL_UTILITY_HPP + +namespace boost { +namespace optional_detail { + +// Workaround: forward and move aren't constexpr in C++11 +template inline constexpr T&& forward(typename boost::remove_reference::type& t) noexcept +{ + return static_cast(t); +} + +template inline constexpr T&& forward(typename boost::remove_reference::type&& t) noexcept +{ + BOOST_STATIC_ASSERT_MSG(!boost::is_lvalue_reference::value, "Can not forward an rvalue as an lvalue."); + return static_cast(t); +} + +template inline constexpr typename boost::remove_reference::type&& move(T&& t) noexcept +{ + return static_cast::type&&>(t); +} + +} // namespace optional_detail +} // namespace boost + +#endif diff --git a/include/boost/optional/optional.hpp b/include/boost/optional/optional.hpp index 37b5c35..6aec3ce 100644 --- a/include/boost/optional/optional.hpp +++ b/include/boost/optional/optional.hpp @@ -51,7 +51,6 @@ #include #include #include -#include #include #include @@ -59,6 +58,7 @@ #include #include #include +#include namespace boost { namespace optional_detail { @@ -178,7 +178,7 @@ class optional_base : public optional_tag : m_initialized(false) { - construct( boost::move(val) ); + construct( optional_detail::move(val) ); } // Creates an optional initialized with 'val' IFF cond is true, otherwise creates an uninitialized optional. @@ -198,7 +198,7 @@ class optional_base : public optional_tag m_initialized(false) { if ( cond ) - construct(boost::move(val)); + construct(optional_detail::move(val)); } // Creates a deep copy of another optional @@ -219,7 +219,7 @@ class optional_base : public optional_tag m_initialized(false) { if ( rhs.is_initialized() ) - construct( boost::move(rhs.get_impl()) ); + construct( optional_detail::move(rhs.get_impl()) ); } @@ -228,7 +228,7 @@ class optional_base : public optional_tag : m_initialized(false) { - construct(boost::forward(expr),tag); + construct(optional_detail::forward(expr),tag); } optional_base& operator= ( optional_base const& rhs ) @@ -269,13 +269,13 @@ class optional_base : public optional_tag if (is_initialized()) { if ( rhs.is_initialized() ) - assign_value( boost::move(rhs.get_impl()) ); + assign_value( optional_detail::move(rhs.get_impl()) ); else destroy(); } else { if ( rhs.is_initialized() ) - construct(boost::move(rhs.get_impl())); + construct(optional_detail::move(rhs.get_impl())); } } @@ -335,8 +335,8 @@ class optional_base : public optional_tag void assign ( rval_reference_type val ) { if (is_initialized()) - assign_value( boost::move(val) ); - else construct( boost::move(val) ); + assign_value( optional_detail::move(val) ); + else construct( optional_detail::move(val) ); } // Assigns from "none", destroying the current value, if any, leaving this UNINITIALIZED @@ -349,8 +349,8 @@ class optional_base : public optional_tag void assign_expr ( Expr&& expr, ExprPtr const* tag ) { if (is_initialized()) - assign_expr_to_initialized(boost::forward(expr),tag); - else construct(boost::forward(expr),tag); + assign_expr_to_initialized(optional_detail::forward(expr),tag); + else construct(optional_detail::forward(expr),tag); } #endif @@ -382,7 +382,7 @@ class optional_base : public optional_tag void construct ( rval_reference_type val ) { - ::new (m_storage.address()) unqualified_value_type( boost::move(val) ) ; + ::new (m_storage.address()) unqualified_value_type( optional_detail::move(val) ) ; m_initialized = true ; } @@ -392,7 +392,7 @@ class optional_base : public optional_tag template void construct ( in_place_init_t, Args&&... args ) { - ::new (m_storage.address()) unqualified_value_type( boost::forward(args)... ) ; + ::new (m_storage.address()) unqualified_value_type( optional_detail::forward(args)... ) ; m_initialized = true ; } @@ -400,7 +400,7 @@ class optional_base : public optional_tag void emplace_assign ( Args&&... args ) { destroy(); - construct(in_place_init, boost::forward(args)...); + construct(in_place_init, optional_detail::forward(args)...); } template @@ -408,7 +408,7 @@ class optional_base : public optional_tag : m_initialized(false) { - construct(in_place_init, boost::forward(args)...); + construct(in_place_init, optional_detail::forward(args)...); } template @@ -417,7 +417,7 @@ class optional_base : public optional_tag m_initialized(false) { if ( cond ) - construct(in_place_init, boost::forward(args)...); + construct(in_place_init, optional_detail::forward(args)...); } #ifndef BOOST_OPTIONAL_NO_INPLACE_FACTORY_SUPPORT @@ -462,7 +462,7 @@ class optional_base : public optional_tag template void construct ( Expr&& expr, void const* ) { - new (m_storage.address()) unqualified_value_type(boost::forward(expr)) ; + new (m_storage.address()) unqualified_value_type(optional_detail::forward(expr)) ; m_initialized = true ; } @@ -473,7 +473,7 @@ class optional_base : public optional_tag template void assign_expr_to_initialized ( Expr&& expr, void const* ) { - assign_value( boost::forward(expr) ); + assign_value( optional_detail::forward(expr) ); } #ifdef BOOST_OPTIONAL_WEAK_OVERLOAD_RESOLUTION @@ -498,7 +498,7 @@ class optional_base : public optional_tag { // An exception can be thrown here. // It it happens, THIS will be left uninitialized. - new (m_storage.address()) unqualified_value_type(boost::move(expr.get())) ; + new (m_storage.address()) unqualified_value_type(optional_detail::move(expr.get())) ; m_initialized = true ; } } @@ -686,7 +686,7 @@ class optional // Creates an optional initialized with 'move(val)'. // Can throw if T::T(T &&) does - optional ( rval_reference_type val ) : base(optional_detail::init_value_tag(), boost::forward(val)) + optional ( rval_reference_type val ) : base(optional_detail::init_value_tag(), optional_detail::forward(val)) {} // Creates an optional initialized with 'val' IFF cond is true, otherwise creates an uninitialized optional. @@ -695,7 +695,7 @@ class optional /// Creates an optional initialized with 'val' IFF cond is true, otherwise creates an uninitialized optional. // Can throw if T::T(T &&) does - optional ( bool cond, rval_reference_type val ) : base( cond, boost::forward(val) ) + optional ( bool cond, rval_reference_type val ) : base( cond, optional_detail::forward(val) ) {} // NOTE: MSVC needs templated versions first @@ -729,7 +729,7 @@ class optional base() { if ( rhs.is_initialized() ) - this->construct( boost::move(rhs.get()) ); + this->construct( optional_detail::move(rhs.get()) ); } #ifndef BOOST_OPTIONAL_NO_INPLACE_FACTORY_SUPPORT @@ -748,7 +748,7 @@ class optional explicit optional ( Expr&& expr, BOOST_DEDUCED_TYPENAME boost::enable_if< optional_detail::is_optional_val_init_candidate, bool>::type = true ) - : base(boost::forward(expr),boost::addressof(expr)) + : base(optional_detail::forward(expr),boost::addressof(expr)) {} #endif // !defined BOOST_OPTIONAL_NO_INPLACE_FACTORY_SUPPORT @@ -768,7 +768,7 @@ class optional #else optional ( optional && rhs ) BOOST_NOEXCEPT_IF(::boost::is_nothrow_move_constructible::value) - : base( boost::move(rhs) ) + : base( optional_detail::move(rhs) ) {} #endif @@ -787,7 +787,7 @@ class optional BOOST_DEDUCED_TYPENAME boost::enable_if, optional&>::type operator= ( Expr&& expr ) { - this->assign_expr(boost::forward(expr),boost::addressof(expr)); + this->assign_expr(optional_detail::forward(expr),boost::addressof(expr)); return *this ; } @@ -809,7 +809,7 @@ class optional template optional& operator= ( optional && rhs ) { - this->assign(boost::move(rhs)); + this->assign(optional_detail::move(rhs)); return *this ; } @@ -845,7 +845,7 @@ class optional BOOST_DEDUCED_TYPENAME boost::enable_if::type>, optional&>::type operator= ( T_&& val ) { - this->assign( boost::forward(val) ) ; + this->assign( optional_detail::forward(val) ) ; return *this ; } @@ -862,7 +862,7 @@ class optional // Assigns from a T (deep-moves the rhs value) optional& operator= ( rval_reference_type val ) { - this->assign( boost::move(val) ) ; + this->assign( optional_detail::move(val) ) ; return *this ; } @@ -882,17 +882,17 @@ class optional template void emplace ( Args&&... args ) { - this->emplace_assign( boost::forward(args)... ); + this->emplace_assign( optional_detail::forward(args)... ); } template explicit optional ( in_place_init_t, Args&&... args ) - : base( in_place_init, boost::forward(args)... ) + : base( in_place_init, optional_detail::forward(args)... ) {} template explicit optional ( in_place_init_if_t, bool cond, Args&&... args ) - : base( in_place_init_if, cond, boost::forward(args)... ) + : base( in_place_init_if, cond, optional_detail::forward(args)... ) {} void swap( optional & arg ) @@ -924,7 +924,7 @@ class optional // No-throw reference_const_type operator *() const& { return this->get() ; } reference_type operator *() & { return this->get() ; } - reference_type_of_temporary_wrapper operator *() && { return boost::move(this->get()) ; } + reference_type_of_temporary_wrapper operator *() && { return optional_detail::move(this->get()) ; } reference_const_type value() const& { @@ -945,7 +945,7 @@ class optional reference_type_of_temporary_wrapper value() && { if (this->is_initialized()) - return boost::move(this->get()) ; + return optional_detail::move(this->get()) ; else throw_exception(bad_optional_access()); } @@ -958,16 +958,16 @@ class optional if (this->is_initialized()) return get(); else - return boost::forward(v); + return optional_detail::forward(v); } template value_type value_or ( U&& v ) && { if (this->is_initialized()) - return boost::move(get()); + return optional_detail::move(get()); else - return boost::forward(v); + return optional_detail::forward(v); } template @@ -983,7 +983,7 @@ class optional value_type value_or_eval ( F f ) && { if (this->is_initialized()) - return boost::move(get()); + return optional_detail::move(get()); else return f(); } @@ -1010,7 +1010,7 @@ class optional optional::type> map(F f) && { if (this->has_value()) - return f(boost::move(this->get())); + return f(optional_detail::move(this->get())); else return none; } @@ -1040,7 +1040,7 @@ class optional flat_map(F f) && { if (this->has_value()) - return f(boost::move(get())); + return f(optional_detail::move(get())); else return none; } @@ -1071,7 +1071,7 @@ template inline optional::type> make_optional ( T && v ) { - return optional::type>(boost::forward(v)); + return optional::type>(optional_detail::forward(v)); } // Returns optional(cond,v) @@ -1079,7 +1079,7 @@ template inline optional::type> make_optional ( bool cond, T && v ) { - return optional::type>(cond,boost::forward(v)); + return optional::type>(cond,optional_detail::forward(v)); } diff --git a/include/boost/optional/optional_io.hpp b/include/boost/optional/optional_io.hpp index 3db6dda..b9ffc25 100644 --- a/include/boost/optional/optional_io.hpp +++ b/include/boost/optional/optional_io.hpp @@ -64,7 +64,7 @@ operator>>(std::basic_istream& in, optional& v) T x; in >> x; #ifndef BOOST_OPTIONAL_DETAIL_NO_RVALUE_REFERENCES - v = boost::move(x); + v = std::move(x); #else v = x; #endif diff --git a/test/optional_test_flat_map.cpp b/test/optional_test_flat_map.cpp index 05ed63a..14311b5 100644 --- a/test/optional_test_flat_map.cpp +++ b/test/optional_test_flat_map.cpp @@ -240,8 +240,8 @@ void test_flat_map_move_only() { { optional om (makeMoveOnly(1)), om2 (makeMoveOnly(2)); - verify_type >(boost::move(om).flat_map(get_val)); - optional oi = boost::move(om2).flat_map(get_val); + verify_type >(std::move(om).flat_map(get_val)); + optional oi = std::move(om2).flat_map(get_val); BOOST_TEST(bool(oi)); BOOST_TEST_EQ(2, *oi); } diff --git a/test/optional_test_map.cpp b/test/optional_test_map.cpp index f0b7f0e..61a1824 100644 --- a/test/optional_test_map.cpp +++ b/test/optional_test_map.cpp @@ -62,8 +62,8 @@ int get_val(MoveOnly m) void test_map_move_only() { optional om (makeMoveOnly(7)), om2 (makeMoveOnly(8)); - verify_type >(boost::move(om).map(get_val)); - optional oi = boost::move(om2).map(get_val); + verify_type >(std::move(om).map(get_val)); + optional oi = std::move(om2).map(get_val); BOOST_TEST(bool(oi)); BOOST_TEST_EQ(8, *oi); @@ -72,7 +72,7 @@ void test_map_move_only() BOOST_TEST_EQ(4, *oj); optional o_; - optional oi_ = boost::move(o_).map(get_val); + optional oi_ = std::move(o_).map(get_val); BOOST_TEST(!oi_); } diff --git a/test/optional_test_move.cpp b/test/optional_test_move.cpp index f27cd99..5561d92 100644 --- a/test/optional_test_move.cpp +++ b/test/optional_test_move.cpp @@ -82,7 +82,7 @@ void test_move_ctor_from_U() BOOST_TEST(o2->s == sValueCopyConstructed || o2->s == sCopyConstructed || o2->s == sMoveConstructed ); BOOST_TEST(v1.s == sIntConstructed); - optional o3 (boost::move(v1)); + optional o3 (std::move(v1)); BOOST_TEST(o3); BOOST_TEST(o3->s == sValueMoveConstructed || o3->s == sMoveConstructed); BOOST_TEST(v1.s == sMovedFrom); @@ -100,7 +100,7 @@ void test_move_ctor_form_T() BOOST_TEST(o2->s == sCopyConstructed); BOOST_TEST(v1.s == sDefaultConstructed); - optional o3 (boost::move(v1)); + optional o3 (std::move(v1)); BOOST_TEST(o3); BOOST_TEST(o3->s == sMoveConstructed); BOOST_TEST(v1.s == sMovedFrom); @@ -109,13 +109,13 @@ void test_move_ctor_form_T() void test_move_ctor_from_optional_T() { optional o1; - optional o2(boost::move(o1)); + optional o2(std::move(o1)); BOOST_TEST(!o1); BOOST_TEST(!o2); optional o3((Oracle())); - optional o4(boost::move(o3)); + optional o4(std::move(o3)); BOOST_TEST(o3); BOOST_TEST(o4); BOOST_TEST(o3->s == sMovedFrom); @@ -156,7 +156,7 @@ void test_move_assign_from_U() BOOST_TEST(v1.s == sIntConstructed); optional o3; - o3 = boost::move(v1); + o3 = std::move(v1); BOOST_TEST(o3); BOOST_TEST(o3->s == sValueMoveConstructed); BOOST_TEST(v1.s == sMovedFrom); @@ -185,7 +185,7 @@ void test_move_assign_from_T() BOOST_TEST(v1.s == sDefaultConstructed); optional o3; - o3 = boost::move(v1); + o3 = std::move(v1); BOOST_TEST(o3); BOOST_TEST(o3->s == sMoveConstructed); BOOST_TEST(v1.s == sMovedFrom); @@ -204,7 +204,7 @@ void test_move_assign_from_optional_T() BOOST_TEST(o1); BOOST_TEST(o1->s == sCopyConstructed); - o2 = boost::move(o3); + o2 = std::move(o3); BOOST_TEST(o3); BOOST_TEST(o3->s == sMovedFrom); BOOST_TEST(o2); @@ -236,15 +236,15 @@ void test_with_move_only() optional o2((MoveOnly(1))); BOOST_TEST(o2); BOOST_TEST(o2->val == 1); - optional o3 (boost::move(o1)); + optional o3 (std::move(o1)); BOOST_TEST(!o3); - optional o4 (boost::move(o2)); + optional o4 (std::move(o2)); BOOST_TEST(o4); BOOST_TEST(o4->val == 1); BOOST_TEST(o2); BOOST_TEST(o2->val == 0); - o3 = boost::move(o4); + o3 = std::move(o4); BOOST_TEST(o3); BOOST_TEST(o3->val == 1); BOOST_TEST(o4); @@ -272,7 +272,7 @@ void test_move_assign_from_optional_U() { optional a((MoveOnly(2))); optional b1; - b1 = boost::move(a); + b1 = std::move(a); BOOST_TEST(b1); BOOST_TEST(b1->val == 2); @@ -288,7 +288,7 @@ void test_move_assign_from_optional_U() void test_move_ctor_from_optional_U() { optional a((MoveOnly(2))); - optional b1(boost::move(a)); + optional b1(std::move(a)); BOOST_TEST(b1); BOOST_TEST(b1->val == 2); @@ -323,7 +323,7 @@ void test_optional_ref_to_movables() BOOST_TEST(m.val == 1); BOOST_TEST(orm->val == 1); - optional orm3 = boost::move(orm); + optional orm3 = std::move(orm); orm3->val = 4; BOOST_TEST(m.val == 4); BOOST_TEST(orm->val == 4); diff --git a/test/optional_test_noexcept_move.cpp b/test/optional_test_noexcept_move.cpp index 258bacd..bc4fa97 100644 --- a/test/optional_test_noexcept_move.cpp +++ b/test/optional_test_noexcept_move.cpp @@ -89,19 +89,19 @@ void test_noexcept_optional_with_operator() // compile-time test ONx0 onx0; BOOST_STATIC_ASSERT( BOOST_NOEXCEPT_EXPR( ONx2() )); - BOOST_STATIC_ASSERT( BOOST_NOEXCEPT_EXPR( ONx2(boost::move(onx2)) )); + BOOST_STATIC_ASSERT( BOOST_NOEXCEPT_EXPR( ONx2(std::move(onx2)) )); BOOST_STATIC_ASSERT( BOOST_NOEXCEPT_EXPR( onx2 = ONx2() )); BOOST_STATIC_ASSERT( BOOST_NOEXCEPT_EXPR( ONxC() )); - BOOST_STATIC_ASSERT( BOOST_NOEXCEPT_EXPR( ONxC(boost::move(onxC)) )); + BOOST_STATIC_ASSERT( BOOST_NOEXCEPT_EXPR( ONxC(std::move(onxC)) )); BOOST_STATIC_ASSERT(!BOOST_NOEXCEPT_EXPR( onxC = ONxC() )); BOOST_STATIC_ASSERT( BOOST_NOEXCEPT_EXPR( ONxA() )); - BOOST_STATIC_ASSERT(!BOOST_NOEXCEPT_EXPR( ONxA(boost::move(onxA)) )); + BOOST_STATIC_ASSERT(!BOOST_NOEXCEPT_EXPR( ONxA(std::move(onxA)) )); BOOST_STATIC_ASSERT(!BOOST_NOEXCEPT_EXPR( onxA = ONxA() )); BOOST_STATIC_ASSERT( BOOST_NOEXCEPT_EXPR( ONx0() )); - BOOST_STATIC_ASSERT(!BOOST_NOEXCEPT_EXPR( ONx0(boost::move(onx0)) )); + BOOST_STATIC_ASSERT(!BOOST_NOEXCEPT_EXPR( ONx0(std::move(onx0)) )); BOOST_STATIC_ASSERT(!BOOST_NOEXCEPT_EXPR( onx0 = ONx0() )); }