[Cuis-dev] On the changes to detect method returns in exception handlers

Hernan Wilkinson hernan.wilkinson at 10pines.com
Sat Oct 19 15:03:46 PDT 2019


👏👏👏

On Sat, Oct 19, 2019 at 5:01 PM Juan Vuletich via Cuis-dev <
cuis-dev at lists.cuis.st> wrote:

> On 10/17/2019 5:35 PM, Phil B wrote:
>
> Juan,
>
> On Thu, Oct 17, 2019 at 1:08 PM Juan Vuletich <juan at jvuletich.org> wrote:
>
>> Hi Phil,
>>
>> On 10/17/2019 2:31 AM, Phil B wrote:
>>
>> My changes do two things. One is to avoid non local returns in handler
>>> blocks. The other one is about a few places where you did [ :exception |
>>> exception signal ] as the signal handler. Exceptions can only be signaled
>>> once! I changed them to do [ :exception | exception pass ]. This was
>>> breaking the exception system if the recent changes were loaded.
>>>
>>
>> 1) Would you be opposed to a #nonLocalReturn: method on Exception?  That
>> seems to me a cleaner and clearer way of doing this.  It's also more
>> consistent with how Exception deals with the other scenarios.
>>
>>
>> I think #nonLocalReturn: would be ok. Maybe a better name could be
>> #methodReturn:
>>
>>
> Attached (along with exception recycling).  This was too easy... what did
> I miss?
>
> Thanks,
> Phil
>
>
> Hi Phil,
>
> I just pushed a change that allows for exception recycling without an
> explicit call. The signaling context is reset after handling.
>
> The change set also adds a couple of preferences to control allowing of
> non-local returns in handlers, and the warning shown in the Transcript.
>
> Thanks,
>
> --
> Juan Vuletichwww.cuis-smalltalk.orghttps://github.com/Cuis-Smalltalk/Cuis-Smalltalk-Devhttps://github.com/jvuletichhttps://www.linkedin.com/in/juan-vuletich-75611b3
> @JuanVuletich
>
> --
> Cuis-dev mailing list
> Cuis-dev at lists.cuis.st
> https://lists.cuis.st/mailman/listinfo/cuis-dev
>


-- 

*Hernán WilkinsonAgile Software Development, Teaching & Coaching*
*Phone: +54-011*-4893-2057
*Twitter: @HernanWilkinson*
*site: http://www.10Pines.com <http://www.10pines.com/>*
Address: Alem 896, Floor 6, Buenos Aires, Argentina
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.cuis.st/mailman/archives/cuis-dev/attachments/20191019/5e147adf/attachment.htm>


More information about the Cuis-dev mailing list