[squeak-dev] Intersection of Bags
Chris Muller
asqueaker at gmail.com
Fri Jan 6 05:47:31 UTC 2023
>
> We have
>
> (Bag with: 1 with: 1 with: 1) intersection: (Bag with: 1)
> -->
> (Bag with: 1 with: 1 with: 1)
>
> and:
>
> (Bag with: 1) intersection: (Bag with: 1 with: 1 with: 1)
> -->
> (Bag with: 1)
>
> Is that a bug or a feature?
>
Such abstract behavior can't be classified as either. The decision has to
be based on the receiver of #intersection: message. Note Array behaves the
same.
Best,
Chris
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20230105/31395ad0/attachment.html>
More information about the Squeak-dev
mailing list
|