title: Assigning an assignment in C++
body: <p>I'm reading a piece of code which does this</p>
  
  <pre><code>void *ptr_to_something = (void*)0x23; // I made this up, it's just a pointer to something
  void *addr;
  void *dst =  (void*)(addr = ptr_to_something); // This is the line that confuses me
  </code></pre>
  
  <p>it seems to assign a pointer to something to another pointer of the same thing. And that's okay.. but then the result is enclosed in parenthesis, cast to the same thing and somehow reassigned to a third pointer to the same thing.</p>
  
  <p>Is this valid C++ at all? Is it guaranteed that assigning the result of an assignment yields the same assigned object?</p>