newbie digging questions

Dan Ingalls Dan.Ingalls at disney.com
Sun Aug 22 03:40:09 UTC 1999


Tom Morgan <tmorgan at acm.org> wrote...
>Another good way to get a picture of what is going on is
>to insert a 'self halt' in a method of interest, then run something that lands on
>the method.
>
>You can then look around the stack trace and use the inspector to see what
>variables contain.
>
>Programs are dynamic entities; lot's can be learned by reading their
>static source, then more can be learned by watching them
>in execution.

I have heard people say they got a nice overview from running the spy
    [newbies: this means executing, eg, 
        MessageTally spyOn: [1000 timesRepeat: [3.14159 printString]]
    ]
because this presents a hierarchical display of who called who.  However detail in the spy is controlled by time spent and is not always what you want.

In Squeak we are fortunate to have an even more useful tool in the exact tally report from the simulator.  Thus, corresponding to the above, you can execute
        MessageTally tallySends: [3.14159 printString]
and see exactly who called who (and how often) throughout any block of Squeak.

It's not considered a newbie tool, but it sure tells you a lot when you're not familiar with the code.

	- Dan





More information about the Squeak-dev mailing list