From 06dce00742a8f1c917c3b9113eafca0883b3e7a4 Mon Sep 17 00:00:00 2001 From: Jonathan Wakely Date: Tue, 11 Mar 2014 17:16:41 +0000 Subject: [PATCH] re PR libstdc++/60499 (non-reserved name in ) PR libstdc++/60499 * include/debug/forward_list (forward_list::operator=(forward_list&&)): Uglify name. * include/debug/map (map::operator=(map&&)): Likewise. * include/debug/multimap (multimap::operator=(multimap&&)): Likewise. * include/debug/multiset (multiset::operator=(multiset&&)): Likewise. * include/debug/set (set::operator=(set&&)): Likewise. * include/debug/unordered_map (unordered_map::operator=(unordered_map&&)): Likewise. (unordered_multimap::operator=(unordered_multimap&&)): Likewise. * include/debug/unordered_set (unordered_set::operator=(unordered_set&&)): Likewise. (unordered_multiset::operator=(unordered_multiset&&)): Likewise. * include/debug/vector (vector::operator=(vector&&)): Likewise. * testsuite/23_containers/forward_list/debug/60499.cc: New * testsuite/23_containers/map/debug/60499.cc: New * testsuite/23_containers/multimap/debug/60499.cc: New * testsuite/23_containers/multiset/debug/60499.cc: New * testsuite/23_containers/set/debug/60499.cc: New * testsuite/23_containers/unordered_map/debug/60499.cc: New * testsuite/23_containers/unordered_multimap/debug/60499.cc: New * testsuite/23_containers/unordered_multiset/debug/60499.cc: New * testsuite/23_containers/unordered_set/debug/60499.cc: New * testsuite/23_containers/vector/debug/60499.cc: New From-SVN: r208490 --- libstdc++-v3/ChangeLog | 27 +++++++++++++++++++ libstdc++-v3/include/debug/forward_list | 4 +-- libstdc++-v3/include/debug/map.h | 4 +-- libstdc++-v3/include/debug/multimap.h | 4 +-- libstdc++-v3/include/debug/multiset.h | 4 +-- libstdc++-v3/include/debug/set.h | 4 +-- libstdc++-v3/include/debug/unordered_map | 8 +++--- libstdc++-v3/include/debug/unordered_set | 8 +++--- libstdc++-v3/include/debug/vector | 4 +-- .../23_containers/forward_list/debug/60499.cc | 27 +++++++++++++++++++ .../23_containers/map/debug/60499.cc | 27 +++++++++++++++++++ .../23_containers/multimap/debug/60499.cc | 27 +++++++++++++++++++ .../23_containers/multiset/debug/60499.cc | 27 +++++++++++++++++++ .../23_containers/set/debug/60499.cc | 27 +++++++++++++++++++ .../unordered_map/debug/60499.cc | 27 +++++++++++++++++++ .../unordered_multimap/debug/60499.cc | 27 +++++++++++++++++++ .../unordered_multiset/debug/60499.cc | 27 +++++++++++++++++++ .../unordered_set/debug/60499.cc | 27 +++++++++++++++++++ .../23_containers/vector/debug/60499.cc | 27 +++++++++++++++++++ 19 files changed, 317 insertions(+), 20 deletions(-) create mode 100644 libstdc++-v3/testsuite/23_containers/forward_list/debug/60499.cc create mode 100644 libstdc++-v3/testsuite/23_containers/map/debug/60499.cc create mode 100644 libstdc++-v3/testsuite/23_containers/multimap/debug/60499.cc create mode 100644 libstdc++-v3/testsuite/23_containers/multiset/debug/60499.cc create mode 100644 libstdc++-v3/testsuite/23_containers/set/debug/60499.cc create mode 100644 libstdc++-v3/testsuite/23_containers/unordered_map/debug/60499.cc create mode 100644 libstdc++-v3/testsuite/23_containers/unordered_multimap/debug/60499.cc create mode 100644 libstdc++-v3/testsuite/23_containers/unordered_multiset/debug/60499.cc create mode 100644 libstdc++-v3/testsuite/23_containers/unordered_set/debug/60499.cc create mode 100644 libstdc++-v3/testsuite/23_containers/vector/debug/60499.cc diff --git a/libstdc++-v3/ChangeLog b/libstdc++-v3/ChangeLog index d079638b340..7c92019a8af 100644 --- a/libstdc++-v3/ChangeLog +++ b/libstdc++-v3/ChangeLog @@ -1,3 +1,30 @@ +2014-03-11 Jonathan Wakely + + PR libstdc++/60499 + * include/debug/forward_list (forward_list::operator=(forward_list&&)): + Uglify name. + * include/debug/map (map::operator=(map&&)): Likewise. + * include/debug/multimap (multimap::operator=(multimap&&)): Likewise. + * include/debug/multiset (multiset::operator=(multiset&&)): Likewise. + * include/debug/set (set::operator=(set&&)): Likewise. + * include/debug/unordered_map + (unordered_map::operator=(unordered_map&&)): Likewise. + (unordered_multimap::operator=(unordered_multimap&&)): Likewise. + * include/debug/unordered_set + (unordered_set::operator=(unordered_set&&)): Likewise. + (unordered_multiset::operator=(unordered_multiset&&)): Likewise. + * include/debug/vector (vector::operator=(vector&&)): Likewise. + * testsuite/23_containers/forward_list/debug/60499.cc: New + * testsuite/23_containers/map/debug/60499.cc: New + * testsuite/23_containers/multimap/debug/60499.cc: New + * testsuite/23_containers/multiset/debug/60499.cc: New + * testsuite/23_containers/set/debug/60499.cc: New + * testsuite/23_containers/unordered_map/debug/60499.cc: New + * testsuite/23_containers/unordered_multimap/debug/60499.cc: New + * testsuite/23_containers/unordered_multiset/debug/60499.cc: New + * testsuite/23_containers/unordered_set/debug/60499.cc: New + * testsuite/23_containers/vector/debug/60499.cc: New + 2014-03-05 Ed Smith-Rowland <3dw4rd@verizon.net> * doc/xml/manual/status_cxx2014.xml: Add new items and latest papers diff --git a/libstdc++-v3/include/debug/forward_list b/libstdc++-v3/include/debug/forward_list index f2984c9c30c..12f6d7fbe1d 100644 --- a/libstdc++-v3/include/debug/forward_list +++ b/libstdc++-v3/include/debug/forward_list @@ -140,10 +140,10 @@ namespace __debug noexcept(_Node_alloc_traits::_S_nothrow_move()) { __glibcxx_check_self_move_assign(__list); - bool xfer_memory = _Node_alloc_traits::_S_propagate_on_move_assign() + bool __xfer_memory = _Node_alloc_traits::_S_propagate_on_move_assign() || __list.get_allocator() == this->get_allocator(); static_cast<_Base&>(*this) = std::move(__list); - if (xfer_memory) + if (__xfer_memory) this->_M_swap(__list); else this->_M_invalidate_all(); diff --git a/libstdc++-v3/include/debug/map.h b/libstdc++-v3/include/debug/map.h index bd68c996d0d..fda6ac1eee5 100644 --- a/libstdc++-v3/include/debug/map.h +++ b/libstdc++-v3/include/debug/map.h @@ -148,10 +148,10 @@ namespace __debug noexcept(_Alloc_traits::_S_nothrow_move()) { __glibcxx_check_self_move_assign(__x); - bool xfer_memory = _Alloc_traits::_S_propagate_on_move_assign() + bool __xfer_memory = _Alloc_traits::_S_propagate_on_move_assign() || __x.get_allocator() == this->get_allocator(); _M_base() = std::move(__x._M_base()); - if (xfer_memory) + if (__xfer_memory) this->_M_swap(__x); else this->_M_invalidate_all(); diff --git a/libstdc++-v3/include/debug/multimap.h b/libstdc++-v3/include/debug/multimap.h index fad80cc8ebe..4c3a3eb8747 100644 --- a/libstdc++-v3/include/debug/multimap.h +++ b/libstdc++-v3/include/debug/multimap.h @@ -150,10 +150,10 @@ namespace __debug noexcept(_Alloc_traits::_S_nothrow_move()) { __glibcxx_check_self_move_assign(__x); - bool xfer_memory = _Alloc_traits::_S_propagate_on_move_assign() + bool __xfer_memory = _Alloc_traits::_S_propagate_on_move_assign() || __x.get_allocator() == this->get_allocator(); _M_base() = std::move(__x._M_base()); - if (xfer_memory) + if (__xfer_memory) this->_M_swap(__x); else this->_M_invalidate_all(); diff --git a/libstdc++-v3/include/debug/multiset.h b/libstdc++-v3/include/debug/multiset.h index bd555b3c290..ae62bf87214 100644 --- a/libstdc++-v3/include/debug/multiset.h +++ b/libstdc++-v3/include/debug/multiset.h @@ -149,10 +149,10 @@ namespace __debug noexcept(_Alloc_traits::_S_nothrow_move()) { __glibcxx_check_self_move_assign(__x); - bool xfer_memory = _Alloc_traits::_S_propagate_on_move_assign() + bool __xfer_memory = _Alloc_traits::_S_propagate_on_move_assign() || __x.get_allocator() == this->get_allocator(); _M_base() = std::move(__x._M_base()); - if (xfer_memory) + if (__xfer_memory) this->_M_swap(__x); else this->_M_invalidate_all(); diff --git a/libstdc++-v3/include/debug/set.h b/libstdc++-v3/include/debug/set.h index f40ecec818f..c83e2afa96c 100644 --- a/libstdc++-v3/include/debug/set.h +++ b/libstdc++-v3/include/debug/set.h @@ -148,10 +148,10 @@ namespace __debug noexcept(_Alloc_traits::_S_nothrow_move()) { __glibcxx_check_self_move_assign(__x); - bool xfer_memory = _Alloc_traits::_S_propagate_on_move_assign() + bool __xfer_memory = _Alloc_traits::_S_propagate_on_move_assign() || __x.get_allocator() == this->get_allocator(); _M_base() = std::move(__x._M_base()); - if (xfer_memory) + if (__xfer_memory) this->_M_swap(__x); else this->_M_invalidate_all(); diff --git a/libstdc++-v3/include/debug/unordered_map b/libstdc++-v3/include/debug/unordered_map index 821bf0bfe81..626beba5f46 100644 --- a/libstdc++-v3/include/debug/unordered_map +++ b/libstdc++-v3/include/debug/unordered_map @@ -143,10 +143,10 @@ namespace __debug noexcept(_Alloc_traits::_S_nothrow_move()) { __glibcxx_check_self_move_assign(__x); - bool xfer_memory = _Alloc_traits::_S_propagate_on_move_assign() + bool __xfer_memory = _Alloc_traits::_S_propagate_on_move_assign() || __x.get_allocator() == this->get_allocator(); _M_base() = std::move(__x._M_base()); - if (xfer_memory) + if (__xfer_memory) this->_M_swap(__x); else this->_M_invalidate_all(); @@ -599,10 +599,10 @@ namespace __debug noexcept(_Alloc_traits::_S_nothrow_move()) { __glibcxx_check_self_move_assign(__x); - bool xfer_memory = _Alloc_traits::_S_propagate_on_move_assign() + bool __xfer_memory = _Alloc_traits::_S_propagate_on_move_assign() || __x.get_allocator() == this->get_allocator(); _M_base() = std::move(__x._M_base()); - if (xfer_memory) + if (__xfer_memory) this->_M_swap(__x); else this->_M_invalidate_all(); diff --git a/libstdc++-v3/include/debug/unordered_set b/libstdc++-v3/include/debug/unordered_set index 3bc3fab5610..a17efd0a5fe 100644 --- a/libstdc++-v3/include/debug/unordered_set +++ b/libstdc++-v3/include/debug/unordered_set @@ -142,10 +142,10 @@ namespace __debug noexcept(_Alloc_traits::_S_nothrow_move()) { __glibcxx_check_self_move_assign(__x); - bool xfer_memory = _Alloc_traits::_S_propagate_on_move_assign() + bool __xfer_memory = _Alloc_traits::_S_propagate_on_move_assign() || __x.get_allocator() == this->get_allocator(); _M_base() = std::move(__x._M_base()); - if (xfer_memory) + if (__xfer_memory) this->_M_swap(__x); else this->_M_invalidate_all(); @@ -593,10 +593,10 @@ namespace __debug noexcept(_Alloc_traits::_S_nothrow_move()) { __glibcxx_check_self_move_assign(__x); - bool xfer_memory = _Alloc_traits::_S_propagate_on_move_assign() + bool __xfer_memory = _Alloc_traits::_S_propagate_on_move_assign() || __x.get_allocator() == this->get_allocator(); _M_base() = std::move(__x._M_base()); - if (xfer_memory) + if (__xfer_memory) this->_M_swap(__x); else this->_M_invalidate_all(); diff --git a/libstdc++-v3/include/debug/vector b/libstdc++-v3/include/debug/vector index 58d98ef5de5..bcca52035d3 100644 --- a/libstdc++-v3/include/debug/vector +++ b/libstdc++-v3/include/debug/vector @@ -163,10 +163,10 @@ namespace __debug operator=(vector&& __x) noexcept(_Alloc_traits::_S_nothrow_move()) { __glibcxx_check_self_move_assign(__x); - bool xfer_memory = _Alloc_traits::_S_propagate_on_move_assign() + bool __xfer_memory = _Alloc_traits::_S_propagate_on_move_assign() || __x.get_allocator() == this->get_allocator(); _M_base() = std::move(__x._M_base()); - if (xfer_memory) + if (__xfer_memory) this->_M_swap(__x); else this->_M_invalidate_all(); diff --git a/libstdc++-v3/testsuite/23_containers/forward_list/debug/60499.cc b/libstdc++-v3/testsuite/23_containers/forward_list/debug/60499.cc new file mode 100644 index 00000000000..f65ed2b08bd --- /dev/null +++ b/libstdc++-v3/testsuite/23_containers/forward_list/debug/60499.cc @@ -0,0 +1,27 @@ +// Copyright (C) 2014 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 3, or (at your option) +// any later version. +// +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING3. If not see +// . +// +// { dg-require-debug-mode "" } +// { dg-options "-std=gnu++11" } +// { dg-do compile } + +// PR libstdc++/60499 + +#define xfer_memory 1 +#include + +std::forward_list a, b = std::move(a); diff --git a/libstdc++-v3/testsuite/23_containers/map/debug/60499.cc b/libstdc++-v3/testsuite/23_containers/map/debug/60499.cc new file mode 100644 index 00000000000..ba868fd2538 --- /dev/null +++ b/libstdc++-v3/testsuite/23_containers/map/debug/60499.cc @@ -0,0 +1,27 @@ +// Copyright (C) 2014 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 3, or (at your option) +// any later version. +// +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING3. If not see +// . +// +// { dg-require-debug-mode "" } +// { dg-options "-std=gnu++11" } +// { dg-do compile } + +// PR libstdc++/60499 + +#define xfer_memory 1 +#include + +std::map a, b = std::move(a); diff --git a/libstdc++-v3/testsuite/23_containers/multimap/debug/60499.cc b/libstdc++-v3/testsuite/23_containers/multimap/debug/60499.cc new file mode 100644 index 00000000000..38b8bcd7319 --- /dev/null +++ b/libstdc++-v3/testsuite/23_containers/multimap/debug/60499.cc @@ -0,0 +1,27 @@ +// Copyright (C) 2014 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 3, or (at your option) +// any later version. +// +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING3. If not see +// . +// +// { dg-require-debug-mode "" } +// { dg-options "-std=gnu++11" } +// { dg-do compile } + +// PR libstdc++/60499 + +#define xfer_memory 1 +#include + +std::multimap a, b = std::move(a); diff --git a/libstdc++-v3/testsuite/23_containers/multiset/debug/60499.cc b/libstdc++-v3/testsuite/23_containers/multiset/debug/60499.cc new file mode 100644 index 00000000000..b0a5cdef591 --- /dev/null +++ b/libstdc++-v3/testsuite/23_containers/multiset/debug/60499.cc @@ -0,0 +1,27 @@ +// Copyright (C) 2014 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 3, or (at your option) +// any later version. +// +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING3. If not see +// . +// +// { dg-require-debug-mode "" } +// { dg-options "-std=gnu++11" } +// { dg-do compile } + +// PR libstdc++/60499 + +#define xfer_memory 1 +#include + +std::multiset a, b = std::move(a); diff --git a/libstdc++-v3/testsuite/23_containers/set/debug/60499.cc b/libstdc++-v3/testsuite/23_containers/set/debug/60499.cc new file mode 100644 index 00000000000..80f32230542 --- /dev/null +++ b/libstdc++-v3/testsuite/23_containers/set/debug/60499.cc @@ -0,0 +1,27 @@ +// Copyright (C) 2014 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 3, or (at your option) +// any later version. +// +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING3. If not see +// . +// +// { dg-require-debug-mode "" } +// { dg-options "-std=gnu++11" } +// { dg-do compile } + +// PR libstdc++/60499 + +#define xfer_memory 1 +#include + +std::set a, b = std::move(a); diff --git a/libstdc++-v3/testsuite/23_containers/unordered_map/debug/60499.cc b/libstdc++-v3/testsuite/23_containers/unordered_map/debug/60499.cc new file mode 100644 index 00000000000..7915f8ed9d4 --- /dev/null +++ b/libstdc++-v3/testsuite/23_containers/unordered_map/debug/60499.cc @@ -0,0 +1,27 @@ +// Copyright (C) 2014 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 3, or (at your option) +// any later version. +// +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING3. If not see +// . +// +// { dg-require-debug-mode "" } +// { dg-options "-std=gnu++11" } +// { dg-do compile } + +// PR libstdc++/60499 + +#define xfer_memory 1 +#include + +std::unordered_map a, b = std::move(a); diff --git a/libstdc++-v3/testsuite/23_containers/unordered_multimap/debug/60499.cc b/libstdc++-v3/testsuite/23_containers/unordered_multimap/debug/60499.cc new file mode 100644 index 00000000000..3a410392bfe --- /dev/null +++ b/libstdc++-v3/testsuite/23_containers/unordered_multimap/debug/60499.cc @@ -0,0 +1,27 @@ +// Copyright (C) 2014 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 3, or (at your option) +// any later version. +// +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING3. If not see +// . +// +// { dg-require-debug-mode "" } +// { dg-options "-std=gnu++11" } +// { dg-do compile } + +// PR libstdc++/60499 + +#define xfer_memory 1 +#include + +std::unordered_multimap a, b = std::move(a); diff --git a/libstdc++-v3/testsuite/23_containers/unordered_multiset/debug/60499.cc b/libstdc++-v3/testsuite/23_containers/unordered_multiset/debug/60499.cc new file mode 100644 index 00000000000..7f61cc7bfc9 --- /dev/null +++ b/libstdc++-v3/testsuite/23_containers/unordered_multiset/debug/60499.cc @@ -0,0 +1,27 @@ +// Copyright (C) 2014 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 3, or (at your option) +// any later version. +// +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING3. If not see +// . +// +// { dg-require-debug-mode "" } +// { dg-options "-std=gnu++11" } +// { dg-do compile } + +// PR libstdc++/60499 + +#define xfer_memory 1 +#include + +std::unordered_multiset a, b = std::move(a); diff --git a/libstdc++-v3/testsuite/23_containers/unordered_set/debug/60499.cc b/libstdc++-v3/testsuite/23_containers/unordered_set/debug/60499.cc new file mode 100644 index 00000000000..a9c71a52918 --- /dev/null +++ b/libstdc++-v3/testsuite/23_containers/unordered_set/debug/60499.cc @@ -0,0 +1,27 @@ +// Copyright (C) 2014 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 3, or (at your option) +// any later version. +// +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING3. If not see +// . +// +// { dg-require-debug-mode "" } +// { dg-options "-std=gnu++11" } +// { dg-do compile } + +// PR libstdc++/60499 + +#define xfer_memory 1 +#include + +std::unordered_set a, b = std::move(a); diff --git a/libstdc++-v3/testsuite/23_containers/vector/debug/60499.cc b/libstdc++-v3/testsuite/23_containers/vector/debug/60499.cc new file mode 100644 index 00000000000..9ba4dfeba98 --- /dev/null +++ b/libstdc++-v3/testsuite/23_containers/vector/debug/60499.cc @@ -0,0 +1,27 @@ +// Copyright (C) 2014 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 3, or (at your option) +// any later version. +// +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING3. If not see +// . +// +// { dg-require-debug-mode "" } +// { dg-options "-std=gnu++11" } +// { dg-do compile } + +// PR libstdc++/60499 + +#define xfer_memory 1 +#include + +std::vector a, b = std::move(a);