I'm bringing this over from the NumPy list. I'm guessing this behaviour is
there so that subclasses written in Cython won't break? Perhaps the error
message could at least be made clearer ("please recompile") + perhaps only
do this check for types which are subclassed?

Dag Sverre

On Sun, Dec 6, 2009 at 07:53, Gael Varoquaux
<gael.varoqu...@normalesup.org> wrote:
> I have a lot of code that has stopped working with my latest SVN pull to
> numpy.
>
> * Some compiled code yields an error looking like (from memory):
>
>    "incorrect type 'numpy.ndarray'"
>
> Rebuilding it is sufficient.

Is this Cython or Pyrex code? Unfortunately Pyrex checks the size of
types exactly such that even if you extend the type in a backwards
compatible way, it will raise that exception. This behavior has been
inherited by Cython. I have asked for this feature to be removed, or
at least turned into a >= check, but it got no traction.

-- 
Robert Kern


_______________________________________________
Cython-dev mailing list
Cython-dev@codespeak.net
http://codespeak.net/mailman/listinfo/cython-dev

Reply via email to