title: no matching function for call to
body: <p>I've this code:</p>
  
  <pre><code>    class XMLNode
      {
          //...
          template &lt;typename T&gt;
          bool getValue(T&amp; t, const std::string&amp; path) const
          {
              if (empty())
              {
                  throw std::runtime_error("Empty node");
              }
              return nsXML::getValue(t, path, *node);
          }
  
          template &lt;typename T&gt;
          T getValue(const std::string&amp; path) const
          {
              if (empty())
              {
                  throw std::runtime_error("Empty node");
              }
              return nsXML::getValue&lt;T&gt;(path, *node);
          }
          //...
      };
  
  class XMLData
  {
      //...
      template &lt;typename T&gt;
      T getValue(const std::string&amp; path)
      {
          return XMLNode(&amp;mDocNode, 0).getValue(path); // ERROR LINE
      }
      //...
  };
  </code></pre>
  
  <p>And gives me error</p>
  
  <pre><code>no matching function for call to ‘nsXML::XMLNode::getValue(const string&amp;)’
  note: candidates are:
  note: template&lt;class T&gt; bool nsXML::XMLNode::getValue(T&amp;, const string&amp;) const
  note: template&lt;class T&gt; T nsXML::XMLNode::getValue(const string&amp;) const
  </code></pre>
  
  <p>Why does <code>g++</code> give me this error?</p>