[Pyrex] Should Pyrex be in standard Python?
Bob Ippolito
bob at redivi.com
Thu Jan 22 04:50:11 CET 2004
On Jan 21, 2004, at 10:05 PM, Paul Prescod wrote:
> Greg Ewing wrote:
>
>> Paul Prescod:
>>> I've written up a proposal for adding Pyrex to Python as the
>>> standard way of building the extension modules that ship with
>>> Python. I'd like feedback from Pyrex users and Greg before I broach
>>> the issue with python-dev.
>> This is a staggering idea!
>> I'd say more, but the scope and implications of it leave me
>> a bit speechless just at the moment...
>
> Pyrex is a staggering idea.
>
> From the point of view of a C programmer it could be thought of as C
> with garbage collection, objects, exceptions and a nice syntax (i.e.
> for loops).
>
> For a C++ programmer it could be thought of as C++ without all of the
> cruft that nobody likes or can figure out.
>
> For a Java programmer it could be a more dynamic Java with
> integrations into
>
> For a Python programmer it is a) an easy way of making Python
> extensions, b) a way of MASSIVELY speeding up Python code. It should
> be a tool in every Python programmer's toolbox.
>
> I believe that Pyrex should be MUCH more popular than it is. It just
> lacks marketing. I'm putting together a few articles and talks (anyone
> else talking at PyCon?) to start filling that gap. I've been told that
> there are several outlets for magazine articles.
Well, I've used Pyrex to wrap a few Apple frameworks:
http://undefined.org/python/
It was just the quickest path.. bgen is clunky, ctypes is
unstable/unpredictable, and the C API raw is too much typing (in any
sense of the word ;).
What I want for Pyrex is a .h -> Pyrex translator (function prototypes,
enums, structs).. it would save me a lot of regexing in vim. Something
like bgen, with a different output. I tried to write one once, but
it's hard and I don't really like text processing (was trying to
tokenize, not regex like bgen) so I've shelved it for now.
I may or may not be talking at PyCon about Mac stuff:
http://undefined.org/python/MacPython-60min_v4.html
I submitted a proposal, has not yet been voted either way at this point
(AFAICT).
-bob
More information about the Pyrex
mailing list