File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -8,6 +8,13 @@ A [separate changelog is kept for rand_core](https://github.com/rust-random/core
88
99You may also find the [ Upgrade Guide] ( https://rust-random.github.io/book/update.html ) useful.
1010
11+ ## [ Unreleased]
12+
13+ ### Additions
14+ - Expose ` ThreadRngCore ` ([ #1750 ] )
15+
16+ [ #1750 ] : https://github.com/rust-random/rand/pull/1750
17+
1118## [ 0.10.0] - 2026-02-08
1219
1320### Changes
Original file line number Diff line number Diff line change 5252//!
5353//! ### Additional generators
5454//!
55+ //! - [`ThreadRngCore`] is the underlying, periodically seeded PRNG of
56+ //! [`ThreadRng`] that allows users to utilize the same reseeding generator
57+ //! where `Send` or `Sync` is required.
5558//! - The [`rdrand`] crate provides an interface to the RDRAND and RDSEED
5659//! instructions available in modern Intel and AMD CPUs.
5760//! - The [`rand_jitter`] crate provides a user-space implementation of
@@ -110,7 +113,7 @@ pub use xoshiro256plusplus::Xoshiro256PlusPlus;
110113#[ cfg( feature = "std_rng" ) ]
111114pub use self :: std:: StdRng ;
112115#[ cfg( feature = "thread_rng" ) ]
113- pub use self :: thread:: ThreadRng ;
116+ pub use self :: thread:: { ThreadRng , ThreadRngCore } ;
114117
115118#[ cfg( feature = "chacha" ) ]
116119pub use chacha20:: { ChaCha8Rng , ChaCha12Rng , ChaCha20Rng } ;
Original file line number Diff line number Diff line change @@ -76,9 +76,10 @@ impl ReseedingCore {
7676
7777/// The [`ThreadRng`] internal
7878///
79- /// This type is the actual pseudo-random number generator that powers [`ThreadRng`]. The same
80- /// Security design criteria and consideration as those of [`ThreadRng`] apply, whereas it allows
81- /// users to utilize the same reseeding generator where `Send` or `Sync` is required.
79+ /// This type is the underlying, periodically seeded pseudorandom number generator that powers
80+ /// [`ThreadRng`]. The same Security design criteria and consideration as those of [`ThreadRng`]
81+ /// apply, whereas it allows users to utilize the same reseeding generator where `Send` or `Sync`
82+ /// is required.
8283pub struct ThreadRngCore {
8384 inner : BlockRng < ReseedingCore > ,
8485}
You can’t perform that action at this time.
0 commit comments