title: what happens if I assign "reference to vector" to "vector"
body: <p>Friends
  I happened to mistakenly write this piece of code:</p>
  
  <pre><code>const std::vector&lt;int&gt; &amp;FunctionReturnReferenceToVector();
  
  vector&lt;int&gt; tmp;
  /*do something else*/
  tmp = FunctionReturnReferenceToVector();
  </code></pre>
  
  <p>The compiler didn't complain, and my program ends successfully with correct result.</p>
  
  <p>May I ask what exactly happened during the whole process?</p>
  
  <p>I used CLion IDE and Clang as compiler.</p>