[squeak-dev] The Trunk: ST80-nice.124.mcz

commits at source.squeak.org commits at source.squeak.org
Mon Feb 14 21:41:38 UTC 2011

Nicolas Cellier uploaded a new version of ST80 to project The Trunk:

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

Name: ST80-nice.124
Author: nice
Time: 14 February 2011, 10:41:20.67 pm
UUID: 3dab1f69-fafe-4879-9d85-f078863b23c7
Ancestors: ST80-nice.123

Get rid of FakeClassPool adopt: again, because my glasses must be dirty.

(Apologies for double posting, the true reason is that my original change was getting rid of OutOfScopeNotification too but I did not want to push this one now)

=============== Diff against ST80-nice.123 ===============

Item was changed:
  ----- Method: ParagraphEditor>>tallySelection (in category 'do-its') -----
  	"Treat the current selection as an expression; evaluate it and return the time took for this evaluation"
  	| result rcvr ctxt valueAsString v |
  	self lineSelectAndEmptyCheck: [^ -1].
  	(model respondsTo: #doItReceiver) 
  		ifTrue: [ rcvr := model doItReceiver.
  				ctxt := model doItContext]
  		ifFalse: [rcvr := ctxt := nil].
  	result := [ | cm |
  		cm := rcvr class evaluatorClass new 
  			compiledMethodFor: self selectionAsStream
  			in: ctxt
  			to: rcvr
  			notifying: self
+ 			ifFail: [^ #failedDoit]
- 			ifFail: [FakeClassPool adopt: nil. ^ #failedDoit]
  			logged: false.
  		Time millisecondsToRun: 
  			[v := cm valueWithReceiver: rcvr arguments: #() ].
  		on: OutOfScopeNotification 
  		do: [ :ex | ex resume: true].
  	"We do not want to have large result displayed"
  	valueAsString := v printString.
  	(valueAsString size > 30) ifTrue: [valueAsString := (valueAsString copyFrom: 1 to: 30), '...'].
  		inform: 'Time to compile and execute: ', result printString, 'ms res: ', valueAsString.

More information about the Squeak-dev mailing list