title: Why does std::vector::get_allocator() return by-value?
body: <p>To my surprise, I got an error when trying to use <code>std::vector::get_allocator()</code> with an non-copyable allocator. Why does <code>std::vector::get_allocator()</code> return by-value and not by-reference?</p>
  
  <pre><code>template&lt;typename T&gt;
  class nc_allocator {
  public:
      using value_type = T;
  
      nc_allocator(nc_allocator const&amp;) = delete;
      nc_allocator&amp; operator=(nc_allocator const&amp;) = delete;
  
      // Other required members.
  };
  
  std::vector&lt;int, nc_allocator&lt;int&gt;&gt; v;
  // boom: use of deleted function
  //           'nc_allocator&lt;T&gt;::nc_allocator(const nc_allocator&lt;T&gt;&amp;) [with T = int]'
  v.get_allocator();
  </code></pre>