[squeak-dev] The Trunk: System-cwp.660.mcz
Colin Putney
colin at wiresong.com
Sat Jan 11 16:37:42 UTC 2014
On Sat, Jan 11, 2014 at 3:13 AM, Levente Uzonyi <leves at elte.hu> wrote:
>
> I think it might help in this case, to ask for the next object before
> evaluating the block in the loop of #allObjectsDo:
>
> [lastObject == object]
> whileFalse: [
> | nextObject |
> nextObject := object nextObject.
> aBlock value: object.
> object := nextObject]
>
>
Yes, that's definitely an improvement.
One thing I still don't understand, though, is why we get 0. In theory, we
need the sentinel to prevent an infinite loop, but when we skip over it, we
still get to the end of the object memory.
Colin
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20140111/2e4e9aca/attachment.htm
More information about the Squeak-dev
mailing list
|