[llvm] b1cef93 - [gn] port bf17016a92bc (-gen-clang-diags-enums)

Nico Weber via llvm-commits llvm-commits at lists.llvm.org
Thu Jan 16 06:32:03 PST 2025


Author: Nico Weber
Date: 2025-01-16T09:31:35-05:00
New Revision: b1cef93917ba1b4825bac99c58057f92e7df0c4a

URL: https://github.com/llvm/llvm-project/commit/b1cef93917ba1b4825bac99c58057f92e7df0c4a
DIFF: https://github.com/llvm/llvm-project/commit/b1cef93917ba1b4825bac99c58057f92e7df0c4a.diff

LOG: [gn] port bf17016a92bc (-gen-clang-diags-enums)

Added: 
    

Modified: 
    llvm/utils/gn/secondary/clang/include/clang/Basic/BUILD.gn

Removed: 
    


################################################################################
diff  --git a/llvm/utils/gn/secondary/clang/include/clang/Basic/BUILD.gn b/llvm/utils/gn/secondary/clang/include/clang/Basic/BUILD.gn
index d8c4d8abdfd111..70af9760a858d6 100644
--- a/llvm/utils/gn/secondary/clang/include/clang/Basic/BUILD.gn
+++ b/llvm/utils/gn/secondary/clang/include/clang/Basic/BUILD.gn
@@ -40,6 +40,14 @@ foreach(diag_group, diag_groups) {
     ]
     td_file = "Diagnostic.td"
   }
+
+  clang_tablegen("Diagnostic${diag_group}Enums") {
+    args = [
+      "-gen-clang-diags-enums",
+      "-clang-component=${diag_group}",
+    ]
+    td_file = "Diagnostic.td"
+  }
 }
 group("diags_tablegen") {
   # DiagnosticGroups and DiagnosticIndexName are intentionally not part of this
@@ -47,7 +55,10 @@ group("diags_tablegen") {
   # but almost nothing needs DiagnosticGroups.inc or DiagnosticIndexName.inc.
   public_deps = []
   foreach(diag_group, diag_groups) {
-    public_deps += [ ":Diagnostic${diag_group}Kinds" ]
+    public_deps += [
+        ":Diagnostic${diag_group}Kinds",
+        ":Diagnostic${diag_group}Enums",
+    ]
   }
 }
 


        


More information about the llvm-commits mailing list