Commit 4b8b86c6 authored by Victor Stinner's avatar Victor Stinner

pystate.h: fix _PyThreadState_UncheckedGet()

Declare the function even if thread support is disabled.
parent 27461683
...@@ -173,11 +173,9 @@ PyAPI_FUNC(void) _PyGILState_Reinit(void); ...@@ -173,11 +173,9 @@ PyAPI_FUNC(void) _PyGILState_Reinit(void);
* the caller needn't check for NULL). */ * the caller needn't check for NULL). */
PyAPI_FUNC(PyThreadState *) PyThreadState_Get(void); PyAPI_FUNC(PyThreadState *) PyThreadState_Get(void);
#ifdef WITH_THREAD
/* Similar to PyThreadState_Get(), but don't issue a fatal error /* Similar to PyThreadState_Get(), but don't issue a fatal error
* if it is NULL. */ * if it is NULL. */
PyAPI_FUNC(PyThreadState *) _PyThreadState_UncheckedGet(void); PyAPI_FUNC(PyThreadState *) _PyThreadState_UncheckedGet(void);
#endif
PyAPI_FUNC(PyThreadState *) PyThreadState_Swap(PyThreadState *); PyAPI_FUNC(PyThreadState *) PyThreadState_Swap(PyThreadState *);
PyAPI_FUNC(PyObject *) PyThreadState_GetDict(void); PyAPI_FUNC(PyObject *) PyThreadState_GetDict(void);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment