[Bug 255374] C++20 features (headers) std::concepts, std::format, std::numbers, std::source_location, etc. are missing

From: <bugzilla-noreply_at_freebsd.org>
Date: Mon, 03 Apr 2023 22:18:01 UTC
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=255374

--- Comment #20 from Mark Millard <marklmi26-fbsd@yahoo.com> ---
(In reply to Mark Millard from comment #19)

I took a stab at trying to use the __cpp_lib_... library
feature test macros for -std=c++20 for the FreeBSD
system clang++ (c++) vs. modern definitions. The lines
with "------" mean that no definition was present.
To the right is is the modern year/month date for the
most recent change in the value for the feature test
macro in question just based on the standards.

Sometimes there are multiple comparisons points from
the standard versions noted via separate lines.
Unfortunately, it is not always obvious if a "(C++23)"
line had some prior language standard definition as well:
the multiple comparison points are likely rather
incomplete. Also, this is subject to errors in the
reference material that I used: I've not validated
that material.

The "(DR)" lines are for where the standards folks
fixed definitions with the intent of updating the
earlier mistake, and so were not just making a new
definition for a new standard: retroactive. Again,
completeness may be an issue.

The differences I got vs modern were:

__cpp_lib_adaptor_iterator_pair_constructor  ------ 202106 (C++23)
__cpp_lib_algorithm_iterator_requirements    ------ 202207 (C++23)
__cpp_lib_allocate_at_least                  ------ 202106 (C++23)
__cpp_lib_associative_heterogeneous_erasure  ------ 202110 (C++23)
__cpp_lib_atomic_float                       ------ 201711 (C++20)
__cpp_lib_atomic_ref                         ------ 201806 (C++20)
__cpp_lib_atomic_shared_ptr                  ------ 201711 (C++20)
__cpp_lib_bind_back                          ------ 202202 (C++23)
__cpp_lib_bitops                             ------ 201907 (C++20)
__cpp_lib_byteswap                           ------ 202110 (C++23)
__cpp_lib_chrono                             201611 201907 (C++20)
__cpp_lib_concepts                           202002 202207 (C++23)
__cpp_lib_constexpr_bitset                   ------ 202207 (C++23)
__cpp_lib_constexpr_charconv                 ------ 202207 (C++23)
__cpp_lib_constexpr_cmath                    ------ 202202 (C++23)
__cpp_lib_constexpr_complex                  ------ 201711 (C++20)
__cpp_lib_constexpr_memory                   201811 202202 (C++23)
__cpp_lib_constexpr_typeinfo                 ------ 202106 (C++23)
__cpp_lib_constexpr_vector                   ------ 201907 (C++20)
__cpp_lib_containers_ranges                  ------ 202202 (C++23)
__cpp_lib_execution                          ------ 201603 (C++17)
__cpp_lib_execution                          ------ 201902 (C++20)
__cpp_lib_expected                           ------ 202202 (C++23)
__cpp_lib_expected                           ------ 202211 (C++23)
__cpp_lib_find_last                          ------ 202207 (C++23)
__cpp_lib_flat_map                           ------ 202207 (C++23)
__cpp_lib_flat_set                           ------ 202207 (C++23)
__cpp_lib_format                             ------ 201907 (C++20)
__cpp_lib_format                             ------ 202106 (C++20) (DR)
__cpp_lib_format                             ------ 202110 (C++20) (DR)
__cpp_lib_format                             ------ 202207 (C++23)
__cpp_lib_format_ranges                      ------ 202207 (C++23)
__cpp_lib_forward_like                       ------ 202207 (C++23)
__cpp_lib_generator                          ------ 202207 (C++23)
__cpp_lib_hardware_interference_size         ------ 201703 (C++17)
__cpp_lib_invoke_r                           ------ 202106 (C++23)
__cpp_lib_ios_noreplace                      ------ 202207 (C++23)
__cpp_lib_is_implicit_lifetime               ------ 202302 (C++23)
__cpp_lib_is_layout_compatible               ------ 201907 (C++20)
__cpp_lib_is_pointer_interconvertible        ------ 201907 (C++20)
__cpp_lib_is_scoped_enum                     ------ 202011 (C++23)
__cpp_lib_jthread                            ------ 201911 (C++20)
__cpp_lib_math_special_functions             ------ 201603 (C++17)
__cpp_lib_mdspan                             ------ 202207 (C++23)
__cpp_lib_memory_resource                    ------ 201603 (C++17)
__cpp_lib_modules                            ------ 202207 (C++23)
__cpp_lib_move_iterator_concept              ------ 202207 (C++23)
__cpp_lib_move_only_function                 ------ 202110 (C++23)
__cpp_lib_optional                           201606 202106 (C++20) (DR)
__cpp_lib_optional                           201606 202110 (C++23)
__cpp_lib_out_ptr                            ------ 202106 (C++23)
__cpp_lib_parallel_algorithm                 ------ 201603 (C++17)
__cpp_lib_polymorphic_allocator              ------ 201902 (C++20)
__cpp_lib_print                              ------ 202207 (C++23)
__cpp_lib_ranges                             ------ 201911 (C++20)
__cpp_lib_ranges                             ------ 202106 (C++20) (DR)
__cpp_lib_ranges                             ------ 202110 (C++20) (DR)
__cpp_lib_ranges                             ------ 202202 (C++23)
__cpp_lib_ranges                             ------ 202207 (C++23)
__cpp_lib_ranges                             ------ 202211 (C++23)
__cpp_lib_ranges_as_const                    ------ 202207 (C++23)
__cpp_lib_ranges_as_rvalue                   ------ 202207 (C++23)
__cpp_lib_ranges_cartesian_product           ------ 202207 (C++23)
__cpp_lib_ranges_chunk                       ------ 202202 (C++23)
__cpp_lib_ranges_chunk_by                    ------ 202202 (C++23)
__cpp_lib_ranges_contains                    ------ 202207 (C++23)
__cpp_lib_ranges_enumerate                   ------ 202303 (C++23)
__cpp_lib_ranges_fold                        ------ 202207 (C++23)
__cpp_lib_ranges_iota                        ------ 202202 (C++23)
__cpp_lib_ranges_join_with                   ------ 202202 (C++23)
__cpp_lib_ranges_repeat                      ------ 202207 (C++23)
__cpp_lib_ranges_slide                       ------ 202202 (C++23)
__cpp_lib_ranges_starts_ends_with            ------ 202106 (C++23)
__cpp_lib_ranges_stride                      ------ 202207 (C++23)
__cpp_lib_ranges_to_container                ------ 202202 (C++23)
__cpp_lib_ranges_zip                         ------ 202110 (C++23)
__cpp_lib_reference_from_temporary           ------ 202202 (C++23)
__cpp_lib_shift                              201806 202202 (C++23)
__cpp_lib_smart_ptr_for_overwrite            ------ 202002 (C++20)
__cpp_lib_source_location                    ------ 201907 (C++20)
__cpp_lib_spanstream                         ------ 202106 (C++23)
__cpp_lib_stacktrace                         ------ 202011 (C++23)
__cpp_lib_start_lifetime_as                  ------ 202207 (C++23)
__cpp_lib_stdatomic_h                        ------ 202011 (C++23)
__cpp_lib_string_contains                    ------ 202011 (C++23)
__cpp_lib_string_resize_and_overwrite        ------ 202110 (C++23)
__cpp_lib_syncbuf                            ------ 201803 (C++20)
__cpp_lib_three_way_comparison               ------ 201907 (C++20)
__cpp_lib_to_chars                           ------ 201611 (C++17)
__cpp_lib_to_underlying                      ------ 202102 (C++23)
__cpp_lib_tuple_like                         ------ 202207 (C++23)
__cpp_lib_unreachable                        ------ 202202 (C++23)
__cpp_lib_variant                            202102 202106 (C++20) (DR)


This was for:

# uname -apKU
FreeBSD CA72_16Gp_ZFS 14.0-CURRENT FreeBSD 14.0-CURRENT #90
main-n261544-cee09bda03c8-dirty: Wed Mar 15 20:25:49 PDT 2023    
root@CA72_16Gp_ZFS:/usr/obj/BUILDs/main-CA72-nodbg-clang/usr/main-src/arm64.aarch64/sys/GENERIC-NODBG-CA72
arm64 aarch64 1400082 1400082

I will note that the results for the likes of devel/llvm16 are the
same because of the implicit use of the system's libc++ .

-- 
You are receiving this mail because:
You are on the CC list for the bug.