You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

18 lines
230 B
Rust

use std::thread;
struct MyBox(u8);
unsafe impl Send for MyBox {}
unsafe impl Sync for MyBox {}
static A: MyBox = MyBox(22);
fn main() {
thread::spawn(move || {
A.0
});
thread::spawn(move || {
A.0
});
}