[squeak-dev] Re: The Trunk: Help-Squeak-Project-mt.40.mcz
marcel.taeumel
Marcel.Taeumel at hpi.de
Fri Aug 12 12:20:07 UTC 2016
Levente Uzonyi wrote
> Hi Marcel,
>
> On Fri, 12 Aug 2016, marcel.taeumel wrote:
>
>> Levente Uzonyi wrote
>>> Please do not use #sortBy:. It should have been deprecated in favor of
>>> #sorted:.
>>>
>>> Levente
>
> snip
>
>>
>> Hi Levente,
>>
>> ah, because it creates a new instance and does not change data in-place.
>> I
>
> No. It's because #sorted: works for all Collections, while #sortBy: is
> specific to SequenceableCollection. #sortBy:'s comment is inaccurate about
> the return value (it doesn't create a _copy_ unless the receiver is an
> OrderedCollection), and it relies on #asOrderedCollection's unusual
> implementation, which returns a copy even if the receiver is an
> OrderedCollection.
>
>> see. Will do.
>
> Thanks!
>
> Levente
>
>>
>> Best,
>> Marcel
>>
>>
>>
>> --
>> View this message in context:
>> http://forum.world.st/The-Trunk-Help-Squeak-Project-mt-40-mcz-tp4910536p4910638.html
>> Sent from the Squeak - Dev mailing list archive at Nabble.com.
>>
>>
Hi Levente,
as far as I could see, the remaining uses of #sortBy: in the image work now
fine with #sorted:. #sortBy: is now officially deprecated. Any objections?
(It's not even much. Only 20 senders of #sorted:.)
Best,
Marcel
--
View this message in context: http://forum.world.st/The-Trunk-Help-Squeak-Project-mt-40-mcz-tp4910536p4910713.html
Sent from the Squeak - Dev mailing list archive at Nabble.com.
More information about the Squeak-dev
mailing list
|