Pipe syntax and the current methods
Fabio Filasieno
fabio.filasieno at gmail.com
Tue Aug 28 09:14:22 UTC 2007
On Aug 28, 2007, at 12:30 AM, Bert Freudenberg wrote:
>
> With the generic pipe object from my change-set in the original
> thread this gets you both - no need to define new methods:
>
> highestNumberedChangeSet
> "ChangeSorter highestNumberedChangeSet"
> ^self allChangeSetNames asPipe
> select:[:aString | aString startsWithDigit];
> collect:[:aString | aString initialIntegerOrNil];
> ifNotEmpty:[:list | list max]
I have to admit that the asPipe idea is really cool and it might do
the trick.
A minor minor thing: you still need to explain it, and it's better to
have 1 syntax token attached to 1 meaning.
Is a bit ugly that cascade changes it's meaning: sometimes does X,
some times does Y.
Still the asPipe is a very very nice hack.
I think the question is different from adding or not syntax to do a
trick.
Do Small-talkers want to assert:
"Use functional programming when possible"
or not ?
This is question. And I can't answer that.
It's not :
"Shall we add a new syntax token to do the trick ?"
Fabio FIlasieno
PS. Note that I associate functional programming with a chained
application of functions (better if pure)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20070828/5c24c908/attachment.htm
More information about the Squeak-dev
mailing list
|