Confusion over basic Array new:

Alan Kay alank at wdi.disney.com
Sat Sep 19 01:44:02 UTC 1998


David --

Yes, Smalltalk-76 had the simpler model that you mention. The basic problem
with the St-80 model is that the benefit/stuff ratio is poor. There are
better ways to deal with a metasystem than either '76 or '80 (and I'm
hoping that some of these can be explored next year).

Cheers,

Alan

-------
At 8:35 AM -0000 9/18/98, David Stes wrote:
>On Thu, 17 Sep 1998, Michael S. Klein wrote:
>
>> Hmm...  I wonder what
>>
>> 	Behavior new superclass
>>
>> should be?  I vote for nil, with Object being a close second.
>
>It's returning nil, but I find this is a bit strange, perhaps because of
>how I'm used to have things working in Objective-C (where only Object has
>nil as superclass).
>
>Objective-C uses some sort of simplified form of what Squeak offers :
>there is no separate metaclass hierarchy.
>
>The root class, Object, is the root for both instances and classes.
>
>  Object instance <------------ Object class
>         ^                             ^
>  Collection instance           Collection class
>         ^                             ^
>  OrderedCollection instance    OrderedCollection class
>
>Where the arrow denotes in the left column how instance method lookup
>proceeds, and in the right column how class (factory) message lookup
>proceeds (ending the search for factory methods with Object's instance
>methods).
>
>There is an instance method class (which returns the class) and a factory
>method class (which returns self!).
>
>Like this, the 'class' message never returns metaclasses (although they do
>exist in the VM).
>
>It's possible that this simplified model was derived from some older
>Smalltalk implementation (I don't know).
>
>Or maybe when O-C was designed, they were thinking that Smalltalk's
>metaclass model was too complicated.





More information about the Squeak-dev mailing list