[llvm] [flang] Fix REAL(10)/COMPLEX(10) component sizes in runtime type info (PR #192049)
via llvm-commits
llvm-commits at lists.llvm.org
Tue Apr 14 08:13:05 PDT 2026
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 -- flang-rt/lib/runtime/type-info.cpp flang-rt/unittests/Runtime/Descriptor.cpp --diff_from_common_commit
``````````
: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/flang-rt/unittests/Runtime/Descriptor.cpp b/flang-rt/unittests/Runtime/Descriptor.cpp
index 92e73bc9e..fc7f266dd 100644
--- a/flang-rt/unittests/Runtime/Descriptor.cpp
+++ b/flang-rt/unittests/Runtime/Descriptor.cpp
@@ -291,7 +291,8 @@ TEST(Descriptor, BytesForRealAndComplex) {
EXPECT_EQ(Descriptor::BytesFor(TC::Real, 3), 2u);
EXPECT_EQ(Descriptor::BytesFor(TC::Real, 4), 4u);
EXPECT_EQ(Descriptor::BytesFor(TC::Real, 8), 8u);
- EXPECT_EQ(Descriptor::BytesFor(TC::Real, 10), 16u); // x87: 80-bit in 128-bit container
+ EXPECT_EQ(Descriptor::BytesFor(TC::Real, 10),
+ 16u); // x87: 80-bit in 128-bit container
EXPECT_EQ(Descriptor::BytesFor(TC::Real, 16), 16u);
// Complex kinds: should be twice the Real storage size
EXPECT_EQ(Descriptor::BytesFor(TC::Complex, 2), 4u);
``````````
</details>
https://github.com/llvm/llvm-project/pull/192049
More information about the llvm-commits
mailing list