title: Struct with partial move errors
body: <p>I've got a simple struct and two instances of it as below:</p>
  
  <pre><code>#[derive(Debug)]
  struct User {
      first: String,
      last: String,
      age: u32,
  }
  
  let u1 = User {
      first: String::from("John"),
      last: String::from("Doe"),
      age: 22,
  };
  
  let u2 = User {
      first: String::from("Mary"),
      ..u1
  };
  
  println!("user: {:#?}", u1);
  </code></pre>
  
  <p>Error message:</p>
  
  <pre class="lang-none prettyprint-override"><code>error[E0382]: borrow of moved value: `u1`
    --&gt; src/main.rs:20:29
     |
  15 |       let u2 = User {
     |  ______________-
  16 | |         first: String::from("Mary"),
  17 | |         ..u1
  18 | |     };
     | |_____- value moved here
  19 | 
  20 |       println!("user: {:#?}", u1);
     |                               ^^ value borrowed here after partial move
     |
     = note: move occurs because `u1.last` has type `std::string::String`, which does not implement the `Copy` trait
  </code></pre>
  
  <p>I tried to revise it to <code>..&amp;u1</code> hoping it will pass the borrow check so that I could spread in the base struct (u1) to u2, but to no avail, wondering is it even possible for what I wanted to do here?</p>
  
  <p>I understand it's because <code>u1.last</code> is a <code>String</code>, hence needing to pass a reference, but I'm not sure how to make it work in this scenario.</p>