[ANSI-Smalltalk] on the pitfalls of design... (short :-)
Paolo Bonzini
bonzini at gnu.org
Mon Mar 17 15:47:20 GMT 2008
>>> (OrderedCollection new <- true <- false <- #foo)
>> No, this cannot work, because by your definition you have
>>
>> Collection >> <-anObject
>> self add: anObject
> I don't think I gave the above definition anywhere (did I?).
> It's not my definition. The definition I had in mind was
>
> Object >> <- anObject
> ^ OrderedCollection new add: self; add: anObject; yourself
The above code gives
OrderedCollection (OrderedCollection (OrderedCollection
(OrderedCollection () true ) false ) #foo )
I also agree going on with this is pointless, I don't want to have "the
last word" on anything. Consensus should be reached by discussion.
But I think we *can* get a lesson we all agree with, from this thread:
>> Defining new language elements is hard.
>
> As I already said, this is not about defining new elements
A "new language element" is anything whose use can become pervasive
enough that it becomes a common language idiom. It need not have any
syntactic part in it, it *can* be a couple of messages as in your
example -- but this does not mean we need to be any less careful in
defining it.
Paolo
More information about the ANSI-Smalltalk
mailing list