I have a minor irritation that when displaying a variable in the debugger, collections wrap like this...
an OrderedCollection(a
MyObject a
MyObject a
MyObject a....

I'd like to see something like this...
an-OrderedCollection(
a-MyObject
a-MyObject
a-MyObject ....

Using the dash has the lowest impact code-wise, but maybe the visual-semantics is too great a change?

The required code change is shown below in comments...

Object>>printOn: aStream
   | title |
   title := self class name.
   aStream
       nextPutAll: (title first isVowel ifTrue: ['an '] ifFalse: ['a ']);
" nextPutAll: (title first isVowel ifTrue: ['an-'] ifFalse: ['a-']); "
       nextPutAll: title

Collection>>printElementsOn: aStream
   aStream nextPut: $(   " ; space " .
self do: [:element | aStream print: element] separatedBy: [aStream space].
   aStream " space ; " nextPut: $)

cheers -ben

Reply via email to