[ANSI-Smalltalk] #contents on WriteStream
Paolo Bonzini
bonzini at gnu.org
Fri Oct 17 08:21:02 BST 2008
Bruce Badger wrote:
> On 17/10/2008, Richard O'Keefe <ok at cs.otago.ac.nz> wrote:
>> What I don't understand is why WriteStream and ReadWriteStream
>> should do _different_ things with #contents.
>
> Because a write stream modifies contents and a read stream does not.
> I imagine what I would find in a file if I closed a file stream at a
> given point. In Paolo's example, I would find 'ab' in the file.
Actually, without an explicit #truncate you wouldn't...
Paolo
More information about the ANSI-Smalltalk
mailing list