title: Why doesn't InterlockedCompareExchange return changed value?
body: <pre><code>LONG __cdecl InterlockedCompareExchange(
    __inout  LONG volatile *Destination,
    __in     LONG Exchange,
    __in     LONG Comparand
  );
  </code></pre>
  
  <blockquote>
    <p><strong>Return value</strong><br>
    The function returns the initial value of the Destination parameter.</p>
  </blockquote>
  
  <p>Just curious.<br>
  Why does InterlockedCompareExchange return <em>initial</em> value? Is there a reason that they designed so?</p>