[libc-commits] [libc] [libc][docs] Add pwd.h POSIX header documentation (PR #186292)

Jeff Bailey via libc-commits libc-commits at lists.llvm.org
Fri May 1 06:32:58 PDT 2026


https://github.com/kaladron updated https://github.com/llvm/llvm-project/pull/186292

>From 37c8649a27f02e5b3f572c904f6e17652c43aa33 Mon Sep 17 00:00:00 2001
From: kovan <xaum.io at gmail.com>
Date: Fri, 13 Mar 2026 02:39:27 +0100
Subject: [PATCH] [libc][docs] Add pwd.h POSIX header documentation

Add YAML metadata for pwd.h listing all POSIX-mandated functions
(endpwent, getpwent, getpwnam, getpwnam_r, getpwuid, getpwuid_r,
setpwent). This header defines no macros per POSIX.

Add pwd to index.rst and CMakeLists.txt docgen_list.

Partial fix for #122006
---
 libc/docs/CMakeLists.txt    |  1 +
 libc/docs/headers/index.rst |  1 +
 libc/utils/docgen/pwd.yaml  | 15 +++++++++++++++
 3 files changed, 17 insertions(+)
 create mode 100644 libc/utils/docgen/pwd.yaml

diff --git a/libc/docs/CMakeLists.txt b/libc/docs/CMakeLists.txt
index b739c494dbe92..57810bca70a6a 100644
--- a/libc/docs/CMakeLists.txt
+++ b/libc/docs/CMakeLists.txt
@@ -56,6 +56,7 @@ if (SPHINX_FOUND)
       net/if
       netinet/in
       pthread
+      pwd
       setjmp
       signal
       stdbit
diff --git a/libc/docs/headers/index.rst b/libc/docs/headers/index.rst
index b77a54f9609ad..daeed00016050 100644
--- a/libc/docs/headers/index.rst
+++ b/libc/docs/headers/index.rst
@@ -22,6 +22,7 @@ Implementation Status
    math/index.rst
    net/if
    netinet/in
+   pwd
    search
    setjmp
    signal
diff --git a/libc/utils/docgen/pwd.yaml b/libc/utils/docgen/pwd.yaml
new file mode 100644
index 0000000000000..156a663c8c5e8
--- /dev/null
+++ b/libc/utils/docgen/pwd.yaml
@@ -0,0 +1,15 @@
+functions:
+  endpwent:
+    in-latest-posix: ''
+  getpwent:
+    in-latest-posix: ''
+  getpwnam:
+    in-latest-posix: ''
+  getpwnam_r:
+    in-latest-posix: ''
+  getpwuid:
+    in-latest-posix: ''
+  getpwuid_r:
+    in-latest-posix: ''
+  setpwent:
+    in-latest-posix: ''



More information about the libc-commits mailing list