PositionnableStream>>peekFor: not standard

James Foster Smalltalk at JGFoster.net
Fri Mar 2 00:26:50 UTC 2007


The final standard is copyrighted and not freely available on the web. 

gettableStream>>peek is described as follows:
"Returns the first object in the receiver's future sequence values. The
object is not removed from the future sequence values. The returned object
must conform to the receiver's sequence value type. Returns nil if the
receiver has no future sequence values. The return value will also be nil if
the first future sequence object is nil."

gettableStream>>peekFor: is described as follows:
"Returns the result of sending #= to the first object in the receiver's
future sequence values with anObject as the argument. Returns false if the
receiver has no future sequence values."

Note that while #peek explicitly says that the object is not removed, the
#peekFor: description does not discuss this question at all. To argue that
advancing the position is not standard is to argue from silence. I'd say
that the much better assumption is that this was simply an oversight and
that the intent of the committee was to document the universal
implementation of this method. (Note that the draft standard was widely
distributed and those of us following comp.lang.smalltalk at the time had a
chance to catch this omission. Calling this an oversight is not intended as
a criticism of those who worked quite hard on a generally very useful
document.)

James Foster

> -----Original Message-----
> From: squeak-dev-bounces at lists.squeakfoundation.org [mailto:squeak-dev-
> bounces at lists.squeakfoundation.org] On Behalf Of stephane ducasse
> Sent: Thursday, March 01, 2007 1:56 PM
> To: The general-purpose Squeak developers list
> Subject: Re: PositionnableStream>>peekFor: not standard
> 
> does somebody has the latest version of the standard because the
> version we have is a beta from 1993?
> After indeed this is strange that with such a consensus they got that
> because on the other part they made a good job.
> 
> Stef
> 




More information about the Squeak-dev mailing list