diff options
author | bkoz <bkoz@138bc75d-0d04-0410-961f-82ee72b054a4> | 2009-05-20 04:05:21 +0000 |
---|---|---|
committer | bkoz <bkoz@138bc75d-0d04-0410-961f-82ee72b054a4> | 2009-05-20 04:05:21 +0000 |
commit | 2b48700aa2898a4510cdf8423489b75c365cf6b0 (patch) | |
tree | dc0ad6d2d060b0ec8282bd5937aebdc5b82254b4 /libstdc++-v3/testsuite/23_containers/list/modifiers/swap/1.cc | |
parent | fffbaaf2c48cd01c8fa93e3ad84e1bec1120f06f (diff) | |
download | ppe42-gcc-2b48700aa2898a4510cdf8423489b75c365cf6b0.tar.gz ppe42-gcc-2b48700aa2898a4510cdf8423489b75c365cf6b0.zip |
2009-05-19 Benjamin Kosnik <bkoz@redhat.com>
* testsuite/23_containers/list/14340.cc: Abstract list type.
* testsuite/23_containers/list/init-list.cc: Same.
* testsuite/23_containers/list/pthread5.cc: Same.
* testsuite/23_containers/list/invalidation/1.cc: Same.
* testsuite/23_containers/list/invalidation/2.cc: Same.
* testsuite/23_containers/list/invalidation/3.cc: Same.
* testsuite/23_containers/list/invalidation/4.cc: Same.
* testsuite/23_containers/list/modifiers/insert/25288.cc: Same.
* testsuite/23_containers/list/modifiers/1.cc: Same.
* testsuite/23_containers/list/modifiers/2.cc: Same.
* testsuite/23_containers/list/modifiers/3.cc: Same.
* testsuite/23_containers/list/modifiers/swap/1.cc: Same.
* testsuite/23_containers/list/modifiers/swap/2.cc: Same.
* testsuite/23_containers/list/modifiers/swap/3.cc: Same.
* testsuite/23_containers/list/cons/1.cc: Same.
* testsuite/23_containers/list/cons/2.cc: Same.
* testsuite/23_containers/list/cons/3.cc: Same.
* testsuite/23_containers/list/cons/4.cc: Same.
* testsuite/23_containers/list/cons/5.cc: Same.
* testsuite/23_containers/list/cons/6.cc: Same.
* testsuite/23_containers/list/cons/7.cc: Same.
* testsuite/23_containers/list/cons/clear_allocator.cc: Same.
* testsuite/23_containers/list/cons/8.cc: Same.
* testsuite/23_containers/list/cons/9.cc: Same.
* testsuite/23_containers/list/operations/1.cc: Same.
* testsuite/23_containers/list/operations/2.cc: Same.
* testsuite/23_containers/list/operations/3.cc: Same.
* testsuite/23_containers/list/operations/4.cc: Same.
* testsuite/23_containers/list/operations/5.cc: Same.
* testsuite/23_containers/list/requirements/citerators.cc: Same.
* testsuite/23_containers/list/requirements/dr438/assign_neg.cc: Same.
* testsuite/23_containers/list/requirements/dr438/insert_neg.cc: Same.
* testsuite/23_containers/list/requirements/dr438/
constructor_1_neg.cc: Same.
* testsuite/23_containers/list/requirements/dr438/
constructor_2_neg.cc: Same.
* testsuite/23_containers/list/requirements/dr438/constructor.cc: Same.
* testsuite/23_containers/list/requirements/
partial_specialization/1.cc: Same.
* testsuite/23_containers/list/23781.cc: Same.
* testsuite/23_containers/list/pthread1.cc: Same.
* testsuite/23_containers/list/capacity/1.cc: Same.
* testsuite/23_containers/list/capacity/29134.cc: Same.
* testsuite/23_containers/list/check_construct_destroy.cc: Same.
* testsuite/23_containers/list/moveable.cc: Same.
* testsuite/util/common_type/assoc/common_type.hpp: Re-break lines.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@147728 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libstdc++-v3/testsuite/23_containers/list/modifiers/swap/1.cc')
-rw-r--r-- | libstdc++-v3/testsuite/23_containers/list/modifiers/swap/1.cc | 26 |
1 files changed, 17 insertions, 9 deletions
diff --git a/libstdc++-v3/testsuite/23_containers/list/modifiers/swap/1.cc b/libstdc++-v3/testsuite/23_containers/list/modifiers/swap/1.cc index ea37be032d7..c66ead57c76 100644 --- a/libstdc++-v3/testsuite/23_containers/list/modifiers/swap/1.cc +++ b/libstdc++-v3/testsuite/23_containers/list/modifiers/swap/1.cc @@ -31,23 +31,31 @@ namespace std } // Should use list specialization for swap. -void test01() +template<typename _Tp> +void +swap11() { bool test __attribute__((unused)) = true; - std::list<T> A; - std::list<T> B; + typedef _Tp list_type; + + list_type A; + list_type B; swap_calls = 0; std::swap(A, B); VERIFY(1 == swap_calls); } // Should use list specialization for swap. -void test02() +template<typename _Tp> +void +swap12() { - bool test __attribute__((unused)) = true; using namespace std; - list<T> A; - list<T> B; + bool test __attribute__((unused)) = true; + typedef _Tp list_type; + + list_type A; + list_type B; swap_calls = 0; swap(A, B); VERIFY(1 == swap_calls); @@ -60,7 +68,7 @@ template class __gnu_cxx::__mt_alloc<std::_List_node<T> >; // See c++/13658 for background info. int main() { - test01(); - test02(); + swap11<std::list<T> >(); + swap12<std::list<T> >(); return 0; } |