[libcxx-commits] [libcxx] [libc++] Optimize vector growth for nothrow move constructible types (PR #214690)
via libcxx-commits
libcxx-commits at lists.llvm.org
Fri Aug 7 03:45:53 PDT 2026
github-actions[bot] wrote:
<!--LLVM CODE FORMAT COMMENT: {clang-format}-->
:warning: C/C++ code formatter, clang-format found issues in your code. :warning:
<details>
<summary>
You can test this locally with the following command:
</summary>
``````````bash
git-clang-format --diff origin/main HEAD --extensions cpp,h -- libcxx/include/__memory/uninitialized_algorithms.h libcxx/test/benchmarks/containers/sequence/vector.bench.cpp --diff_from_common_commit
``````````
:warning:
The reproduction instructions above might return results for more than one PR
in a stack if you are using a stacked PR workflow. You can limit the results by
changing `origin/main` to the base branch/commit you want to compare against.
:warning:
</details>
<details>
<summary>
View the diff from clang-format here.
</summary>
``````````diff
diff --git a/libcxx/include/__memory/uninitialized_algorithms.h b/libcxx/include/__memory/uninitialized_algorithms.h
index 9c48c8eaf..425ef5425 100644
--- a/libcxx/include/__memory/uninitialized_algorithms.h
+++ b/libcxx/include/__memory/uninitialized_algorithms.h
@@ -405,7 +405,7 @@ _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR_SINCE_CXX14 void __uninitialized_allocat
static_assert(
__is_cpp17_move_insertable_v<_Alloc>, "The specified type does not meet the requirements of Cpp17MoveInsertable");
- using __value_type = typename iterator_traits<_ContiguousIterator>::value_type;
+ using __value_type = typename iterator_traits<_ContiguousIterator>::value_type;
if _LIBCPP_CONSTEXPR (__allocator_has_trivial_move_construct_v<_Alloc, __value_type> &&
__allocator_has_trivial_destroy_v<_Alloc, __value_type> &&
``````````
</details>
https://github.com/llvm/llvm-project/pull/214690
More information about the libcxx-commits
mailing list