[Pyrex] fan mail; ideas for the future?

William Stein wstein at ucsd.edu
Tue Oct 11 07:07:07 CEST 2005


On Mon, 10 Oct 2005 21:32:10 -0700, Nitin Madnani <nmadnani at wam.umd.edu> wrote:
> Same here. Pyrex has been a lifesaver !

I agree.  SAGE (http://modular.ucsd.edu/sage) which is my main computational
project for the foreseable future, uses Pyrex extensively, and would be much
more painful without Pyrex.  I don't think I need C++ support personally,
because I don't find wrapping the C++ libraries that I use via C too
difficult, and one of *my* main uses of Pyrex is to create new
extension classes.    The main improvement I would like in Pyrex is more
work on optimization of the C code it produces.  For example, Pyrex could
probably generate code that more efficient uses the C library to access
elements of a list.

It would also be nice to support list comprehensions in Pyrex.  How difficult
would this be to add?  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.

I wrote some tricky macros (they're in SAGE) for interrupt handling so that
when one calls a C library from Pyrex and a calculation takes a long time,
and one presses "Ctrl-C", one is returned to the Python prompt.  (They also
deal with other cases, e.g., client code that calls abort().)   I'd be interested
in making something based on this part of some future version of the
Pyrex language.  The notation I currently use is:
    _sig_on              # activates trapping of signals like ctrl-c, etc.
    block of pure C code
    _sig_off

What are other people's ideas for what they wish were in Pyrex?  I'm possibly
interested in funding some local work on Pyrex (e.g., hiring a student), since
it would directly benefit SAGE.   I've been drawing up a huge list of things to
add to SAGE, but 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?

William

> On Oct 10, 2005, at 11:54 PM, David McNab wrote:
>
>>
>> Hi again Greg and folks,
>>
>> I note a conspicuous absence of a PayPal link on the Pyrex website,
>> and
>> no other way in which grateful users can express their gratitude via
>> transmission of the good crispies.
>>
>> If Canterbury Uni doesn't have any sticky conflict of interest issues
>> with it, you might want to consider opening yourself to receive some
>> reciprocation of the wonderful energy you've put into Pyrex.
>>
>> I'd certainly lob in a few bucks if I knew C++ support was in the
>> pipeline.
>>
>> --
>> Cheers
>> David
>>
>> _______________________________________________
>> Pyrex mailing list
>> Pyrex at lists.copyleft.no
>> http://lists.copyleft.no/mailman/listinfo/pyrex
>>
>
>
> _______________________________________________
> Pyrex mailing list
> Pyrex at lists.copyleft.no
> http://lists.copyleft.no/mailman/listinfo/pyrex
>
>



-- 
William A. Stein
Associate Professor of Mathematics
University of California at San Diego
AP&M 5111; http://modular.ucsd.edu
858-220-6876 (mobile phone); 858-534-4413 (office)



More information about the Pyrex mailing list