[squeak-dev] The Inbox: Monticello-nice.545.mcz

commits at source.squeak.org commits at source.squeak.org
Thu May 23 21:00:35 UTC 2013


Nicolas Cellier uploaded a new version of Monticello to project The Inbox:
http://source.squeak.org/inbox/Monticello-nice.545.mcz

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

Name: Monticello-nice.545
Author: nice
Time: 23 May 2013, 11:00:14.509 pm
UUID: 83c3e004-45ee-4976-b80e-de52f74691c5
Ancestors: Monticello-fbs.544

Let MC encode source in UTF-8
STEP 2: let MCStWriter encode and MCStReader decode.

Note 1: no BOM is used in this version, and legacy code is handled in InvalidUTF8 exception handling.

Note 2: MCStReader is not used.

=============== Diff against Monticello-fbs.544 ===============

Item was changed:
  ----- Method: MCMczWriter>>serializeDefinitions: (in category 'serializing') -----
  serializeDefinitions: aCollection
  	| writer s |
+ 	s := String new writeStream.
- 	s := RWBinaryOrTextStream on: String new.
  	writer := self snapshotWriterClass on: s.
  	writer writeDefinitions: aCollection.
  	^ s contents!

Item was changed:
  ----- Method: MCStReader>>readStream (in category 'evaluating') -----
  readStream
+ 	| contents |
+ 	contents := stream contents.
  	^ ('!!!!
  
+ ', ([contents utf8ToSqueak] on: InvalidUTF8 do: [:exc | exc return: contents])) readStream!
- ', stream contents) readStream!

Item was changed:
  ----- Method: MCStWriter>>writeDefinitions: (in category 'writing') -----
  writeDefinitions: aCollection
  	"initStream is an ugly hack until we have proper init defs"
  	initStream := String new writeStream.
  
  	(MCDependencySorter sortItems: aCollection)
  		do: [:ea | ea accept: self]
  		displayingProgress: 'Writing definitions...'.
  	
+ 	stream nextPutAll: initStream contents squeakToUtf8.!
- 	stream nextPutAll: initStream contents.!



More information about the Squeak-dev mailing list