b6b6600678
This disables a use of dynamic_cast that is not valid for -fno-rtti and adjusts some tests so they don't FAIL with -fno-rtti. Some tests are skipped completely, and others just make use of typeid conditional on the __cpp_rtti macro. A couple of tests were using typeid to verify typedefs denote the right type, which can be done at compile-time using templates instead. libstdc++-v3/ChangeLog: * include/experimental/memory_resource [!__cpp_rtti] (__resource_adaptor_imp::do_is_equal): Do not use dynamic_cast when RTTI is disabled. * testsuite/17_intro/freestanding.cc: Require RTTI. * testsuite/18_support/exception/38732.cc: Likewise. * testsuite/18_support/exception_ptr/rethrow_exception.cc: Likewise. * testsuite/18_support/nested_exception/68139.cc: Likewise. * testsuite/18_support/nested_exception/rethrow_if_nested.cc: Likewise. * testsuite/18_support/type_info/103240.cc: Likewise. * testsuite/18_support/type_info/fundamental.cc: Likewise. * testsuite/18_support/type_info/hash_code.cc: Likewise. * testsuite/20_util/any/assign/emplace.cc: Likewise. * testsuite/20_util/any/cons/in_place.cc: Likewise. * testsuite/20_util/any/misc/any_cast.cc: Likewise. * testsuite/20_util/any/observers/type.cc: Likewise. * testsuite/20_util/function/1.cc: Likewise. * testsuite/20_util/function/2.cc: Likewise. * testsuite/20_util/function/3.cc: Likewise. * testsuite/20_util/function/4.cc: Likewise. * testsuite/20_util/function/5.cc: Likewise. * testsuite/20_util/function/6.cc: Likewise. * testsuite/20_util/function/7.cc: Likewise. * testsuite/20_util/function/8.cc: Likewise. * testsuite/20_util/polymorphic_allocator/resource.cc: Likewise. * testsuite/20_util/shared_ptr/casts/1.cc: Likewise. * testsuite/20_util/shared_ptr/casts/rval.cc: Likewise. * testsuite/20_util/shared_ptr/cons/unique_ptr_deleter_ref_2.cc: Likewise. * testsuite/20_util/shared_ptr/misc/get_deleter.cc: Likewise. * testsuite/20_util/typeindex/comparison_operators.cc: Likewise. * testsuite/20_util/typeindex/comparison_operators_c++20.cc: Likewise. * testsuite/20_util/typeindex/hash.cc: Likewise. * testsuite/20_util/typeindex/hash_code.cc: Likewise. * testsuite/20_util/typeindex/name.cc: Likewise. * testsuite/22_locale/ctype/is/string/89728_neg.cc: Likewise. * testsuite/22_locale/global_templates/standard_facet_hierarchies.cc: Likewise. * testsuite/22_locale/global_templates/user_facet_hierarchies.cc: Likewise. * testsuite/22_locale/locale/13630.cc: Check type without using RTTI. * testsuite/23_containers/array/requirements/non_default_constructible.cc: Require RTTI. * testsuite/27_io/basic_ostream/emit/1.cc: Likewise. * testsuite/27_io/fpos/14320-1.cc: Check type without using RTTI. * testsuite/27_io/fpos/mbstate_t/12065.cc: Require RTTI. * testsuite/27_io/ios_base/failure/dual_abi.cc: Likewise. * testsuite/experimental/any/misc/any_cast.cc: Likewise. * testsuite/experimental/any/observers/type.cc: Likewise. * testsuite/experimental/memory_resource/resource_adaptor.cc: Likewise. * testsuite/lib/libstdc++.exp (check_effective_target_rtti): Define new proc. * testsuite/tr1/3_function_objects/function/1.cc: Likewise. * testsuite/tr1/3_function_objects/function/2.cc: Likewise. * testsuite/tr1/3_function_objects/function/3.cc: Likewise. * testsuite/tr1/3_function_objects/function/4.cc: Likewise. * testsuite/tr1/3_function_objects/function/5.cc: Likewise. * testsuite/tr1/3_function_objects/function/6.cc: Likewise. * testsuite/tr1/3_function_objects/function/7.cc: Likewise. * testsuite/tr1/3_function_objects/function/8.cc: Likewise. * testsuite/tr2/bases/value.cc: Likewise. * testsuite/tr2/direct_bases/value.cc: Likewise. * testsuite/util/exception/safety.h [!__cpp_rtti]: Don't print types without RTTI. |
||
---|---|---|
.. | ||
add_const | ||
add_cv | ||
add_lvalue_reference | ||
add_pointer | ||
add_rvalue_reference | ||
add_volatile | ||
addressof | ||
align | ||
aligned_storage | ||
aligned_union | ||
alignment_of | ||
allocator | ||
allocator_traits | ||
any | ||
as_const | ||
assume_aligned | ||
auto_ptr | ||
bad_function_call | ||
bind | ||
bool_constant | ||
common_reference | ||
common_type/requirements | ||
conditional/requirements | ||
decay/requirements | ||
declval/requirements | ||
default_delete | ||
duration | ||
duration_cast | ||
enable_if/requirements | ||
enable_shared_from_this | ||
exchange | ||
expected | ||
extent | ||
forward | ||
from_chars | ||
function | ||
function_objects | ||
has_unique_object_representations | ||
has_virtual_destructor | ||
hash | ||
headers | ||
in_place | ||
integer_comparisons | ||
integer_sequence | ||
integral_constant | ||
invoke_result | ||
is_abstract | ||
is_aggregate | ||
is_arithmetic | ||
is_array | ||
is_assignable | ||
is_base_of | ||
is_bounded_array | ||
is_class | ||
is_complete_or_unbounded | ||
is_compound | ||
is_const | ||
is_constant_evaluated | ||
is_constructible | ||
is_convertible | ||
is_copy_assignable | ||
is_copy_constructible | ||
is_default_constructible | ||
is_destructible | ||
is_empty | ||
is_enum | ||
is_final | ||
is_floating_point | ||
is_function | ||
is_fundamental | ||
is_implicitly_default_constructible | ||
is_integral | ||
is_invocable | ||
is_layout_compatible | ||
is_literal_type | ||
is_lvalue_reference | ||
is_member_function_pointer | ||
is_member_object_pointer | ||
is_member_pointer | ||
is_move_assignable | ||
is_move_constructible | ||
is_nothrow_assignable | ||
is_nothrow_constructible | ||
is_nothrow_convertible | ||
is_nothrow_copy_assignable | ||
is_nothrow_copy_constructible | ||
is_nothrow_default_constructible | ||
is_nothrow_destructible | ||
is_nothrow_invocable | ||
is_nothrow_move_assignable | ||
is_nothrow_move_constructible | ||
is_nothrow_swappable | ||
is_nothrow_swappable_with | ||
is_null_pointer | ||
is_object | ||
is_pod | ||
is_pointer | ||
is_pointer_interconvertible | ||
is_polymorphic | ||
is_reference | ||
is_rvalue_reference | ||
is_same | ||
is_scalar | ||
is_scoped_enum | ||
is_signed | ||
is_standard_layout | ||
is_swappable | ||
is_swappable_with | ||
is_trivial | ||
is_trivially_assignable | ||
is_trivially_constructible | ||
is_trivially_copy_assignable | ||
is_trivially_copy_constructible | ||
is_trivially_copyable | ||
is_trivially_default_constructible | ||
is_trivially_destructible | ||
is_trivially_move_assignable | ||
is_trivially_move_constructible | ||
is_unbounded_array | ||
is_union | ||
is_unsigned | ||
is_void | ||
is_volatile | ||
logical_traits | ||
make_signed/requirements | ||
make_unsigned/requirements | ||
memory_resource | ||
monotonic_buffer_resource | ||
move | ||
move_if_noexcept | ||
move_only_function | ||
nonesuch | ||
optional | ||
owner_less | ||
pair | ||
pointer_safety | ||
pointer_traits | ||
polymorphic_allocator | ||
rank | ||
ratio | ||
raw_storage_iterator | ||
reference_wrapper | ||
remove_all_extents | ||
remove_const | ||
remove_cv | ||
remove_cvref | ||
remove_extent | ||
remove_pointer | ||
remove_reference | ||
remove_volatile | ||
result_of | ||
scoped_allocator | ||
shared_ptr | ||
specialized_algorithms | ||
steady_clock | ||
synchronized_pool_resource | ||
system_clock | ||
time_point | ||
time_point_cast | ||
to_address | ||
to_chars | ||
to_underlying | ||
tuple | ||
type_identity/requirements | ||
typeindex | ||
underlying_type/requirements | ||
unique_ptr | ||
unreachable | ||
unsynchronized_pool_resource | ||
unwrap_reference | ||
uses_allocator | ||
variant | ||
void_t | ||
weak_ptr | ||
rel_ops.cc | ||
temporary_buffer.cc | ||
variable_templates_for_traits.cc |