Modules and class... [ a off-topic question ?]
goran.hultgren at bluefish.se
goran.hultgren at bluefish.se
Mon Feb 25 09:39:33 UTC 2002
I read your thread and even though you both are much, MUCH more
experienced in these areas I need to speak up. :-)
David certainly might have a point in that you CAN (perhaps with some
mindbending IMHO) unify classes and modules - obviously he has done it.
:-) But just because you CAN do it... ;-)
To me it feels rather "contrived" (is that the right word?). As Les
points out there are numerous differences and it doesn't feel obvious at
all (to me).
The most naive view of a module is that it is a collection of classes
more or less self contained - it is a grouping of classes. So...
following my naive reasoning (which I think is a great way of testing if
these conceptual things feels natural) - if a module is a class, and a
module is a collection of classes, then a class is a collection of
classes. BEEP. That doesn't sound right to me.
Ok, perhaps I did that wrong. Perhaps a module is "a kind of" class, and
I can not draw the conclusion that all classes are modules.
I still think this smells like "over unification" or something. No
offense intended. :-) :-)
regards, Göran
PS. The Module system in Squeak OTOH feels nice to me - "A module is an
instance of the class Module and it holds classes and submodules etc."
:-) :-) DS
More information about the Squeak-dev
mailing list
|