RFR: 8293984: Unnecessary Vector usage in PropertyEditorSupport [v2]

Andrey Turbanov aturbanov at openjdk.org
Sun Oct 9 21:03:54 UTC 2022


On Fri, 7 Oct 2022 00:07:31 GMT, Sergey Bylokhov <serb at openjdk.org> wrote:

>> Andrey Turbanov has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   8293984: Unnecessary Vector usage in PropertyEditorSupport
>>   
>>   use ArrayList constructor instead of clone
>
> src/java.desktop/share/classes/java/beans/PropertyEditorSupport.java line 301:
> 
>> 299:     @SuppressWarnings("unchecked")
>> 300:     private <T> ArrayList<T> unsafeClone(ArrayList<T> v) {
>> 301:         return (ArrayList<T>)v.clone();
> 
> I think this can be simplified by using the new list in place of "unsafeClone".

Updated

-------------

PR: https://git.openjdk.org/jdk/pull/10331



More information about the client-libs-dev mailing list