Chris Colbert, 18.02.2011 03:23:
What is the rule of thumb when declaring functions from python's C-api when
comes to ref counting?
The general rule is to not declare them yourself. Instead, cimport them
from the cpython package. (See Cython/Includes/)
If I define a test case like so:
cde
What is the rule of thumb when declaring functions from python's C-api when
comes to ref counting?
If I define a test case like so:
cdef extern from "Python.h":
object PyWeakref_NewRef(object, object)
object PyWeakref_GET_OBJECT(object)
class Foo(object):
pass
cdef class Test: