[squeak-dev] ifNotNil: takes block with one argument. Why not
ifNil:ifNotNil:?
David T. Lewis
lewis at mail.msen.com
Wed Apr 30 02:44:31 UTC 2008
On Tue, Apr 29, 2008 at 11:43:44AM +0100, John Thornborrow wrote:
> >I always use ifNotNilDo: (or ifNil:ifNotNilDo: or variant) if I need to
> >use a block with one argument. ifNotNil: sends valueWithPossibleArgs: so
> >you don't have to send a block with an argument.
> >
> and just to add, when I try and use a one-arg block and try to 'do' it,
> I am told: " <- argument of ifNotNil: must be a 0-argument block ->"
This bug is documented on Mantis at http://bugs.squeak.org/view.php?id=4867
Dave
More information about the Squeak-dev
mailing list
|