[libc-commits] [libc] [libc][docs] Updates implementation status for some preexisting docgen json files (PR #89281)

Nick Desaulniers via libc-commits libc-commits at lists.llvm.org
Thu Apr 18 13:14:27 PDT 2024


================
@@ -1,29 +1,56 @@
 {
-  "macros": [
-    "SIG_DFL",
-    "SIG_ERR",
-    "SIG_IGN",
-    "SIGABRT",
-    "SIGFPE",
-    "SIGILL",
-    "SIGINT",
-    "SIGSEGV",
-    "SIGTERM"
-  ],
+  "macros": {
+    "SIG_DFL": {
+      "defined": "7.14.3",
+      "implemented": false
+    },
+    "SIG_ERR": {
+      "defined": "7.14.3",
+      "implemented": false
+    },
+    "SIG_IGN": {
+      "defined": "7.14.3",
+      "implemented": false
+    },
+    "SIGABRT": {
+      "defined": "7.14.3",
+      "implemented": true
+    },
+    "SIGFPE": {
+      "defined": "7.14.3",
+      "implemented": true
+    },
+    "SIGILL": {
+      "defined": "7.14.3",
+      "implemented": true
+    },
+    "SIGINT": {
+      "defined": "7.14.3",
+      "implemented": true
+    },
+    "SIGSEGV": {
+      "defined": "7.14.3",
+      "implemented": true
+    },
+    "SIGTERM": {
+      "defined": "7.14.3",
+      "implemented": true
+    }
+  },
   "functions": {
+    "signal": {
+      "defined": "7.14.1.1"
+    },
+    "raise": {
+      "defined": "7.14.2.1"
+    },
----------------
nickdesaulniers wrote:

> I thought the current sorting in the generated rst docs was on purpose, there is an [explicit sort on function names](https://github.com/llvm/llvm-project/blob/22cd7f28164543895eef245b30348427a379a7be/libc/utils/docgen/docgen.py#L47).

Oh, that's right. I wrote that.  Either way, I don't have my heart set on that.  What's more important to me is that we maintain some form of determinism in output in case folks decide to re-arrange the order of things in json.  Though maybe we just keep the json sorted (painful) and rely on that ordering.  Personally, I think it'll be easier to enforce the ordering if the tool just sorts every time, then we can add new stuff to the json in any order.

> Another ordering to take into account, that does bug me a bit, is the ordering of the listed headers in the left side bar on libc.llvm.org

heh, I was just talking with @dpxf about that.  yeah it's ugly and will grow to be unwieldy very quickly.  I'd like to have one tab, that links to a newly created page, that lists each header we provide, which is a link to the corresponding page.

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


More information about the libc-commits mailing list