mirror of
https://github.com/pybind/pybind11.git
synced 2024-11-22 05:05:11 +00:00
PYBIND11_TLS_REPLACE_VALUE should use macro argument value in Python 3.7+ (#1683)
This commit is contained in:
parent
2b045757b5
commit
f93cd0aa72
@ -23,7 +23,7 @@ inline PyObject *make_object_base_type(PyTypeObject *metaclass);
|
||||
#if PY_VERSION_HEX >= 0x03070000
|
||||
# define PYBIND11_TLS_KEY_INIT(var) Py_tss_t *var = nullptr
|
||||
# define PYBIND11_TLS_GET_VALUE(key) PyThread_tss_get((key))
|
||||
# define PYBIND11_TLS_REPLACE_VALUE(key, value) PyThread_tss_set((key), (tstate))
|
||||
# define PYBIND11_TLS_REPLACE_VALUE(key, value) PyThread_tss_set((key), (value))
|
||||
# define PYBIND11_TLS_DELETE_VALUE(key) PyThread_tss_set((key), nullptr)
|
||||
#else
|
||||
// Usually an int but a long on Cygwin64 with Python 3.x
|
||||
|
Loading…
Reference in New Issue
Block a user