File tree Expand file tree Collapse file tree 1 file changed +8
-5
lines changed Expand file tree Collapse file tree 1 file changed +8
-5
lines changed Original file line number Diff line number Diff line change @@ -701,6 +701,7 @@ typedef struct {
701
701
702
702
#define _PicklerObject_CAST (op ) ((PicklerObject *)(op))
703
703
#define _UnpicklerObject_CAST (op ) ((UnpicklerObject *)(op))
704
+ #define _PicklerMemoProxyObject_CAST (op ) ((PicklerMemoProxyObject *)(op))
704
705
705
706
/* Forward declarations */
706
707
static int save (PickleState * state , PicklerObject * , PyObject * , int );
@@ -4980,27 +4981,29 @@ static PyMethodDef picklerproxy_methods[] = {
4980
4981
};
4981
4982
4982
4983
static void
4983
- PicklerMemoProxy_dealloc (PicklerMemoProxyObject * self )
4984
+ PicklerMemoProxy_dealloc (PyObject * op )
4984
4985
{
4986
+ PicklerMemoProxyObject * self = _PicklerMemoProxyObject_CAST (op );
4985
4987
PyTypeObject * tp = Py_TYPE (self );
4986
4988
PyObject_GC_UnTrack (self );
4987
4989
Py_CLEAR (self -> pickler );
4988
- tp -> tp_free (( PyObject * ) self );
4990
+ tp -> tp_free (self );
4989
4991
Py_DECREF (tp );
4990
4992
}
4991
4993
4992
4994
static int
4993
- PicklerMemoProxy_traverse (PicklerMemoProxyObject * self ,
4994
- visitproc visit , void * arg )
4995
+ PicklerMemoProxy_traverse (PyObject * op , visitproc visit , void * arg )
4995
4996
{
4997
+ PicklerMemoProxyObject * self = _PicklerMemoProxyObject_CAST (op );
4996
4998
Py_VISIT (Py_TYPE (self ));
4997
4999
Py_VISIT (self -> pickler );
4998
5000
return 0 ;
4999
5001
}
5000
5002
5001
5003
static int
5002
- PicklerMemoProxy_clear (PicklerMemoProxyObject * self )
5004
+ PicklerMemoProxy_clear (PyObject * op )
5003
5005
{
5006
+ PicklerMemoProxyObject * self = _PicklerMemoProxyObject_CAST (op );
5004
5007
Py_CLEAR (self -> pickler );
5005
5008
return 0 ;
5006
5009
}
You can’t perform that action at this time.
0 commit comments