[ANSI-Smalltalk] #contents on <collectionStream> (was: #contents on WriteStream)

cstb jas at cruzio.com
Sat Oct 18 06:36:48 BST 2008


At 12:14 AM 10/16/2008, Paulo wrote:
>In the standard, the definition of #contents for <WriteStream> comes
>from <collectionStream> so that this:
>
>   (WriteStream on: String new) nextPutAll: 'abc'; skip: -1;
>      contents
>
>should "return a collection that contains the receiver's past and future
>sequence values, in order", i.e. 'abc'.  To me it makes more sense that
>it returns 'ab'.
>
>Opinions?


It would be nice if the standard was 
for <collectionStream> to provide both

        contents        ->      upTo: readLimit
and
        currentContents ->      upTo: position


-Jim







More information about the ANSI-Smalltalk mailing list