>>931
エラーになるよ

use std::{thread, time::Duration};

fn main() {
let v = vec![Box::new(1), Box::new(2)];
thread::spawn(|| {
thread::sleep(Duration::from_secs(100000));
let ptr = &v[1];
println!("{ptr}");
});
drop(v);
}

https://play.rust-lang.org/?version=stable&;mode=debug&edition=2021&gist=6ffcf2e259e138e27d653db6fdd4fc98