[libcxx-commits] [libcxx] [libc++][hardening] Add a bounds check for `valarray` and `bitset`. (PR #120685)
via libcxx-commits
libcxx-commits at lists.llvm.org
Thu Dec 19 22:34:37 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 918d4558b0bad366ecadd411ed48cf64728c68d7 25114892fa1dd0c61f660536ba908223d46d01c7 --extensions cpp, -- libcxx/test/libcxx/numerics/numarray/assert.pass.cpp libcxx/test/libcxx/utilities/template.bitset/assert.abi-v1.pass.cpp libcxx/test/libcxx/utilities/template.bitset/assert.abi-v2.pass.cpp libcxx/include/bitset libcxx/include/valarray
``````````
</details>
<details>
<summary>
View the diff from clang-format here.
</summary>
``````````diff
diff --git a/libcxx/include/bitset b/libcxx/include/bitset
index b8c31d5ddd..df9fdfe6dd 100644
--- a/libcxx/include/bitset
+++ b/libcxx/include/bitset
@@ -132,8 +132,8 @@ template <size_t N> struct hash<std::bitset<N>>;
# include <__algorithm/fill.h>
# include <__algorithm/fill_n.h>
# include <__algorithm/find.h>
-# include <__bit_reference>
# include <__assert>
+# include <__bit_reference>
# include <__config>
# include <__functional/hash.h>
# include <__functional/unary_function.h>
``````````
</details>
https://github.com/llvm/llvm-project/pull/120685
More information about the libcxx-commits
mailing list