On Fri, 25 Mar 2022 17:27:32 GMT, Naoto Sato <na...@openjdk.org> wrote:

>> Claes Redestad has updated the pull request incrementally with one 
>> additional commit since the last revision:
>> 
>>   Override ZoneOffset::normalized, cache ZoneOffset::getRules, revert change 
>> to add 2nd parameter to ZoneId::getOffset
>
> test/micro/org/openjdk/bench/java/time/GetYearBench.java line 66:
> 
>> 64:     private TimeZone UTC = TimeZone.getTimeZone("UTC");
>> 65: 
>> 66:     private TimeZone LONDON = TimeZone.getTimeZone("Europe/London");
> 
> Nit: No need to use `TimeZone.getTimeZone()` here (and later convert them to 
> `toZoneId()`). `ZoneId.of()` should suffice.

It was somewhat intentional to do it like way in this microbenchmark experiment 
to check that the `toZoneId()` doesn't cause surprises and ideally that it 
doesn't cost anything.

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

PR: https://git.openjdk.java.net/jdk/pull/7957

Reply via email to