Even if the patch is not accepted, I've pushed the refcount fix,
Cython was leaking a reference to PyCObject at every export of a cdef
api function.

BTW, I've added a testcase for this, using sys.getrefcount... any
objections regarding its implementation?


On Tue, Feb 24, 2009 at 6:44 PM, Lisandro Dalcin <[email protected]> wrote:
> Just to prevent this:
>
> warning: ISO C forbids conversion of function pointer to object pointer type
>
>
> - Please note that I've changed the names of some local variables to
> make {Import|Export}Function implementations more symmetric.
>
> - Additionaly, note the Py_DECREF(cobj) I've added at ExportFunction,
> it seems we should refnanny our "trusted" utility code ;-) ...
>
>
> --
> Lisandro Dalcín
> ---------------
> Centro Internacional de Métodos Computacionales en Ingeniería (CIMEC)
> Instituto de Desarrollo Tecnológico para la Industria Química (INTEC)
> Consejo Nacional de Investigaciones Científicas y Técnicas (CONICET)
> PTLC - Güemes 3450, (3000) Santa Fe, Argentina
> Tel/Fax: +54-(0)342-451.1594
>



-- 
Lisandro Dalcín
---------------
Centro Internacional de Métodos Computacionales en Ingeniería (CIMEC)
Instituto de Desarrollo Tecnológico para la Industria Química (INTEC)
Consejo Nacional de Investigaciones Científicas y Técnicas (CONICET)
PTLC - Güemes 3450, (3000) Santa Fe, Argentina
Tel/Fax: +54-(0)342-451.1594
_______________________________________________
Cython-dev mailing list
[email protected]
http://codespeak.net/mailman/listinfo/cython-dev

Reply via email to