Christoph Thiede uploaded a new version of KernelTests to project The Trunk: http://source.squeak.org/trunk/KernelTests-jar.448.mcz
==================== Summary ====================
Name: KernelTests-jar.448 Author: jar Time: 30 December 2023, 6:28:02.589852 pm UUID: 058e235e-90d4-d648-9442-b468fee2bb2e Ancestors: KernelTests-jar.447
Test if #return:from: correctly handles returns to dead or nil contexts.
=============== Diff against KernelTests-jar.447 ===============
Item was added: + ----- Method: ContextTest>>testBlockCannotReturn (in category 'tests') ----- + testBlockCannotReturn + "Test if #return:from: correctly handles returns to dead or nil contexts." + + | p | + p := [ thisContext pc: nil ] newProcess. + p runUntil: [:ctx | ctx method selector = #pc: and: [ctx sender isDead]]. + + "assert p stoped at the last instruction, i.e. a return, of #pc: + and is about to return to a dead context" + self assert: p suspendedContext method selector equals: #pc:. + self assert: p suspendedContext sender isDead. + self assert: p suspendedContext willReturn. + self assert: p suspendedContext atEnd. + + p step. "step into a return to a dead sender" + + self assert: p suspendedContext method selector = #cannotReturn:!
squeak-dev@lists.squeakfoundation.org