Stefan Behnel | 18 Jul 2012 09:09
Picon
Favicon

[Cython] code generated for arguments of type "type"

Hi,

the following pull request tries to fix the fact that we currently generate
arguments of type "PyObject*" when someone spells out "type" for them.

https://github.com/cython/cython/pull/126

That's mostly a problem in CPython's C-API, but also in some NumPy
functions. The correct way to translate this would be as a "PyTypeObject*",
not a bare "PyObject*".

Does anyone see a general problem with changing this in the compiler
directly? I'm not sure that it won't break code, for example. We'll at
least have to cast the arguments on the way in as well.

Stefan

Gmane