RFR: 8348351: Improve lazy initialization of the available currencies set [v2]

Justin Lu jlu at openjdk.org
Thu May 8 23:30:06 UTC 2025


On Thu, 8 May 2025 23:08:27 GMT, Chen Liang <liach at openjdk.org> wrote:

>> Justin Lu has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   Chen's review - method name clarification
>
> src/java.base/share/classes/java/util/Currency.java line 471:
> 
>> 469: 
>> 470:     // Builds and returns the set of available Currencies
>> 471:     private static HashSet<Currency> getCurrencies() {
> 
> I think we should rename this to `computeCurrencies` or `makeCurrencies` to indicate we are creating a new instance.

Definitely; updated in https://github.com/openjdk/jdk/pull/25134/commits/e2672ba1846c17b723d6bcbee0ef20488c0dca24.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/25134#discussion_r2080621783


More information about the core-libs-dev mailing list