[squeak-dev] OrderedCollection and asOrderedCollection

Levente Uzonyi leves at elte.hu
Wed Jul 18 22:13:52 UTC 2012

On Wed, 18 Jul 2012, Frank Shearar wrote:

> Is there any particular reason why we don't have OrderedCollection >>
> #asOrderedCollection simply return self?

There are other as* methods which return a copy. Unifying them would be 
nice, but I'm sure it'd break lots of packages.


> Right now (OrderedCollection with: 1) asOrderedCollection calls
> Collection >> #asOrderedCollection, which calls self as:
> OrderedCollection, which copies the collection.
> This would also make OrderedCollection work a bit more like Array -
> Array >> #asArray simply returns self.
> frank

More information about the Squeak-dev mailing list