[PATCH] Inefficient ArrayList.subList().toArray() (original) (raw)
John Rose john.r.rose at oracle.com
Fri Jan 26 00:41:04 UTC 2018
- Previous message: [PATCH] Inefficient ArrayList.subList().toArray()
- Next message: [PATCH] Inefficient ArrayList.subList().toArray()
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
On Jan 25, 2018, at 2:02 PM, Сергей Цыпанов <sergei.tsypanov at yandex.ru> wrote:
+ return (T[]) Arrays.copyOfRange(root.elementData, offset, size, a.getClass());
Giving this a quick glance: I think you may want s/size/offset+size/. There should be calls to checkForComodification.
- Previous message: [PATCH] Inefficient ArrayList.subList().toArray()
- Next message: [PATCH] Inefficient ArrayList.subList().toArray()
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]