Skip to content

Instantly share code, notes, and snippets.

@lmllrjr
Created November 8, 2023 22:56
Show Gist options
  • Save lmllrjr/cad5148c1c16d6b9b94867fbcb474d01 to your computer and use it in GitHub Desktop.
Save lmllrjr/cad5148c1c16d6b9b94867fbcb474d01 to your computer and use it in GitHub Desktop.
const std = @import("std");
const time = std.time;
pub fn main() !void {
var timespec = std.os.timespec{
.tv_sec = 0,
.tv_nsec = 0,
};
std.debug.print("\n\n{any}\n\n", .{timespec});
try std.os.clock_gettime(std.os.CLOCK.REALTIME, &timespec);
std.debug.print("\n\n{any}\n\n", .{timespec});
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment