]> git.ipfire.org Git - thirdparty/gcc.git/commit
libstdc++: Adding missing feature-test macros for C++23 ranges algos
authorPatrick Palka <ppalka@redhat.com>
Tue, 18 Apr 2023 11:21:09 +0000 (07:21 -0400)
committerPatrick Palka <ppalka@redhat.com>
Tue, 18 Apr 2023 11:24:19 +0000 (07:24 -0400)
commit033560317078d2a3472f577cf8f39f6be1e9b343
treef305b6d203aead89d22e7808333ded0efb353891
parent4dc8c0b62d91d239b88cc81bbb8f4fbde317fde6
libstdc++: Adding missing feature-test macros for C++23 ranges algos

This patch also renames __cpp_lib_fold to __cpp_lib_ranges_fold
as per the current draft standard.

libstdc++-v3/ChangeLog:

* include/bits/ranges_algo.h (__cpp_lib_ranges_contains):
Define for C++23.
(__cpp_lib_ranges_iota): Likewise.
(__cpp_lib_ranges_find_last): Likewise.
(__cpp_lib_fold): Rename to ...
(__cpp_lib_ranges_fold): ... this.
* include/std/version: As above.
* testsuite/25_algorithms/fold_left/1.cc: Adjust after
renaming __cpp_lib_fold.
* testsuite/std/ranges/version_c++23.cc: Verify values
of the above feature-test macros.

(cherry picked from commit 95525c5b8c2d6317b693d441520b7bc808cf9ec7)
libstdc++-v3/include/bits/ranges_algo.h
libstdc++-v3/include/std/version
libstdc++-v3/testsuite/25_algorithms/fold_left/1.cc
libstdc++-v3/testsuite/std/ranges/version_c++23.cc