[libcxx-commits] [PATCH] D147741: [libc++, std::vector] call the optimized version of __uninitialized_allocator_copy for trivial types

Aditya Kumar via Phabricator via libcxx-commits libcxx-commits at lists.llvm.org
Thu Apr 27 17:21:44 PDT 2023


hiraditya added inline comments.


================
Comment at: libcxx/include/__memory/uninitialized_algorithms.h:602
+_LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR_SINCE_CXX20 _Up*
+__uninitialized_allocator_copy_impl(_Alloc&, const _Type* __first1, const _Type* __last1, _Up* __first2) {
+  // TODO: Remove the const_cast once we drop support for std::allocator<T const>
----------------
this version gets called for test cases like `vector<const int>`


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D147741/new/

https://reviews.llvm.org/D147741



More information about the libcxx-commits mailing list