A Lisper asks, "Am I supposed to like Smalltalk?"
Andreas Raab
andreas.raab at gmx.de
Wed May 17 08:27:43 UTC 2006
Stéphane Rollandin wrote:
> "
> Second is the 'OOP all the way' flavor of the Smalltalk language.
> Sometimes a function is just a function, and doesn't need to be in a
> class. I prefer the options that Lisp provides, I use imperative, OO,
> and functional, depending on the problem.
> "
>
> this is now possible with LambdaMessageSend (on Squeakmap). a function
> can be just a function
Out of curiosity, can you explain to me why using:
f := Lambda x + Lambda y.
f <~~ {3. 4}
would be substantially different from
f := [:x :y| x + y].
f value: 3 value: 4.
(other than that the former looks more unusual ;-) If it's about the
syntax it'd be pretty simple to change the block syntax to something
like here:
f(x, y) := [x + y].
f(3, 4).
[Hm ... actually this *does* look pretty reasonable; I should consider
this for Croquet] I'm in particular curious about your claim this is
"now" possible which seems to imply that there is something
LambdaMessageSend does that blocks/closures for some reason can't
represent properly.
Cheers,
- Andreas
More information about the Squeak-dev
mailing list
|