title: Using variadic templates to implement Get(Tuple) got "parameter packs not expanded with ‘...’" error
body: <p>I want to implement something like std::get(std::tuple), having a tuple class:</p>
  
  <pre><code>template&lt;typename ... Types&gt; class Tuple;
  template&lt;&gt; class Tuple&lt;&gt; {};
  template&lt;typename First, typename ... Rest&gt;
  class Tuple&lt;First, Rest...&gt;: private Tuple&lt;Rest...&gt; {
    First Member;
   public:
    Tuple(const First&amp; first, const Rest&amp; ... rest):
        Tuple&lt;Rest...&gt;(rest...), Member(first) {}
  
    const First&amp; Head() const {
      return Member;
    }
  
    const Tuple&lt;Rest...&gt;&amp; Tail() const {
      return *this;
    }
  };
  </code></pre>
  
  <p>I've also implemented a helper struct tuple_element.</p>
  
  <pre><code>template&lt;size_t I, class T&gt;
  struct tuple_element;
  
  template&lt;size_t I, class Head, class ... Tail&gt;
  struct tuple_element&lt;I, Tuple&lt;Head, Tail...&gt; &gt;:
      tuple_element&lt;I - 1, Tuple&lt;Tail...&gt; &gt; {};
  
  template&lt;class Head, class ... Tail&gt;
  struct tuple_element&lt;0, Tuple&lt;Head, Tail...&gt; &gt; {
    typedef Head type;
  };
  </code></pre>
  
  <p>But I can't realise how to implement Get(Tuple) function. I think I've tried everything.
  My last try:</p>
  
  <pre><code>template&lt;class T, class Head, class ... Tail&gt;
  T Get(size_t pos, const Tuple&lt;Head, Tail...&gt;&amp; t) {
    if (pos &gt; 0) {
      return Get&lt;T&gt;(pos - 1, t.Tail());
    }
    return t.Head();
  }
  template&lt;size_t Pos, class Head, class ... Tail&gt;
  typename tuple_element&lt;Pos, Tuple&lt;Head, Tail...&gt; &gt;::type
      Get(const Tuple&lt;Head, Tail...&gt;&amp; t) {
    return Get&lt;typename tuple_element&lt;Pos, Tuple&lt;Head, Tail...&gt; &gt;::type&gt;(Pos, t);
  }
  </code></pre>
  
  <p>But I got an error: parameter packs not expanded with ‘...’</p>
  
  <p>What am I doing wrong?</p>