diff options
author | Jonathan Wakely <jwakely@redhat.com> | 2025-09-02 17:04:13 +0100 |
---|---|---|
committer | Jonathan Wakely <redi@gcc.gnu.org> | 2025-09-03 10:49:06 +0100 |
commit | 381dbd4a9564525d930737a790c9b7d31dfc181f (patch) | |
tree | 551cda518a27c1de4608efe538c2f3639515c614 /gcc/testsuite/gcc.dg/format/bitfld-1.c | |
parent | 9f94029829daf3b83bb95226dcfe003c5ddcade2 (diff) | |
download | gcc-381dbd4a9564525d930737a790c9b7d31dfc181f.zip gcc-381dbd4a9564525d930737a790c9b7d31dfc181f.tar.gz gcc-381dbd4a9564525d930737a790c9b7d31dfc181f.tar.bz2 |
libstdc++: Restore C++20 <chrono> support for old std::string ABI
The r16-3416-g806de30f51c8b9 change to use __cpp_lib_chrono in
preprocessor conditions broke support for <chrono> for freestanding and
the COW std::string ABI. That happened because __cpp_lib_chrono is only
defined to the C++20 value for hosted and for the new ABI, because the
full set of C++20 features are not defined for freestanding and tzdb is
not defined for the old ABI.
This introduces a new internal feature test macro that corresponds to
the features that are always supported (e.g. chrono::local_time,
chrono::year, chrono::weekday).
libstdc++-v3/ChangeLog:
* include/bits/version.def (chrono_cxx20): Define.
* include/bits/version.h: Regenerate.
* include/std/chrono: Check __glibcxx_chrono_cxx20 instead of
__cpp_lib_chrono for C++20 features that don't require the new
std::string ABI and/or can be used for freestanding.
* src/c++20/clock.cc: Adjust preprocessor condition.
Reviewed-by: Tomasz KamiĆski <tkaminsk@redhat.com>
Diffstat (limited to 'gcc/testsuite/gcc.dg/format/bitfld-1.c')
0 files changed, 0 insertions, 0 deletions