[Pyrex] Pyrex release for Python 2.5?

William Stein wstein at gmail.com
Wed Oct 25 00:00:35 UTC 2006


On Tue, 24 Oct 2006 18:28:37 -0500, Greg Ewing  
<greg.ewing at canterbury.ac.nz> wrote:
> William Stein wrote:
>> I don't think it matters, since the nb_index field is at the
>> very end of the struct that defines the class, so probably it would  
>> still  work in the older versions.
>
> A binary compiled for 2.5 with an nb_index field
> would probably work with an older Python, yes.
>
> But you wouldn't be able to compile it against a
> pre-2.5 Python installation, because the type
> struct wouldn't be declared as having an nb_index
> slot.
>
> So for full compatibility, the Pyrex compiler
> would need to detect whether it was running under
> 2.5 and conditionally include the nb_index slot.
> I don't know whether the patch in question does
> that.

It doesn't.  It's the fairly simple patch I sent you a few weeks
ago, and doesn't take at all into account the Pyrex version.

By the way, you might find this amusing:

http://sage.math.washington.edu:8100/169

It's an open web-based graphical user interface to SAGE. SAGE can
Pyrex compile and load input cells on-the-fly if you put %pyrex
at the beginning of an input cell.  E.g., you could go to the page
above and change a line of the pyrex code, hit "shift-enter" to
submit the changed cell, and the new code will be loaded into
the running Python process.

You can add new cells at the bottom to try out random things,
if you want.

   -- William



More information about the Pyrex mailing list