[libcxx-commits] [libcxx] [libc++][string] Fix unnecessary padding for basic_string's __short (PR #135973)

via libcxx-commits libcxx-commits at lists.llvm.org
Wed Apr 16 08:08:16 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 HEAD~1 HEAD --extensions  -- libcxx/include/string
``````````

</details>

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

``````````diff
diff --git a/libcxx/include/string b/libcxx/include/string
index c82cb5074..50bfe4422 100644
--- a/libcxx/include/string
+++ b/libcxx/include/string
@@ -819,7 +819,7 @@ private:
 
   struct __short {
     value_type __data_[__min_cap];
-    value_type : 0;
+    value_type               : 0;
     unsigned char __size_    : 7;
     unsigned char __is_long_ : 1;
   };

``````````

</details>


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


More information about the libcxx-commits mailing list