title: strange error: use of deleted function 'std::unique_ptr<_Tp, _Dp>::unique_ptr when no pointers really created
body: <p>I have a class, which looks like that:</p>
  
  <pre><code>    template&lt;typename T&gt;
      using VectorPtr=std::vector&lt;std::unique_ptr&lt;T&gt;&gt;;
  
      template&lt;typename T&gt;
      using VectorRawPtr=std::vector&lt;T*&gt;;
  
      class ItemsSet{ // &lt;-- Compiler say this line contans an error 0_o ?
      public:
            ItemsSet(VectorPtr&lt;Item&gt;&amp; items);  
  
            ~ItemsSet() = default;
  
             VectorRawPtr&lt;Item&gt; GetItems();
  
             VectorRawPtr&lt;Item&gt; GetSuitableItemsForPeriod(const IPeriod &amp;period);
  
             double CalculateTotal();
      private:
         VectorPtr&lt;Item&gt; _items;
      };
  </code></pre>
  
  <p>constructor looks like:</p>
  
  <pre><code>ItemsSet::ItemsSet(VectorPtr&lt;Item&gt; &amp; items) {
       for(auto &amp;itm: items){
          _items.emplace_back(std::move(itm));
       }
  }
  </code></pre>
  
  <p>however this code isn't compiled and failed with error:</p>
  
  <pre><code>/usr/lib/gcc/x86_64-pc-cygwin/5.4.0/include/c++/bits/stl_construct.h: In instantiation of 'void std::_Construct(_T1*, _Args&amp;&amp; ...) [with _T1 = std::unique_ptr&lt;Item, std::default_delete&lt;Item&gt; &gt;; _Args = {const std::unique_ptr&lt;Item, std::default_delete&lt;Item&gt; &gt;&amp;}]':
  /usr/lib/gcc/x86_64-pc-cygwin/5.4.0/include/c++/bits/stl_uninitialized.h:75:18:   required from 'static _ForwardIterator std::__uninitialized_copy&lt;_TrivialValueTypes&gt;::__uninit_copy(_InputIterator, _InputIterator, _ForwardIterator) [with _InputIterator = __gnu_cxx::__normal_iterator&lt;const std::unique_ptr&lt;Item, std::default_delete&lt;Item&gt; &gt;*, std::vector&lt;std::unique_ptr&lt;Item, std::default_delete&lt;Item&gt; &gt;, std::allocator&lt;std::unique_ptr&lt;Item, std::default_delete&lt;Item&gt; &gt; &gt; &gt; &gt;; _ForwardIterator = std::unique_ptr&lt;Item, std::default_delete&lt;Item&gt; &gt;*; bool _TrivialValueTypes = false]'
  /usr/lib/gcc/x86_64-pc-cygwin/5.4.0/include/c++/bits/stl_uninitialized.h:126:15:   required from '_ForwardIterator std::uninitialized_copy(_InputIterator, _InputIterator, _ForwardIterator) [with _InputIterator = __gnu_cxx::__normal_iterator&lt;const std::unique_ptr&lt;Item, std::default_delete&lt;Item&gt; &gt;*, std::vector&lt;std::unique_ptr&lt;Item, std::default_delete&lt;Item&gt; &gt;, std::allocator&lt;std::unique_ptr&lt;Item, std::default_delete&lt;Item&gt; &gt; &gt; &gt; &gt;; _ForwardIterator = std::unique_ptr&lt;Item, std::default_delete&lt;Item&gt; &gt;*]'
  /usr/lib/gcc/x86_64-pc-cygwin/5.4.0/include/c++/bits/stl_uninitialized.h:281:37:   required from '_ForwardIterator std::__uninitialized_copy_a(_InputIterator, _InputIterator, _ForwardIterator, std::allocator&lt;_Tp&gt;&amp;) [with _InputIterator = __gnu_cxx::__normal_iterator&lt;const std::unique_ptr&lt;Item, std::default_delete&lt;Item&gt; &gt;*, std::vector&lt;std::unique_ptr&lt;Item, std::default_delete&lt;Item&gt; &gt;, std::allocator&lt;std::unique_ptr&lt;Item, std::default_delete&lt;Item&gt; &gt; &gt; &gt; &gt;; _ForwardIterator = std::unique_ptr&lt;Item, std::default_delete&lt;Item&gt; &gt;*; _Tp = std::unique_ptr&lt;Item, std::default_delete&lt;Item&gt; &gt;]'
  /usr/lib/gcc/x86_64-pc-cygwin/5.4.0/include/c++/bits/stl_vector.h:322:31:   required from 'std::vector&lt;_Tp, _Alloc&gt;::vector(const std::vector&lt;_Tp, _Alloc&gt;&amp;) [with _Tp = std::unique_ptr&lt;Item, std::default_delete&lt;Item&gt; &gt;; _Alloc = std::allocator&lt;std::unique_ptr&lt;Item, std::default_delete&lt;Item&gt; &gt; &gt;]'
  /cygdrive/d/code/itemSet.h:4:19:   required from here
  /usr/lib/gcc/x86_64-pc-cygwin/5.4.0/include/c++/bits/stl_construct.h:75:7: error: use of deleted function 'std::unique_ptr&lt;_Tp, _Dp&gt;::unique_ptr(const std::unique_ptr&lt;_Tp, _Dp&gt;&amp;) [with _Tp = Item; _Dp = std::default_delete&lt;Item&gt;]'
       { ::new(static_cast&lt;void*&gt;(__p)) _T1(std::forward&lt;_Args&gt;(__args)...); }
  </code></pre>
  
  <p>Could anyone explain me what I'm doing wrong and how could I fix my problem?</p>