[libc-commits] [libc] [libc] Refactor sysinfo (PR #221498)
Alexey Samsonov via libc-commits
libc-commits at lists.llvm.org
Mon Sep 7 16:05:17 PDT 2026
vonosmas wrote:
I believe we should keep setting errno in our implementation, as other major libc implementations on Linux do that.
The fact that it's not explicitly mentioned in the Linux man pages is likely due to the fact that it's a legacy(-ish) BSD extension, not mentioned in POSIX, and Linux man pages might not want to promise / document / encode particular behavior, which would often be implementation-specific.
I wouldn't necessarily call this a defect, given that programmer, in general, can't assume that errno would *not* be modified by the library function call unless it's explicitly promised in the docs.
https://github.com/llvm/llvm-project/pull/221498
More information about the libc-commits
mailing list