Skip to content

Commit

Permalink
use __STDC_NO_ATOMICS__ instead of _MSC_VER wrt stdatomic.h
Browse files Browse the repository at this point in the history
  • Loading branch information
yamt committed Aug 12, 2024
1 parent 63f4383 commit 3625b1d
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion lib/cluster.h
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#if !defined(_MSC_VER)
#if !defined(__STDC_NO_ATOMICS__)
#include <stdatomic.h>
#endif
#include <stdbool.h>
Expand Down
2 changes: 1 addition & 1 deletion lib/exec_context.h
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#if !defined(_MSC_VER)
#if !defined(__STDC_NO_ATOMICS__)
#include <stdatomic.h>
#endif
#include <stdbool.h>
Expand Down
2 changes: 1 addition & 1 deletion lib/mem.c
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#include <assert.h>
#include <errno.h>
#if !defined(_MSC_VER)
#if !defined(__STDC_NO_ATOMICS__)
#include <stdatomic.h>
#endif
#include <stdint.h>
Expand Down
2 changes: 1 addition & 1 deletion lib/platform.h
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,7 @@
(a != 0 && (SIZE_MAX / a < b) ? 1 : (*c = a * b, 0))
#endif

#if defined(_MSC_VER)
#if defined(__STDC_NO_ATOMICS__)
#define _Atomic
#define atomic_uint unsigned int
#endif
Expand Down

0 comments on commit 3625b1d

Please sign in to comment.