Forum: Ruby Re: Diff of opinion on dynamic stuff

Announcement (2017-05-07): is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see and for other Rails- und Ruby-related community platforms.
C5c57a548f07dcfc633017277426151a?d=identicon&s=25 Molitor, Stephen L (Guest)
on 2005-12-23 01:00
(Received via mailing list)
>> Is Python against dynamic stuff?  And Ruby for it?

Certainly Python can't be against all dynamic stuff.  Ain't that dynamic
stuff what Eckel and others *like* about Python compared to Java --
'latent typing', etc.?  And can't you make the same sort of arguments
against duck/latent typing that the blogger makes against open classes
and dynamically generated code?  For example:

    "It's the second generation that's going to be less enthused,
    that's going to stare in bafflement at these methods that
    mysteriously accept any type, and trying to figure out what's
    going on when there's an exception in dynamically typed

Or you could even complain about operator overloading, which isn't even
a dynamic feature:

    "It's the second generation that's going to be less enthused,
    that's going to stare in bafflement at these operators that can
    mysteriously be overridden to do anything, and trying to figure out
    going when there's an exception in an overridden '+' operator."

Of course, he could still be correct -- maybe duck typing and operator
loading are safe enough, and open classes are too dangerous.  But it's
still kind of interesting that a Python guy is criticizing Ruby for
being *too* dynamic, flexible and open.  That's of course the argument
of the static typing crowd against dynamic typing.  I guess he must hate
class-less languages like Self (or even Javascript).

Maybe that's the core difference between the Python and Ruby
philosophies?  Ruby is even more dynamic and 'open'?

Ruby isn't Self, but seems closer to the idea that essence of OO is that
objects respond to messages.  Precisely how you create an object,
whether via a closed class, an open class, a Javascript constructor, or
whatever is less essential from that point of view.  Whereas other
languages seem to be much more class-centric.

I worked my way through a Python book a few years ago, but I've
forgotten most of it.  Are classes objects in Python?

This topic is locked and can not be replied to.