A Comparison of Python and Ruby Extension Interfaces (Re: Comparison between Python and "Ruby")

Fernando Pereira pereira at research.att.com
Wed Nov 3 05:27:52 CET 1999

In article <38204614.2EAC6051 at compaq.com>, Greg Ewing
<greg.ewing at compaq.com> wrote:
> * Since Ruby has mark-and-sweep garbage collection, there
> is no manipulation of reference counts. There weren't
> actually any examples of this in the Python dbm module,
> though.
What's the effect of this on portability? For instance, how are
pointers to live objects from the C stack handled? As is well-known,
this cannot be done portably.
> * Ruby seems to be able to raise exceptions without
> having to explicitly propagate them back out of routines,
> which eliminates a lot of result testing and returning of
> -1's and None's that goes on in Python extension code.
Same comment. There is no portable way of unwinding the C stack. What
does that mean for Ruby's portability?

These were pretty ugly problems when I devoted quite a bit of effort to
them in the 80s (Prolog<->C integration back then), and they can only
have become worse with new architectures and more highly optimizing C

-- F

More information about the Python-list mailing list