[squeak-dev] The Trunk: ScriptLoader-nice.330.mcz

commits at source.squeak.org commits at source.squeak.org
Sun Jan 3 14:52:46 UTC 2010


Nicolas Cellier uploaded a new version of ScriptLoader to project The Trunk:
http://source.squeak.org/trunk/ScriptLoader-nice.330.mcz

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

Name: ScriptLoader-nice.330
Author: nice
Time: 3 January 2010, 3:52:43 am
UUID: 4471623d-cd60-4bd4-b14d-7a9358a3f891
Ancestors: ScriptLoader-ar.329

remove some #or:or: #and:and: sends

=============== Diff against ScriptLoader-ar.329 ===============

Item was changed:
  ----- Method: ScriptLoader>>fixObsoleteReferences (in category 'cleaning') -----
  fixObsoleteReferences
  	"self new fixObsoleteReferences"
  
  	
  	Preference allInstances do: [:each | | informee | 
  		informee := each instVarNamed: #changeInformee.
  		((informee isKindOf: Behavior)
  			and: [informee isObsolete])
  			ifTrue: [
  				Transcript show: each name; cr.
  				each instVarNamed: #changeInformee put: (Smalltalk at: (informee name copyReplaceAll: 'AnObsolete' with: '') asSymbol)]].
   
  	CompiledMethod allInstances do: [:method |
  		| obsoleteBindings |
  		obsoleteBindings := method literals select: [:literal |
  			literal isVariableBinding
+ 				and: [literal value isBehavior
+ 				and: [literal value isObsolete]]].
- 				and: [literal value isBehavior]
- 				and: [literal value isObsolete]].
  		obsoleteBindings do: [:binding |
  			| obsName realName realClass |
  			obsName := binding value name.
  			Transcript show: obsName; cr.
  			realName := obsName copyReplaceAll: 'AnObsolete' with: ''.
  			realClass := Smalltalk at: realName asSymbol ifAbsent: [UndefinedObject].
  			binding isSpecialWriteBinding
  				ifTrue: [binding privateSetKey: binding key value: realClass]
  				ifFalse: [binding key: binding key value: realClass]]].
  
  
  	Behavior flushObsoleteSubclasses.
  	Smalltalk garbageCollect; garbageCollect.
  	SystemNavigation default obsoleteBehaviors size > 0
  		ifTrue: [SystemNavigation default obsoleteBehaviors inspect]!




More information about the Squeak-dev mailing list