File tree Expand file tree Collapse file tree 2 files changed +12
-1
lines changed Expand file tree Collapse file tree 2 files changed +12
-1
lines changed Original file line number Diff line number Diff line change @@ -12,7 +12,7 @@ use std::env;
12
12
use std:: io:: { self , Error , ErrorKind } ;
13
13
use std:: fs;
14
14
use std:: path:: { self , PathBuf , Path } ;
15
- use std:: rand :: { thread_rng, Rng } ;
15
+ use std:: __rand :: { thread_rng, Rng } ;
16
16
17
17
/// A wrapper for a path to temporary directory implementing automatic
18
18
/// scope-based deletion.
Original file line number Diff line number Diff line change @@ -280,6 +280,17 @@ pub mod rt;
280
280
mod panicking;
281
281
mod rand;
282
282
283
+ // Some external utilities of the standard library rely on randomness (aka
284
+ // rustc_back::TempDir and tests) and need a way to get at the OS rng we've got
285
+ // here. This module is not at all intended for stabilization as-is, however,
286
+ // but it may be stabilized long-term. As a result we're exposing a hidden,
287
+ // unstable module so we can get our build working.
288
+ #[ doc( hidden) ]
289
+ #[ unstable( feature = "rand" ) ]
290
+ pub mod __rand {
291
+ pub use rand:: { thread_rng, Rng } ;
292
+ }
293
+
283
294
// Modules that exist purely to document + host impl docs for primitive types
284
295
285
296
mod array;
You can’t perform that action at this time.
0 commit comments