title: Template specialization for a set of types
body: <p>How do I specialize a template for a set of data types? For example:</p>
  <pre><code>template&lt;typename T&gt;
  inline T getRatio(T numer, T denom){
      return (numer/denom);
  }
  </code></pre>
  <p>I want to specialize it for a set of data types so it only works with <code>int</code>, <code>long</code>, <code>double</code> and <code>float</code>. So if the user would try to use this function with a <code>char</code> type, the compiler would throw error.</p>