[squeak-dev] The Trunk: Collections-fn.825.mcz

commits at source.squeak.org commits at source.squeak.org
Fri Apr 12 07:30:32 UTC 2019

Fabio Niephaus uploaded a new version of Collections to project The Trunk:

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

Name: Collections-fn.825
Author: fn
Time: 12 April 2019, 9:30:29.397159 am
UUID: 3110d8f6-fa38-4d91-8358-aed2eadbd9a7
Ancestors: Collections-nice.824

Just like strings, characters should convert themselves to an integer when involved in arithmetic with a number.

$c < 98.9 "false"
98.9 < $c "opened debugger, now returns true"

=============== Diff against Collections-nice.824 ===============

Item was added:
+ ----- Method: Character>>adaptToNumber:andSend: (in category 'converting') -----
+ adaptToNumber: rcvr andSend: selector
+ 	"If I am involved in arithmetic with a number, convert me to an integer."
+ 	^ rcvr perform: selector with: self asInteger!

More information about the Squeak-dev mailing list