]> git.ipfire.org Git - thirdparty/gcc.git/commit
libstd++: Implement C++23 P2674R1 - A trait for implicit lifetime types
authorJakub Jelinek <jakub@redhat.com>
Thu, 30 Oct 2025 07:43:18 +0000 (08:43 +0100)
committerJakub Jelinek <jakub@gcc.gnu.org>
Thu, 30 Oct 2025 07:46:26 +0000 (08:46 +0100)
commitacdf675933d549f2fe2c89e4feabcf36e382b4f5
tree5410602e29b10b41a8f1f673078a6eda6514532b
parentbd9f3590a3912f0a3944e22ac5034d2488c3e0b2
libstd++: Implement C++23 P2674R1 - A trait for implicit lifetime types

The following patch attempts to implement the library side of the
C++23 P2674R1 paper.  As mentioned in the paper, since CWG2605
the trait isn't really implementable purely on the library side.

The compiler side has been committed earlier, so this just uses
the new builtin trait on the library side.

2025-10-30  Jakub Jelinek  <jakub@redhat.com>

* include/bits/version.def (is_implicit_lifetime): New.
* include/bits/version.h: Regenerate.
* include/std/type_traits (std::is_implicit_lifetime,
std::is_implicit_lifetime_v): New trait.
* src/c++23/std.cc.in (std::is_implicit_lifetime,
std::is_implicit_lifetime_v): Export.
* testsuite/20_util/is_implicit_lifetime/version.cc: New test.
* testsuite/20_util/is_implicit_lifetime/value.cc: New test.
libstdc++-v3/include/bits/version.def
libstdc++-v3/include/bits/version.h
libstdc++-v3/include/std/type_traits
libstdc++-v3/src/c++23/std.cc.in
libstdc++-v3/testsuite/20_util/is_implicit_lifetime/value.cc [new file with mode: 0644]
libstdc++-v3/testsuite/20_util/is_implicit_lifetime/version.cc [new file with mode: 0644]