The Trunk: Collections-ul.542.mcz

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

The Trunk: Collections-ul.542.mcz

commits-2
Levente Uzonyi uploaded a new version of Collections to project The Trunk:
http://source.squeak.org/trunk/Collections-ul.542.mcz

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

Name: Collections-ul.542
Author: ul
Time: 26 October 2013, 12:22:26.493 am
UUID: e52fefbe-fb04-46f4-a956-f7bbcb5c8965
Ancestors: Collections-cmm.541

Make Dictionary >> #includesKey: more lightweight.

=============== Diff against Collections-cmm.541 ===============

Item was changed:
  ----- Method: Dictionary>>includesKey: (in category 'testing') -----
  includesKey: key
  "Answer whether the receiver has a key equal to the argument, key."
 
+ ^(array at: (self scanFor: key)) ~~ nil "We could use #notNil here, but ProtoObject doesn't understand it."!
- self at: key ifAbsent: [^false].
- ^true!