[squeak-dev] Fixing a terminate bug

Jaromir Matas mail at jaromir.net
Wed Jun 8 21:28:11 UTC 2022


Hi Marcel,

Could you please merge Kernel-jar.1478 fixing a silly bug I missed; while searching for a context that cannot return (to avoid the VM crash after BCR error) I forgot to limit the search to the relevant part of the stack only (i.e. search only between the contexts to be executed). As a result the following example currently fails to unwind:

p := [[[^2] on: BlockCannotReturn do: [Semaphore new wait]] ensure: [Transcript show: 'been here ']] fork.
Processor yield.
[p terminate] fork

Plus a minor change to allow unwinding even in this case (starts searching again right below the cannot return context in case one is found):

p := [[] ensure: [[[^2] on: BlockCannotReturn do: [Semaphore new wait]] ensure: [Transcript show: 'been here ']]] fork.
Processor yield.
[p terminate] fork

Thanks very much.

best,
Jaromir


--

Jaromír Matas

mail at jaromir.net

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20220608/615bdfe6/attachment.html>


More information about the Squeak-dev mailing list