[clang] [CLANG] Enable alignas after GNU attributes (PR #133107)

via cfe-commits cfe-commits at lists.llvm.org
Tue Apr 8 12:36:36 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 cpp,c,h -- clang/include/clang/Parse/Parser.h clang/lib/Parse/ParseDeclCXX.cpp clang/lib/Parse/ParseStmt.cpp clang/test/AST/ast-dump-color.cpp clang/test/Index/annotate-attribute.cpp clang/test/Parser/c2x-alignas.c clang/test/Parser/cxx0x-attributes.cpp clang/test/SemaCXX/warn-thread-safety-analysis.cpp
``````````

</details>

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

``````````diff
diff --git a/clang/lib/Parse/ParseStmt.cpp b/clang/lib/Parse/ParseStmt.cpp
index 5cfe06e2b..64d184695 100644
--- a/clang/lib/Parse/ParseStmt.cpp
+++ b/clang/lib/Parse/ParseStmt.cpp
@@ -235,8 +235,7 @@ Retry:
   }
 
   default: {
-    if (getLangOpts().CPlusPlus &&
-        MaybeParseCXX11Attributes(CXX11Attrs, true))
+    if (getLangOpts().CPlusPlus && MaybeParseCXX11Attributes(CXX11Attrs, true))
       goto Retry;
 
     bool HaveAttrs = !CXX11Attrs.empty() || !GNUAttrs.empty();

``````````

</details>


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


More information about the cfe-commits mailing list