Rollup merge of #130811 - RalfJung:random, r=joboet

add link from random() helper fn to extensive DefaultRandomSource docs
This commit is contained in:
Matthias Krüger 2024-09-25 20:10:59 +02:00 committed by GitHub
commit 3ee3e063c1
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -71,7 +71,8 @@ impl RandomSource for DefaultRandomSource {
/// ///
/// This is a convenience function for `T::random(&mut DefaultRandomSource)` and /// This is a convenience function for `T::random(&mut DefaultRandomSource)` and
/// will sample according to the same distribution as the underlying [`Random`] /// will sample according to the same distribution as the underlying [`Random`]
/// trait implementation. /// trait implementation. See [`DefaultRandomSource`] for more information about
/// how randomness is sourced.
/// ///
/// **Warning:** Be careful when manipulating random values! The /// **Warning:** Be careful when manipulating random values! The
/// [`random`](Random::random) method on integers samples them with a uniform /// [`random`](Random::random) method on integers samples them with a uniform