What's better about Ruby than Python?

Olivier Drolet trimtab at mac.com
Fri Aug 22 03:04:34 CEST 2003

"Andrew Dalke" <adalke at mindspring.com> wrote in message news:<Uw81b.1989$Ej6.1167 at newsread4.news.pas.earthlink.net>...
> Olivier Drolet:
> > Really cute intuition pump you've got there, Alex!  :-)
> Err, it was me, no?

Sorry for the confusion. As a neophite news poster, I got mixed up
with names. Alex Martelli's arguments really got my attention and his
name stuck. Especially his argument regarding linguistic divergence.

> Following Aahz's suggestion -- what would a Python-with-macros
> look like?

I presume Aahz' suggestion is "readability". Thats indeed tricky.
Macros can only work consistently in Common Lisp because of
parentheses, but I don't know ennough about the reliability of
Python's delimitors. Dylan macros, for example, are said to differ in
power and flexibility from those of CL, so I'm led to understand. It
must be said that parens in Common Lisp are also essential in ensuring
the ability of a program alter itself or another program. Whence the
notion of Lisp as a "programmable programming language". (This isn't
to say that this is impossible in other programming languages, only
perhaps a bit trickier.)

Common Lisp macros can often significantly improve code readability by
merely reducing the amount of code. This is seen as a desirable
tradeoff, especially in large projects. If code readability is
paramount within the Python community, does the latter generally shy
away from projects in which code complexity is likely to increase
dramatically, i.e. where readability is likely to suffer?

I ask this only because of the fierce opposition the idea of macros
has been receiving here. Linguistic divergence seems to be seen as
leading inexhorably towards a degradation in code readability.

At the end of the day, I understand and respect a community's choice.
I'm in agreement with the view that languages are molded by their
community, and inversely so. The relation between the language, its
practitionners and the problem spaces being addressed is a dynamic
one. In the end, what ever works for the Python community is fine,
even rejecting macros for the sake of readability.


More information about the Python-list mailing list