Skip to content

Commit

Permalink
Define FLINT_TLS_PREFIX as thread_local
Browse files Browse the repository at this point in the history
We are using C11, so this keyword or macro should exist by standard.
  • Loading branch information
albinahlback committed Nov 18, 2023
1 parent 2d17ae4 commit c543ce3
Showing 1 changed file with 1 addition and 9 deletions.
10 changes: 1 addition & 9 deletions src/flint.h.in
Original file line number Diff line number Diff line change
Expand Up @@ -152,15 +152,7 @@ typedef struct __FLINT_FILE FLINT_FILE;
#endif

#if FLINT_USES_TLS
# if defined(__GNUC__)
# define FLINT_TLS_PREFIX __thread
# elif __STDC_VERSION__ >= 201112L
# define FLINT_TLS_PREFIX _Thread_local
# elif defined(_MSC_VER)
# define FLINT_TLS_PREFIX __declspec(thread)
# else
# error "thread local prefix defined in C11 or later"
# endif
# define FLINT_TLS_PREFIX thread_local
#else
# define FLINT_TLS_PREFIX
#endif
Expand Down

0 comments on commit c543ce3

Please sign in to comment.