This commit is contained in:
blueloveTH 2024-11-08 18:23:46 +08:00
parent eb280910c9
commit ab4ff49eda

View File

@ -4,6 +4,7 @@
#define NANOS_PER_SEC 1000000000
#ifndef __circle__
int64_t time_ns() {
struct timespec tms;
#ifdef CLOCK_REALTIME
@ -18,6 +19,11 @@ int64_t time_ns() {
nanos += tms.tv_nsec;
return nanos;
}
#else
int64_t time_ns() {
return 0;
}
#endif
static bool time_time(int argc, py_Ref argv) {
PY_CHECK_ARGC(0);