On Wed, 17 Feb 2021 19:56:01 GMT, Ian Graves wrote:
>> Modify the `unmodifiable*` methods in `java.util.Collections` to be
>> idempotent. That is, when given an immutable collection from
>> `java.util.ImmutableCollections` or `java.util.Collections`, these methods
>> will return the reference
On Thu, 18 Feb 2021 16:18:42 GMT, jmehrens
wrote:
>> Yes -- I think in response to this it makes more sense to pull the
>> `ImmutableCollections` classes out for now and only focus on the wrapping of
>> the classes within `Collections` so we aren't blocked by studying and
>> rectifying these
On Wed, 17 Feb 2021 19:12:19 GMT, Ian Graves wrote:
>> This raises some interesting issues and makes me wonder if we should allow a
>> single-wrap of the `ImmutableCollections` classes for now to make this less
>> onerous.
>
> Yes -- I think in response to this it makes more sense to pull the
On Wed, 17 Feb 2021 14:14:57 GMT, Claes Redestad wrote:
>> No? This unmodifiable set here just delegates call to the backing field `c`,
>> so all exceptions from `c`'s calls are just delegated, aren't they? The NPE
>> will still be thrown; it's just that the stack trace will be different (i.e.
> Modify the `unmodifiable*` methods in `java.util.Collections` to be
> idempotent. That is, when given an immutable collection from
> `java.util.ImmutableCollections` or `java.util.Collections`, these methods
> will return the reference instead of creating a new immutable collection that
> wra