Login  Register

Re: stepping over non local return in a protected block

Posted by marcel.taeumel on Apr 19, 2021; 7:54am
URL: https://forum.world.st/stepping-over-non-local-return-in-a-protected-block-tp5128777p5128838.html

Hmm... at least you get a debugger. In Squeak 5.3, you are not able to put a "self halt" into that event handler in test03EventHandler. ^__^

Yet, I noticed that when stepping over that "^ self dispatchEvent:..." in #dispatchMouseDown:with:, a second debugger appears. That's a bug. The expected behavior would be that the same debugger shows the "halt." I think.



Best,
Marcel

Am 17.04.2021 10:58:06 schrieb Jaromir Matas <[hidden email]>:

Hi Nicolas,


Nicolas Cellier wrote
> When debugging things like this:
>
> [^2] ensure: [Transcript cr; show: 'done'].
>
> if we step into the protected block [^2], then step over ^2, we
> incorrectly get a BlockCannotReturn.

Hmm, that's the bug that plagued #terminate and caused unwind errors... I
didn't fully realize then; I simply avoided it by eliminating the simulation
code from #terminate :) This behavior happens when the VM calls
#aboutToReturn:through: and the Debugger executes #stepOver it (or over
#return:through: or #resume:through:) - sorry if I'm stating the obvious;
unfortunately I have negligible knowledge of the Debugger. I'm really
looking forward to seeing a solution!
Thanks,
best,



-----
^[^ Jaromir
--
Sent from: http://forum.world.st/Squeak-Dev-f45488.html