title: Why is the size of a template 1 Byte in C++?
body: <p>With <code>using</code>, an alias for a type can be defined and a unit of this type has the same size like an original instantation (1). A template however only weights 1 byte (2).</p>
  <pre><code>using aliasOfInt = int;
  
  template&lt;typename T&gt;
  struct intWrapper {
      using wrappedAliasOfInt = T;
  };
  
  
  int main() {
      // (1) --&gt; 4B
      std::cout &lt;&lt; &quot;sizeof(aliasOfInt)      = &quot; &lt;&lt; sizeof(aliasOfInt) &lt;&lt; std::endl;
  
      // (2) --&gt; 1B
      std::cout &lt;&lt; &quot;sizeof(intAliasWrapper) = &quot; &lt;&lt; sizeof(intWrapper&lt;int&gt;) &lt;&lt; std::endl;
  }
  </code></pre>
  <p>In (2), is there a real type compiled or why is this only 1B?</p>
  <p><a href="http://cpp.sh/3eiry" rel="nofollow noreferrer">http://cpp.sh/3eiry</a></p>