[libcxx-commits] [libcxx] [libc++] Allow for hardening in multiple categories (PR #79859)

via libcxx-commits libcxx-commits at lists.llvm.org
Mon Jan 29 08:44:42 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 7c8ef76500b40c3b7cb65b839b61345b713aeb5a f7ad5414b06bfea3471e92956de856c9059c1e96 -- libcxx/include/__config libcxx/include/__iterator/counted_iterator.h
``````````

</details>

<details>
<summary>
View the diff from clang-format here.
</summary>

``````````diff
diff --git a/libcxx/include/__iterator/counted_iterator.h b/libcxx/include/__iterator/counted_iterator.h
index 58f4317f0b..290fa5ca2f 100644
--- a/libcxx/include/__iterator/counted_iterator.h
+++ b/libcxx/include/__iterator/counted_iterator.h
@@ -229,7 +229,8 @@ public:
   _LIBCPP_HIDE_FROM_ABI constexpr decltype(auto) operator[](iter_difference_t<_Iter> __n) const
     requires random_access_iterator<_Iter>
   {
-    _LIBCPP_ASSERT_P(VALID_ELEMENT_ACCESS|VALID_PRECONDITIONS, __n < __count_, "Subscript argument must be less than size.");
+    _LIBCPP_ASSERT_P(
+        VALID_ELEMENT_ACCESS | VALID_PRECONDITIONS, __n < __count_, "Subscript argument must be less than size.");
     return __current_[__n];
   }
 

``````````

</details>


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


More information about the libcxx-commits mailing list