[libc-commits] [libc] [libc] Add -Werror for libc tests (PR #160413)

via libc-commits libc-commits at lists.llvm.org
Sat Sep 27 18:18:06 PDT 2025


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 -- libc/test/src/math/exhaustive/bfloat16_sub_test.cpp libc/test/src/stdio/fileop_test.cpp
``````````

: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/libc/test/src/math/exhaustive/bfloat16_sub_test.cpp b/libc/test/src/math/exhaustive/bfloat16_sub_test.cpp
index c3d0d5c3b..350af5293 100644
--- a/libc/test/src/math/exhaustive/bfloat16_sub_test.cpp
+++ b/libc/test/src/math/exhaustive/bfloat16_sub_test.cpp
@@ -23,8 +23,9 @@ struct Bfloat16SubChecker : public virtual LIBC_NAMESPACE::testing::Test {
   using FPBits = LIBC_NAMESPACE::fputil::FPBits<bfloat16>;
   using StorageType = typename FPBits::StorageType;
 
-  uint64_t check(uint16_t x_start, uint16_t x_stop, [[maybe_unused]] uint16_t y_start,
-                 uint16_t y_stop, mpfr::RoundingMode rounding) {
+  uint64_t check(uint16_t x_start, uint16_t x_stop,
+                 [[maybe_unused]] uint16_t y_start, uint16_t y_stop,
+                 mpfr::RoundingMode rounding) {
     mpfr::ForceRoundingMode r(rounding);
     if (!r.success)
       return true;

``````````

</details>


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


More information about the libc-commits mailing list