One Logo Pool Ball
System · IOS API REFERENCE

CInterop

enum · iOS 15.0+ · SDK 27.1

enum CInterop

A namespace for C and platform types

Members (1)

static · iOS 15.0+

stat

TypeScript
static stat(path: SDKHandle, s: SDKHandle): { $ret: number; $out: { "s": SDKHandle } }
Swift declaration
static func stat(_ path: UnsafePointer<CChar>, _ s: inout CInterop.Stat) -> Int32

Calls the C `stat()` function. This is a direct wrapper around the C `stat()` system call. For a more ergonomic Swift API, use `Stat` instead. - Warning: This API is primarily intended for migration purposes when supporting older deployment targets. If your deployment target supports it, prefer using the `Stat` API introduced in SYS-0006, which provides type-safe, ergonomic access to file metadata in Swift. - Parameters: - path: A null-terminated C string representing the file path. - s: An `inout` reference to a `CInterop.Stat` struct to populate. - Returns: 0 on success, -1 on error (check `Errno.current`).

Omit the output parameters from the call. The result contains $ret and $out, with s inside $out.

Skipped declarations

No declarations were skipped in this snapshot.

All System types →