[squeak-dev] The Trunk: System-ul.940.mcz

commits at source.squeak.org commits at source.squeak.org
Tue Mar 21 17:57:00 UTC 2017


Levente Uzonyi uploaded a new version of System to project The Trunk:
http://source.squeak.org/trunk/System-ul.940.mcz

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

Name: System-ul.940
Author: ul
Time: 21 March 2017, 6:55:02.32896 pm
UUID: bb942b8d-8893-42f6-b10f-ba058fbda68c
Ancestors: System-ul.939

- SmalltalkImage >> #specialSelectors returns the raw array used by the VM
- introduced SmalltalkImage >> #specialSelectorNames, which returns just the names of the special selectors without their argument count

=============== Diff against System-ul.939 ===============

Item was added:
+ ----- Method: SmalltalkImage>>specialSelectorNames (in category 'special objects') -----
+ specialSelectorNames
+ 	"Return a collection with the names of the special selectors."
+ 	
+ 	| arrayOfPairs |
+ 	arrayOfPairs := self specialSelectors.
+ 	^Array new: arrayOfPairs size // 2 streamContents: [ :stream |
+ 		arrayOfPairs pairsDo: [ :selector :numArgs |
+ 			stream nextPut: selector ] ]
+ !

Item was changed:
  ----- Method: SmalltalkImage>>specialSelectors (in category 'special objects') -----
  specialSelectors
+ 	"Return an array with flattened special selector - argument count pairs. VMMaker relies on this."
  	
+ 	^self specialObjectsArray at: 24!
- 	| arrayOfPairs |
- 	arrayOfPairs := self specialObjectsArray at: 24.
- 	^Array new: arrayOfPairs size // 2 streamContents: [ :stream |
- 		arrayOfPairs pairsDo: [ :selector :numArgs |
- 			stream nextPut: selector ] ]
- !

Item was changed:
  ----- Method: SystemNavigation>>allSentMessagesWithout: (in category 'query') -----
  allSentMessagesWithout: classesAndMessagesPair 
  	"Answer the set of selectors which are sent somewhere in the system,  
  	computed in the absence of the supplied classes and messages."
  	| sent absentClasses absentSelectors |
  	sent := IdentitySet new: CompiledMethod instanceCount.
  	absentClasses := classesAndMessagesPair first.
  	absentSelectors := classesAndMessagesPair second.
  	"sd 29/04/03"
  	Cursor execute showWhile: [
  		self environment allClassesAndTraitsDo: [:cls |
  			((absentClasses includes: cls name)
  				ifTrue: [{}]
  				ifFalse: [{cls. cls classSide}])
  					do: [:each | (absentSelectors isEmpty
  						ifTrue: [each selectors]
  						ifFalse: [each selectors copyWithoutAll: absentSelectors])
  						do: [:sel | "Include all sels, but not if sent by self"
  							(each compiledMethodAt: sel) literalsDo: [:m | 
  									(m isSymbol)
  										ifTrue: ["might be sent"
  											m == sel
  												ifFalse: [sent add: m]].
  									(m isMemberOf: Array)
  										ifTrue: ["might be performed"
  											m
  												do: [:x | (x isSymbol)
  														ifTrue: [x == sel
  																ifFalse: [sent add: x]]]]]]]]].
  	"The following may be sent without being in any literal frame"
+ 	Smalltalk specialSelectorNames do: [:sel | sent add: sel].
- 	Smalltalk specialSelectors do: [:sel | sent add: sel].
  	Smalltalk presumedSentMessages	do: [:sel | sent add: sel].
  	^ sent.!



More information about the Squeak-dev mailing list