[libcxx-commits] [libcxx] [libc++] Require the exact assignment expression to be trivial in `__uninitialized_allocator_copy_impl` (PR #196648)

Yuxuan Chen via libcxx-commits libcxx-commits at lists.llvm.org
Sat May 9 10:51:40 PDT 2026


================
@@ -486,7 +486,7 @@ inline const bool __allocator_has_trivial_copy_construct_v<allocator<_Type>, _Ty
 template <class _Alloc,
           class _In,
           class _Out,
-          __enable_if_t<is_trivially_copy_constructible<_In>::value && is_trivially_copy_assignable<_In>::value &&
+          __enable_if_t<is_trivially_copy_constructible<_In>::value && is_trivially_assignable<_Out&, _In&>::value &&
----------------
yuxuanchen1997 wrote:

That should work too. Will update the patch. 

https://github.com/llvm/llvm-project/pull/196648


More information about the libcxx-commits mailing list