We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent f38dba6 commit ea9cff2Copy full SHA for ea9cff2
src/tools/miri/tests/many-seeds/tls-leak.rs
@@ -0,0 +1,13 @@
1
+//! Regression test for <https://github.com/rust-lang/rust/issues/123583>.
2
+use std::thread;
3
+
4
+pub(crate) fn with_thread_local() {
5
+ thread_local! { static X: Box<u8> = Box::new(0); }
6
+ X.with(|_x| {})
7
+}
8
9
+fn main() {
10
+ let j2 = thread::spawn(with_thread_local);
11
+ with_thread_local();
12
+ j2.join().unwrap();
13
0 commit comments