[clang] [clang] Implement CWG2759 "`[[no_unique_address]` and common initial sequence" (PR #82607)

via cfe-commits cfe-commits at lists.llvm.org
Thu Feb 22 07:09:15 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 fde344aef20bc4280f01294ac6e14a5c2db2d572 263468bd571a274125883cdc3acb4c4b73c6d908 -- clang/lib/Sema/SemaChecking.cpp clang/test/CXX/drs/dr27xx.cpp clang/test/SemaCXX/cxx2a-ms-no-unique-address.cpp clang/test/SemaCXX/type-traits.cpp
``````````

</details>

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

``````````diff
diff --git a/clang/lib/Sema/SemaChecking.cpp b/clang/lib/Sema/SemaChecking.cpp
index 3414127394..7ee46df063 100644
--- a/clang/lib/Sema/SemaChecking.cpp
+++ b/clang/lib/Sema/SemaChecking.cpp
@@ -19034,7 +19034,7 @@ static bool isLayoutCompatible(ASTContext &C, FieldDecl *Field1,
   }
 
   if (Field1->hasAttr<clang::NoUniqueAddressAttr>() ||
-      Field2->hasAttr<clang::NoUniqueAddressAttr>()) 
+      Field2->hasAttr<clang::NoUniqueAddressAttr>())
     return false;
   return true;
 }

``````````

</details>


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


More information about the cfe-commits mailing list