void permissions(const path& p, perms prms, perm_options opts=perm_options::replace);
void permissions(const path& p, perms prms, error_code& ec) noexcept;
void permissions(const path& p, perms prms, perm_options opts, error_code& ec);
Remarks: The second signature behaves as if it had an additional parameter perm_options opts with an argument of perm_options::replace.
Effects: Applies the action specified by opts to the file p resolves to, or to file p itself if p is a symbolic link and perm_options::nofollow is set in opts. The action is applied as if by POSIX fchmodat().
[ Note: Conceptually permissions are viewed as bits, but the actual implementation may use some other mechanism. — end note ]
Throws: As specified in [fs.err.report].