[squeak-dev] The Trunk: Kernel-nice.246.mcz

commits at source.squeak.org commits at source.squeak.org
Wed Sep 16 20:06:57 UTC 2009


Nicolas Cellier uploaded a new version of Kernel to project The Trunk:
http://source.squeak.org/trunk/Kernel-nice.246.mcz

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

Name: Kernel-nice.246
Author: nice
Time: 16 September 2009, 10:06:06 am
UUID: 36a9d04a-8c90-44a2-bb85-056633ab29d6
Ancestors: Kernel-nice.245

Another #removeAll for hackers.
Don't know if anyone would use this (unless attacking some squeak services).

=============== Diff against Kernel-nice.245 ===============

Item was added:
+ ----- Method: MethodDictionary>>removeAll (in category 'removing') -----
+ removeAll
+ 	"This provides a faster way than repeated become.
+ 	a single become is still in use to prevent system crash."
+ 	
+ 	| newSelf |
+ 	tally = 0 ifTrue: [^self].
+ 	newSelf := self species new: self size.  "This will preserve the capacity"
+ 	self become: newSelf!




More information about the Squeak-dev mailing list