[TEST][BUG][BC][V4] cannotReturn: not being caught by handler
Rob Withers
rwithers12 at mediaone.net
Sat Jan 26 07:02:17 UTC 2002
Anthony and Boris,
Attached is a merged test case for our two tests. I refactored the code I
had written and you, Boris, had repaired. I almost never write code that
returns a block, so I don't have a good feel for the rule that you cannot
explicitly return out of a block that was created in a context that no
longer exists.
The is still a bug in this scenario, after Anthony's last fix (to:by:do:
fix) the test for cannotReturn fails to throw the exception into the test
case handler. I won't even begin to guess why this is, being that it is in
the middle of non-local activity. So I will have to punt this one as
well. :( Sorry about that.
I updated the block closure site, with this test case changeset, and
removed the link to the other test changeset. Does it look alright to you,
Boris?
Rob
At 04:04 PM 1/25/2002, you wrote:
>The problem with ClosureTestCase>>#constructFibonacciBlock is that it
>has returns (^) that get executed after its home context has alread
>returned, so it has no where to return to. My error is that this should
>raise a
>cannotReturn: instead of blowing up on a dead frame. I will fix this.
>If you remove the returns the test case will work. If you want you can
>change '^' to 'thisContext return:' to do a local return.
>
>I posted Rob's and Boris's test case on the block closure page ("New
>Block Closure Version"). Thanks, guys.
>
>Cheers,
>Anthony
-------------- next part --------------
A non-text attachment was scrubbed...
Name: ClosureTestCase-rww-bg.2.cs
Type: application/octet-stream
Size: 21384 bytes
Desc: not available
Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20020126/b7c6fc0d/ClosureTestCase-rww-bg.2.obj
More information about the Squeak-dev
mailing list
|