Sunday, June 11, 2006

Re: Cool Block Idea

Colin Putney was kind to inform me that #--> method from the previous is already implemented in Squeak! In Squeak, it's called #in:. So, the code before looks like this now:
((2 in: [:x| x * x ]) in: [:x| x + 5 ]) in: [:x| x sqrt ]

How cool is that?

1 comment:

Andres said...

However, --> is better because it avoids parentheses.