title: How to call the right constructor of a template type?
body: <p>In the following code, how can I make the commented line working in the same way as the line just above of it?</p>
  
  <p>I would like to make it a generic code, that call suitable constructor of a template <code>Type</code>.</p>
  
  <pre class="lang-cpp prettyprint-override"><code>#include &lt;string&gt;
  #include &lt;iostream&gt;
  
  template &lt;typename Type&gt;
  struct Class
  {
      Type data;
      Class(Type data) : data(data) { }
  };
  
  int main()
  {
      Class&lt;std::string&gt; a = std::string("abc");
      // Class&lt;std::string&gt; b = "abc";
      std::cout &lt;&lt; a.data &lt;&lt; std::endl;
      return 0;
  }
  </code></pre>