Collectors update
Remi Forax
forax at univ-mlv.fr
Tue Jan 29 17:21:54 PST 2013
On 01/30/2013 02:09 AM, Brian Goetz wrote:
>> why not using a Supplier ?
>
> How is that better?
yes, I was just answering to why using IntFunction,
it doesn't solve the type safety issue.
> It still has all the safety problems, PLUS the risk that the user
> serves up an array other than size 2.
even if the argument is 2, user can create an array of 1.
> And prevents the user from using array ctor refs (Foo[]::new).
>
yes.
Rémi
More information about the lambda-libs-spec-experts
mailing list