[clang] [clang] Add support for new loop attribute [[clang::code_align()]] (PR #70762)

Erich Keane via cfe-commits cfe-commits at lists.llvm.org
Wed Nov 1 10:18:10 PDT 2023


================
@@ -4280,3 +4280,12 @@ def PreferredType: InheritableAttr {
   let Args = [TypeArgument<"Type", 1>];
   let Documentation = [PreferredTypeDocumentation];
 }
+
+def CodeAlign: StmtAttr {
+  let Spellings = [CXX11<"clang", "code_align">,
+                   C23<"clang", "code_align">];
+  let Subjects = SubjectList<[ForStmt, CXXForRangeStmt, WhileStmt, DoStmt],
+                              ErrorDiag, "'for', 'while', and 'do' statements">;
+  let Args = [ExprArgument<"NExpr">];
----------------
erichkeane wrote:

This needs a more descriptive name

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


More information about the cfe-commits mailing list