diff --git a/Modules/_remote_debugging_module.c b/Modules/_remote_debugging_module.c index 19f12c3b02e5a4..77f8e526f4212c 100644 --- a/Modules/_remote_debugging_module.c +++ b/Modules/_remote_debugging_module.c @@ -212,6 +212,8 @@ typedef struct { #endif } RemoteUnwinderObject; +#define RemoteUnwinder_CAST(op) ((RemoteUnwinderObject *)(op)) + typedef struct { int lineno; @@ -2899,8 +2901,9 @@ static PyMethodDef RemoteUnwinder_methods[] = { }; static void -RemoteUnwinder_dealloc(RemoteUnwinderObject *self) +RemoteUnwinder_dealloc(PyObject *op) { + RemoteUnwinderObject *self = RemoteUnwinder_CAST(op); PyTypeObject *tp = Py_TYPE(self); if (self->code_object_cache) { _Py_hashtable_destroy(self->code_object_cache);