title: Syntax for specialization of nested template class
body: <p>I'm trying to figure out the correct syntax for explicit specialization of a nested template class.  The following code will better illustrate:</p>
  
  <pre><code>struct Column_Major;
  struct Row_Major;
  
  template&lt;size_t rows, size_t cols, typename T, typename Allocator&gt;
  class Matrix
  {
  
      /* bunch of members */
      template &lt;typename storage = Column_Major&gt;
      class Iterator
      {
          /* bunch of members */
      };
  };
  </code></pre>
  
  <p>I'd like to write an explicit specialization for <code>template &lt;&gt; class Matrix&lt;...&gt;::Iterator&lt;Row_Major</code>, but the syntax is eluding me.  I have a suspicion that it is not possible to explicitly specialize the Iterator class without an explicit specialization of the containing class, Matrix.  But I would be very happy if there is a way to do this.</p>
  
  <p>I know I <em>could</em> make the Iterator class a separate class, not a member of the Matrix class, but having the classes nested as such allows me full access to the template parameters and datamebers of the Matrix class, which simplifies things.  I know I could work around this if I need to, but I'd first like to investigate and understand the possibilities for the nested approach.</p>
  
  <p>Thanks,
  Shmuel</p>