gcc/libstdc++-v3/testsuite/20_util
Ville Voutilainen a2863bde75 Implement LWG 2766,
Swapping non-swappable types and LWG 2749,
swappable traits for variants.
* include/bits/move.h (swap(_Tp&, _Tp&)): Constrain
with __is_tuple_like.
* include/bits/stl_pair.h (swap(pair<_T1, _T2>&, pair<_T1, _T2>&)):
Add a deleted overload.
* include/bits/unique_ptr.h
(swap(unique_ptr<_Tp, _Dp>&, unique_ptr<_Tp, _Dp>&)): Likewise.
* include/std/array
(swap(array<_Tp, _Nm>&, array<_Tp, _Nm>&)): Likewise.
* include/std/optional
(swap(optional<_Tp>&, optional<_Tp>&)): Likewise.
* include/std/tuple (__is_tuple_like_impl, __is_tuple_like):
Move to type_traits.
(swap(tuple<_Elements...>&, tuple<_Elements...>&)): Add a deleted
overload.
* include/std/type_traits (__is_tuple_like_impl, __is_tuple_like):
New.
(swap(_Tp&, _Tp&)): Constrain with __is_tuple_like.
* include/std/utility (__is_tuple_like_impl): Move to type_traits.
* include/std/variant
(swap(variant<_Types...>&, variant<_Types...>&)):
Add a deleted overload.
* testsuite/20_util/optional/swap/2.cc: Add tests for disabled
swaps.
* testsuite/20_util/pair/swap_cxx17.cc: New.
* testsuite/20_util/tuple/swap_cxx17.cc: Likewise.
* testsuite/20_util/unique_ptr/specialized_algorithms/swap_cxx17.cc:
Likewise.
* testsuite/20_util/variant/compile.cc: Add tests for disabled
swaps.
* testsuite/23_containers/array/specialized_algorithms/swap_cxx17.cc:
New.
* testsuite/23_containers/array/tuple_interface/get_neg.cc: Adjust.
* testsuite/23_containers/array/tuple_interface/tuple_element_neg.cc:
Likewise.

From-SVN: r243120
2016-12-01 18:23:21 +02:00
..
add_const Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
add_cv Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
add_lvalue_reference Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
add_pointer Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
add_rvalue_reference Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
add_volatile Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
addressof testsuite_hooks.h: Rewrite VERIFY in terms of __builtin_printf and __builtin_abort. 2016-10-12 16:13:06 +00:00
align testsuite_hooks.h: Rewrite VERIFY in terms of __builtin_printf and __builtin_abort. 2016-10-12 16:13:06 +00:00
aligned_storage Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
aligned_union Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
alignment_of Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
allocator PR78052 Define std::allocator<void>::{construct,destroy} 2016-10-20 11:13:10 +01:00
allocator_traits testsuite_hooks.h: Rewrite VERIFY in terms of __builtin_printf and __builtin_abort. 2016-10-12 16:13:06 +00:00
any Fix find&replace error in license boilerplate 2016-11-15 14:33:41 +00:00
as_const
auto_ptr Fix incorrect comment about std::auto_ptr 2016-10-19 19:18:43 +01:00
bad_function_call Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
bind Fix find&replace error in license boilerplate 2016-11-15 14:33:41 +00:00
bool_constant
common_type/requirements testsuite_hooks.h: Rewrite VERIFY in terms of __builtin_printf and __builtin_abort. 2016-10-12 16:13:06 +00:00
conditional/requirements Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
decay/requirements Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
declval/requirements re PR libstdc++/77395 (std::is_constructible is false for type constructible via implicit conversion operator affecting std::tuple) 2016-08-30 21:46:11 +03:00
default_delete Implement P0513R0, Poisoning the Hash. 2016-11-14 23:22:53 +02:00
duration Fix find&replace error in license boilerplate 2016-11-15 14:33:41 +00:00
duration_cast Replace non-constexpr decrement in std::chrono::floor 2016-10-13 15:42:09 +01:00
enable_if/requirements testsuite_hooks.h: Rewrite VERIFY in terms of __builtin_printf and __builtin_abort. 2016-10-12 16:13:06 +00:00
enable_shared_from_this Add more tests for enable_shared_from_this ambiguities 2016-10-20 11:13:04 +01:00
exchange testsuite_hooks.h: Rewrite VERIFY in terms of __builtin_printf and __builtin_abort. 2016-10-12 16:13:06 +00:00
extent Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
forward testsuite_hooks.h: Rewrite VERIFY in terms of __builtin_printf and __builtin_abort. 2016-10-12 16:13:06 +00:00
function testsuite_hooks.h: Rewrite VERIFY in terms of __builtin_printf and __builtin_abort. 2016-10-12 16:13:06 +00:00
function_objects Fix exception-specifications for std::_Not_fn 2016-10-13 11:19:24 +01:00
has_unique_object_representations Implement std::has_unique_object_representations 2016-10-07 19:02:43 +01:00
has_virtual_destructor Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
hash testsuite_hooks.h: Rewrite VERIFY in terms of __builtin_printf and __builtin_abort. 2016-10-12 16:13:06 +00:00
headers Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
in_place Fix find&replace error in license boilerplate 2016-11-15 14:33:41 +00:00
integer_sequence Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
integral_constant testsuite_hooks.h: Rewrite VERIFY in terms of __builtin_printf and __builtin_abort. 2016-10-12 16:13:06 +00:00
is_abstract Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_arithmetic Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_array Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_assignable Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_base_of Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_callable
is_class Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_compound Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_const Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_constructible re PR libstdc++/77395 (std::is_constructible is false for type constructible via implicit conversion operator affecting std::tuple) 2016-08-30 21:46:11 +03:00
is_convertible Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_copy_assignable Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_copy_constructible Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_default_constructible Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_destructible Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_empty Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_enum Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_final Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_floating_point Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_function testsuite_hooks.h: Rewrite VERIFY in terms of __builtin_printf and __builtin_abort. 2016-10-12 16:13:06 +00:00
is_fundamental Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_implicitly_default_constructible Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_integral Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_literal_type Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_lvalue_reference Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_member_function_pointer Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_member_object_pointer Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_member_pointer Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_move_assignable Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_move_constructible Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_nothrow_assignable Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_nothrow_callable
is_nothrow_constructible Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_nothrow_copy_assignable Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_nothrow_copy_constructible Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_nothrow_default_constructible Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_nothrow_destructible Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_nothrow_move_assignable Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_nothrow_move_constructible Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_nothrow_swappable Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_nothrow_swappable_with
is_null_pointer Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_object testsuite_hooks.h: Rewrite VERIFY in terms of __builtin_printf and __builtin_abort. 2016-10-12 16:13:06 +00:00
is_pod Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_pointer Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_polymorphic Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_reference Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_rvalue_reference Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_same Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_scalar Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_signed Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_standard_layout Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_swappable Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_swappable_with
is_trivial Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_trivially_assignable Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_trivially_constructible Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_trivially_copy_assignable Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_trivially_copy_constructible Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_trivially_copyable Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_trivially_default_constructible Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_trivially_destructible Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_trivially_move_assignable Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_trivially_move_constructible Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_union Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_unsigned Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_void Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
is_volatile Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
logical_traits
make_signed/requirements Improve various diagnostic issues. 2016-11-13 23:58:45 -05:00
make_unsigned/requirements Improve various diagnostic issues. 2016-11-13 23:58:45 -05:00
move Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
move_if_noexcept testsuite_hooks.h: Rewrite VERIFY in terms of __builtin_printf and __builtin_abort. 2016-10-12 16:13:06 +00:00
optional Implement LWG 2766, 2016-12-01 18:23:21 +02:00
owner_less testsuite_hooks.h: Rewrite VERIFY in terms of __builtin_printf and __builtin_abort. 2016-10-12 16:13:06 +00:00
pair Implement LWG 2766, 2016-12-01 18:23:21 +02:00
pointer_safety Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
pointer_traits Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
rank Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
ratio Fix find&replace error in license boilerplate 2016-11-15 14:33:41 +00:00
raw_storage_iterator libstdc++/51960 move-construction for raw_storage_iterator 2016-08-26 14:11:29 +01:00
reference_wrapper testsuite_hooks.h: Rewrite VERIFY in terms of __builtin_printf and __builtin_abort. 2016-10-12 16:13:06 +00:00
remove_all_extents Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
remove_const Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
remove_cv Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
remove_extent Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
remove_pointer Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
remove_reference Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
remove_volatile Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
result_of Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
scoped_allocator Avoid copies in std::scoped_allocator_adaptor piecewise construction 2016-10-14 17:12:21 +01:00
shared_ptr Add array support to std::shared_ptr for C++17 2016-11-13 22:57:45 +00:00
specialized_algorithms Avoid #include <functional> in other headers 2016-10-13 17:59:19 +01:00
steady_clock Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
system_clock Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
time_point testsuite_hooks.h: Rewrite VERIFY in terms of __builtin_printf and __builtin_abort. 2016-10-12 16:13:06 +00:00
time_point_cast Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
tuple Implement LWG 2766, 2016-12-01 18:23:21 +02:00
typeindex testsuite_hooks.h: Rewrite VERIFY in terms of __builtin_printf and __builtin_abort. 2016-10-12 16:13:06 +00:00
underlying_type/requirements Use effective-target instead of -std options 2016-08-26 12:41:37 +01:00
unique_ptr Implement LWG 2766, 2016-12-01 18:23:21 +02:00
uses_allocator Fix find&replace error in license boilerplate 2016-11-15 14:33:41 +00:00
variant Implement LWG 2766, 2016-12-01 18:23:21 +02:00
void_t
weak_ptr testsuite_hooks.h: Rewrite VERIFY in terms of __builtin_printf and __builtin_abort. 2016-10-12 16:13:06 +00:00
rel_ops.cc
temporary_buffer.cc testsuite_hooks.h: Rewrite VERIFY in terms of __builtin_printf and __builtin_abort. 2016-10-12 16:13:06 +00:00
variable_templates_for_traits.cc Fix find&replace error in license boilerplate 2016-11-15 14:33:41 +00:00