title: Determine type of argument
body: <p>Is it somehow possible to reflect the type of the argument of a function at compile time?</p>
  
  <p>So that</p>
  
  <pre><code>int b = add(3, 6)
  </code></pre>
  
  <p>Would result in a template instantiation in the form of</p>
  
  <pre><code>int add(int a, int b) { return a + b }
  </code></pre>
  
  <p>out of some however declared function template</p>
  
  <pre><code>A add(A a, B b) { return a + b }
  </code></pre>
  
  <p>I don't know if that is possible with templates they do not really seem to be made for heavy meta-programming.</p>