From: Jonathan Wakely Date: Thu, 9 Jan 2014 18:38:52 +0000 (+0000) Subject: re PR libstdc++/59738 (r206444 caused FAIL: 23_containers/vector/52591.cc) X-Git-Tag: releases/gcc-4.9.0~1747 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=f0bc4aead81f19574ae543f3ce9e9849a2b6bec8;p=thirdparty%2Fgcc.git re PR libstdc++/59738 (r206444 caused FAIL: 23_containers/vector/52591.cc) PR libstdc++/59738 * include/bits/stl_vector.h (vector<>::_M_move_assign): Restore support for non-Movable types. From-SVN: r206480 --- diff --git a/libstdc++-v3/ChangeLog b/libstdc++-v3/ChangeLog index 965b0916c6a1..78cce64ac421 100644 --- a/libstdc++-v3/ChangeLog +++ b/libstdc++-v3/ChangeLog @@ -1,3 +1,9 @@ +2014-01-09 Jonathan Wakely + + PR libstdc++/59738 + * include/bits/stl_vector.h (vector<>::_M_move_assign): Restore + support for non-Movable types. + 2014-01-08 François Dumont * include/bits/stl_vector.h (std::vector<>::_M_move_assign): Pass diff --git a/libstdc++-v3/include/bits/stl_vector.h b/libstdc++-v3/include/bits/stl_vector.h index 3638a8c07efb..2cedd39cae8b 100644 --- a/libstdc++-v3/include/bits/stl_vector.h +++ b/libstdc++-v3/include/bits/stl_vector.h @@ -1433,7 +1433,8 @@ _GLIBCXX_BEGIN_NAMESPACE_CONTAINER void _M_move_assign(vector&& __x, std::true_type) noexcept { - const vector __tmp(std::move(*this), get_allocator()); + vector __tmp(get_allocator()); + this->_M_impl._M_swap_data(__tmp._M_impl); this->_M_impl._M_swap_data(__x._M_impl); if (_Alloc_traits::_S_propagate_on_move_assign()) std::__alloc_on_move(_M_get_Tp_allocator(),