stat(_:_:)
Calls the C stat() function.
Declaration
static func stat(_ path: UnsafePointer<CChar>, _ s: inout CInterop.Stat) -> Int32Parameters
- path:
A null-terminated C string representing the file path.
- s:
An
inoutreference to aCInterop.Statstruct to populate.
Return Value
0 on success, -1 on error (check Errno.current).
Discussion
This is a direct wrapper around the C stat() system call. For a more ergonomic Swift API, use Stat instead.