std.c: use linux.timerfd_clockid_t

This commit is contained in:
John Benediktsson 2025-02-02 10:16:59 -08:00 committed by Alex Rønne Petersen
parent 6a1b76a02c
commit d358ef804e

View File

@ -222,11 +222,12 @@ pub const ARCH = switch (native_os) {
// that actually work. // that actually work.
pub const TIMERFD_CLOCK = timerfd_clockid_t; pub const TIMERFD_CLOCK = timerfd_clockid_t;
pub const timerfd_clockid_t = switch (native_os) { pub const timerfd_clockid_t = switch (native_os) {
.linux, .freebsd => enum(u32) { .freebsd => enum(u32) {
REALTIME = 0, REALTIME = 0,
MONOTONIC = 1, MONOTONIC = 1,
_, _,
}, },
.linux => linux.timerfd_clockid_t,
else => clockid_t, else => clockid_t,
}; };