RFR: 8001647: In-place methods on Collection/List

Mike Duigou mike.duigou at oracle.com
Thu Apr 18 12:36:59 PDT 2013


Hi Akhil;

List.sort:: 

- @since tag is in a strange location.

- The (optional) on IAE is in a strange position and not linked like the others.


AbstractList::

- Should we consider adding overrides for default methods here even if our impls wouldn't use them? We could at least add modCount checking.

Tests::

- Lots of enhancement here since my last review. Good Job!

- Wrong GPL license. Tests don't get Classpath exemption.

- In Map.Defaults (around line 539 in http://cr.openjdk.java.net/~mduigou/JDK-8010122/6/webrev/test/java/util/Map/Defaults.java.html) I found it useful to generate an implementation of the base interface to directly test the default methods implementations. You may want to add something similar to CollectionExtensionMethodsTest. 

- You may want to include a Collections.newSetFromMap in DataProvider.

- I am now preferring the Iterator<Object[]> return from DataProvider though I haven't made an on-demand provider yet. You could also mark your DataProvider as ", parallel = true"

On Apr 18 2013, at 11:49 , Akhil Arora wrote:

> Looks like the stars are aligning on getting on this into TL... the refreshed webrev is -
> 
> http://cr.openjdk.java.net/~akhil/8001647.8/webrev/
> 
> Please review
> 
> Thanks
> 
> On 12/10/2012 09:31 PM, Akhil Arora wrote:
>> http://cr.openjdk.java.net/~akhil/8001647.3/webrev/
>> 
>> - now with synchronized and unmodifiable wrappers in Collections.java
>> for the default methods being added
>> 
>> On 12/10/2012 01:48 PM, Akhil Arora wrote:
>>> Updated with yours and Alan's comments -
>>> 
>>> http://cr.openjdk.java.net/~akhil/8001647.2/webrev/
>>> 
>>> - removed null check for removeSet
>>> - cache this.size in removeAll, replaceAll
>>>     (for ArrayList, Vector and CopyOnWriteArrayList)
>>> - calculate removeCount instead of BitCount.cardinality()
>>> - removed unnecessary @library from test support classes
> 



More information about the lambda-dev mailing list