From 7aed692cc30c2da0c6295842f5985ecbc17ed389 Mon Sep 17 00:00:00 2001 From: Brendan Hansen Date: Mon, 15 May 2023 13:11:33 -0500 Subject: [PATCH] bugfix: JavaScript runtime would not compile --- core/time/time.onyx | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/core/time/time.onyx b/core/time/time.onyx index b497a12d..da79a36e 100644 --- a/core/time/time.onyx +++ b/core/time/time.onyx @@ -1,7 +1,6 @@ package core.time use core -use core.os use core.io use core.string use core.conv @@ -53,7 +52,11 @@ Timestamp :: struct #size (sizeof u32 * 12) { now :: () -> Timestamp { - current_time := os.time(); + #if runtime.platform.Supports_Time { + current_time := runtime.platform.__time(); + } else { + current_time := 0; + } // // Localtime operates on seconds, while os.time -- 2.25.1