From 1f052da0b91abbbe102a6e858b2b393f7a307c17 Mon Sep 17 00:00:00 2001 From: Christoffer Lerno Date: Fri, 16 Feb 2024 21:31:49 +0100 Subject: [PATCH] Clock.c3 fix. --- lib/std/time/clock.c3 | 5 +++-- lib/std/time/time.c3 | 2 +- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/lib/std/time/clock.c3 b/lib/std/time/clock.c3 index 91436eeba..c5d70ccee 100644 --- a/lib/std/time/clock.c3 +++ b/lib/std/time/clock.c3 @@ -1,11 +1,12 @@ module std::time::clock; +import std::time::os; fn Clock now() { - $if $defined(native_clock): + $if $defined(os::native_clock): return os::native_clock(); $else - return 0; + unreachable("Clock unsupported"); $endif } diff --git a/lib/std/time/time.c3 b/lib/std/time/time.c3 index 7b7cd070a..c58273ad6 100644 --- a/lib/std/time/time.c3 +++ b/lib/std/time/time.c3 @@ -1,5 +1,5 @@ module std::time; -import std::io; +import std::io, std::time::os; distinct Time = long; distinct Duration = long;