nicolas cellier wrote:
James Foster a écrit :
Actually, in this case I'd suggest that we change the standard! In each of the six Smalltalk dialects I have available (Dolphin, GemStone, Squeak, VisualAge, VisualSmalltalk, VisualWorks) the following returns true:
((ReadStream on: 'abc') peekFor: $a; next) = $b.
Also add stx (Smalltalk-X) and gst (GNU Smalltalk) to the list.
I can't help but wonder how ANSI ended up with that definition if basically every Smalltalk in existence does it differently. Just one of those "design by committee" decisions? Or perhaps there is a good reason for it that just never made the light of the day? Mostly, the standards committee seemed to have gone with existing notions if there wide agreement on them - peekFor: seems to be one of those cases where the standard went wildly differently and I really wonder why.
Cheers, - Andreas