diff --git a/src/_wrappers.c b/src/_wrappers.c index 2deb6d0..1661c42 100644 --- a/src/_wrappers.c +++ b/src/_wrappers.c @@ -2044,6 +2044,16 @@ moduleinit(void) PyModule_AddObject(module, "FunctionWrapper", (PyObject *)&WraptFunctionWrapper_Type); + Py_INCREF(&WraptFunctionWrapperBase_Type); + PyModule_AddObject(module, "_FunctionWrapperBase", + (PyObject *)&WraptFunctionWrapperBase_Type); + Py_INCREF(&WraptBoundFunctionWrapper_Type); + PyModule_AddObject(module, "_BoundFunctionWrapper", + (PyObject *)&WraptBoundFunctionWrapper_Type); + Py_INCREF(&WraptBoundMethodWrapper_Type); + PyModule_AddObject(module, "_BoundMethodWrapper", + (PyObject *)&WraptBoundMethodWrapper_Type); + return module; } diff --git a/src/wrappers.py b/src/wrappers.py index 2ead039..475c94c 100644 --- a/src/wrappers.py +++ b/src/wrappers.py @@ -509,7 +509,8 @@ class FunctionWrapper(_FunctionWrapperBase): adapter, bound_type) try: - from ._wrappers import ObjectProxy, FunctionWrapper + from ._wrappers import (ObjectProxy, FunctionWrapper, + _FunctionWrapperBase, _BoundFunctionWrapper, _BoundMethodWrapper) except ImportError: pass