lib/std: PermissionDenied/AccessDenied cleanup and fallout

This PR consistently maps .ACCES into AccessDenied and .PERM into
PermissionDenied.  AccessDenied is returned if the file mode bit
(user/group/other rwx bits) disallow access (errno was `EACCES`).
PermissionDenied is returned if something else denies access (errno was
`EPERM`) (immutable bit, SELinux, capabilities, etc).  This somewhat
subtle distinction is a POSIX thing.

Most of the change is updating std.posix Error Sets to contain both
errors, and then propagating the pair up through caller Error Sets.

Fixes #16782
14c046fc07Pat Tullmann committed on 3/24/2025, 3:20:45 PM· committed by Alex Rønne Petersenparent02373eb
7 files changedLine totals unavailable