[Pyrex] fan mail; ideas for the future?

Greg Ewing greg.ewing at canterbury.ac.nz
Tue Oct 11 09:59:48 CEST 2005


William Stein wrote:

> It would also be nice to support list comprehensions in Pyrex.  How 
> difficult would this be to add?

It shouldn't present any particular difficulty, since
it's just syntactic sugar for a for-loop. The details
could be a bit tedious, though, and so far I haven't
felt it to be worth the effort. I'll keep the idea in
mind for the future.

> It would also be good to include more Pyrex source code in  the
 > generated C code files. I often try to read these C files to make
> sure code that I think should be converted to pure C really is.

A better way might be to have some sort of "pure-C"
assertion that could be applied to a block of code, so
you would get an error if you did anything that invoked
a Python/C API call. I'm already thinking about tracking
allowability of Python operations in connection with GIL
management, and if I end up doing that, adding a feature
like this could be quite easy.

> I could also make a section in my list of work that 
> could be done on Pyrex. Gregg, are you keeping such a
 > list somewhere?

You're welcome to send any suggestions you have, and I'll
file them away.

If you're thinking in terms of a list published on a web
page of things other people might like to take up, I don't
have one at the moment, but something like that could be
arranged.

Greg



More information about the Pyrex mailing list