RFR: 8372134: ThreadLocalRandom no longer overrides nextGaussian [v2]
James Yuzawa
duke at openjdk.org
Wed Nov 26 22:08:15 UTC 2025
On Wed, 26 Nov 2025 16:35:10 GMT, Alan Bateman <alanb at openjdk.org> wrote:
>> James Yuzawa has updated the pull request incrementally with one additional commit since the last revision:
>>
>> 8372134: ThreadLocalRandom no longer overrides nextGaussian
>>
>> Fix javadoc
>
> src/java.base/share/classes/java/util/concurrent/ThreadLocalRandom.java line 507:
>
>> 505: * {@link java.util.Random#nextGaussian()} and instead uses the
>> 506: * ziggurat-based algorithm from the default implementation of
>> 507: * {@link java.util.random.RandomGenerator#nextGaussian()}.
>
> The implNotes in this class start with "This method is implemented ...". How about: "This implementation invokes the default implementation of RandomGenerator.nextGaussian and so uses McFarland's fast modified ziggurat algorithm rather than the polar method described in the super class."
Done
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/28483#discussion_r2566596488
More information about the core-libs-dev
mailing list