title: Compare typedef is same type
body: <p>I am using C++ (not 11) and using some libraries which have different typedefs for integer data types. Is there any way I can assert that two typedefs are the same type? I've come up with the following solution myself.. is it safe?
  Thanks</p>
  
  <pre><code>template&lt;typename T&gt;
  struct TypeTest
  {
      static void Compare(const TypeTest&amp; other) {}
  };
  
  typedef unsigned long long UINT64;
  typedef unsigned long long UINT_64;
  typedef unsigned int UINT_32;
  
  int main()
  {
      TypeTest&lt;UINT64&gt;::Compare(TypeTest&lt;UINT64&gt;()); // pass
      TypeTest&lt;UINT64&gt;::Compare(TypeTest&lt;UINT_64&gt;()); // pass
      TypeTest&lt;UINT64&gt;::Compare(TypeTest&lt;UINT_32&gt;()); // fail
  }
  </code></pre>