DoxigAlpha

isGetFdPathSupportedOnTarget

Function parameters

Parameters

#
os:std.Target.Os

Type definitions in this namespace

Types

#

Call from Windows-specific code if you already have a WTF-16LE encoded, null terminated string.

Functions

#
accessW
Call from Windows-specific code if you already have a WTF-16LE encoded, null terminated string.
getFdPath
Return canonical path of handle `fd`.
fstatat_wasi
WASI-only.

See also `getenv`.

Values

#
environ
See also `getenv`.
argv
Populated by startup code before main().

Source

Implementation

#
pub fn isGetFdPathSupportedOnTarget(os: std.Target.Os) bool {
    return switch (os.tag) {
        .windows,
        .macos,
        .ios,
        .watchos,
        .tvos,
        .visionos,
        .linux,
        .solaris,
        .illumos,
        .freebsd,
        .serenity,
        => true,

        .dragonfly => os.version_range.semver.max.order(.{ .major = 6, .minor = 0, .patch = 0 }) != .lt,
        .netbsd => os.version_range.semver.max.order(.{ .major = 10, .minor = 0, .patch = 0 }) != .lt,
        else => false,
    };
}