The Trunk: Collections-dtl.716.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-dtl.716.mcz

commits-2
David T. Lewis uploaded a new version of Collections to project The Trunk:
http://source.squeak.org/trunk/Collections-dtl.716.mcz

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

Name: Collections-dtl.716
Author: dtl
Time: 29 August 2016, 8:02:18.941698 pm
UUID: 33e9eb9e-1da0-49a7-9840-9770305ec0d4
Ancestors: Collections-dtl.715, Collections-tfel.715

Merge Collections-dtl.715, Collections-tfel.715

=============== Diff against Collections-dtl.715 ===============

Item was changed:
  ----- Method: TranscriptStream class>>registerInFlapsRegistry (in category 'class initialization') -----
  registerInFlapsRegistry
  "Register the receiver in the system's flaps registry"
  self environment
  at: #Flaps
+ ifPresent: [:cl | cl registerQuad: {#TranscriptStream. #openMorphicTranscript. 'Transcript' translatedNoop. 'A Transcript is a window usable for logging and debugging; browse references to #Transcript for examples of how to write to it.' translatedNoop}
- ifPresent: [:cl | cl registerQuad: #(TranscriptStream openMorphicTranscript 'Transcript' 'A Transcript is a window usable for logging and debugging; browse references to #Transcript for examples of how to write to it.')
  forFlapNamed: 'Tools']
  !

Item was changed:
  ----- Method: WriteStream>>nextPut: (in category 'accessing') -----
  nextPut: anObject
  "Primitive. Insert the argument at the next position in the Stream
  represented by the receiver. Fail if the collection of this stream is not an
  Array or a String. Fail if the stream is positioned at its end, or if the
  position is out of bounds in the collection. Fail if the argument is not
  of the right type for the collection. Optional. See Object documentation
  whatIsAPrimitive."
 
  <primitive: 66>
+ ((collection class == ByteString) and: [
+ anObject isCharacter and:[anObject isOctetCharacter not]]) ifTrue: [
+ collection := (WideString from: collection).
+ ^self nextPut: anObject.
+ ].
  position >= writeLimit
  ifTrue: [^ self pastEndPut: anObject]
  ifFalse:
  [position := position + 1.
  ^collection at: position put: anObject]!