diff options
author | Nicholas Clark <nick@ccl4.org> | 2022-01-04 18:27:17 +0000 |
---|---|---|
committer | Nicholas Clark <nick@ccl4.org> | 2022-01-12 20:12:50 +0000 |
commit | c4b6855dd57cd9a2ac4647c33c5636ed7d15d64a (patch) | |
tree | 03836a092e02ec90439d106e93ea40179629cacb /time64_config.h | |
parent | 79314061206e91d12ed1d2ee0915c80b7375f8b8 (diff) | |
download | perl-c4b6855dd57cd9a2ac4647c33c5636ed7d15d64a.tar.gz |
For C++ extensions, use the pthreads definition of PERL_GET_CONTEXT
Configure probes the C compiler to find out whether it supports C11 thread
local storage, and if found uses this for PERL_SET_CONTEXT/PERL_GET_CONTEXT,
in preference to the pthread_setspecific()/pthread_getspecific() approach.
However, we can come unstuck with XS extensions written in C++, as C++ and C
disagree on the syntax used for thread local storage, meaning that the
working token that Configure probed for C turns out to be a compiler error
on C++.
As Configure doesn't have a way to probe for C++ dialects, we just take the
safe option and do the same as 5.34.0 and earlier - use pthreads on C++.
This commit is minimal because the implementation of PERL_SET_CONTEXT for
C11 thread local storage was already defensively written to *also* call
pthread_setspecific().
Diffstat (limited to 'time64_config.h')
0 files changed, 0 insertions, 0 deletions