I know Smalltalk hierarchy, I just wanted to point out, that Hierarchy Browser does not provide (maybe I am dumb, but I do not see any) obvious way to show the hierarchy to see that Array class inherits from Behavior.
PV. ----- PŮVODNÍ ZPRÁVA ----- Od: "Stéphane Ducasse" <[email protected]> Komu: "Petr Vácha" <[email protected]> Předmět: Re: Hierarchy browsers & implementers of Datum: 7.10.2009 - 21:22:42 > I suggest you to read the chapter on the Smalltalk > model in the Squeak > or pharo by example book > the key is: > > when you look for a message you look in the CLASS of > the receiver > then its superclasses. > > So when you look for new sent to Array you should look > in the Array > class superclasses and you will see it contains > Behavior before ProtoObject > > Stef > > PS: you can sent to the mailing-list just register > to it. You do not > need to have a google account. > > On Oct 7, 2009, at 1:00 PM, Petr Vácha wrote: > > > Hi again, > > when try to find out that Array>>new: bug I found > > one thing that I > > > think > > may be very confusing - somehow mangled information > > from hierarchy > > > browsers > > (see figure). > > > > Array>>new: calls primitive and uses self>>basicNew: > > call as fallback. > > > Array does not implement basicNew: so I tried to > > find implementors of > > > it. Behavior has this implementation. However, when > > you show hierarchy > > > of Array, it ends in ProtoObject with no Behavior > > involved. I think > > > this to be is somewhat confusing for beginners especially > > when they > > > are trying to get into method lookup chain. > > > > Petr Vacha > > > > > > <pharo-browsers.jpg> > _______________________________________________ Pharo-project mailing list [email protected] http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
