title: Can't assign -2147483648 to variable of type long long
body: <p>I'm compiling the code below and for some reason I can't assign -2147483648 to the variable which is 8 bytes long and signed.</p>
  
  <pre><code>long long x = -2147483648;
  </code></pre>
  
  <p>When I step over this line, the value of x is 2147483648 and the 'Watch' window in MS Visual Studio shows that the type of x is __int64. A sizeof(x) also returns 8.</p>
  
  <p>According to limit.h the limits for a signed long long are:</p>
  
  <pre><code>#define LLONG_MAX     9223372036854775807i64       /* maximum signed long long int value */
  #define LLONG_MIN   (-9223372036854775807i64 - 1)  /* minimum signed long long int value */
  </code></pre>
  
  <p>and:</p>
  
  <pre><code>/* minimum signed 64 bit value */
  #define _I64_MIN    (-9223372036854775807i64 - 1)
  /* maximum signed 64 bit value */
  #define _I64_MAX      9223372036854775807i64
  </code></pre>
  
  <p>I just don't get it!!!</p>
  
  <p>Can somebody please shed some light on this?</p>