[libcxx-commits] [libcxx] [libc++] Add missing iterator requirement checks in the PSTL (PR #88127)
via libcxx-commits
libcxx-commits at lists.llvm.org
Tue Apr 9 07:01:36 PDT 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 d022f6b8ff94bb13d12d39f23a3c3e7836e90756 b039aeea5d756a03ad39ec04aaa3985cfd43a55a -- libcxx/test/std/algorithms/pstl.iterator-constraints.verify.cpp libcxx/include/__algorithm/pstl_any_all_none_of.h libcxx/include/__algorithm/pstl_copy.h libcxx/include/__algorithm/pstl_count.h libcxx/include/__algorithm/pstl_equal.h libcxx/include/__algorithm/pstl_fill.h libcxx/include/__algorithm/pstl_find.h libcxx/include/__algorithm/pstl_for_each.h libcxx/include/__algorithm/pstl_generate.h libcxx/include/__algorithm/pstl_is_partitioned.h libcxx/include/__algorithm/pstl_merge.h libcxx/include/__algorithm/pstl_move.h libcxx/include/__algorithm/pstl_replace.h libcxx/include/__algorithm/pstl_rotate_copy.h libcxx/include/__algorithm/pstl_sort.h libcxx/include/__algorithm/pstl_stable_sort.h libcxx/include/__algorithm/pstl_transform.h libcxx/include/__iterator/cpp17_iterator_concepts.h libcxx/test/libcxx/algorithms/cpp17_iterator_concepts.verify.cpp libcxx/test/support/test_iterators.h
``````````
</details>
<details>
<summary>
View the diff from clang-format here.
</summary>
``````````diff
diff --git a/libcxx/test/support/test_iterators.h b/libcxx/test/support/test_iterators.h
index e2a3c2cdae..aa819ecd47 100644
--- a/libcxx/test/support/test_iterators.h
+++ b/libcxx/test/support/test_iterators.h
@@ -1508,9 +1508,7 @@ public:
return iter;
}
- friend Derived operator+(difference_type i, Derived iter) {
- return iter + i;
- }
+ friend Derived operator+(difference_type i, Derived iter) { return iter + i; }
friend bool operator==(const iterator_wrapper& lhs, const iterator_wrapper& rhs) { return lhs.iter_ == rhs.iter_; }
friend bool operator!=(const iterator_wrapper& lhs, const iterator_wrapper& rhs) { return lhs.iter_ != rhs.iter_; }
``````````
</details>
https://github.com/llvm/llvm-project/pull/88127
More information about the libcxx-commits
mailing list