diff --git a/Doc/library/ctypes.rst b/Doc/library/ctypes.rst index 5f305475b5e633..ebc0b6b2f0d5de 100644 --- a/Doc/library/ctypes.rst +++ b/Doc/library/ctypes.rst @@ -2052,7 +2052,11 @@ See :ref:`ctypes-callback-functions` for examples. .. function:: PYFUNCTYPE(restype, *argtypes) The returned function prototype creates functions that use the Python calling - convention. The function will *not* release the GIL during the call. + convention. Unlike :func:`CFUNCTYPE` and :func:`WINFUNCTYPE`, ctypes does + *not* release the GIL before calling the foreign function, so the function + may safely use the Python C API. Note that this does not prevent the GIL + from being released *during* the call. + Function prototypes created by these factory functions can be instantiated in different ways, depending on the type and number of the parameters in the call: