[squeak-dev] Re: Empty categories
Andreas Raab
andreas.raab at gmx.de
Wed Feb 10 04:27:00 UTC 2010
Eliot Miranda wrote:
> Pedantry:
> [block value]
> on: Error
> do: [:error | Transcript show: error;
> cr]]].
>
> is equivalent to
>
> block
> on: Error
> do: [:error | Transcript show: error;
> cr]]].
Since we're being pedantic, we should also make the point that the above
is only equivalent if the "block" argument truly is an instance of
BlockClosure. If you have reason to expect that it might be useful to
support something else (MessageSend etc) then it's not equivalent at
all. If in doubt, use the first form.
Cheers,
- Andreas
More information about the Squeak-dev
mailing list
|