Mantis - Squeak
Viewing Issue Advanced Details
7584 Collections minor always 12-14-10 01:40 12-16-10 23:14
nicolas cellier  
 
normal  
new trunk  
open  
none    
none  
0007584: Cannot print a Dictionary with a Complex key
self
  shouldnt: [
    ({
      (1 i) -> 'imaginary'.
      1 -> 'real'
    } as: Dictionary) printString]
  raise: Error
#keysSortedSafely is not robust.
More other, #isNumber expectations have been changed since 0002688
I don't think 0002688 was a good solution because most methods testing isNumber don't expecta Complex number.

Notes
(0013988)
leves   
12-16-10 23:14   
What can we do?
- add an #isComplex check?
- remove #isNumber from Complex?
- use #isKindOf: Number instead of #isNumber (which may be too slow)?
- use a Schwartzian transform?
- redesign the whole number handling code? :)