[squeak-dev] The Trunk: System-mt.1073.mcz

commits at source.squeak.org commits at source.squeak.org
Mon Jul 22 09:45:00 UTC 2019


Marcel Taeumel uploaded a new version of System to project The Trunk:
http://source.squeak.org/trunk/System-mt.1073.mcz

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

Name: System-mt.1073
Author: mt
Time: 22 July 2019, 11:44:51.098271 am
UUID: 03eef6f8-69b5-4a5b-8b2b-9e47fccae8f2
Ancestors: System-mt.1072

Adds support for class bindings to system navigation.

Not sure about "self environment" vs. "aClass environment" because tools will usually create a system navigation with the correct environment set.

=============== Diff against System-mt.1072 ===============

Item was changed:
  ----- Method: SystemNavigation>>allCallsOnClass: (in category 'query') -----
+ allCallsOnClass: aBehaviorOrBinding
- allCallsOnClass: aBehavior
  	"Answer a sorted collection of all the methods that refer to aBehavior."
  	
+ 	| binding thisClass result |
+ 	binding := aBehaviorOrBinding isBehavior
+ 		ifTrue: [self environment bindingOf: aBehaviorOrBinding theNonMetaClass name]
+ 		ifFalse: [aBehaviorOrBinding].
+ 	thisClass := binding value.
+ 	
- 	| theClass result |
- 	theClass := aBehavior theNonMetaClass.
  	result := self 
+ 		allCallsOn: binding
- 		allCallsOn: (theClass environment bindingOf: theClass name)
  		fromBehaviors: self allBehaviors
  		sorted: false.
+ 
+ 	self environment allClassesDo: [:otherClass |
+ 		(otherClass sharedPools includes: thisClass) ifTrue: [
+ 			result add: (ClassReference class: otherClass) ] ].
+ 	
+ 	^ result sort!
- 	theClass environment allClassesDo: [ :class |
- 		(class sharedPools includes: theClass) ifTrue: [
- 			result add: (ClassReference class: class) ] ].
- 	^result sort!

Item was changed:
  ----- Method: SystemNavigation>>browseAllCallsOnClass: (in category 'browse') -----
+ browseAllCallsOnClass: aBehaviorOrBinding
- browseAllCallsOnClass: aBehavior
  	"Create and schedule a message browser on each method that refers to aBehavior."
  	"self default browseAllCallsOnClass: Array"
  	
  	| behaviorName |
+ 	behaviorName := aBehaviorOrBinding isBehavior
+ 		ifTrue: [aBehaviorOrBinding theNonMetaClass name]
+ 		ifFalse: [aBehaviorOrBinding key].
- 	behaviorName := aBehavior theNonMetaClass name.
  	self
+ 		browseMessageList: [ self allCallsOnClass: aBehaviorOrBinding ]
- 		browseMessageList: [ self allCallsOnClass: aBehavior ]
  		name: 'Users of ', behaviorName
  		autoSelect: behaviorName!



More information about the Squeak-dev mailing list