[Pharo-project] Finding all places where a class is instantiated?

Stefan Marr smalltalk at stefan-marr.de
Sun Jan 15 17:59:58 CET 2012

Hi Lukas:

On 15 Jan 2012, at 17:46, Lukas Renggli wrote:

> Depends on how you use your classes.
> If you have have a finite set of constructor methods you can use
> 'Refactor > Search code...' with something like this:
> RBParseTreeSearcher new
> 	matches: 'PluggableButtonMorph on: `@.arg1' do: [ :node :answer | node ];
> 	matches: 'PluggableButtonMorph on: `@.arg1 getState: `@.arg2 action:
> `@.arg3' do: [ :node :answer | node ];
> 	yourself
> Of course, if you put all your constructor methods into a distinct
> protocol, you could automate the creation of the searcher.

Hm, I should probably find out how to use that. But the code is old and not properly categorized, and all in all also not large enough to really worry.

It is just one of those Sundays where these kind of little things are annoying ;)


Stefan Marr
Software Languages Lab
Vrije Universiteit Brussel
Pleinlaan 2 / B-1050 Brussels / Belgium
Phone: +32 2 629 2974
Fax:   +32 2 629 3525

More information about the Pharo-project mailing list