From b040b42a959e21ce36990a80973adebbc09dbb6c Mon Sep 17 00:00:00 2001 From: Plantaquatix <5758369+Plantaquatix@users.noreply.github.com> Date: Sun, 3 Nov 2024 16:06:51 +0000 Subject: [PATCH] fix: Removing ATOMIC_UINT32_INIT ATOMIC_UINT32_INIT has been removed in C23. --- munit.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/munit.c b/munit.c index 00ede07..eb10fe4 100644 --- a/munit.c +++ b/munit.c @@ -795,23 +795,18 @@ munit_clock_get_elapsed(struct PsnipClockTimespec* start, struct PsnipClockTimes #if defined(_OPENMP) # define ATOMIC_UINT32_T uint32_t -# define ATOMIC_UINT32_INIT(x) (x) #elif defined(HAVE_STDATOMIC) # include # define ATOMIC_UINT32_T _Atomic uint32_t -# define ATOMIC_UINT32_INIT(x) ATOMIC_VAR_INIT(x) #elif defined(HAVE_CLANG_ATOMICS) # define ATOMIC_UINT32_T _Atomic uint32_t -# define ATOMIC_UINT32_INIT(x) (x) #elif defined(_WIN32) # define ATOMIC_UINT32_T volatile LONG -# define ATOMIC_UINT32_INIT(x) (x) #else # define ATOMIC_UINT32_T volatile uint32_t -# define ATOMIC_UINT32_INIT(x) (x) #endif -static ATOMIC_UINT32_T munit_rand_state = ATOMIC_UINT32_INIT(42); +static ATOMIC_UINT32_T munit_rand_state = 42; #if defined(_OPENMP) static inline void