[squeak-dev] The Trunk: Monticello-eem.784.mcz

commits at source.squeak.org commits at source.squeak.org
Thu Jan 12 18:48:39 UTC 2023


Eliot Miranda uploaded a new version of Monticello to project The Trunk:
http://source.squeak.org/trunk/Monticello-eem.784.mcz

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

Name: Monticello-eem.784
Author: eem
Time: 12 January 2023, 10:48:36.847985 am
UUID: 7c088cc0-a716-4395-9344-1bf3c77cb854
Ancestors: Monticello-eem.783

Oops! Carriage returns are badly needed in MCCodeTool>>#fileOutDefinition otherwise two consecutive methods get a doubled !! from the end of the first chunk and the start of the method preamble chunk.  Rename methodsForString to methodCategoryPreambleString now I've remembered what it's called.

=============== Diff against Monticello-eem.783 ===============

Item was changed:
  ----- Method: MCCodeTool>>fileOutDefinition (in category 'menus') -----
  fileOutDefinition
  	"Put a description of the selected definition(s) on a file.
  	 Output the version(s) corresponding to the incoming definition(s), not the versions in this system."
  
  	| index fileName itemsToFileOut |
  	itemsToFileOut := (index := self selection) ~= 0
  							ifTrue: [{items at: index}]
  							ifFalse: [items].
  	items isEmpty ifTrue:
  		[^self].
  	fileName := UIManager default
  					saveFilenameRequest: 'File out on which file?'
  					initialAnswer: (index ~= 0
  										ifTrue: [itemsToFileOut first summary]
  										ifFalse: ['definitions']).
  	fileName isEmptyOrNil ifTrue: [^self].
  	Cursor write showWhile:
  		[| definitionStream |
  		definitionStream := WriteStream on: (String new: 1000).
  		definitionStream header; timeStamp.
+ 		itemsToFileOut
+ 			do: [:patchOp| patchOp definition fileOutOn: definitionStream]
+ 			separatedBy: [definitionStream cr; cr].
- 		itemsToFileOut do:
- 			[:patchOp| 
- 			patchOp definition fileOutOn: definitionStream].
  		FileStream writeSourceCodeFrom: definitionStream baseName: fileName isSt: true useHtml: false]!

Item was changed:
  ----- Method: MCMethodDefinition>>fileOutOn: (in category 'printing') -----
  fileOutOn: aStream
  	"File out the receiver's definition in chunk format.
  	 Override to add the methodsFor: chunk."
+ 	aStream nextPut: $!!; nextChunkPut: self methodCategoryPreambleString.
- 	aStream nextPut: $!!; nextChunkPut: self methodsForString.
  	super fileOutOn: aStream!

Item was added:
+ ----- Method: MCMethodDefinition>>methodCategoryPreambleString (in category 'printing') -----
+ methodCategoryPreambleString
+ 	"Answer the string that defines the class, category and timestamp, for file out."
+ 	^String streamContents:
+ 		[:s|
+ 		s nextPutAll: className.
+ 		classIsMeta ifTrue:
+ 			[s nextPutAll: ' class'].
+ 		s nextPutAll: ' methodsFor: '; store: category; nextPutAll: ' stamp: '; print: timeStamp]!

Item was removed:
- ----- Method: MCMethodDefinition>>methodsForString (in category 'printing') -----
- methodsForString
- 	"Answer the string that defines the class, category and timestamp, for file out."
- 	^String streamContents:
- 		[:s|
- 		s nextPutAll: className.
- 		classIsMeta ifTrue:
- 			[s nextPutAll: ' class'].
- 		s nextPutAll: ' methodsFor: '; store: category; nextPutAll: ' stamp: '; print: timeStamp]!



More information about the Squeak-dev mailing list