Magma1.0-cmm.4 (was: Double the size)
Chris Muller
chris at funkyobjects.org
Fri Feb 24 06:45:08 UTC 2006
Hm, you definitely found a bug. Enumerating a
non-persistent MagmaCollection (as opposed to a
Reader) is very rare, so I'm not surprised no one
noticed this.
I have now posted Magma1.0-cmm.4 on SqueakSource which
fixes this bug. A quick fix, but the test cases
passed.
Thank you, Brian, for pointing it out and also for
providing such an easy way to reproduce it. Easily
reproduced = easily fixed!
- Chris
PS - Your e-mail was rejected by the list, I had to
manually approve it. I hope you will join us on the
Magma list.
--- Brian Murphy-Dye <brian.murphy-dye at sri.com> wrote:
> The following code snippet shows a size of 10, but
> #do: processes
> those 10 items twice. Any ideas what I'm doing
> wrong?
>
> m := MagmaCollection new.
> 1 to: 10 do: [:each | m add: each].
> Transcript show: String cr, 'size: ', m size
> asString, String cr.
> m do: [:each | Transcript show: each asString,
> String cr].
>
> Brian.
>
>
More information about the Magma
mailing list