[Pkg] The Trunk: System-mtf.399.mcz

commits at source.squeak.org commits at source.squeak.org
Sun Dec 12 18:32:57 UTC 2010


Matthew Fulmer uploaded a new version of System to project The Trunk:
http://source.squeak.org/trunk/System-mtf.399.mcz

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

Name: System-mtf.399
Author: mtf
Time: 12 December 2010, 1:31:27.888 pm
UUID: 74bdf8be-686b-4552-9201-b0771ff3639b
Ancestors: System-mtf.293, System-ul.398

fixed Utilities >> pointersTo:except: according to http://bugs.squeak.org/view.php?id=7158

=============== Diff against System-ul.398 ===============

Item was changed:
  ----- Method: Utilities class>>pointersTo:except: (in category 'finding pointers') -----
  pointersTo: anObject except: objectsToExclude 
  	"Find all occurrences in the system of pointers to the argument
  	anObject. Remove objects in the exclusion list from the
  	results. "
+ 	^ anObject inboundPointersExcluding: objectsToExclude!
- 	| results anObj lastObj |
- 	Smalltalk garbageCollect.
- 	"big collection shouldn't grow, so it's contents array is always the same"
- 	results := OrderedCollection new: 1000.
- 	"allObjectsDo: is expanded inline to keep spurious
- 	method and block contexts out of the results"
- 	anObj := self someObject.
- 	lastObj := Object new.
- 	[lastObj == anObj] whileFalse: [
- 		anObj isInMemory ifTrue: [
- 			(anObj pointsTo: anObject) ifTrue: [
- 				"exclude the results collector and contexts in call chain"
- 				(anObj ~~ results collector 
- 					and: [anObj ~~ objectsToExclude
- 					and: [anObj ~~ thisContext
- 					and: [anObj ~~ thisContext sender
- 					and: [anObj ~~ thisContext sender sender]]]])
- 						ifTrue: [results add: anObj]]].
- 		anObj := anObj nextObject].
- 	objectsToExclude do: [:obj | results removeAllSuchThat: [:el | el == obj]].
- 	^ results asArray!



More information about the Packages mailing list