[all-commits] [llvm/llvm-project] 45d493: [libc++] Add the __is_replaceable type trait (#132...
Louis Dionne via All-commits
all-commits at lists.llvm.org
Thu May 8 13:35:22 PDT 2025
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 45d493b680e3e79e4e9c19d665df83823c52a73a
https://github.com/llvm/llvm-project/commit/45d493b680e3e79e4e9c19d665df83823c52a73a
Author: Louis Dionne <ldionne.2 at gmail.com>
Date: 2025-05-08 (Thu, 08 May 2025)
Changed paths:
M libcxx/include/CMakeLists.txt
M libcxx/include/__exception/exception_ptr.h
M libcxx/include/__expected/expected.h
M libcxx/include/__locale
M libcxx/include/__memory/shared_ptr.h
M libcxx/include/__memory/unique_ptr.h
M libcxx/include/__split_buffer
A libcxx/include/__type_traits/is_replaceable.h
M libcxx/include/__utility/pair.h
M libcxx/include/__vector/vector.h
M libcxx/include/array
M libcxx/include/deque
M libcxx/include/module.modulemap.in
M libcxx/include/optional
M libcxx/include/string
M libcxx/include/tuple
M libcxx/include/variant
A libcxx/test/libcxx/type_traits/is_replaceable.compile.pass.cpp
Log Message:
-----------
[libc++] Add the __is_replaceable type trait (#132408)
That type trait represents whether move-assigning an object is
equivalent to destroying it and then move-constructing a new one from
the same argument. This will be useful in a few places where we may want
to destroy + construct instead of doing an assignment, in particular
when implementing some container operations in terms of relocation.
This is effectively adding a library emulation of P2786R12's
is_replaceable trait, similarly to what we do for trivial relocation.
Eventually, we can replace this library emulation by the real
compiler-backed trait.
This is building towards #129328.
To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications
More information about the All-commits
mailing list