[squeak-dev] 'Method for block not found on stack, can''t edit and continue'

Frank Shearar frank.shearar at gmail.com
Mon Jan 20 22:01:18 UTC 2014


I often use Blocks for holding tiny bits of state not worth
formalising as a class. As a result, I often get this error because I
also spend a lot of time developing in the Debugger.

Is the following a completely crazy idea?

self selectedContext activeHome ifNil: [ |ctxt|
    ctxt := self selectedContext.
    "look up ctxt method methodClass >> ctxt selector."
    "Save the code as normal"
    ctxt method become: ctxt method methodClass >> ctxt selector].

You'd need to fiddle the stack pointer, but that you have to do anyway
in edit-and-continue.

frank


More information about the Squeak-dev mailing list