diff options
author | bkoz <bkoz@138bc75d-0d04-0410-961f-82ee72b054a4> | 2007-10-03 17:27:18 +0000 |
---|---|---|
committer | bkoz <bkoz@138bc75d-0d04-0410-961f-82ee72b054a4> | 2007-10-03 17:27:18 +0000 |
commit | 5348e86a46b129b304326f3db600aaaae9c62ee9 (patch) | |
tree | 46cc3fffe09f0d59f370c379911fdc297f83f02b /libstdc++-v3/testsuite/25_algorithms/reverse | |
parent | 9c78c8fe7549b840655bf32cb19695d53eb83b63 (diff) | |
download | gcc-5348e86a46b129b304326f3db600aaaae9c62ee9.tar.gz |
2007-10-03 Chris Jefferson <chris@bubblescope.net>
Benjamin Kosnik <bkoz@redhat.com>
* testsuite/20_util/pair/moveable.cc: New. Merge from
libstdcxx_so_7-branch.
* testsuite/23_containers/deque/capacity/moveable.cc: Same.
* testsuite/23_containers/deque/cons/moveable.cc: Same.
* testsuite/23_containers/deque/modifiers/moveable.cc: Same.
* testsuite/23_containers/deque/moveable.cc: Same.
* testsuite/23_containers/list/moveable.cc: Same.
* testsuite/23_containers/map/moveable.cc: Same.
* testsuite/23_containers/multimap/moveable.cc: Same.
* testsuite/23_containers/multiset/moveable.cc: Same.
* testsuite/23_containers/set/moveable.cc: Same.
* testsuite/23_containers/vector/cons/moveable.cc: Same.
* testsuite/23_containers/vector/modifiers/moveable.cc: Same.
* testsuite/23_containers/vector/moveable.cc: Same.
* testsuite/23_containers/vector/resize/moveable.cc: Same.
* testsuite/25_algorithms/heap/moveable.cc: Same.
* testsuite/25_algorithms/nth_element/moveable.cc: Same.
* testsuite/25_algorithms/partial_sort/moveable.cc: Same.
* testsuite/25_algorithms/partition/moveable.cc: Same.
* testsuite/25_algorithms/remove_if/moveable.cc: Same.
* testsuite/25_algorithms/remove/moveable.cc: Same.
* testsuite/25_algorithms/reverse/moveable.cc: Same.
* testsuite/25_algorithms/rotate/moveable.cc: Same.
* testsuite/25_algorithms/sort/moveable.cc: Same.
* testsuite/25_algorithms/swap_ranges/moveable.cc: Same.
* testsuite/25_algorithms/unique/moveable.cc: Same.
* testsuite/util/testsuite_rvalref.h: New.
* testsuite/25_algorithms/equal/equal.cc: Move to...
* testsuite/25_algorithms/equal/no_operator_ne.cc: ...this.
* testsuite/25_algorithms/heap/heap.cc: Move to...
* testsuite/25_algorithms/heap/1.cc: ...this.
* testsuite/25_algorithms/lower_bound/lower_bound.cc: Move to...
* testsuite/25_algorithms/lower_bound/no_operator_ne.cc: ...this.
* testsuite/25_algorithms/partition/partition.cc: Move to...
* testsuite/25_algorithms/partition/1.cc: ...this.
* testsuite/25_algorithms/stable_partition/1.cc: ... and this.
* testsuite/25_algorithms/search/1.cc: Update from merge.
* testsuite/25_algorithms/search/check_type.cc: Same.
* testsuite/lib/dg-options.exp (dg-require-rvalref): New.
* testsuite/lib/libstdc++.exp (check_v3_target_rvalref): New.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@128990 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libstdc++-v3/testsuite/25_algorithms/reverse')
-rw-r--r-- | libstdc++-v3/testsuite/25_algorithms/reverse/moveable.cc | 45 |
1 files changed, 45 insertions, 0 deletions
diff --git a/libstdc++-v3/testsuite/25_algorithms/reverse/moveable.cc b/libstdc++-v3/testsuite/25_algorithms/reverse/moveable.cc new file mode 100644 index 00000000000..10577fc631b --- /dev/null +++ b/libstdc++-v3/testsuite/25_algorithms/reverse/moveable.cc @@ -0,0 +1,45 @@ +// { dg-do compile } +// { dg-require-rvalref "" } +// { dg-options "-std=gnu++0x" } + +// Copyright (C) 2005, 2007 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 2, 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 COPYING. If not, write to the Free +// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, +// USA. + +// 25.2.9 Reverse + +#undef _GLIBCXX_CONCEPT_CHECKS + +#include <algorithm> +#include <testsuite_iterators.h> + +using __gnu_test::bidirectional_iterator_wrapper; + +class X +{ + X(); + X(const X&); + void operator=(const X&); +}; + +void +swap(X&, X&) { } + +void +test1(bidirectional_iterator_wrapper<X>& begin, + bidirectional_iterator_wrapper<X>& end) +{ std::reverse(begin, end); } |