[squeak-dev] The Trunk: Collections-ul.877.mcz

commits at source.squeak.org commits at source.squeak.org
Fri Feb 28 13:21:02 UTC 2020


Marcel Taeumel uploaded a new version of Collections to project The Trunk:
http://source.squeak.org/trunk/Collections-ul.877.mcz

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

Name: Collections-ul.877
Author: ul
Time: 27 February 2020, 2:00:22.678898 pm
UUID: df2c680a-81dd-49bf-a1c2-a0fec288ce0f
Ancestors: Collections-mt.876

- recalculate tally in WeakIdentityDictionary >> #noCheckNoGrowFillFrom: to prevent it becoming greater than the maximum number of elements the dictionary can hold

=============== Diff against Collections-mt.876 ===============

Item was changed:
  ----- Method: WeakIdentityDictionary>>noCheckNoGrowFillFrom: (in category 'private') -----
  noCheckNoGrowFillFrom: anArray
  	"Add the elements of anArray except nils to me assuming that I don't contain any of them, they are unique and I have more free space than they require."
  
+ 	tally := 0.
  	1 to: anArray size do: [ :index |
  		(anArray at: index) ifNotNil: [ :association |
+ 			association == vacuum ifFalse: [
+ 				array
- 			association == vacuum
- 				ifFalse: [array
  					at: (self scanForEmptySlotFor: association key)
+ 					put: association.
+ 				tally := tally + 1 ] ] ]!
- 					put: association ] ] ]!



More information about the Squeak-dev mailing list