title: Typedef compilation error on function overload
body: <p>Why can't I compile the program 1 when the the program 2 is working fine ? Why is it's behavior different?</p>
  
  <p>Program 1:</p>
  
  <pre><code>#include &lt;iostream&gt;
  typedef int s1;
  typedef int s2;
  
  void print(s1 a){ std::cout &lt;&lt; "s1\n"; }
  void print(s2 a){ std::cout &lt;&lt; "s2\n"; }
  
  int main() {
          s1 a;
          s2 b;
  
          print(a);
          print(b);
  
          return 0;
  }
  </code></pre>
  
  <p>Program 2:</p>
  
  <pre><code>#include &lt;iostream&gt;
  typedef struct{int a;} s1;
  typedef struct{int a;} s2;
  
  void print(s1 a){ std::cout &lt;&lt; "s1\n"; }
  void print(s2 a){ std::cout &lt;&lt; "s2\n"; }
  int main() {
          s1 a;
          s2 b;
  
          print(a);
          print(b);
  
          return 0;
  }
  </code></pre>
  
  <p>This is a bug reproduce from templated class, How can I verify if two template argument are from the same type (in the case of the program 1)</p>