« Return to Thread: 2.8 collections

Re: 2.8 collections

by Dimitris Andreou :: Rate this Message:

Reply to Author | View in Thread

I see these two methods on sets:

xs put x : Adds element x to xs and returns whether x was previously
contained in the set.
xs remove x : Removes element x from xs and returns whether x was
previously contained in the set.

The semantics of the return values is the opposite of the analogous
methods of java.util.Collection#{add, remove}, is this intentional?
This is bound to create some confusion...

Dimitris

2009/5/18 martin odersky <martin.odersky@...>:

> I have finished a first implementation of 2.8 collections. I'd like to
> submit this as a SIP, so that it can be discussed and improved. For
> practical reasons, the current design is already intregrated in trunk.
> But this should not stop it from being discussed seriously.
>
> Personally, I will let collections rest for the next two weeks or so,
> because I need all my bandwidth for the Eclipse IDE overhoal.
>
> Thanks
>
>  -- Martin
>

 « Return to Thread: 2.8 collections