The Trunk: System-eem.482.mcz

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

The Trunk: System-eem.482.mcz

commits-2
Eliot Miranda uploaded a new version of System to project The Trunk:
http://source.squeak.org/trunk/System-eem.482.mcz

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

Name: System-eem.482
Author: eem
Time: 8 April 2012, 2:10:18.095 pm
UUID: 257a71d2-4234-44f4-9646-bbd06b7fb551
Ancestors: System-eem.481

allMethodsSelect:localTo: aClass

=============== Diff against System-eem.481 ===============

Item was added:
+ ----- Method: SystemNavigation>>allMethodsSelect:localTo: (in category 'query') -----
+ allMethodsSelect: aBlock localTo: aClass
+ "Answer a SortedCollection of each methodr in, above, or below the given
+ class that, when used as the argument to aBlock, gives a true result."
+
+ | aSet |
+ aSet := Set new.
+ Cursor wait showWhile:
+ [aClass theNonMetaClass withAllSuperAndSubclassesDoGently:
+ [:class |
+ class selectorsAndMethodsDo:
+ [:aSelector :aMethod|
+ (aBlock value: aMethod) ifTrue:
+ [aSet add: (MethodReference new setStandardClass: class methodSymbol: aSelector)]]].
+ aClass theNonMetaClass class withAllSuperAndSubclassesDoGently:
+ [:class |
+ class selectorsAndMethodsDo:
+ [:aSelector :aMethod|
+ (aBlock value: aMethod) ifTrue:
+ [aSet add: (MethodReference new setStandardClass: class methodSymbol: aSelector)]]]].
+ ^aSet!

Item was added:
+ ----- Method: SystemNavigation>>browseAllSelect:localTo: (in category 'browse') -----
+ browseAllSelect: aBlock localTo: aClass
+ "Create and schedule a message browser on each method in or below the given class
+ that, when used as the block argument to aBlock gives a true result. For example,  
+ SystemNavigation default browseAllSelect: [:m | m numLiterals > 10] localTo: Morph."
+ aClass ifNil: [^self inform: 'no class selected'].
+ ^self
+ browseMessageList: (self allMethodsSelect: aBlock localTo: aClass) asSortedCollection
+ name: 'selected messages local to ', aClass name!