2 #![allow(unused_must_use)]
3 // Test that we are able to reinitialize box with moved referent
4 static mut ORDER: [usize; 3] = [0, 0, 0];
5 static mut INDEX: usize = 0;
12 ORDER[INDEX] = self.0;
26 let mut x = Box::new(Dropee(1));
27 *x; // move out from `*x`
29 *x = Dropee(3); // re-initialize `*x`
32 assert_eq!(ORDER, [1, 2, 3]);