[squeak-dev] The Trunk: Collections-cmm.675.mcz

commits at source.squeak.org commits at source.squeak.org
Sun Jan 3 21:34:02 UTC 2016


Chris Muller uploaded a new version of Collections to project The Trunk:
http://source.squeak.org/trunk/Collections-cmm.675.mcz

==================== Summary ====================

Name: Collections-cmm.675
Author: cmm
Time: 3 January 2016, 3:33:44.302 pm
UUID: d019e6cc-abbb-4077-9e3d-2f471f6fb07a
Ancestors: Collections-eem.672

grownBy: should answer the same class of object asked to be grown.

=============== Diff against Collections-eem.672 ===============

Item was changed:
  ----- Method: SequenceableCollection>>grownBy: (in category 'copying') -----
+ grownBy: length 
- grownBy: length
  	"Answer a copy of receiver collection with size grown by length"
+ 	^ (self class ofSize: self size + length)
+ 		replaceFrom: 1 to: self size with: self startingAt: 1 ;
+ 		yourself!
- 
- 	| newCollection |
- 	newCollection := self species ofSize: self size + length.
- 	newCollection replaceFrom: 1 to: self size with: self startingAt: 1.
- 	^ newCollection!



More information about the Squeak-dev mailing list