From dc082c77eb028c6f39660ccf6a06ad9eb4f6edcc Mon Sep 17 00:00:00 2001 From: Tau Date: Fri, 23 Nov 2018 18:23:41 -0500 Subject: [PATCH] util/clock.c: Use #define constants MSVC doesn't allow chaining of const expressions grumble grumble (need to use constexpr, which is a. an extremely ugly looking reserved word and b. exclusive to C++) --- util/clock.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/util/clock.c b/util/clock.c index 5e51b70..44fb85e 100644 --- a/util/clock.c +++ b/util/clock.c @@ -42,9 +42,9 @@ static const struct hook_symbol clock_hook_syms[] = { /* FILETIME is expressed in 100ns i.e. 0.1us i.e. 10^-7 sec units. No official name for these units is given so let's call them "jiffies". */ -static const int64_t jiffies_per_sec = 10000000LL; -static const int64_t jiffies_per_hour = jiffies_per_sec * 3600LL; -static const int64_t jiffies_per_day = jiffies_per_hour * 24LL; +#define jiffies_per_sec 10000000LL +#define jiffies_per_hour (jiffies_per_sec * 3600LL) +#define jiffies_per_day (jiffies_per_hour * 24LL) static void WINAPI my_GetSystemTimeAsFileTime(FILETIME *out) {