[Pyrex] fix for tp_clear()

Greg Ewing greg.ewing at canterbury.ac.nz
Tue Jan 29 01:38:06 CET 2008


Stefan Behnel wrote:
> Also, Pyrex and Cython set the type members to None, while the page above
> assigns NULL. I don't know if None is needed here

Pyrex sets them to None in case any Python code gets triggered
by the clearing that ends up looking at them. Pyrex-generated
access code for C attributes assumes they contain valid references.

--
Greg



More information about the Pyrex mailing list