empty vector allows push back first element of itself
<p>One friend of mine showed very simple example:</p>

<pre><code>#include &lt;vector&gt;

int main()
{
    vector&lt;int&gt; v;
    v.push_back( v[0] );

    return 0;
}
</code></pre>

<p>It compiles, without any warnings. Problems with templates should be detected at compile time. What is your explanation of this strange behavior?</p>
