[libcxx-commits] [libcxx] Lower std::string's alignment requirement from 16 to 8. (PR #68749)
via libcxx-commits
libcxx-commits at lists.llvm.org
Tue Oct 10 15:25:27 PDT 2023
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 3a6cc52fe3501b2b7b3aabdff305a18122c9e0db b28778923ab1e5ace7c0d534bce0a2c0de0deecc -- libcxx/test/libcxx/strings/basic.string/string.capacity/allocation_size.pass.cpp libcxx/test/libcxx/strings/basic.string/string.capacity/max_size.pass.cpp
``````````
</details>
<details>
<summary>
View the diff from clang-format here.
</summary>
``````````diff
diff --git a/libcxx/test/libcxx/strings/basic.string/string.capacity/allocation_size.pass.cpp b/libcxx/test/libcxx/strings/basic.string/string.capacity/allocation_size.pass.cpp
index 97714a118359..6260cbd92e17 100644
--- a/libcxx/test/libcxx/strings/basic.string/string.capacity/allocation_size.pass.cpp
+++ b/libcxx/test/libcxx/strings/basic.string/string.capacity/allocation_size.pass.cpp
@@ -23,7 +23,7 @@ constexpr std::size_t alignment =
#ifdef _LIBCPP_ABI_STRING_8_BYTE_ALIGNMENT
8;
#else
- 16;
+ 16;
#endif
int main(int, char**) {
diff --git a/libcxx/test/libcxx/strings/basic.string/string.capacity/max_size.pass.cpp b/libcxx/test/libcxx/strings/basic.string/string.capacity/max_size.pass.cpp
index 70aa8f7bda65..a3cb79522f2e 100644
--- a/libcxx/test/libcxx/strings/basic.string/string.capacity/max_size.pass.cpp
+++ b/libcxx/test/libcxx/strings/basic.string/string.capacity/max_size.pass.cpp
@@ -23,7 +23,7 @@ static const std::size_t alignment =
#ifdef _LIBCPP_ABI_STRING_8_BYTE_ALIGNMENT
8;
#else
- 16;
+ 16;
#endif
template <class = int>
``````````
</details>
https://github.com/llvm/llvm-project/pull/68749
More information about the libcxx-commits
mailing list