[libcxx-commits] [libcxx] [libc++] Optimize ranges::fill{, _n} for vector<bool>::iterator (PR #84642)
via libcxx-commits
libcxx-commits at lists.llvm.org
Sat Mar 9 09:27:25 PST 2024
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 92d7aca441e09c85ab9355f99f93f3dbc35924a0 a85183edea154e15aeaf4f2375839f3d3df59d7c -- libcxx/benchmarks/algorithms/fill.bench.cpp libcxx/include/__algorithm/fill_n.h libcxx/include/__bit_reference libcxx/test/std/algorithms/alg.modifying.operations/alg.fill/fill.pass.cpp
``````````
</details>
<details>
<summary>
View the diff from clang-format here.
</summary>
``````````diff
diff --git a/libcxx/test/std/algorithms/alg.modifying.operations/alg.fill/fill.pass.cpp b/libcxx/test/std/algorithms/alg.modifying.operations/alg.fill/fill.pass.cpp
index 7960483104..8aa6356577 100644
--- a/libcxx/test/std/algorithms/alg.modifying.operations/alg.fill/fill.pass.cpp
+++ b/libcxx/test/std/algorithms/alg.modifying.operations/alg.fill/fill.pass.cpp
@@ -76,8 +76,8 @@ TEST_CONSTEXPR_CXX20 bool test() {
{ // partial byte in the front and back is not filled
std::vector<bool> in(16, false);
std::vector<bool> expected(16, true);
- expected[0] = false;
- expected[1] = false;
+ expected[0] = false;
+ expected[1] = false;
expected[14] = false;
expected[15] = false;
std::fill(in.begin() + 2, in.end() - 2, true);
``````````
</details>
https://github.com/llvm/llvm-project/pull/84642
More information about the libcxx-commits
mailing list