Re: [C++-sig] enhancement: Py_DECREF / Py_XDECREF assertion

2016-04-27 Thread Stefan Seefeld
Hi Willi, On 26.04.2016 16:19, Wilfried Karel wrote: > Dear list, > > I suggest to insert an assertion before calling Py_DECREF/Py_XDECREF > which ensures that the reference count before the call is larger than > zero. Otherwise, this means that a PyObject that has already been > destroyed is plan

[C++-sig] enhancement: Py_DECREF / Py_XDECREF assertion

2016-04-27 Thread Wilfried Karel
Dear list, I suggest to insert an assertion before calling Py_DECREF/Py_XDECREF which ensures that the reference count before the call is larger than zero. Otherwise, this means that a PyObject that has already been destroyed is planned to be destroyed a second time - which will not happen, as the