RFR: 8271603: Unnecessary Vector usage in java.desktop

2021-08-09 Thread Andrey Turbanov
Usage of thread-safe collection `Vector` is unnecessary. It's recommended to use `ArrayList` if a thread-safe implementation is not needed. In post-BiasedLocking times, this is gets worse, as every access is synchronized. I checked only places where `Vector` was used as local variable. -

Re: RFR: 8271603: Unnecessary Vector usage in java.desktop

2021-08-09 Thread Сергей Цыпанов
On Sun, 4 Jul 2021 20:42:41 GMT, Andrey Turbanov wrote: > Usage of thread-safe collection `Vector` is unnecessary. It's recommended to > use `ArrayList` if a thread-safe implementation is not needed. In > post-BiasedLocking times, this is gets worse, as every access is synchronized. > I checke

Re: RFR: 8271603: Unnecessary Vector usage in java.desktop

2021-08-09 Thread Andrey Turbanov
On Mon, 5 Jul 2021 14:03:18 GMT, Сергей Цыпанов wrote: >> Usage of thread-safe collection `Vector` is unnecessary. It's recommended to >> use `ArrayList` if a thread-safe implementation is not needed. In >> post-BiasedLocking times, this is gets worse, as every access is >> synchronized. >> I

Re: RFR: 8271603: Unnecessary Vector usage in java.desktop

2021-08-09 Thread Сергей Цыпанов
On Mon, 5 Jul 2021 19:03:49 GMT, Andrey Turbanov wrote: >> src/java.desktop/share/classes/java/awt/Menu.java line 489: >> >>> 487: } >>> 488: >>> 489: synchronized Enumeration shortcuts() { >> >> I'm not sure whether it's ok to change return type here, probably it'd be >> better to k

Re: RFR: 8271603: Unnecessary Vector usage in java.desktop

2021-08-09 Thread Sergey Bylokhov
On Sun, 4 Jul 2021 20:42:41 GMT, Andrey Turbanov wrote: > Usage of thread-safe collection `Vector` is unnecessary. It's recommended to > use `ArrayList` if a thread-safe implementation is not needed. In > post-BiasedLocking times, this is gets worse, as every access is synchronized. > I checke

Re: RFR: 8271603: Unnecessary Vector usage in java.desktop

2021-08-09 Thread Sergey Bylokhov
On Mon, 5 Jul 2021 14:00:07 GMT, Сергей Цыпанов wrote: >> Usage of thread-safe collection `Vector` is unnecessary. It's recommended to >> use `ArrayList` if a thread-safe implementation is not needed. In >> post-BiasedLocking times, this is gets worse, as every access is >> synchronized. >> I

Integrated: 8264792: The NumberFormat for locale sq_XK formats price incorrectly.

2021-08-09 Thread Naoto Sato
On Fri, 6 Aug 2021 16:39:34 GMT, Naoto Sato wrote: > Please review the fix to the subject issue. The root cause of this problem is > that the currency for the country code `XK` is undefined because the country > code is user-defined in the ISO 3166 standard. However, it is commonly used > to r

Re: RFR: 8271603: Unnecessary Vector usage in java.desktop

2021-08-09 Thread Phil Race
On Tue, 6 Jul 2021 11:32:18 GMT, Сергей Цыпанов wrote: >> It's not a public API. As I see from other PR/commits changing >> package-private methods shouldn't be a problem. > > Even non-public method can be called via reflection, so I'd be cautios about > changing return type Apps should not b

Re: RFR: 8271603: Unnecessary Vector usage in java.desktop

2021-08-09 Thread Phil Race
On Sun, 4 Jul 2021 20:42:41 GMT, Andrey Turbanov wrote: > Usage of thread-safe collection `Vector` is unnecessary. It's recommended to > use `ArrayList` if a thread-safe implementation is not needed. In > post-BiasedLocking times, this is gets worse, as every access is synchronized. > I checke