Interrupting a workspace evaluation?

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

Interrupting a workspace evaluation?

Geoffrey King
How do i interrupt a workspace evaluation...preferrably via the
keyboard...so i dont loose my image (again :)

Thanks.


Reply | Threaded
Open this post in threaded view
|

Re: Interrupting a workspace evaluation?

Ian Bartholomew-18
Geoffrey,

> How do i interrupt a workspace evaluation...preferrably via the
> keyboard...so i dont loose my image (again :)

Ctrl-Break will interrupt a workspace evaluation, with the following caveat.

Dolphin's VM only checks for key presses at certain points in it's execution
sequence.  If your evaluation (as it usually will) contains "normal"
Smalltalk message sends then the break response will be almost immediate.
For example, the following breaks quickly

(1 to: 10000000) inject: 0 into: [:sum :each | sum + each]

However, if you evaluation only contains certain optimised message sends, or
code that is very low level and being evaluated in primitives, then the
break request may take some time to be, or might never be, acted upon.

20000 factorial

Evaluating this will not allow Ctrl-Break to interrupt.

(You may want to adjust the above numbers if you are using a slower machine)

--
Ian