[BUG] ReadStream>>isEmpty ?

Ken Causey ken at kencausey.com
Fri Aug 8 20:27:46 UTC 2003


That simple of a solution won't work either.  ReadStream>>size simply
returns readLimit which can be non-zero and still mean there is that can
be read from the stream.  I'm at a loss to say what isEmpty should mean
in the current context where the size of the stream does not necessarily
match the number of item you get if you iterate through it.

Ken

On Fri, 2003-08-08 at 15:18, Chris Muller wrote:
> > As a followup, redefining PositionableStream>>isEmpty to collection
> > isEmpty breaks quite a few things including the use of backspace in most
> > text panes and selecting from the stack list in the debugger.
> 
> A safer bet would be to implement isEmpty in ReadStream to:
> 
>   ^self size = 0
> 
> Did you try that and did you notice any impacts?
> 
> 

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part
Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20030808/9e9c829c/attachment.pgp


More information about the Squeak-dev mailing list