• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 // run-pass
2 
main()3 pub fn main() {
4     let mut i: Box<_> = Box::new(1);
5     // Should be a copy
6     let mut j = i.clone();
7     *i = 2;
8     *j = 3;
9     assert_eq!(*i, 2);
10     assert_eq!(*j, 3);
11 }
12