[BUG]Collection>>removeAll:
Jarvis, Robert P. (Contingent)
Jarvisb at timken.com
Thu Aug 15 12:56:47 UTC 2002
> From: Bergel Alexandre [mailto:bergel at iam.unibe.ch]
> Is it a bug ?
>
> -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
> t := #(1 2 3 4) asOrderedCollection.
> t removeAll: t
> -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
> => an OrderedCollection(2 4)
Try this:
t := #(1 2 3 4) asOrderedCollection.
z := t removeAll: t copy.
t will now be an empty OrderedCollection.
z will be an OrderedCollection containing #(1 2 3 4).
Bob Jarvis
Compuware @ Timken
**********************************************************************
This message and any attachments are intended for the
individual or entity named above. If you are not the intended
recipient, please do not forward, copy, print, use or disclose this
communication to others; also please notify the sender by
replying to this message, and then delete it from your system.
The Timken Company
**********************************************************************
More information about the Squeak-dev
mailing list
|