[Seaside-dev] Seaside and exception behaviour

Paolo Bonzini bonzini at gnu.org
Sun Jan 9 17:11:38 UTC 2011


On Wed, Jan 5, 2011 at 17:23,  <mkobetic at cincom.com> wrote:
> "Paolo Bonzini"<bonzini at gnu.org> wrote:
>> Does VW have #on:do:on:do:?  If so, what happens for
>>
>>       [       [       self error: 'trigger error'
>>               ] on: ZeroDivide do: [ :ex | 'Squeak' ]
>>       ] on: Error do: [ :ex | 3 / 0 ]
>>         on: ZeroDivide do: [ :ex | 'VW' ]
>
> It doesn't. Personally, without knowing much about the intent of on:do:on:do

It's the same as two nested on:do: except that: 1) the handlers are
automatically reordered so that the most specific goes first; 2) after
this change, search would start outside _both_ handlers.

> Or to put it differently I'd expect on: X do: [X] on: Y do: [Y] to be
> equivalent to on: X, Y do: [ :ex | (X handles: ex) ifTrue: [X] ifFalse: [Y]],
> if that makes sense.

Yes, that would take care of (2).

Paolo


More information about the seaside-dev mailing list