title: Error for typedef in header file using std::pair class
body: <p>I'm writing SkipList implementation in a STD-like way: using allocators, iterators, etc. Whole class is done and is working but right now I'm trying to write a header file for the class I made. My current header file content is:</p>
  
  <pre><code>template&lt;class _MySkiplist&gt;
      class _Skiplist_const_iterator;
  
  template&lt;class _MySkiplist&gt;
      class _Skiplist_iterator;
  
  template&lt;class _Kty,
      class _Pr,
      class _Alloc&gt;
          class skiplist
          {
              typedef skiplist&lt;_Kty, _Pr, _Alloc&gt; _Myt;
  
              typedef typename _Skiplist_const_iterator&lt;_Myt&gt; const_iterator;
              typedef typename _Skiplist_iterator&lt;_Myt&gt; iterator;
  
              typedef typename _Alloc::size_type size_type;
  
              typedef std::pair&lt;iterator, iterator&gt; _Pairii;
              typedef std::pair&lt;iterator, bool&gt; _Pairib;
  
              skiplist();
              skiplist(const _Alloc&amp; _Al);
              skiplist(const _Pr&amp; _Pred);
              skiplist(const _Pr&amp; _Pred, const _Alloc&amp; _Al);
              ~skiplist();
  
              iterator begin();
              const_iterator begin() const;
              iterator end();
              const_iterator end() const;
  
              size_type size() const;
              size_type max_size() const;
              bool empty() const;
  
          //  _Pairib insert(_Kty&amp; _val);
          //  _Pairib  insert(const _Kty&amp; _val);
              size_type erase(const _Kty&amp; x);
              void clear();
  
              _Pr key_comp() const;
              _Pr value_comp() const;
  
              iterator find(const _Kty&amp; x);
              size_type count(const _Kty&amp; x) const;
              iterator lower_bound(const _Kty&amp; x) const;
              iterator upper_bound(const _Kty&amp; x) const;
      //      _Pairii equal_range(const _Kty&amp; x) const;
  
              _Alloc get_allocator() const;
          };
  </code></pre>
  
  <p>I'm keeping getting following errors:</p>
  
  <blockquote>
    <p>Error 1   error C2143: syntax error : missing ';' before '&lt;'</p>
    
    <p>Error 3   error C2238: unexpected token(s) preceding ';'</p>
    
    <p>Error 5   error C2238: unexpected token(s) preceding ';'</p>
    
    <p>Error 2   error C4430: missing type specifier - int assumed. Note: C++
    does not support default-int</p>
  </blockquote>
  
  <p>All these errors refers to following two lines in header file: </p>
  
  <pre><code>        typedef std::pair&lt;iterator, iterator&gt; _Pairii;
          typedef std::pair&lt;iterator, bool&gt; _Pairib;
  </code></pre>
  
  <p>I'm running out of ideas why the errors occur.</p>