Exception Handling

Zulq Alam zulq at orange.net
Tue Mar 21 13:06:47 UTC 2006


Thank you all. All makes sense now.

Z.

Chris Muller wrote:
> If you wish to handle FooError and UnrelatedToFooError in the same way, you can use the concatenation operator:
>  
>      [ someObject foo ]
>          on: FooError, UnrelatedToFooError
>          do: [ : err | "handle the err" ]
>  
>  If, however, you wish to handle them differently you may nest them:
>  
>      [ [ someObject foo ]
>          on: FooError
>          do: [ :fooErr | "handle fooErr" ] ]
>              on: UnrelatedToFooError
>              do: [ :unToFooErr | "..." ]
>  
>   




More information about the Squeak-dev mailing list