const values run-time evaluation
<p>The output of the following code:</p>

<pre><code>const int i= 1;
(int&amp;)i= 2;          // or:  const_cast&lt; int&amp;&gt;(i)= 2;
cout &lt;&lt; i &lt;&lt; endl;
</code></pre>

<p>is <strong>1</strong> (at least under VS2012)</p>

<p>My question:</p>

<ul>
<li>Is this behavior defined?</li>
<li>Would the compiler always use the defined value for constants?</li>
<li>Is it possible to construct an example where the compiler would use the value of the latest assignment?</li>
</ul>
