title: What is the bit size of long on 64-bit Windows?
body: <p>Not to long ago, someone told me that <code>long</code> are not 64 bits on 64 bit machines and I should always use <code>int</code>. This did not make sense to me. I have seen docs (such as the one on Apple's official site) say that <code>long</code> are indeed 64 bits when compiling for a 64-bit CPU. I looked up what it was on 64-bit Windows and found </p>
  
  <blockquote>
    <ul>
    <li>Windows: <code>long</code> and <code>int</code> remain 32-bit in length, and special new data types
    are defined for 64-bit integers.</li>
    </ul>
  </blockquote>
  
  <p>(from <a href="http://web.archive.org/web/20080117221414/http://www.intel.com:80/cd/ids/developer/asmo-na/eng/197664.htm?page=2" rel="noreferrer">http://www.intel.com/cd/ids/developer/asmo-na/eng/197664.htm?page=2</a>)</p>
  
  <p>What should I use? Should I define something like <code>uw</code>, <code>sw</code> ((un)signed width) as a <code>long</code> if not on Windows, and otherwise do a check on the target CPU bitsize?</p>