title: default argument for template parameter for class enclosing
body: <p>code:</p>
  
  <pre><code>template &lt;typename element_type, typename container_type = std::deque&lt;element_type&gt; &gt;
  class stack
  {
      public:
          stack() {}
          template &lt;typename CT&gt;
          stack(CT temp) : container(temp.begin(), temp.end()) {}
          bool empty();
     private:
         container_type container;
  };
  
  template &lt;typename element_type, typename container_type = std::deque&lt;element_type&gt; &gt;
  bool stack&lt;element_type, container_type&gt;::empty()
  {
      return container.empty();
  }
  </code></pre>
  
  <p>When I compile it gives the error.</p>
  
  <blockquote>
    <p>default argument for template parameter for  class enclosing <code>'bool stack&lt;element_type,container_type&gt;::empty()'</code></p>
  </blockquote>
  
  <p>Why is the compiler complaining and how can I make it work?</p>